|
| Foundation |
|
| |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||
com.sas.services.util.AttributeMap
@SASScope(value="ALL") @BinaryCompatibilityOnly public class AttributeMap
Represents the name/value pairs. A name/value can be specified as a name, a name and a value, or a name and multiple values.
Name/value pairs are used by the Publish services to provide user or application control information describing the result package or entry. Name/values can be associated with a result package, or with individual entries within the result package.
| Constructor Summary | |
|---|---|
AttributeMap()
Constructor. |
|
| Method Summary | |
|---|---|
void |
addAttribute(java.lang.String name,
java.lang.String value)
Add a value to existing name/value pair. |
static boolean |
applyFilter(java.lang.String filter,
AttributeMapInterface attr)
Apply a filter string to the specified name/value pairs to determine if there is a match. |
static java.lang.String |
buildValue(java.lang.String[] values)
Takes the values of a name/value pair, and builds the appropriate value String. |
java.lang.String |
getAttribute(java.lang.String name)
Get the value for the specified name. |
java.lang.String[] |
getAttributes(java.lang.String name)
Get all the values for the specified name. |
java.lang.String[] |
listAttributeNames()
Returns an array of all the names. |
static AttributeMapInterface |
parseNameValuePairs(AttributeMapInterface attrMap,
java.lang.String nameValuePairs)
Parses a name/value pairs string. |
static AttributeMapInterface |
parseValues(AttributeMapInterface attrMap,
java.lang.String name,
java.lang.String values)
Parses a name/value pairs string. |
void |
setAttribute(java.lang.String name,
java.lang.String value)
Set the name/value pair. |
| Constructor Detail |
|---|
public AttributeMap()
throws java.rmi.RemoteException
java.rmi.RemoteException - if unable to export a remote object to the RMI
system.| Method Detail |
|---|
public java.lang.String getAttribute(java.lang.String name)
throws java.rmi.RemoteException
getAttribute in interface AttributeMapInterfacename - The name portion of the name/value pair.
String The value.
java.rmi.RemoteException - If a network anomaly is encountered.
public java.lang.String[] getAttributes(java.lang.String name)
throws java.rmi.RemoteException
getAttributes in interface AttributeMapInterfacename - The name portion of the name/value pair.
String[] An array of all values for the specified
name.
java.rmi.RemoteException - If a network anomaly is encountered.
public void setAttribute(java.lang.String name,
java.lang.String value)
throws java.rmi.RemoteException,
java.lang.IllegalArgumentException
setAttribute in interface AttributeMapInterfacename - The name portion of the name/value pair.value - The value portion of the name/value pair. If this value is
null, any existing value(s) are removed for the name/value pair.
java.lang.IllegalArgumentException - If a null or blank name is
specified.
java.rmi.RemoteException - If a network anomaly is encountered.
public void addAttribute(java.lang.String name,
java.lang.String value)
throws java.rmi.RemoteException,
java.lang.IllegalArgumentException
setAttribute(String, String). The order is preserved between
addAttribute and getAttributes(String).
addAttribute in interface AttributeMapInterfacename - The name portion of the name/value pair.value - The value portion of the name/value pair.
java.lang.IllegalArgumentException - If a null or blank name is
specified.
java.rmi.RemoteException - If a network anomaly is encountered.
public java.lang.String[] listAttributeNames()
throws java.rmi.RemoteException
listAttributeNames in interface AttributeMapInterfaceSet An array of all the names.
java.rmi.RemoteException - If a network anomaly is encountered.
public static AttributeMapInterface parseNameValuePairs(AttributeMapInterface attrMap,
java.lang.String nameValuePairs)
throws ParseException
attrMap - The AttributeMapInterface to continue to build with the
parsed name/value pairs. This may be null. If
null, a new attribute map will be created and
returned. If not null, the existing map will be
updated and returned.nameValuePairs - The name/value string to parse.
ParseException - If an error occurs during parsing.
public static AttributeMapInterface parseValues(AttributeMapInterface attrMap,
java.lang.String name,
java.lang.String values)
throws ParseException
attrMap - The AttributeMapInterface to continue to build with the
parsed name/value pairs. This may be null. If
null, a new attribute map will be created and
returned. If not null, the existing map will be
updated and returned.name - The name to parse.values - Values to be parsed.
ParseException - If an error occurs during parsing.
public static java.lang.String buildValue(java.lang.String[] values)
throws ParseException
values - The array of values for this name/value specification
String The constructed values string. This may be
null.
ParseException - If an error is encountered building the value
string.
public static boolean applyFilter(java.lang.String filter,
AttributeMapInterface attr)
throws ParseException
filter - Filter to be applied.attr - Map of attributes.
boolean Returns true if the
name/value filter matches the name/value pair specification;
otherwise if there is not match, false is returned.
ParseException - If an error occurs parsing the name/value filter.
|
| Foundation |
|
| |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||