jpos.util
Interface JposProperties.MultiProperty

All Known Implementing Classes:
DefaultProperties.MultiProp
Enclosing class:
JposProperties

public static interface JposProperties.MultiProperty

Speficies an interface used for returning multi properties. That is properties that are named like .x where x = 0, 1, ...x

Since:
1.3 (Washington DC 2001 meeting)
Author:
E. Michael Maximilien (maxim@us.ibm.com)

Method Summary
 java.lang.String getBasePropertyName()
           
 int getNumberOfProperties()
           
 java.util.Iterator getPropertyNames()
           
 java.lang.String getPropertyString(int i)
           
 java.lang.String getPropertyString(java.lang.String propName)
           
 java.util.Iterator getPropertyValues()
           
 java.util.Iterator getSortedPropertyNames()
           
 int propertyNumber(java.lang.String propName)
           
 

Method Detail

propertyNumber

public int propertyNumber(java.lang.String propName)
                   throws java.lang.IllegalArgumentException
Parameters:
propName - the property name to get the number of
Returns:
the number of this property name that is for property .x returns x
Throws:
java.lang.IllegalArgumentException - if the property name does not follow the .x name pattern

getBasePropertyName

public java.lang.String getBasePropertyName()
Returns:
the base property name for this multi-property that is the name w/o the number suffix

getPropertyNames

public java.util.Iterator getPropertyNames()
Returns:
an iterator of the property names for this multi-property

getSortedPropertyNames

public java.util.Iterator getSortedPropertyNames()
Returns:
an iterator of the property names alphabetically sorted for this multi-property

getPropertyValues

public java.util.Iterator getPropertyValues()
Returns:
an iterator of the property values for this multi-property

getPropertyString

public java.lang.String getPropertyString(java.lang.String propName)
Parameters:
propName - the full property name .x
Returns:
the value for this property from the full property name

getPropertyString

public java.lang.String getPropertyString(int i)
                                   throws java.lang.IllegalArgumentException
Parameters:
number - suffix for the property name
Returns:
the value for this property from the full property name
Throws:
java.lang.IllegalArgumentException - if the i negative

getNumberOfProperties

public int getNumberOfProperties()
Returns:
the number of properties defined in this multi-property


This API and code belongs to the JavaPOS committee please see LISCENCE file for details