|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.apache.torque.om.BaseObject
org.tigris.scarab.om.BaseAttribute
org.tigris.scarab.om.Attribute
This class represents the SCARAB_R_OPTION_OPTION table. Please note that this class caches several pieces of data depending on the methods called. If you would like to clear these caches, it is a good idea to call the doRemoveCaches() method after making any modifications to the ROptionOption, ParentChildAttributeOption, and AttributeOption objects.
| Field Summary |
| Fields inherited from class org.tigris.scarab.om.BaseAttribute |
collActivitys, collAttributeOptions, collAttributeValues, collConditions, collRAttributeAttributeGroups, collRIssueTypeAttributes, collRModuleAttributes, collRModuleUserAttributes, collTransitions |
| Fields inherited from class org.apache.torque.om.BaseObject |
NEW_ID |
| Constructor Summary | |
protected |
Attribute()
Must call getInstance() |
| Method Summary | |
void |
buildOptionsMap()
Build a list of options. |
static boolean |
checkForDuplicate(java.lang.String attributeName)
Checks to see if there is another attribute with the same name already in the database. |
static boolean |
checkForDuplicate(java.lang.String attributeName,
Attribute attribute)
|
Attribute |
copyAttribute(ScarabUser user)
Copy the Attribute and its options Make sure the new options have a row in the option join table |
void |
deleteIssueTypeMappings()
Delete mappings with global issue types. |
void |
deleteModuleMappings()
Delete mappings with all modules and issue types. |
(package private) void |
doRemoveCaches()
Clears the internal caches for this object |
java.util.List |
getActivitys()
Override autogenerated base class method There should be no actitivites being returned |
static java.util.List |
getAllAttributes()
get a list of all of the Attributes in the database |
static java.util.List |
getAllAttributeTypes()
Little method to return a List of all Attribute Type's. |
AttributeOption |
getAttributeOption(java.lang.Integer pk)
Gets one of the options belonging to this attribute. if the PrimaryKey does not belong to an option in this attribute null is returned. |
AttributeOption |
getAttributeOption(java.lang.String optionID)
Get an option by String id. |
java.util.List |
getAttributeOptions(boolean includeDeleted)
Get a list of all attribute options or just the ones that have not been marked as deleted. |
AttributeType |
getAttributeType()
Override the base class to provide caching of AttributeType objects and save a hit to the database. |
(package private) static java.lang.String |
getCacheKey(org.apache.torque.om.ObjectKey key)
|
java.util.List |
getCompatibleAttributeTypes()
Method to return compatible Attribute Type's. |
java.util.List |
getConditions()
If this collection has already been initialized, returns the collection. |
java.lang.Integer[] |
getConditionsArray()
Returns the array of attributeOptionIds that will force the requiment of this attribute if set. |
java.lang.String |
getCreatedUserName()
Helper method that takes a Integer |
static Attribute |
getInstance(int id)
Return an instance based on the passed in attribute id as an int It will return a cached instance if possible. |
static Attribute |
getInstance(java.lang.String attributeName)
Return an instance based on the passed in attribute name as a String. |
java.util.List |
getOrderedAttributeOptionList()
Creates an ordered List of AttributeOptions which are children within this Attribute. |
java.util.List |
getOrderedROptionOptionList()
Creates an ordered List of ROptionOption which are children within this Attribute. |
java.util.List |
getParentChildAttributeOptions()
This returns a list of ParentChildAttributeOption objects which have been populated with combined join data from ROptionOption and the AttributeOption table. |
AttributeOption |
getRequiredOption()
Gets the attributeOption that will force this attribute to be required, in case of being set. |
java.util.List |
getTransitions()
Returns the transitions defined for this Attribute |
boolean |
hasGlobalIssueTypeMappings()
Refers to global issue types. |
boolean |
hasGlobalMapping(IssueType issueType)
Refers to global issue types. |
boolean |
hasMapping(Module module,
IssueType issueType)
|
boolean |
hasModuleMappings()
|
boolean |
isConditioned()
|
boolean |
isDateAttribute()
|
boolean |
isIntegerAttribute()
|
boolean |
isOptionAttribute()
|
boolean |
isRequiredIf(java.lang.Integer optionID)
Return true if the given attributeOptionId will make the current attribute required. |
boolean |
isSystemDefined()
Checks if this attribute is associated with atleast one of the global issue types that is system defined. |
boolean |
isTextAttribute()
|
boolean |
isUserAttribute()
|
void |
setConditionsArray(java.lang.Integer[] aOptionId)
Load the attribute options' IDs from the template combo. |
(package private) void |
setOrderedAttributeOptionList(java.util.List value)
package protected method to set the value of the cached list. |
(package private) void |
setOrderedROptionOptionList(java.util.List value)
package protected method to set the value of the cached list. |
(package private) void |
setParentChildAttributeOptions(java.util.List value)
package protected method to set the value of the cached list. |
| Methods inherited from class org.apache.torque.om.BaseObject |
equals, equals, getLog, hashCode, isModified, isNew, resetModified, setModified, setNew, setPrimaryKey |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.apache.torque.om.Persistent |
getPrimaryKey, isModified, isNew, save, save, save, setModified, setNew, setPrimaryKey, setPrimaryKey |
| Constructor Detail |
protected Attribute()
| Method Detail |
static java.lang.String getCacheKey(org.apache.torque.om.ObjectKey key)
public static Attribute getInstance(int id)
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public static Attribute getInstance(java.lang.String attributeName)
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public static boolean checkForDuplicate(java.lang.String attributeName)
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public static boolean checkForDuplicate(java.lang.String attributeName,
Attribute attribute)
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public java.lang.String getCreatedUserName()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueExceptionvoid doRemoveCaches()
public static java.util.List getAllAttributeTypes()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public java.util.List getCompatibleAttributeTypes()
throws org.apache.torque.TorqueException,
com.workingdogs.village.DataSetException
org.apache.torque.TorqueException
com.workingdogs.village.DataSetException
public AttributeType getAttributeType()
throws org.apache.torque.TorqueException
getAttributeType in class BaseAttributeorg.apache.torque.TorqueException
public static java.util.List getAllAttributes()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public boolean isOptionAttribute()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public boolean isUserAttribute()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public boolean isTextAttribute()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public boolean isIntegerAttribute()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public boolean isDateAttribute()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public AttributeOption getAttributeOption(java.lang.Integer pk)
throws org.apache.torque.TorqueException
pk - a Integer value
AttributeOption value
org.apache.torque.TorqueException
public AttributeOption getAttributeOption(java.lang.String optionID)
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException - if optionId is emptyvoid setParentChildAttributeOptions(java.util.List value)
public java.util.List getParentChildAttributeOptions()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueExceptionvoid setOrderedROptionOptionList(java.util.List value)
public java.util.List getOrderedROptionOptionList()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueExceptionvoid setOrderedAttributeOptionList(java.util.List value)
public java.util.List getOrderedAttributeOptionList()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public java.util.List getAttributeOptions(boolean includeDeleted)
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public void buildOptionsMap()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public java.util.List getActivitys()
throws org.apache.torque.TorqueException
getActivitys in class BaseAttributeorg.apache.torque.TorqueException
public Attribute copyAttribute(ScarabUser user)
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public boolean hasModuleMappings()
throws org.apache.torque.TorqueException,
com.workingdogs.village.DataSetException
org.apache.torque.TorqueException
com.workingdogs.village.DataSetException
public boolean hasMapping(Module module,
IssueType issueType)
throws org.apache.torque.TorqueException,
com.workingdogs.village.DataSetException
module - null to ignore this criterion.issueType - null to ignore this criterion.
Module and IssueType.
org.apache.torque.TorqueException
com.workingdogs.village.DataSetException
public boolean hasGlobalIssueTypeMappings()
throws org.apache.torque.TorqueException,
com.workingdogs.village.DataSetException
org.apache.torque.TorqueException
com.workingdogs.village.DataSetExceptionhasGlobalMapping(IssueType)
public boolean hasGlobalMapping(IssueType issueType)
throws org.apache.torque.TorqueException,
com.workingdogs.village.DataSetException
issueType - A specific IssueType to find
associated attributes for, or null to ignore this
criterion.
org.apache.torque.TorqueException
com.workingdogs.village.DataSetException
public void deleteModuleMappings()
throws org.apache.torque.TorqueException,
ScarabException
org.apache.torque.TorqueException
ScarabException
public void deleteIssueTypeMappings()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueException
public boolean isSystemDefined()
throws org.apache.torque.TorqueException
org.apache.torque.TorqueExceptionpublic AttributeOption getRequiredOption()
public java.lang.Integer[] getConditionsArray()
getConditionsArray in interface Conditioned
public java.util.List getConditions()
throws org.apache.torque.TorqueException
BaseAttribute
getConditions in class BaseAttributeorg.apache.torque.TorqueException
public void setConditionsArray(java.lang.Integer[] aOptionId)
throws org.apache.torque.TorqueException
setConditionsArray in interface ConditionedaOptionId -
org.apache.torque.TorqueException
public boolean isRequiredIf(java.lang.Integer optionID)
throws org.apache.torque.TorqueException
isRequiredIf in interface ConditionedoptionID -
org.apache.torque.TorqueExceptionpublic boolean isConditioned()
isConditioned in interface Conditionedpublic java.util.List getTransitions()
getTransitions in class BaseAttribute
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||