Package com.opencloud.slee.profile
Class ProfileDataCollection.Profile
- java.lang.Object
- 
- com.opencloud.slee.profile.ProfileDataCollection.Profile
 
- 
- All Implemented Interfaces:
- Serializable
 - Enclosing class:
- ProfileDataCollection
 
 public static final class ProfileDataCollection.Profile extends Object implements Serializable Class representing a profile. - See Also:
- Serialized Form
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classProfileDataCollection.Profile.ActionManagement actions that can be performed with aProfileDataCollection.Profileobject.
 - 
Constructor SummaryConstructors Constructor Description Profile(String profileName)Create a new profile import record.Profile(String profileName, ProfileDataCollection.Profile.Action action, boolean failIfExists, boolean failIfNotExists)Create a new profile import record.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddAttributeValue(String attrName, ProfileDataCollection.AttributeValue attrValue)Add an attribute value to this profile.booleanfailIfExists()Determine if the fail-if-exists flag has been set for CREATE actions.booleanfailIfNotExists()Determine if the fail-if-not-exists flag has been set for REMOVE actions.ProfileDataCollection.Profile.ActiongetAction()Get the action to be applied to the profile.StringgetName()Get the name of the profile.Map<String,ProfileDataCollection.AttributeValue>getValues()Get the attribute names and values for this profile.StringtoString()
 
- 
- 
- 
Constructor Detail- 
Profilepublic Profile(String profileName) Create a new profile import record. The profile action is CREATE, and errors are ignored. <p> This constructor is equivalent to new Profile(profileName, CREATE, false, false).- Parameters:
- profileName- the name of the profile. The value- nullis acceptable and indicates the profile table’s default profile.
 
 - 
Profilepublic Profile(String profileName, ProfileDataCollection.Profile.Action action, boolean failIfExists, boolean failIfNotExists) Create a new profile import record. - Parameters:
- profileName- the name of the profile. The value- nullis acceptable and indicates the profile table’s default profile.
- action- the import action. Must be one of the constants defined by the- ProfileDataCollection.Profile.Actionenumeration.
- failIfExists- flag indicating if an exception should be thrown during import if- action == CREATEand a profile with the name specified by- profileNamealready exists.
- failIfNotExists- flag indicating if an exception should be thrown during import if- action == REMOVEand a profile with the name specified by- profileNamedoes not exist.
- Throws:
- IllegalArgumentException- if an invalid- actionis specified, if- failIfExistsis- truebut- action != CREATEif- failIfNotExistsis- truebut- action != remove, or if the default profile is selected for removal.
 
 
- 
 - 
Method Detail- 
getNamepublic String getName() Get the name of the profile. - Returns:
- the name of the profile.
 
 - 
getActionpublic ProfileDataCollection.Profile.Action getAction() Get the action to be applied to the profile. - Returns:
- the action.
 
 - 
failIfExistspublic boolean failIfExists() Determine if the fail-if-exists flag has been set for CREATE actions. - Returns:
- trueif the fail-if-exists flag has been set,- falseotherwise.
 
 - 
failIfNotExistspublic boolean failIfNotExists() Determine if the fail-if-not-exists flag has been set for REMOVE actions. - Returns:
- trueif the fail-if-not-exists flag has been set,- falseotherwise.
 
 - 
addAttributeValuepublic void addAttributeValue(String attrName, ProfileDataCollection.AttributeValue attrValue) Add an attribute value to this profile. - Parameters:
- attrName- the name of the attribute.
- attrValue- the value of the attribute.
- Throws:
- IllegalStateException- if the action for this profile is REMOVE.
- IllegalArgumentException- if a value for the given attribute has already been specified for this profile.
 
 - 
getValuespublic Map<String,ProfileDataCollection.AttributeValue> getValues() Get the attribute names and values for this profile. - Returns:
- a map of attribute name to attribute value.
 
 
- 
 
-