cc.redberry.core.context.defaults
Class LatinUpperCaseConverter
- java.lang.Object
-
- cc.redberry.core.context.defaults.LatinUpperCaseConverter
-
- All Implemented Interfaces:
- IndexSymbolConverter
public final class LatinUpperCaseConverter extends java.lang.Object implements IndexSymbolConverter
IndexSymbolConverterfor latin upper case letters.- Since:
- 1.0
-
-
Field Summary
Fields Modifier and Type Field and Description static LatinUpperCaseConverterINSTANCESingleton instancestatic byteTYPEIndex type = 1
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description booleanapplicableToSymbol(java.lang.String symbol)Returns true if this converter can convert index string to integer representationintgetCode(java.lang.String symbol)Returns integer representation from specified string representation of single index.java.lang.StringgetSymbol(int code, OutputFormat mode)Returns string representation from specified integer representation of single index in the specifiedoutputFormat.bytegetType()Returns the type of indices, which this converter processes.intmaxNumberOfSymbols()Returns the number of symbols, supported by this converter.
-
-
-
Field Detail
-
TYPE
public static final byte TYPE
Index type = 1- See Also:
- Constant Field Values
-
INSTANCE
public static final LatinUpperCaseConverter INSTANCE
Singleton instance
-
-
Method Detail
-
applicableToSymbol
public boolean applicableToSymbol(java.lang.String symbol)
Description copied from interface:IndexSymbolConverterReturns true if this converter can convert index string to integer representation- Specified by:
applicableToSymbolin interfaceIndexSymbolConverter- Parameters:
symbol- index string representation- Returns:
- true, if this converter can convert index string to integer representation
-
getCode
public int getCode(java.lang.String symbol)
Description copied from interface:IndexSymbolConverterReturns integer representation from specified string representation of single index.- Specified by:
getCodein interfaceIndexSymbolConverter- Parameters:
symbol- index string representation- Returns:
- index integer representation
-
getSymbol
public java.lang.String getSymbol(int code, OutputFormat mode) throws IndexConverterExceptionDescription copied from interface:IndexSymbolConverterReturns string representation from specified integer representation of single index in the specifiedoutputFormat.- Specified by:
getSymbolin interfaceIndexSymbolConverter- Parameters:
code- index integer representationmode- output format- Returns:
- string representation of specified integer index, according to the specified output format
- Throws:
IndexConverterException- if code does not corresponds to this converter- See Also:
OutputFormat
-
getType
public byte getType()
Description copied from interface:IndexSymbolConverterReturns the type of indices, which this converter processes. The type value is unique for each converter.- Specified by:
getTypein interfaceIndexSymbolConverter- Returns:
- 1
-
maxNumberOfSymbols
public int maxNumberOfSymbols()
Description copied from interface:IndexSymbolConverterReturns the number of symbols, supported by this converter. For exampleLatinLowerCaseConvertersupports 26 symbols (Latin alphabet size).- Specified by:
maxNumberOfSymbolsin interfaceIndexSymbolConverter- Returns:
- the number of symbols, supported by this converter
-
-
DataMelt 3.0 © DataMelt by jWork.ORG