Follow the links below to browse sample Javadoc for MJ classes and tools, including the MJ Runtime Library.

 

Package: com.arsi.mj.maprpt.enums  previous next contents

Provides for definition of an enumeration used by an entity.

Classes and Interfaces
CharacterKeyEnumMapping Defines String-value enumeration and maps single-character key to the enumerated constants.
IMaprptEnumDef Provides for definition of an enumeration used by an entity.
IntegerKeyEnumMapping Defines String-value enumeration and maps integer keys to the enumerated constants.
IntegerRangeKeyEnumMapping Defines String-value enumeration and maps ranges of integers (e.g., 100-200) to the enumerated constants.
LineTypeEnumMapping Defines String-value enumeration and maps single-character Mapper line types to the enumerated constants.
ReportNumberEnumMapping Defines String-value enumeration and maps Mapper report numbers to the enumerated constants.
ReportRangeEnumMapping Defines String-value enumeration and maps ranges of Mapper report numbers (e.g., 100-200) to the enumerated constants.
StringKeyEnumMapping Defines String-value enumeration and maps String key to the enumerated constants.

Class: CharacterKeyEnumMapping   next package

Defines String-value enumeration and maps single-character key to the enumerated constants. An instance of this class is typically instantiated as a Spring bean, where the enumerated constants and keys are defined as Properties.
Treat this class as "thread-safe" when used as intended, since an instance is not modified after initialization, but "thread-hostile" if changes are made after creating the class by concurrent threads since none of the methods are synchronized.

public class com.arsi.mj.maprpt.enums.CharacterKeyEnumMapping
  extends java.lang.Object
  implements com.arsi.mj.maprpt.enums.IMaprptEnumDef
Constructors
public CharacterKeyEnumMapping()
Methods
public void defineEnum(java.lang.Character aKey, com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant aConstant)
public java.util.Map enums()
public java.lang.String getEnumClassName()
public java.lang.Character keyOf(java.lang.String aConstantValue)
Set the name of the enumeration class, including package.
Parameters:
aClassName - full name of enumeration class, e.g., "com.acme.myapp.entity.OrderStatusEnum".
public void setEnumClassName(java.lang.String aClassName)
Property entries must be of the form key=symbol->value.
See Also:
com.arsi.mj.maprpt.enums.IMaprptEnumDef#setEnumsFromProperties(java.util.Properties)
public void setEnumsFromProperties(java.util.Properties aProps)
public com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant valueOf(java.lang.Character aKey)

Interface: IMaprptEnumDef   previous next package

Provides for definition of an enumeration used by an entity. The enumeration has a class name (this class will extend org.hibernate.usertype.EnhancedUserType) and a symbol name and value for each of the enumerated constants. An arbitrary key value is mapped to and from an enumerated constant; if there is no other key to map, the value of the enumerated constant may be used as the key. For example:
   true-key "cherry" = SymbolicConstant(RED, "red") OR
   pseudo-key "red" = SymbolicConstant(RED, "red")
 
Parameters:
<C> - type of constant value (e.g., String, Integer).
<K> - type of key (e.g., String, Character, Integer).
public interface com.arsi.mj.maprpt.enums.IMaprptEnumDef
Inner Class SymbolicConstant
Defines a symbol name and value for an enumerated constant.
Parameters:
<C> - type of constant value (e.g., String, Integer).
public static class com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant
  extends java.lang.Object
public final java.lang.String name()
public final java.lang.Object value()
Methods
Define an enumerated constant and specify it's associated key.
Parameters:
aKey - key associated with enumerated constant.
aConstant - the enumerated constant to define.
public void defineEnum(java.lang.Object aKey, com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant aConstant)
Return the enumerated constants defined by this class instance, mapped to the keys associated with the enumerated constants.
Returns:
map of keys to enumerated constants.
public java.util.Map enums()
Get the name of the enumeration class, including the package name.
Returns:
full name of the enumeration class.
public java.lang.String getEnumClassName()
Get the key(s) associated with the specified enumerated constant.
Parameters:
aConstantValue - enumerated constant believed to be associated with one or more keys.
Returns:
key(s) associated with enumerated constant, or empty array if none.
public java.lang.Object keyOf(java.lang.Object aConstantValue)
Define enumerated constants and associated keys from a properties object. Each properties entry must be in one of two valid formats:
  • symbol=value
  • key=symbol->value

