com.ptc.windchill.cadx.common.picker
Class PickerUtilities

java.lang.Object
  extended bycom.ptc.windchill.cadx.common.picker.PickerUtilities
All Implemented Interfaces:
Externalizable, Serializable
Direct Known Subclasses:
PickerBrowserUtilities, PickerSearcherUtilities

public class PickerUtilities
extends Object
implements Externalizable

This utilty provides methods to access information required by the picker processors. To use instanciate the class, then call initialize, and then call any of the methods. The form processor passed in initailize is used to obtain required support objects. The get methods associated with the search attribute list properties use the search attribute list returned by the picker search attribute list factory.

Supported API: false

Extendable: false

See Also:
Serialized Form

Field Summary
static String ALL_CONTAINERS_CONTEXT
           
private  PickerSearchAttributeList attr_list
           
static String AUTHORING_APP
           
protected static String CELL_CLASS
           
private static String CLASSNAME
           
protected static String COLUMN_SORT_SERVICE_DELIM
           
static String DELETABLE_ONLY_FILTER
           
static String DO_SORT
          Property which indicates if the table model is to be sorted prior to table service show.
static long EXTERNALIZATION_VERSION_UID
           
static String FILTER
           
static String FIND_RESULTS
          This property should be set to false if the desire is to not find results.
protected  Properties formData
           
static String IN_SHARED_CABINET_ONLY_FILTER_VALUE
           
protected static String LABEL_ALIGN
           
protected static String LABEL_CLASS
           
protected  Locale locale
           
static String LOCATION
          This is the location key used by the picker.
static String MULTI_SELECT
          This is the selection mode value for multiple selection.
protected static long OLD_FORMAT_VERSION_UID
           
protected  OutputStream os
           
protected  PrintWriter out
           
private  Vector output_attributes
           
static String PDMLINK_CONTAINERS_CONTEXT
           
static String PICKER_ACTION_VALUE
          This is the main Picker action value.
static String PICKER_BROWSER_ACTION_VALUE
          This is the browser Picker action value.
static String PICKER_CONTAINER_CONTEXT
           
static String PICKER_COOKIE_ID
          PICKER_COOKIE_ID is used for the cookie id for storing and retrieving session cookie state during interaction with Picker.
static String PICKER_POPUP_SUCCESS_ACTION_VALUE
           
static String PICKER_RADIO_SET
           
static String PICKER_RADIO_SET_BROWSE
           
static String PICKER_RADIO_SET_SEARCH
           
static String PICKER_REFRESH_ON_TABLE_ACTION_COOKIE_KEY
           
static String PICKER_SEARCHER_ACTION_VALUE
          This is the searcher Picker action value.
static String PICKER_WS_PROP_COOKIE_KEY
           
static String PICKER_WS_PROP_KEY
           
protected  BasicTemplateProcessor pickerFormProcessor
           
static String POPUP
           
static String PROCESS_CALLBACK
           
protected  Properties properties
           
static String QUERY
          This is the query key required by the picker.
protected  Properties queryData
           
static String REFERER
          Property which indicates the referer url.
private static String RESOURCE
           
static String SELECTED_OBJECT_NAME
           
static String SELECTED_OBJECT_NUMBER
           
static String SELECTED_OBJECT_OID
           
static String SELECTION_MODE
          This is the selection mode key.
(package private) static long serialVersionUID
           
protected static String SESSION_ID
           
static String SINGLE_SELECT
          This is the selection mode value for single selection.
protected  HTTPState state
           
static String SUBMIT_ACTION
          This is the submit action key required by the picker to redirect after submit.
static String SUBMIT_OID
          This is the submit oid key required by the picker to redirect after submit.
protected  TemplateProcessorTableService tableService
           
static String TITLE_RESOURCE_CLASS
          This is the resource class key required by the picker.
static String TITLE_RESOURCE_CLASS_DEFAULT
           
static String TITLE_RESOURCE_KEY
          This is the resource key required by the picker.
static String TITLE_RESOURCE_KEY_DEFAULT
           
static String TYPE_LIST
          This is the type list key used by the picker.
static String TYPE_LIST_ID
          This is the type list id key used by the picker.
static String USE_LOCATION
          If this property is set then the value of the LOCATION property should be used.
 
Constructor Summary
PickerUtilities()
           
 
Method Summary
 void addHiddenFields(Map hiddenFields)
          Generates the list of hidden fields.
 void addHiddenFields(String[] hiddenFields)
          Generates the list of hidden fields.
 void clearDoSort()
          Removes the DO_SORT property.
