View Javadoc
1   package org.kuali.ole.utility.callnumber;
2   
3   
4   /**
5    * Created with IntelliJ IDEA.
6    * User: ?
7    * Date: 20/2/13
8    * Time: 7:30 PM
9    * To change this template use File | Settings | File Templates.
10   */
11  public class DDCallNumber extends AbstractCallNumber implements CallNumber {
12      private static DDCallNumber ourInstance = null;
13  
14      public static DDCallNumber getInstance() {
15          if (null == ourInstance) {
16              ourInstance = new DDCallNumber();
17          }
18          return ourInstance;
19      }
20  
21      public String getSortableKey(String callNumber) {
22          String normalizedCallNumber = CallNumUtils.getDeweyShelfKey(callNumber);
23          return normalizedCallNumber;
24      }
25  
26      public boolean isValid(String callNumber) {
27          boolean isValid = CallNumUtils.isValidDewey(callNumber);
28          if (!isValid) {
29              isValid = CallNumUtils.isValidDeweyWithCutter(callNumber);
30          }
31          return isValid;
32      }
33  }