In the first format, the key is assigned from the value, i.e., the key for purposes of this class is the constant value that appears after the equal sign.

In the second format, the key is in the expected position for a properties entry (before the equal sign), but the data after the equal sign has two parts (enumerated symbol and constant value) which are separated by ->.

Parameters:
aProps - a properties object in one of the described formats.
public void setEnumsFromProperties(java.util.Properties aProps)
Get the enumerated constant associated with the specified key.
Parameters:
aKey - key believed to be associated an enumerated constant.
Returns:
enumerated constant associated with key, or NULL if none.
public com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant valueOf(java.lang.Object aKey)

Class: IntegerKeyEnumMapping   previous next package

Defines String-value enumeration and maps integer keys to the enumerated constants. An instance of this class is typically instantiated as a Spring bean, where the enumerated constants and keys are defined as Properties.
Treat this class as "thread-safe" when used as intended, since an instance is not modified after initialization, but "thread-hostile" if changes are made after creating the class by concurrent threads since none of the methods are synchronized.

public class com.arsi.mj.maprpt.enums.IntegerKeyEnumMapping
  extends java.lang.Object
  implements com.arsi.mj.maprpt.enums.IMaprptEnumDef
Constructors
public IntegerKeyEnumMapping()
Methods
public void defineEnum(java.lang.Integer aKey, com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant aConstant)
public java.util.Map enums()
public java.lang.String getEnumClassName()
public java.lang.Integer keyOf(java.lang.String aConstantValue)
Set the name of the enumeration class, including package.
Parameters:
aClassName - full name of enumeration class, e.g., "com.acme.myapp.entity.OrderStatusEnum".
public void setEnumClassName(java.lang.String aClassName)
Property entries must be of the form key=symbol->value.
See Also:
com.arsi.mj.maprpt.enums.IMaprptEnumDef#setEnumsFromProperties(java.util.Properties)
public void setEnumsFromProperties(java.util.Properties aProps)
public com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant valueOf(java.lang.Integer aKey)

Class: IntegerRangeKeyEnumMapping   previous next package

Defines String-value enumeration and maps ranges of integers (e.g., 100-200) to the enumerated constants. An instance of this class is typically instantiated as a Spring bean, where the enumerated constants and keys are defined as Properties.
Treat this class as "thread-safe" when used as intended, since an instance is not modified after initialization, but "thread-hostile" if changes are made after creating the class by concurrent threads since none of the methods are synchronized.

public class com.arsi.mj.maprpt.enums.IntegerRangeKeyEnumMapping
  extends java.lang.Object
  implements com.arsi.mj.maprpt.enums.IMaprptEnumDef
Constructors
public IntegerRangeKeyEnumMapping()
Methods
public void defineEnum(com.arsi.mj.config.atoms.IntegerRange aKey, com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant aConstant)
public java.util.Map enums()
public java.lang.String getEnumClassName()
public com.arsi.mj.config.atoms.IntegerRange keyOf(java.lang.String aConstantValue)
Set the name of the enumeration class, including package.
Parameters:
aClassName - full name of enumeration class, e.g., "com.acme.myapp.entity.OrderStatusEnum".
public void setEnumClassName(java.lang.String aClassName)
Property entries must be of the form lowerBound-upperBound=symbol->value, e.g., "100-200=RED->r". When specifying properties in a Spring XML file, avoid whitespace on either side of the equal sign (=) and on either side of the hyphen (-) that separates the lower and upper bounds.
See Also:
com.arsi.mj.maprpt.enums.IMaprptEnumDef#setEnumsFromProperties(java.util.Properties)
public void setEnumsFromProperties(java.util.Properties aProps)
Get the enumerated constant associated with the specified key.
Parameters:
aKey - integer key believed to be within one of the ranges associated an enumerated constant.
Returns:
enumerated constant associated with key, or NULL if none.
public com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant valueOf(java.lang.Integer aKey)
public com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant valueOf(com.arsi.mj.config.atoms.IntegerRange aKey)

