Package com.ptc.core.components.beans
Class ObjectBean
java.lang.Object
com.ptc.core.components.beans.ObjectBean
- All Implemented Interfaces:
FormDataHolder,Externalizable,Serializable
A class used to access the form data specific to a single object being created or updated by a HTML wizard and the
form data common to all target objects. Also contains the instance of the object created during the processing of the
wizard.
See the Windchill Customizers' Guide for more information on wizard processing.
Supported API: true
Extendable: false
See the Windchill Customizers' Guide for more information on wizard processing.
Supported API: true
Extendable: false
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddChild(ObjectBean child) Adds a child ObjectBean to this ObjectBean.Gets the object that is the target of the action.getAddedItemsByName(String param_name) Returns a the list of NmOids for objects which were added to the component with the nameparam_name.Returns the combo box input fields that were modified by the user.Returns the radio button input fields that were modified by the user.Returns the textbox input fields that were modified by the user.Returns the textarea input fields that were modified by the user.Returns the checkbox input fields that were checked by the user.Gets the value of the attribute: children.getInitialItemsByName(String param_name) Returns the list of initial NmOids for objects which are associated to the component with the nameparam_name.
Supported API: trueGets the value of the attribute: object.Gets the value of the attribute: objectHandle.Gets the value of the attribute: parent.getRemovedItemsByName(String param_name) Returns a list of the objects that were removed from a component.getTextParameter(String key) Gets a HTTP request parameter value in UTF8 format.String[]Gets all the HTTP request parameter values for the given key in UTF8 format.Returns a hashMap of all the un-checked checkboxes on the page.booleanReturns true if this ObjectBean has child ObjectBeans; false otherwise.voidsetChildren(List<ObjectBean> a_Children) Sets the value of the attribute: children.voidSets the value of the attribute: object.voidsetParent(ObjectBean a_Parent) Sets the value of the attribute: parent.toString()Dumps the contents of this ObjectBean.
-
Method Details
-
getChildren
Gets the value of the attribute: children. These are the children of this ObjectBean. They typically represent related objects that are dependent on this object or that should be processed after this object. For example, if this ObjectBean represents a ChangeRequest it might have have children that are the related ChangeActivities.
Supported API: true- Returns:
- List
-
setChildren
Sets the value of the attribute: children. These are the children of this ObjectBean. They typically represent related objects that are dependent on this object or that should be processed after this object. For example, if this ObjectBean represents a ChangeRequest it might have have children that are the related ChangeActivities.
Supported API: true- Parameters:
a_Children-
-
getObject
Gets the value of the attribute: object. This is an instance of the target object whose attributes are set to the values in the form data.
Supported API: true- Returns:
- Object
-
setObject
Sets the value of the attribute: object. This is an instance of the target object whose attributes are set to the values in the form data.
Supported API: true- Parameters:
a_Object-
-
getObjectHandle
Gets the value of the attribute: objectHandle. This is the string used in form field names to identify the data of the object represented by this ObjectBean.
Supported API: true- Returns:
- String
-
getParent
Gets the value of the attribute: parent. This is the parent of this ObjectBean. It typically represents a related object on which this object depends or that should be processed before this object. For example, if this ObjectBean represents a ChangeActivity it's parent might be the ChangeRequest with which it is associated.
Supported API: true- Returns:
- ObjectBean
-
setParent
Sets the value of the attribute: parent. This is the parent of this ObjectBean. It typically represents a related object on which this object depends or that should be processed before this object. For example, if this ObjectBean represents a ChangeActivity it's parent might be the ChangeRequest with which it is associated.
Supported API: true- Parameters:
a_Parent-
-
addChild
Adds a child ObjectBean to this ObjectBean.
Supported API: true- Parameters:
child-
-
hasChildren
public boolean hasChildren()Returns true if this ObjectBean has child ObjectBeans; false otherwise.
Supported API: true- Returns:
- boolean
-
toString
Dumps the contents of this ObjectBean.
Supported API: true -
getAddedItemsByName
Returns a the list of NmOids for objects which were added to the component with the nameparam_name.
Supported API: true- Specified by:
getAddedItemsByNamein interfaceFormDataHolder- Parameters:
param_name- The name of the component to which the items were added (for example: table ID)- Returns:
- a list of oids that are added from the component.
Supported API: true
-
getChangedComboBox
Returns the combo box input fields that were modified by the user.
Supported API: true- Specified by:
getChangedComboBoxin interfaceFormDataHolder- Returns:
- Map - keys are the field names and values are the field values
- Throws:
WTException
-
getChangedRadio
Returns the radio button input fields that were modified by the user. Buttons must have been rendered by a GuiComponent.
Supported API: true- Specified by:
getChangedRadioin interfaceFormDataHolder- Returns:
- Map<String,String>
- Throws:
WTException
-
getChangedText
Returns the textbox input fields that were modified by the user.
Supported API: true- Specified by:
getChangedTextin interfaceFormDataHolder- Returns:
- Map<String,String> - Keys are the field names and values are the field vales
- Throws:
WTException
-
getChangedTextArea
Returns the textarea input fields that were modified by the user.
Supported API: true- Specified by:
getChangedTextAreain interfaceFormDataHolder- Returns:
- Map<String,String> - keys are the field names, values are the field values
- Throws:
WTException
-
getChecked
Returns the checkbox input fields that were checked by the user.
Supported API: true- Specified by:
getCheckedin interfaceFormDataHolder- Returns:
- Map
-
getNewChecked
Supported API: true- Specified by:
getNewCheckedin interfaceFormDataHolder- Returns:
- Map<String,List
> - Throws:
WTException
-
getRemovedItemsByName
Returns a list of the objects that were removed from a component.
Supported API: true- Specified by:
getRemovedItemsByNamein interfaceFormDataHolder- Parameters:
param_name- - the name of the component. E.g., table id.- Returns:
- List - of NmOids
-
getTextParameter
Gets a HTTP request parameter value in UTF8 format. If there is more than one value for the given key, only the first value will be returned.
Use this instead of getRequest().getParameter()
Available in the servlet container and in the Method Server
Supported API: true- Specified by:
getTextParameterin interfaceFormDataHolder- Parameters:
key- - name of parameter to retrieve- Returns:
- String - value of parameter
-
getTextParameterValues
Gets all the HTTP request parameter values for the given key in UTF8 format.
Available in the servlet container and in the Method Server
Supported API: true- Specified by:
getTextParameterValuesin interfaceFormDataHolder- Parameters:
key- - name of parameter to retrieve- Returns:
- String[] - value(s) of parameters
-
getUnChecked
Returns a hashMap of all the un-checked checkboxes on the page. Only returns values for fields rendered with checkbox GuiComponents. Keys in returned map are checkbox names and values are optional column names. For example, if one was to make a table of principals to access control permissions, the name would be the user, and the optional column name would be the access control permission.
Supported API: true- Specified by:
getUnCheckedin interfaceFormDataHolder- Returns:
- Map<String,List
> - Throws:
WTException
-
getActionOid
Gets the object that is the target of the action. This could be the elementOid for a row based action or the primaryOid for actions invoked on the details page
Supported API: true- Throws:
WTException
-
getInitialItemsByName
Returns the list of initial NmOids for objects which are associated to the component with the nameparam_name.
Supported API: true- Specified by:
getInitialItemsByNamein interfaceFormDataHolder- Parameters:
param_name- The name of the component with the initial items (for example: table ID)- Returns:
- a list of initial oids that are from the component.
Supported API: true
-