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.
author: Jon S. Stevens version: $Id: Attribute.java 10042 2006-04-11 11:28:39Z jorgeuriarte $
getParentChildAttributeOptions() This returns a list of ParentChildAttributeOption objects
which have been populated with combined join data from
ROptionOption and the AttributeOption table.
hasGlobalMapping(IssueType issueType) Refers to global issue types.
Parameters: issueType - A specific IssueType to findassociated attributes for, or null to ignore thiscriterion.
Gets one of the options belonging to this attribute. if the
PrimaryKey does not belong to an option in this attribute
null is returned.
Parameters: pk - a Integer value an AttributeOption value
Method to return compatible Attribute Type's.
if the attribute has not been used at all, all types are
compatible. if issues have been entered which use the
attribute only text types are compatible with each other
It is here for convenience with regards to needing this
functionality from within a Template.
public static Attribute getInstance(int id) throws TorqueException(Code)
Return an instance based on the passed in attribute id as an int
It will return a cached instance if possible.
getInstance
public static Attribute getInstance(String attributeName) throws TorqueException(Code)
Return an instance based on the passed in
attribute name as a String. It will return
the first match if the number of Attributes found > 0
Note: The business logic dicates that there should
never be duplicate Attributes. Therefore, the checkForDuplicate
method will return true if the number of Attributes found
is > 0
Creates an ordered List of AttributeOptions which are
children within this Attribute. The list is ordered according
to the preferred order.
a List of AttributeOption's
Creates an ordered List of ROptionOption which are
children within this Attribute. The list is ordered according
to the preferred order.
a List of ROptionOption's
This returns a list of ParentChildAttributeOption objects
which have been populated with combined join data from
ROptionOption and the AttributeOption table.
a List of ParentChildAttributeOption objects
public boolean hasGlobalMapping(IssueType issueType) throws TorqueException, DataSetException(Code)
Refers to global issue types.
Parameters: issueType - A specific IssueType to findassociated attributes for, or null to ignore thiscriterion. Whether there are any mappings for this attribute.
hasMapping
public boolean hasMapping(Module module, IssueType issueType) throws TorqueException, DataSetException(Code)
Parameters: module - null to ignore this criterion. Parameters: issueType - null to ignore this criterion. Whether this attribute is already mapped to thespecified Module and IssueType.
hasModuleMappings
public boolean hasModuleMappings() throws TorqueException, DataSetException(Code)
public boolean isDateAttribute() throws TorqueException(Code)
isIntegerAttribute
public boolean isIntegerAttribute() throws TorqueException(Code)
isOptionAttribute
public boolean isOptionAttribute() throws TorqueException(Code)
isRequiredIf
public boolean isRequiredIf(Integer optionID) throws TorqueException(Code)
Return true if the given attributeOptionId will make the current
attribute required.
Parameters: optionID - throws: TorqueException -
isSystemDefined
public boolean isSystemDefined() throws TorqueException(Code)
Checks if this attribute is associated with atleast one of the
global issue types that is system defined.
True if the attribute is associated with a System definedglobal Issue Type.False otherwise.
isTextAttribute
public boolean isTextAttribute() throws TorqueException(Code)
isUserAttribute
public boolean isUserAttribute() throws TorqueException(Code)
setConditionsArray
public void setConditionsArray(Integer aOptionId) throws TorqueException(Code)
Load the attribute options' IDs from the template combo.
Parameters: aOptionId - throws: TorqueException -