|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwt.enterprise.BasicTemplateProcessor
wt.enterprise.FormProcessor
wt.doc.DocConfigSpecProcessor
Form processor which handles the display of the forms used to set a Configuration Specification. This form processor is used by the DocumentStructureProcessor which requires having a config spec set in order to display a document structure.
Nested Class Summary | |
static class |
DocConfigSpecProcessor.ListEntry
Helper class for maintaining both the OID of an object and its display value. |
Field Summary | |
private ConfigSpec |
configSpec
|
private Properties |
contextProperties
|
private Properties |
formProperties
|
static String |
ID_SEPARATOR
|
private static String |
RESOURCE
|
private static boolean |
VERBOSE
|
Fields inherited from interface wt.templateutil.processor.ContextTranslator |
CONTEXT_LIST_IN, CONTEXT_LIST_OUT |
Fields inherited from interface wt.templateutil.processor.ContextHolder |
CONTEXT_ACTION, CONTEXT_CLASS_NAME, CONTEXT_OBJ, CONTEXT_PROPERTIES, FORM_DATA, QUERY_DATA, RESPONSE_EXCEPTIONS, RESPONSE_FOOTERS, RESPONSE_HEADERS, RESPONSE_MESSAGES, RESPONSE_STRING, STATUS |
Constructor Summary | |
DocConfigSpecProcessor(Properties props,
HTTPRequest request)
Constructor for DocConfigSpecProcessor. |
Method Summary | |
void |
buildSearchURL(Properties parameters,
Locale locale,
OutputStream os)
Output an HTML link to a search page. |
protected static Properties |
combineParameters(Properties params_to_add,
Properties original_params)
Add the key-value pairs in the first Properties object to the second Properties object. |
protected static Properties |
combineParameters(Properties params_to_add,
Properties original_params,
boolean strip_oid_and_action)
Add the key-value pairs in the first Properties object to the second Properties object. |
static void |
configItemSearch(HTTPRequest request,
HTTPResponse response)
Display the HTML page to search for a configuration item. |
void |
createSetConfigSpecLink(Properties parameters,
Locale locale,
OutputStream os)
Output the HTML code to display a link to the form to set a configuration specification. |
void |
generateAction(Properties parameters,
Locale locale,
OutputStream os)
Outputs the URL to be used as the ACTION of an HTML FORM. |
static void |
generateForm(HTTPRequest request,
HTTPResponse response)
Generates the form which supports setting a configuration specification. |
protected static String |
getActionParameter(Properties properties)
Retrieves the action parameter from the given Properties object. |
protected Object |
getAttributeValue(String attribute)
Returns the object which is the value of the given attribute on the current config spec. |
String |
getAttributeValueString(String attribute,
Properties properties,
Locale locale)
Returns the String value of the given attribute for the current config spec. |
static Vector |
getCabinetList()
Generates a Vector of cabinet strings to be used in the drop down list. |
protected ConfigSpec |
getConfigSpec()
Returns the Configuration Specification used to initially populate the form fields. |
static Vector |
getDataFormatList()
Generates a Vector of data format strings to be used in the drop down list. |
static Vector |
getLCTList()
Generates a Vector of life cycle template strings to be used in the drop down list. |
static Vector |
getLegalValueList(String method_name)
Generates a Vector of legal value strings to be used in the drop down list. |
protected static PropertyDescriptor |
getPropertyDescriptor(Class attr_class,
String attribute)
Retrieves the PropertyDescriptor for the given attribute. |
static Vector |
getTeamTemplateList()
Generates a Vector of teamTemplate strings to be used in the drop down list. |
Vector |
getValueList(PropertyDescriptor pd,
Locale locale)
Tries to generate a Vector of legal value strings to be used in the drop down list. |
static Vector |
getViewList()
Generates a Vector of view strings to be used in the drop down list. |
static void |
invokeAction(HTTPRequest request,
HTTPResponse response)
Method invoked as the action of an HTML FORM. |
void |
outputAttributeValue(Properties properties,
Locale locale,
OutputStream os)
Outputs the value of the given attribute. |
void |
outputFormFields(Properties parameters,
Locale locale,
OutputStream os)
For all of the key-value pairs in the given Properties object, create a hidden form field with the key as the name and the value as the value of the form field. |
static void |
outputHiddenField(String name,
String value,
PrintWriter out)
Outputs a HIDDEN form field with the given name and given value to the given printwriter. |
void |
outputObjectReference(Properties properties,
Locale locale,
OutputStream os)
Outputs the object reference of a specified object to the given OutputStream. |
void |
printDataList(Properties parameters,
Locale locale,
OutputStream os)
Output an HTML SELECT form field whose values are specified by the value of "type" in the given Properties object. |
protected static String |
splitString(String string_to_split)
Removes the ID_SEPARATOR characters in the given string and replaces them with spaces. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static boolean VERBOSE
private static final String RESOURCE
public static String ID_SEPARATOR
private Properties formProperties
private Properties contextProperties
private ConfigSpec configSpec
Constructor Detail |
public DocConfigSpecProcessor(Properties props, HTTPRequest request) throws ClassNotFoundException, WTException, PropertyVetoException
props
- the Properties object used to initialize the
context propertiesrequest
- the HTTPRequest which resulted in creating
this form processor.Method Detail |
public void generateAction(Properties parameters, Locale locale, OutputStream os) throws WTException
generateAction
in class FormProcessor
parameters
- the Properties object which may contain the Class and
Method to use in building the URLlocale
- the Locale in which the HTML pages are displayedos
- the OutputStream to write the URL to
WTException
public static void generateForm(HTTPRequest request, HTTPResponse response) throws WTException, PropertyVetoException, IOException, InvocationTargetException, IllegalAccessException, ClassNotFoundException
request
- the HTTPRequest objectresponse
- the HTTPResponse object
WTException
PropertyVetoException
IOException
InvocationTargetException
IllegalAccessException
ClassNotFoundException
public static void invokeAction(HTTPRequest request, HTTPResponse response) throws Exception
Exception
public void outputFormFields(Properties parameters, Locale locale, OutputStream os)
public static void outputHiddenField(String name, String value, PrintWriter out)
name
- the Name of the hidden fieldvalue
- the value of the hidden fieldout
- the PrintWriter to write to.public void createSetConfigSpecLink(Properties parameters, Locale locale, OutputStream os)
protected ConfigSpec getConfigSpec()
public void outputObjectReference(Properties properties, Locale locale, OutputStream os)
public static void configItemSearch(HTTPRequest request, HTTPResponse response) throws WTException, IOException, PropertyVetoException, ClassNotFoundException
WTException
IOException
PropertyVetoException
ClassNotFoundException
public void buildSearchURL(Properties parameters, Locale locale, OutputStream os) throws WTException
WTException
public void printDataList(Properties parameters, Locale locale, OutputStream os) throws WTException
WTException
protected static Properties combineParameters(Properties params_to_add, Properties original_params)
params_to_add
- the Properties object containing the parameters
to add to the second Properties objectoriginal_params
- the Properties object to add the first given
Properties to.
protected static Properties combineParameters(Properties params_to_add, Properties original_params, boolean strip_oid_and_action)
params_to_add
- the Properties object containing the parameters
to add to the second Properties objectoriginal_params
- the Properties object to add the first given
Properties to.strip_oid_and_action
- if true, any parameters with the key "oid"
or the key "action" will not be combined.
protected static String getActionParameter(Properties properties)
properties
- the Properties object from which the action
parameter is retrieved
public static Vector getTeamTemplateList() throws WTException
WTException
public static Vector getCabinetList() throws WTException
WTException
public static Vector getViewList() throws WTException
WTException
public static Vector getDataFormatList() throws WTException
WTException
public static Vector getLCTList() throws WTException
WTException
public static Vector getLegalValueList(String method_name) throws WTException
WTException
public Vector getValueList(PropertyDescriptor pd, Locale locale)
public void outputAttributeValue(Properties properties, Locale locale, OutputStream os) throws WTException
properties
- parameters passed into the script calllocale
- the locale in which to display the valueos
- the OutputStream to write to
WTException
public String getAttributeValueString(String attribute, Properties properties, Locale locale)
attribute
- the attribute whose value is retrieved from the
current config spec
protected Object getAttributeValue(String attribute) throws InvocationTargetException, IllegalAccessException, WTException
attribute
- the attribute whose value is retrieved
InvocationTargetException
IllegalAccessException
WTException
protected static PropertyDescriptor getPropertyDescriptor(Class attr_class, String attribute) throws WTException
WTException
protected static String splitString(String string_to_split)
string_to_split
- the string to split
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |