001package org.kuali.ole.utility.callnumber; 002 003 004/** 005 * Created with IntelliJ IDEA. 006 * User: ? 007 * Date: 20/2/13 008 * Time: 7:30 PM 009 * To change this template use File | Settings | File Templates. 010 */ 011public class DDCallNumber extends AbstractCallNumber implements CallNumber { 012 private static DDCallNumber ourInstance = null; 013 014 public static DDCallNumber getInstance() { 015 if (null == ourInstance) { 016 ourInstance = new DDCallNumber(); 017 } 018 return ourInstance; 019 } 020 021 public String getSortableKey(String callNumber) { 022 String normalizedCallNumber = CallNumUtils.getDeweyShelfKey(callNumber); 023 return normalizedCallNumber; 024 } 025 026 public boolean isValid(String callNumber) { 027 boolean isValid = CallNumUtils.isValidDewey(callNumber); 028 if (!isValid) { 029 isValid = CallNumUtils.isValidDeweyWithCutter(callNumber); 030 } 031 return isValid; 032 } 033}