com.bowstreet.profiles
Class ProfileDef

java.lang.Object
  extended by com.bowstreet.profiles.ProfileDef
All Implemented Interfaces:
IProfileDefines

public class ProfileDef
extends java.lang.Object
implements IProfileDefines

Class that represents a single ProfileDef from within a ProfileSet

See Also:
ProfileDefEntry

Field Summary
 
Fields inherited from interface com.bowstreet.profiles.IProfileDefines
CURRENT_CUSTOM_VALUE_PSET, CUSTOM_VALUE_MAP_KEY, DEFAULT, DESCRIPTION, EDIT_STATUS, EDITABLE, EFFECTS_CHILD, emptyIterator, ENTRIES, ENTRY, EXTRA_DATA, FALSE, FINAL_LOCKED, FINAL_LOCKED_STR, INHERITED_FROM, INHERITED_LOCKED, INHERITED_LOCKED_STR, IS_CONTAINER, IS_FINAL, IS_INHERITED, IS_RUNTIME, LAST_MODIFIED, LAST_MODIFIED_BY, MODEL, MODELS, NAME, PARENT, PC_ALREADY_CONVERTED, PC_INVALID_DATA, PC_NO_PROFILE, PC_OK, PROFILE, PROFILE_ATTR, PROFILE_DEF, PROFILE_SET, PROFILE_SET_MAP_PREVIEW_KEY, PROFILED, PROFILES, PROMPT, ROLE, ROLE_SELECTION_CLASS, ROLES, TRUE, TYPE, UI, USE_FULL_NAMES, VALUE, VALUE_CLASS, VALUES
 
Constructor Summary
ProfileDef()
           
ProfileDef(IXml tdProfileDef)
           
 
Method Summary
 void addEntry(ProfileDefEntry entry)
          Adds a ProfileDefEntry to this ProfileDef.
 java.lang.Object clone()
          Creates and returns a copy of this ProfileDef object.
 boolean equals(java.lang.Object obj)
          Compare two ProfileDef's.
 IXml getAsIXml()
          Gets the entire ProfileDef as IXml.
 java.util.Iterator getEntries()
          Gets an Iterator to all of the the ProfileDefEntry objects.
 ProfileDefEntry getEntry(java.lang.String strName)
          Gets a specified ProfileDefEntry by name.
 void modifyEntry(ProfileDefEntry entry)
          modifies an existing ProfileDefEntry.
 void removeEntry(java.lang.String strName)
          Removes the specified ProfileDefEntry by name.
 void setFromIXml(IXml tdProfileDef)
          Sets the entire ProfileDef from a IXml.
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProfileDef

public ProfileDef()

ProfileDef

public ProfileDef(IXml tdProfileDef)
           throws ProfileException
Throws:
ProfileException
Method Detail

addEntry

public void addEntry(ProfileDefEntry entry)
              throws ProfileException
Adds a ProfileDefEntry to this ProfileDef.

Parameters:
entry - The ProfileDefEntry to add.
Throws:
ProfileException - if duplicate name in entry.
See Also:
ProfileDefEntry

clone

public java.lang.Object clone()
Creates and returns a copy of this ProfileDef object.

Overrides:
clone in class java.lang.Object
Returns:
A copy of this ProfileDef object.

equals

public boolean equals(java.lang.Object obj)
Compare two ProfileDef's. This will just compare the entries.

Overrides:
equals in class java.lang.Object
Parameters:
obj - The ProfileDef to compare against.
Returns:
true if ProfileDef is equal, else false.

getAsIXml

public IXml getAsIXml()
               throws ProfileException
Gets the entire ProfileDef as IXml. The entire ProfileDef will be represented as one block of XML(IXml).

Returns:
The XML data representation of this ProfileDef.
Throws:
ProfileException
See Also:
IXml

getEntries

public java.util.Iterator getEntries()
Gets an Iterator to all of the the ProfileDefEntry objects.

Returns:
The iterator of ProfileDefEntry.
See Also:
ProfileDefEntry

getEntry

public ProfileDefEntry getEntry(java.lang.String strName)
Gets a specified ProfileDefEntry by name.

Parameters:
strName - The name of the ProfileDefEntry to get.
Returns:
A ProfileDefEntry.
See Also:
ProfileDefEntry

modifyEntry

public void modifyEntry(ProfileDefEntry entry)
                 throws ProfileException
modifies an existing ProfileDefEntry. If the enty does not exis then it will be added.

Parameters:
entry - The ProfileDefEntry to modify or add.
Throws:
ProfileException
See Also:
ProfileDefEntry

removeEntry

public void removeEntry(java.lang.String strName)
Removes the specified ProfileDefEntry by name.

Parameters:
strName - The name of the ProfileDefEntry to remove.
See Also:
ProfileDefEntry

setFromIXml

public void setFromIXml(IXml tdProfileDef)
                 throws ProfileException
Sets the entire ProfileDef from a IXml. The entire ProfileDef will be overwritten with the XML(IXml) data.

Parameters:
tdProfileDef - The IXml representation of a ProfileDef.
Throws:
ProfileException
See Also:
IXml


Copyright © 2009 IBM. All Rights Reserved.