|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.infoengine.SAK.IeService
com.infoengine.jsp.InfoEngine
public class InfoEngine
This class extends the Info*Engine Server Access Kit. It provides additional functionality that facilitates interaction between JSP pages and Info*Engine. For example, this class makes it convenient to execute Info*Engine templates and tasks, access the results, and render them in various ways.
| Constructor Summary | |
|---|---|
InfoEngine()
Create an instance that is not associated with any particular Info*Engine server or servlet request. |
|
InfoEngine(javax.servlet.http.HttpServletRequest request)
Create an instance that is associated with a specified servlet request but no particular Info*Engine server. |
|
InfoEngine(javax.servlet.http.HttpServletRequest request,
java.lang.String serverUri)
Create an instance that is associated with a specified servlet request and Info*Engine server. |
|
| Method Summary | |
|---|---|
java.lang.String |
applyXSL(java.io.Reader xslReader,
java.lang.String styleBaseUri)
Internally render the default group as an XML string, then apply a specified XSL stylesheet to produce a string that is returned as a result. |
java.lang.String |
applyXSL(java.lang.String groupName,
java.io.Reader xslReader,
java.lang.String styleBaseUri)
Internally render a group as an XML string, then apply a specified XSL stylesheet to produce a string that is returned as a result. |
java.lang.String |
applyXSL(java.lang.String stylesheet,
java.lang.String styleBaseUri)
Internally render the default group as an XML string, then apply a specified XSL stylesheet to produce a string that is returned as a result. |
java.lang.String |
applyXSL(java.lang.String groupName,
java.lang.String stylesheet,
java.lang.String styleBaseUri)
Internally render a group as an XML string, then apply a specified XSL stylesheet to produce a string that is returned as a result. |
void |
beginRequestWithParameters(java.lang.String templatePath)
Initiate a request to the Info*Engine server, and send all variables supplied in the query string and/or HTML form of the servlet request as parameters of the template or task. |
void |
executeTask(java.lang.String uri)
Execute an Info*Engine task and update the internal collection of groups from the result. |
void |
executeTaskWithParameters(java.lang.String uri)
Execute an Info*Engine task and update the internal collection of groups from the result. |
java.lang.String |
formatAttributeNames(java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
Obtain the names of the attributes contained within each element of the default Info*Engine group, and format the names as a String that can be rendered for display. |
java.lang.String |
formatAttributeNames(java.lang.String groupName,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
Obtain the names of the attributes contained within each element of an Info*Engine group, and format the names as a String that can be rendered for display. |
java.lang.String |
formatColumn(java.lang.String attrName,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
Obtain all of the values contained within all attributes of a specified name of all elements of the default group, and format them as a String that can be rendered for display. |
java.lang.String |
formatColumn(java.lang.String groupName,
java.lang.String attrName,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
Obtain all of the values contained within all attributes of a specified name of all elements of a specified group, and format them as a String that can be rendered for display. |
java.lang.String |
formatGroup(java.lang.String elementPrefix,
java.lang.String elementSuffix,
java.lang.String elementSeparator,
java.lang.String attributePrefix,
java.lang.String attributeSuffix,
java.lang.String attributeSeparator,
java.lang.String valuePrefix,
java.lang.String valueSuffix,
java.lang.String valueSeparator)
Traverse the entire set of elements contained within the default Info*Engine group, and format all of their attribute values as a String that can be rendered for display. |
java.lang.String |
formatGroup(java.lang.String groupName,
java.lang.String elementPrefix,
java.lang.String elementSuffix,
java.lang.String elementSeparator,
java.lang.String attributePrefix,
java.lang.String attributeSuffix,
java.lang.String attributeSeparator,
java.lang.String valuePrefix,
java.lang.String valueSuffix,
java.lang.String valueSeparator)
Traverse the entire set of elements contained within an Info*Engine group, and format all of their attribute values as a String that can be rendered for display. |
java.lang.String |
formatRow(int index,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
Obtain all of the attribute values contained within an element of the default group, and format them as a String that can be rendered for display. |
java.lang.String |
formatRow(java.lang.String groupName,
int index,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
Obtain all of the attribute values contained within an element of a group, and format them as a String that can be rendered for display. |
java.util.Vector |
getColumn(java.lang.String attrName)
Return all of the values of a named attribute of all elements of the default group. |
int |
getElementCount()
Return the number of elements in the default group. |
java.lang.String |
getMessage()
Return the message string associated with the default group. |
java.util.Vector |
getRow(int index)
Return all of the values of an element of the default group. |
int |
getStatus()
Return the status value associated with the default group. |
java.lang.String |
invokeRequest(java.lang.String templatePath)
Execute an Info*Engine template or task and return the result as a String. |
java.lang.String |
invokeRequestWithParameters(java.lang.String templatePath)
Execute an Info*Engine template or task, and send all variables supplied in the query string and/or HTML form of the servlet request as parameters of the template or task. |
void |
setServletRequest(javax.servlet.http.HttpServletRequest request)
Set the servlet request object associated with this object instance. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public InfoEngine()
public InfoEngine(javax.servlet.http.HttpServletRequest request)
throws javax.servlet.ServletException
request - the servlet request object
javax.servlet.ServletException - if authentication information provided
in the servlet request can not be validated
public InfoEngine(javax.servlet.http.HttpServletRequest request,
java.lang.String serverUri)
throws javax.servlet.ServletException
request - the servlet request objectserverUri - the base URI of the Info*Engine server
javax.servlet.ServletException - if authentication information provided
in the servlet request can not be validated| Method Detail |
|---|
public void setServletRequest(javax.servlet.http.HttpServletRequest request)
throws javax.servlet.ServletException
request - the servlet request object
javax.servlet.ServletException - if authentication information provided
in the servlet request can not be validated
public void beginRequestWithParameters(java.lang.String templatePath)
throws IeServiceException
templatePath - the pathname of a template or task.
IeServiceException - if the request was not initiated
successfully
public java.lang.String invokeRequest(java.lang.String templatePath)
throws IeServiceException
templatePath - the pathname of a template or task.
IeServiceException - if the request was not initiated
successfully
public java.lang.String invokeRequestWithParameters(java.lang.String templatePath)
throws IeServiceException
templatePath - the pathname of a template or task.
IeServiceException - if the request was not initiated
successfully
public void executeTask(java.lang.String uri)
throws IeServiceException
templatePath - the pathname of a task.
IeServiceException - if the request was not executed
successfully
public void executeTaskWithParameters(java.lang.String uri)
throws IeServiceException
templatePath - the pathname of a task.
IeServiceException - if the request was not executed
successfully
public java.lang.String formatAttributeNames(java.lang.String groupName,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
groupName - the name of the group from which attribute names
will be obtained. The group must exist within the
internal collection.prefix - the string to insert immediately before each attribute
namesuffix - the string to insert immediatly after each attribute
nameseparator - the string to insert between attribute names
public java.lang.String formatAttributeNames(java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
prefix - the string to insert immediately before each attribute
namesuffix - the string to insert immediatly after each attribute
nameseparator - the string to insert between attribute names
public java.lang.String formatGroup(java.lang.String groupName,
java.lang.String elementPrefix,
java.lang.String elementSuffix,
java.lang.String elementSeparator,
java.lang.String attributePrefix,
java.lang.String attributeSuffix,
java.lang.String attributeSeparator,
java.lang.String valuePrefix,
java.lang.String valueSuffix,
java.lang.String valueSeparator)
groupName - the name of the group to be formatted. The group
must exist within the internal collection.elementPrefix - the string to insert immediately before each
element of the group. An element can be envisioned
as a row of a table.elementSuffix - the string to insert immediatly after each
element (row) of the group.elementSeparator - the string to insert between elements (rows)
of the group.attributePrefix - the string to insert immediately before each
attribute of an element. An attribute can be envisioned
as a column of a table.attributeSuffix - the string to insert immediatly after each
attribute (column) of an element.attributeSeparator - the string to insert between attributes
(columns) of an element.valuePrefix - the string to insert immediately before each
value of an attribute. Attributes can have more than
one value. In case an attribute is multi-valued, this
parameter specifies a prefix to insert immediately
before each one.valueSuffix - the string to insert immediatly after each value
of an attribute.valueSeparator - the string to insert between values of a
multi-valued attribute.
public java.lang.String formatGroup(java.lang.String elementPrefix,
java.lang.String elementSuffix,
java.lang.String elementSeparator,
java.lang.String attributePrefix,
java.lang.String attributeSuffix,
java.lang.String attributeSeparator,
java.lang.String valuePrefix,
java.lang.String valueSuffix,
java.lang.String valueSeparator)
groupName - the name of the group to be formatted. The group
must exist within the internal collection.elementPrefix - the string to insert immediately before each
element of the group. An element can be envisioned
as a row of a table.elementSuffix - the string to insert immediatly after each
element (row) of the group.elementSeparator - the string to insert between elements (rows)
of the group.attributePrefix - the string to insert immediately before each
attribute of an element. An attribute can be envisioned
as a column of a table.attributeSuffix - the string to insert immediatly after each
attribute (column) of an element.attributeSeparator - the string to insert between attributes
(columns) of an element.valuePrefix - the string to insert immediately before each
value of an attribute. Attributes can have more than
one value. In case an attribute is multi-valued, this
parameter specifies a prefix to insert immediately
before each one.valueSuffix - the string to insert immediatly after each value
of an attribute.valueSeparator - the string to insert between values of a
multi-valued attribute.
public java.lang.String formatRow(java.lang.String groupName,
int index,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
groupName - the name of the group from which the element will
be obtained. The group must exist within the
internal collection.index - the index of the element within the group. Use
getElementCount to determine how many elements are
contained within the group. Valid indexes range from
0 to the element count - 1.prefix - the string to insert immediately before each attribute
valuesuffix - the string to insert immediatly after each attribute
valueseparator - the string to insert between attribute values
public java.lang.String formatRow(int index,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
index - the index of the element within the group. Use
getElementCount to determine how many elements are
contained within the group. Valid indexes range from
0 to the element count - 1.prefix - the string to insert immediately before each attribute
valuesuffix - the string to insert immediatly after each attribute
valueseparator - the string to insert between attribute values
public java.lang.String formatColumn(java.lang.String groupName,
java.lang.String attrName,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
groupName - the name of the group from which the attributes will
be obtained. The group must exist within the
internal collection.attrName - the name of the attribute from which values will
be obtained. This attribute will be extracted from
each element of the group.prefix - the string to insert immediately before each attribute
valuesuffix - the string to insert immediatly after each attribute
valueseparator - the string to insert between attribute values
public java.lang.String formatColumn(java.lang.String attrName,
java.lang.String prefix,
java.lang.String suffix,
java.lang.String separator)
attrName - the name of the attribute from which values will
be obtained. This attribute will be extracted from
each element of the group.prefix - the string to insert immediately before each attribute
valuesuffix - the string to insert immediatly after each attribute
valueseparator - the string to insert between attribute values
public java.lang.String applyXSL(java.lang.String groupName,
java.io.Reader xslReader,
java.lang.String styleBaseUri)
throws IeServiceException
groupName - the name of the group to which the stylesheet will
be applied. The group must exist within the
internal collection.xslReader - the Reader from which the XSL stylesheet can be readstyleBaseUri - a URI specifying where to find additional
stylesheets that might be referenced by the main
stylesheet read from xslReader
IeServiceException - if the XSL stylesheet was not applied
successfully, possible due to a syntax
error in the stylesheet, or a failure
in trying to read the stylesheet
public java.lang.String applyXSL(java.io.Reader xslReader,
java.lang.String styleBaseUri)
throws IeServiceException
xslReader - the Reader from which the XSL stylesheet can be readstyleBaseUri - a URI specifying where to find additional
stylesheets that might be referenced by the main
stylesheet read from xslReader
IeServiceException - if the XSL stylesheet was not applied
successfully, possible due to a syntax
error in the stylesheet, or a failure
in trying to read the stylesheet
public java.lang.String applyXSL(java.lang.String groupName,
java.lang.String stylesheet,
java.lang.String styleBaseUri)
throws IeServiceException
groupName - the name of the group to which the stylesheet will
be applied. The group must exist within the
internal collection.stylesheet - a String containing the XSL stylesheet to applystyleBaseUri - a URI specifying where to find additional
stylesheets that might be referenced by the main
stylesheet specified by the stylesheet parameter
IeServiceException - if the XSL stylesheet was not applied
successfully, possible due to a syntax
error in the stylesheet, or a failure
in trying to read the stylesheet
public java.lang.String applyXSL(java.lang.String stylesheet,
java.lang.String styleBaseUri)
throws IeServiceException
stylesheet - a String containing the XSL stylesheet to applystyleBaseUri - a URI specifying where to find additional
stylesheets that might be referenced by the main
stylesheet specified by the stylesheet parameter
IeServiceException - if the XSL stylesheet was not applied
successfully, possible due to a syntax
error in the stylesheet, or a failure
in trying to read the stylesheetpublic int getElementCount()
public java.util.Vector getColumn(java.lang.String attrName)
attrName - The name of the attribute.
public java.util.Vector getRow(int index)
index - The index of the element.
public int getStatus()
public java.lang.String getMessage()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||