protected  String columnNameToSortAttribute(String columnName)
          Returns the attribute to be used for sorting the column of the column name.
 String createTagIDValuePair(String attributeName)
           
 String createUniqueTagIDValue(String attributeName)
           
 QueryResult filterResults(QueryResult results)
          Returns subset of results.
 void generatePickerPageURL(String action, Properties properties)
          Generate picker page url for the action.
 void generateString(String string)
          

Supported API: false
 void generateStringWithOutNewLine(String string)
          

Supported API: false
 EPMAuthoringAppType getAuthoringApplication()
          Returns EPMAuthoringAppType if valid value is specified for AUTHORING_APP.
protected  BasicTemplateProcessor getBasicTemplateProcessor()
          

Supported API: false
 ColumnSortService getColumnSortService()
          

Supported API: false
 String getContainerVisibilityMask()
           
 String getContainerVisibilityMask(boolean searchAcrossProducts)
           
 String getContainerVisibilityMask(Object inContextObj)
           
 String getContainerVisibilityMask(Object inContextObj, boolean searchAcrossProducts)
           
static String getEncodedOID(Persistable persistable)
          Returns the encoded OID of the persistable.
 String getFindResults()
          Gets the property value from the form processor.
protected  Properties getFormData()
          

Supported API: false
protected  TemplateProcessorTableService getHTMLTableService()
          

Supported API: false
 void getLabelHTML(StringBuffer output, String labelName)
          

Supported API: false
 void getLabelHTML(StringBuffer output, String labelName, boolean nowrap)
           
 String getLocation()
          Gets the property value from the form processor.
static Persistable getObject(String oid)
          Returns persistable identified by the oid.
static String getOID(Persistable persistable)
          Returns the OID of the persistable.
protected  Vector getOutputAttributes(int query_type)
          Returns the output attributes for the specified query type from the configured picker search attribute list.
protected  SearchAttributeListDelegate getPickerSearchAttributeList()
          Returns the configured picker search attribute list.
protected  Vector getPickList()
          Returns the type list display values for the specified query list from the configured picker search attribute list.
protected  Vector getPickValues()
          Returns the type list query values for the specified query list from the configured picker search attribute list.
protected  PrintWriter getPrintWriter()
          

Supported API: false
 String getProperty(String propertyName)
          Returns the property value specified for the property name.
 String getQuery()
          Gets the query value.
protected  Vector getQueryClass(int query_type)
          Returns the list of query classes for the specified query type from the configured picker search attribute list.
protected  String getQueryClassName(int query_type)
          Returns the query class name for the specified query type from the configured picker search attribute list.
protected  Vector getQueryClassWithNoDescendents(int query_type)
          Returns the list of query classes for the specified query type from the configured picker search attribute list w/o descendent entries filtered out.
protected  Properties getQueryData()
          

Supported API: false
 Properties getQueryProperties(String[] propertyKeys)
          Return Properties object which contains key/value pairs for the keys in propertyKeys.
protected  int getQueryType(String query)
          Returns the query type for the specified query from the configured picker search attribute list.
protected  RowDataTableModel getRowDataTableModel(Vector results)
           
 String getSelectionMode()
          Gets the property value from the form processor.
 long getSessionId()
          Returns the session id property as a long.
protected  Properties getSortableColumns(int query_type)
          Returns as Properties object which contains key value pairs wher the keys are column names and the values are Boolean.TRUE for columns which are sortable.
protected  String getSortByCommandString(String tableName, String columnName)
          Returns a valid ColumnSortService.SORT_BY command string.
 String getSortedColumnName(String tableName)
          Returns the current sorted column in the table with the specified table name.
protected  SortedEnumeration getSortedEnumeration(QueryResult qr)
          Returns a SortedEnumeration with the results sorted based on the first column attribute in accending order.
protected  SortedEnumeration getSortedEnumeration(QueryResult qr, String sort_preference)
          Returns a SortedEnumeration with the results sorted based on the attribute specified for sort_preference.
protected  Vector getSortList(int query_type)
          Returns the sort list for the specified query type from the configured picker search attribute list.
protected  HTTPState getState()
          

Supported API: false
 String getSubmitAction()
          Gets the property value from the form processor.
 String getSubmitOID()
          Gets the property value from the form processor.
 String getTitleResourceClass()
          Gets the property value from the form processor.
 String getTitleResourceKey()
          Gets the property value from the form processor.
 String getTypeList()
          Gets the property value from the form processor.
 String getTypeListID()
          Gets the property value from the form processor.
protected  String getTypeListValuesString()
          Returns configured picker type list value.