Class: LineTypeEnumMapping   previous next package

Defines String-value enumeration and maps single-character Mapper line types to the enumerated constants. An instance of this class is typically instantiated as a Spring bean, where the enumerated constants and keys are defined as Properties.
Treat this class as "thread-safe" when used as intended, since an instance is not modified after initialization, but "thread-hostile" if changes are made after creating the class by concurrent threads since none of the methods are synchronized.

public class com.arsi.mj.maprpt.enums.LineTypeEnumMapping
  extends com.arsi.mj.maprpt.enums.CharacterKeyEnumMapping
Constructors
public LineTypeEnumMapping()

Class: ReportNumberEnumMapping   previous next package

Defines String-value enumeration and maps Mapper report numbers to the enumerated constants. An instance of this class is typically instantiated as a Spring bean, where the enumerated constants and keys are defined as Properties.
Treat this class as "thread-safe" when used as intended, since an instance is not modified after initialization, but "thread-hostile" if changes are made after creating the class by concurrent threads since none of the methods are synchronized.

public class com.arsi.mj.maprpt.enums.ReportNumberEnumMapping
  extends com.arsi.mj.maprpt.enums.IntegerKeyEnumMapping
Constructors
public ReportNumberEnumMapping()

Class: ReportRangeEnumMapping   previous next package

Defines String-value enumeration and maps ranges of Mapper report numbers (e.g., 100-200) to the enumerated constants. An instance of this class is typically instantiated as a Spring bean, where the enumerated constants and keys are defined as Properties.
Treat this class as "thread-safe" when used as intended, since an instance is not modified after initialization, but "thread-hostile" if changes are made after creating the class by concurrent threads since none of the methods are synchronized.

public class com.arsi.mj.maprpt.enums.ReportRangeEnumMapping
  extends com.arsi.mj.maprpt.enums.IntegerRangeKeyEnumMapping
Constructors
public ReportRangeEnumMapping()

Class: StringKeyEnumMapping   previous package

Defines String-value enumeration and maps String key to the enumerated constants. An instance of this class is typically instantiated as a Spring bean, where the enumerated constants and keys are defined as Properties.
Treat this class as "thread-safe" when used as intended, since an instance is not modified after initialization, but "thread-hostile" if changes are made after creating the class by concurrent threads since none of the methods are synchronized.

public class com.arsi.mj.maprpt.enums.StringKeyEnumMapping
  extends java.lang.Object
  implements com.arsi.mj.maprpt.enums.IMaprptEnumDef
Constructors
public StringKeyEnumMapping()
Methods
public void defineEnum(java.lang.String aKey, com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant aConstant)
public java.util.Map enums()
public java.lang.String getEnumClassName()
public java.lang.String keyOf(java.lang.String aConstantValue)
Set the name of the enumeration class, including package.
Parameters:
aClassName - full name of enumeration class, e.g., "com.acme.myapp.entity.OrderStatusEnum".
public void setEnumClassName(java.lang.String aClassName)
Property entries must be of the form key=symbol->value.
See Also:
com.arsi.mj.maprpt.enums.IMaprptEnumDef#setEnumsFromProperties(java.util.Properties)
public void setEnumsFromProperties(java.util.Properties aProps)
public com.arsi.mj.maprpt.enums.IMaprptEnumDef.SymbolicConstant valueOf(java.lang.String aKey)