static String getURL(Persistable contextObject, String action, Properties queryProperties, URLFactory factory)
          Return url for the action.
 String getUseLocation()
          Gets the property value from the form processor.
 void initialize(BasicTemplateProcessor processor, Properties parameters, Locale locale, OutputStream os)
          

Supported API: false
protected  boolean isChangeablesOnly()
           
 boolean isCollapse()
          Returns true if ColumnCollapseService.COLLAPSE is configured in the form data.
 boolean isDeletableOnlyFilter()
          Returns true if filter property is set to DELETABLE_ONLY_FILTER.
 boolean isDoSort()
          Returns false if the DO_SORT property is set to "false"; true is returned otherwise.
 boolean isExpandCollapse()
          Returns true if ExpandCollapseSectionProcessor.EXPAND_COLLAPSE_FORM_DATA_KEY is configured in the form data.
 boolean isInSharedCabinetOnlyFilter()
          Returns true if filter property is set to IN_SHARED_CABINET_ONLY_FILTER_VALUE.
 boolean isPopup()
           
 boolean isSortBy()
          Returns true if ColumnSortService.SORT_BY is configured in the form data.
 boolean isTableAction()
          Returns true if a table action like ColumnSortService.SORT_BY or ColumnCollapseService.COLLAPSE is configured in the form data.
 boolean isValidType(Object object)
          Returns true if the object specified is one of the obejct types supported by the configured search attribute list.
 void listTypes()
          Generates list of available types if the key TYPE_LIST_ID is specified.
 void readExternal(ObjectInput input)
          Reads the non-transient fields of this class from an external source.
private  boolean readOldVersion(ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source, which is not the current version.
protected  boolean readVersion(PickerUtilities thisObject, ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source.
 void setDoSort(boolean enabled)
          Set the property which determines if the results are to be sorted in showResults.
 void setSessionId(long sessionId)
          Sets the session id property.
 void setSortBy(String tableName, String columnName)
          Sets in form data a valid value based on tableName and columnName for the ColumnSortService.SORT_BY property.
 void showResults(String tableName, QueryResult results)
          Generates an HTMLTable with the rows corresponding to the QueryResult.
 void showResults(String tableName, QueryResult results, ColumnSortService columnSortService)
          Generates an HTMLTable with the rows corresponding to the QueryResult.
 void showResults(String tableName, SortedEnumeration results)
          Generates an HTMLTable with the rows corresponding to the results enumeration.
 void showResults(String tableName, SortedEnumeration results, ColumnSortService columnSortService)
          Generates an HTMLTable with the rows corresponding to the results enumeration.
 void showResults(String tableName, Vector results)
          Generates an HTMLTable with the rows corresponding to the results vector.
 void showResults(String tableName, Vector results, ColumnSortService columnSortService)
          Generates an HTMLTable with the rows corresponding to the results vector.
protected  String sortAttributeToColumnName(String sortAttribute)
          Returns the column name which sorts based on the sort attribute.
 QueryResult toQueryResult(Object[] results)
          If results is null then an empty QueryResult is returned.
 QueryResult toQueryResult(SortedEnumeration results)
          If results is null then an empty QueryResult is returned.
 QueryResult toQueryResult(Vector resultsVector)
           
 Vector toResultsVector(PagingQueryResult results)
          If results is null then an empty Vector is returned.
 Vector toResultsVector(QueryResult results)
          If results is null then an empty Vector is returned.
 Vector toResultsVector(SortedEnumeration results)
          If results is null then an empty Vector is returned.
 void writeExternal(ObjectOutput output)
          Writes the non-transient fields of this class to an external source.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

QUERY

public static final String QUERY
This is the query key required by the picker. Needs to be changed if the key name is modified. Valid query values are found in wt.query.queryResource.

Supported API: false

See Also:
Constant Field Values

TITLE_RESOURCE_KEY

public static final String TITLE_RESOURCE_KEY
This is the resource key required by the picker. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

TITLE_RESOURCE_CLASS

public static final String TITLE_RESOURCE_CLASS
This is the resource class key required by the picker. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

SUBMIT_ACTION

public static final String SUBMIT_ACTION
This is the submit action key required by the picker to redirect after submit. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

SUBMIT_OID

public static final String SUBMIT_OID
This is the submit oid key required by the picker to redirect after submit. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

TYPE_LIST_ID

public static final String TYPE_LIST_ID
This is the type list id key used by the picker. Needs to be changed if the key name is modified. The id is used get the list defined in com.ptc.windchill.cadx.common To use the list specified by the id value set an entry in com/ptc/windchill/cadx/common/picker/picker.properties which corresponds to the id and the value specified for the com.ptc.windchill.cadx.common.picker.pickerSearchAttributeList in property set in wt.properties. wt.services/svc/default/wt.templateutil.DefaultHTMLTemplate/PickerBrowser/java.lang.Object/0=templates.cadx.common.picker.PickerBrowser/duplicate See also com.ptc.windchill.cadx.common.picker.PickerSearchAttributeList for details about customizing com.ptc.windchill.cadx.common.picker.pickerSearchAttributeList.

Supported API: false

See Also:
Constant Field Values

TYPE_LIST

public static final String TYPE_LIST
This is the type list key used by the picker. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

USE_LOCATION

public static final String USE_LOCATION
If this property is set then the value of the LOCATION property should be used. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

SELECTION_MODE

public static final String SELECTION_MODE
This is the selection mode key. Valid values are MULTI_SELECT and SINGLE_SELECT. The default is multi-select. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

SINGLE_SELECT

public static final String SINGLE_SELECT
This is the selection mode value for single selection.

Supported API: false

See Also:
Constant Field Values

MULTI_SELECT

public static final String MULTI_SELECT
This is the selection mode value for multiple selection.

Supported API: false

See Also:
Constant Field Values

LOCATION

public static final String LOCATION
This is the location key used by the picker. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

FIND_RESULTS

public static final String FIND_RESULTS
This property should be set to false if the desire is to not find results. Needs to be changed if the key name is modified.

Supported API: false

See Also:
Constant Field Values

PICKER_ACTION_VALUE

public static final String PICKER_ACTION_VALUE
This is the main Picker action value.

Supported API: false

See Also:
Constant Field Values

PICKER_BROWSER_ACTION_VALUE

public static final String PICKER_BROWSER_ACTION_VALUE
This is the browser Picker action value.

Supported API: false

See Also:
Constant Field Values

PICKER_SEARCHER_ACTION_VALUE

public static final String PICKER_SEARCHER_ACTION_VALUE
This is the searcher Picker action value.

Supported API: false

See Also:
Constant Field Values

PICKER_COOKIE_ID

public static final String PICKER_COOKIE_ID
PICKER_COOKIE_ID is used for the cookie id for storing and retrieving session cookie state during interaction with Picker. The user of Picker component could use this 'id' to identify such session cookie.

Supported API: false

See Also:
Constant Field Values

DO_SORT

public static final String DO_SORT
Property which indicates if the table model is to be sorted prior to table service show.

Supported API: false

See Also:
Constant Field Values

REFERER

public static final String REFERER
Property which indicates the referer url. The REFERER value is used on Cancel of picker. If not specified the Picker determines the referer url.

Supported API: false

See Also:
Constant Field Values

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

EXTERNALIZATION_VERSION_UID

public static final long EXTERNALIZATION_VERSION_UID
See Also:
Constant Field Values

OLD_FORMAT_VERSION_UID

protected static final long OLD_FORMAT_VERSION_UID
See Also:
Constant Field Values

PICKER_CONTAINER_CONTEXT

public static final String PICKER_CONTAINER_CONTEXT
See Also:
Constant Field Values

PDMLINK_CONTAINERS_CONTEXT

public static final String PDMLINK_CONTAINERS_CONTEXT
See Also:
Constant Field Values

ALL_CONTAINERS_CONTEXT

public static final String ALL_CONTAINERS_CONTEXT
See Also:
Constant Field Values

PICKER_REFRESH_ON_TABLE_ACTION_COOKIE_KEY

public static final String PICKER_REFRESH_ON_TABLE_ACTION_COOKIE_KEY
See Also:
Constant Field Values

PICKER_WS_PROP_COOKIE_KEY

public static final String PICKER_WS_PROP_COOKIE_KEY
See Also:
Constant Field Values

PICKER_WS_PROP_KEY

public static final String PICKER_WS_PROP_KEY
See Also:
Constant Field Values

POPUP

public static final String POPUP
See Also:
Constant Field Values

PROCESS_CALLBACK

public static final String PROCESS_CALLBACK
See Also:
Constant Field Values

SELECTED_OBJECT_OID

public static final String SELECTED_OBJECT_OID
See Also:
Constant Field Values

SELECTED_OBJECT_NAME

public static final String SELECTED_OBJECT_NAME
See Also:
Constant Field Values

SELECTED_OBJECT_NUMBER

public static final String SELECTED_OBJECT_NUMBER
See Also:
Constant Field Values

PICKER_POPUP_SUCCESS_ACTION_VALUE

public static final String PICKER_POPUP_SUCCESS_ACTION_VALUE
See Also:
Constant Field Values

FILTER

public static final String FILTER
See Also:
Constant Field Values

IN_SHARED_CABINET_ONLY_FILTER_VALUE

public static final String IN_SHARED_CABINET_ONLY_FILTER_VALUE
See Also:
Constant Field Values

DELETABLE_ONLY_FILTER

public static final String DELETABLE_ONLY_FILTER
See Also:
Constant Field Values

AUTHORING_APP

public static final String AUTHORING_APP
See Also:
Constant Field Values

TITLE_RESOURCE_CLASS_DEFAULT

public static final String TITLE_RESOURCE_CLASS_DEFAULT
See Also:
Constant Field Values

TITLE_RESOURCE_KEY_DEFAULT

public static final String TITLE_RESOURCE_KEY_DEFAULT
See Also:
Constant Field Values

PICKER_RADIO_SET

public static final String PICKER_RADIO_SET
See Also:
Constant Field Values

PICKER_RADIO_SET_SEARCH

public static final String PICKER_RADIO_SET_SEARCH
See Also:
Constant Field Values

PICKER_RADIO_SET_BROWSE

public static final String PICKER_RADIO_SET_BROWSE
See Also:
Constant Field Values

CELL_CLASS

protected static final String CELL_CLASS
See Also:
Constant Field Values

LABEL_ALIGN

protected static final String LABEL_ALIGN
See Also:
Constant Field Values

LABEL_CLASS

protected static final String LABEL_CLASS
See Also:
Constant Field Values

SESSION_ID

protected static String SESSION_ID

COLUMN_SORT_SERVICE_DELIM

protected static String COLUMN_SORT_SERVICE_DELIM

pickerFormProcessor

protected BasicTemplateProcessor pickerFormProcessor

attr_list

private PickerSearchAttributeList attr_list

output_attributes

private Vector output_attributes

locale

protected Locale locale

os

protected OutputStream os

out

protected PrintWriter out

tableService

protected TemplateProcessorTableService tableService

state

protected HTTPState state

formData

protected Properties formData

queryData

protected Properties queryData

properties

protected Properties properties
Constructor Detail

PickerUtilities

public PickerUtilities()
Method Detail

writeExternal

public void writeExternal(ObjectOutput output)
                   throws IOException
Writes the non-transient fields of this class to an external source.

Supported API: false

Specified by:
writeExternal in interface Externalizable
Parameters:
output -
Throws:
IOException

readExternal

public void readExternal(ObjectInput input)
                  throws IOException,
                         ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Specified by:
readExternal in interface Externalizable
Parameters:
input -
Throws:
IOException
ClassNotFoundException

readVersion

protected boolean readVersion(PickerUtilities thisObject,
                              ObjectInput input,
                              long readSerialVersionUID,
                              boolean passThrough,
                              boolean superDone)
                       throws IOException,
                              ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Parameters:
thisObject -
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

readOldVersion

private boolean readOldVersion(ObjectInput input,
                               long readSerialVersionUID,
                               boolean passThrough,
                               boolean superDone)
                        throws IOException,
                               ClassNotFoundException
Reads the non-transient fields of this class from an external source, which is not the current version.

Parameters:
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

getQuery

public String getQuery()
Gets the query value. If the TYPE_LIST property is non-null then it's values is returned, otherwise the QUERY property value is returned.

Supported API: false

Returns:
String

getTitleResourceKey

public String getTitleResourceKey()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getTitleResourceClass

public String getTitleResourceClass()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getSubmitAction

public String getSubmitAction()
Gets the property value from the form processor.

Supported API: false

Returns:
String

initialize

public void initialize(BasicTemplateProcessor processor,
                       Properties parameters,
                       Locale locale,
                       OutputStream os)


Supported API: false

Parameters:
processor -
parameters -
locale -
os -

getProperty

public String getProperty(String propertyName)
Returns the property value specified for the property name. The property value is looked for in the processors form data first, then the processors query data, and then the properties file specified during initilialization of this utility.

Supported API: false

Parameters:
propertyName -
Returns:
String

showResults

public void showResults(String tableName,
                        SortedEnumeration results)
                 throws WTException
Generates an HTMLTable with the rows corresponding to the results enumeration. If isSortBy() returns true then the results are sorted using the ColumnSortService returned by getColumnSortService().

Supported API: false

Parameters:
tableName -
results -
Throws:
WTException

showResults

public void showResults(String tableName,
                        Vector results)
                 throws WTException
Generates an HTMLTable with the rows corresponding to the results vector. If isSortBy() returns true then the results are sorted using the ColumnSortService returned by getColumnSortService().

Supported API: false

Parameters:
tableName -
results -
Throws:
WTException

toResultsVector

public Vector toResultsVector(QueryResult results)
If results is null then an empty Vector is returned.

Supported API: false

Parameters:
results -
Returns:
Vector

listTypes

public void listTypes()
               throws WTException
Generates list of available types if the key TYPE_LIST_ID is specified. If this is not set then the type list will be set to the QUERY key value only.

Supported API: false

Throws:
WTException

generateString

public void generateString(String string)


Supported API: false

Parameters:
string -

addHiddenFields

public void addHiddenFields(String[] hiddenFields)
Generates the list of hidden fields.

Supported API: false

Parameters:
hiddenFields -

getFormData

protected Properties getFormData()


Supported API: false

Returns:
Properties

getQueryData

protected Properties getQueryData()


Supported API: false

Returns:
Properties

getState

protected HTTPState getState()


Supported API: false

Returns:
HTTPState

getPrintWriter

protected PrintWriter getPrintWriter()


Supported API: false

Returns:
PrintWriter

getHTMLTableService

protected TemplateProcessorTableService getHTMLTableService()


Supported API: false

Returns:
TemplateProcessorTableService

getQueryType

protected int getQueryType(String query)
                    throws WTException
Returns the query type for the specified query from the configured picker search attribute list.

Supported API: false

Parameters:
query -
Returns:
int
Throws:
WTException

getQueryClassName

protected String getQueryClassName(int query_type)
                            throws WTException
Returns the query class name for the specified query type from the configured picker search attribute list.

Supported API: false

Parameters:
query_type -
Returns:
String
Throws:
WTException

getOutputAttributes

protected Vector getOutputAttributes(int query_type)
                              throws WTException
Returns the output attributes for the specified query type from the configured picker search attribute list.

Supported API: false

Parameters:
query_type -
Returns:
Vector
Throws:
WTException

getPickerSearchAttributeList

protected SearchAttributeListDelegate getPickerSearchAttributeList()
                                                            throws WTException
Returns the configured picker search attribute list. The list's filter is set to the configured type list if configured, otherwise the filter is set to the value returned by getQuery.

Supported API: false

Returns:
SearchAttributeListDelegate
Throws:
WTException

getQueryClass

protected Vector getQueryClass(int query_type)
                        throws WTException
Returns the list of query classes for the specified query type from the configured picker search attribute list.

Supported API: false

Parameters:
query_type -
Returns:
Vector
Throws:
WTException

getSortedEnumeration

protected SortedEnumeration getSortedEnumeration(QueryResult qr)
Returns a SortedEnumeration with the results sorted based on the first column attribute in accending order.

Supported API: false

Parameters:
qr -
Returns:
SortedEnumeration

getSortedEnumeration

protected SortedEnumeration getSortedEnumeration(QueryResult qr,
                                                 String sort_preference)
Returns a SortedEnumeration with the results sorted based on the attribute specified for sort_preference.

Supported API: false

Parameters:
qr -
sort_preference -
Returns:
SortedEnumeration

getBasicTemplateProcessor

protected BasicTemplateProcessor getBasicTemplateProcessor()


Supported API: false

Returns:
BasicTemplateProcessor

getSubmitOID

public String getSubmitOID()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getURL

public static String getURL(Persistable contextObject,
                            String action,
                            Properties queryProperties,
                            URLFactory factory)
                     throws WTException
Return url for the action. Property key/value pairs are included in the url.

Supported API: false

Parameters:
contextObject -
action -
queryProperties -
factory -
Returns:
String
Throws:
WTException

getQueryProperties

public Properties getQueryProperties(String[] propertyKeys)
Return Properties object which contains key/value pairs for the keys in propertyKeys.

Supported API: false

Parameters:
propertyKeys -
Returns:
Properties

generatePickerPageURL

public void generatePickerPageURL(String action,
                                  Properties properties)
                           throws WTException
Generate picker page url for the action. The url will contain the key/value pars for the property values specified. The URL requires the page source contain or include a Java Script goToPickerPage (url) function.

Supported API: false

Parameters:
action -
properties -
Throws:
WTException

getTypeListID

public String getTypeListID()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getTypeList

public String getTypeList()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getPickValues

protected Vector getPickValues()
                        throws WTException
Returns the type list query values for the specified query list from the configured picker search attribute list.

Supported API: false

Returns:
Vector
Throws:
WTException

getPickList

protected Vector getPickList()
                      throws WTException
Returns the type list display values for the specified query list from the configured picker search attribute list.

Supported API: false

Returns:
Vector
Throws:
WTException

getLabelHTML

public void getLabelHTML(StringBuffer output,
                         String labelName)


Supported API: false

Parameters:
output -
labelName -

getObject

public static Persistable getObject(String oid)
                             throws WTException
Returns persistable identified by the oid.

Supported API: false

Parameters:
oid -
Returns:
Persistable
Throws:
WTException

getOID

public static String getOID(Persistable persistable)
                     throws WTException
Returns the OID of the persistable.

Supported API: false

Parameters:
persistable -
Returns:
String
Throws:
WTException

getTypeListValuesString

protected String getTypeListValuesString()
                                  throws WTException
Returns configured picker type list value.

Supported API: false

Returns:
String
Throws:
WTException

getUseLocation

public String getUseLocation()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getEncodedOID

public static String getEncodedOID(Persistable persistable)
                            throws WTException
Returns the encoded OID of the persistable.

Supported API: false

Parameters:
persistable -
Returns:
String
Throws:
WTException

getSelectionMode

public String getSelectionMode()
Gets the property value from the form processor. If no value is specified the SINGLE_SELECT is returned.

Supported API: false

Returns:
String

addHiddenFields

public void addHiddenFields(Map hiddenFields)
Generates the list of hidden fields.

Supported API: false

Parameters:
hiddenFields -

isValidType

public boolean isValidType(Object object)
                    throws WTException
Returns true if the object specified is one of the obejct types supported by the configured search attribute list.

Supported API: false

Parameters:
object -
Returns:
boolean
Throws:
WTException

getLocation

public String getLocation()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getFindResults

public String getFindResults()
Gets the property value from the form processor.

Supported API: false

Returns:
String

getQueryClassWithNoDescendents

protected Vector getQueryClassWithNoDescendents(int query_type)
                                         throws WTException
Returns the list of query classes for the specified query type from the configured picker search attribute list w/o descendent entries filtered out.

Supported API: false

Parameters:
query_type -
Returns:
Vector
Throws:
WTException

setSessionId

public void setSessionId(long sessionId)
Sets the session id property.

Supported API: false

Parameters:
sessionId -

getSessionId

public long getSessionId()
Returns the session id property as a long.

Supported API: false

Returns:
long

showResults

public void showResults(String tableName,
                        Vector results,
                        ColumnSortService columnSortService)
                 throws WTException
Generates an HTMLTable with the rows corresponding to the results vector. If isSortBy() returns true then the results are sorted using the ColumnSortService returned by getColumnSortService().

Supported API: false

Parameters:
tableName -
results -
columnSortService -
Throws:
WTException

showResults

public void showResults(String tableName,
                        QueryResult results,
                        ColumnSortService columnSortService)
                 throws WTException
Generates an HTMLTable with the rows corresponding to the QueryResult. If isSortBy() returns true then the results are sorted using the ColumnSortService returned by getColumnSortService().

Supported API: false

Parameters:
tableName -
results -
columnSortService -
Throws:
WTException

showResults

public void showResults(String tableName,
                        SortedEnumeration results,
                        ColumnSortService columnSortService)
                 throws WTException
Generates an HTMLTable with the rows corresponding to the results enumeration. If isSortBy() returns true then the results are sorted using the ColumnSortService returned by getColumnSortService().

Supported API: false

Parameters:
tableName -
results -
columnSortService -
Throws:
WTException

showResults

public void showResults(String tableName,
                        QueryResult results)
                 throws WTException
Generates an HTMLTable with the rows corresponding to the QueryResult. If isSortBy() returns true then the results are sorted using the ColumnSortService returned by getColumnSortService().

Supported API: false

Parameters:
tableName -
results -
Throws:
WTException

toResultsVector

public Vector toResultsVector(PagingQueryResult results)
If results is null then an empty Vector is returned.

Supported API: false

Parameters:
results -
Returns:
Vector

toResultsVector

public Vector toResultsVector(SortedEnumeration results)
If results is null then an empty Vector is returned.

Supported API: false

Parameters:
results -
Returns:
Vector

getSortByCommandString

protected String getSortByCommandString(String tableName,
                                        String columnName)
Returns a valid ColumnSortService.SORT_BY command string. If the column for the column name is sorted in one order the command string be be set to sort in the opposite order. If the column is not currently sorted then the command will be set for ascending order.

Supported API: false

Parameters:
tableName -
columnName -
Returns:
String

toQueryResult

public QueryResult toQueryResult(SortedEnumeration results)
If results is null then an empty QueryResult is returned.

Supported API: false

Parameters:
results -
Returns:
QueryResult

isTableAction

public boolean isTableAction()
Returns true if a table action like ColumnSortService.SORT_BY or ColumnCollapseService.COLLAPSE is configured in the form data.

Supported API: false

Returns:
boolean

isSortBy

public boolean isSortBy()
Returns true if ColumnSortService.SORT_BY is configured in the form data.

Supported API: false

Returns:
boolean

isCollapse

public boolean isCollapse()
Returns true if ColumnCollapseService.COLLAPSE is configured in the form data.

Supported API: false

Returns:
boolean

setSortBy

public void setSortBy(String tableName,
                      String columnName)
Sets in form data a valid value based on tableName and columnName for the ColumnSortService.SORT_BY property.

Supported API: false

Parameters:
tableName -
columnName -

getSortList

protected Vector getSortList(int query_type)
                      throws WTException
Returns the sort list for the specified query type from the configured picker search attribute list.

Supported API: false

Parameters:
query_type -
Returns:
Vector
Throws:
WTException

getSortableColumns

protected Properties getSortableColumns(int query_type)
                                 throws WTException
Returns as Properties object which contains key value pairs wher the keys are column names and the values are Boolean.TRUE for columns which are sortable.

Supported API: false

Parameters:
query_type -
Returns:
Properties
Throws:
WTException

getSortedColumnName

public String getSortedColumnName(String tableName)
Returns the current sorted column in the table with the specified table name.

Supported API: false

Parameters:
tableName -
Returns:
String

columnNameToSortAttribute

protected String columnNameToSortAttribute(String columnName)
Returns the attribute to be used for sorting the column of the column name.

Supported API: false

Parameters:
columnName -
Returns:
String

sortAttributeToColumnName

protected String sortAttributeToColumnName(String sortAttribute)
Returns the column name which sorts based on the sort attribute.

Supported API: false

Parameters:
sortAttribute -
Returns:
String

isDoSort

public boolean isDoSort()
Returns false if the DO_SORT property is set to "false"; true is returned otherwise.

Supported API: false

Returns:
boolean

setDoSort

public void setDoSort(boolean enabled)
Set the property which determines if the results are to be sorted in showResults. If seeting in HTML file then the valid values are "true" and "false".

Supported API: false

Parameters:
enabled -

clearDoSort

public void clearDoSort()
Removes the DO_SORT property.

Supported API: false


getColumnSortService

public ColumnSortService getColumnSortService()


Supported API: false

Returns:
ColumnSortService

toQueryResult

public QueryResult toQueryResult(Object[] results)
If results is null then an empty QueryResult is returned.

Supported API: false

Parameters:
results -
Returns:
QueryResult

generateStringWithOutNewLine

public void generateStringWithOutNewLine(String string)


Supported API: false

Parameters:
string -

isExpandCollapse

public boolean isExpandCollapse()
Returns true if ExpandCollapseSectionProcessor.EXPAND_COLLAPSE_FORM_DATA_KEY is configured in the form data.

Supported API: false

Returns:
boolean

createTagIDValuePair

public String createTagIDValuePair(String attributeName)

createUniqueTagIDValue

public String createUniqueTagIDValue(String attributeName)

getRowDataTableModel

protected RowDataTableModel getRowDataTableModel(Vector results)
                                          throws WTException
Throws:
WTException

isPopup

public boolean isPopup()

isChangeablesOnly

protected boolean isChangeablesOnly()

getContainerVisibilityMask

public String getContainerVisibilityMask()

getContainerVisibilityMask

public String getContainerVisibilityMask(boolean searchAcrossProducts)

getContainerVisibilityMask

public String getContainerVisibilityMask(Object inContextObj)

getContainerVisibilityMask

public String getContainerVisibilityMask(Object inContextObj,
                                         boolean searchAcrossProducts)

filterResults

public QueryResult filterResults(QueryResult results)
Returns subset of results. If sharedOnlyCabinet is specidied only objects in shared cabinets are returned. If the conetxt is a Project any shared and checked out objects are filtered.


toQueryResult

public QueryResult toQueryResult(Vector resultsVector)

isInSharedCabinetOnlyFilter

public boolean isInSharedCabinetOnlyFilter()
Returns true if filter property is set to IN_SHARED_CABINET_ONLY_FILTER_VALUE.


isDeletableOnlyFilter

public boolean isDeletableOnlyFilter()
Returns true if filter property is set to DELETABLE_ONLY_FILTER.


getLabelHTML

public void getLabelHTML(StringBuffer output,
                         String labelName,
                         boolean nowrap)

getAuthoringApplication

public EPMAuthoringAppType getAuthoringApplication()
Returns EPMAuthoringAppType if valid value is specified for AUTHORING_APP.