|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.adobe.livecycle.formsservice.client.FormsResult
public class FormsResult
Provides access to the Forms service processing results, such as the data content, the transformation result,
and the content type. To display a form in a client web browser, write the data stream obtained using this
object to a client web browser. To obtain a data stream, invoke the
method.
A getOutputContent
FormsResult
object is returned by the following FormsServiceClient
methods:
renderFormGuide()
renderHTMLForm()
renderPDFForm()
renderPDFForm2()
renderPDFFormWithUsageRights()
processFormSubmission()
To see how to write data located within an object of this type to a client web browser, see the Rendering an interactive PDF form using the Java API quick start in Programming with LiveCycle ES4.
Constructor Summary | |
---|---|
FormsResult()
This constructor is for internal use only. |
|
FormsResult(short action,
java.lang.String options,
java.lang.String tratransformationID,
java.lang.String formQuery,
long pageNumber,
long pageCount,
java.util.List attachments,
Document validationErrorsList,
java.lang.String clickedBtn,
Document xMLData)
This constructor is for internal use only. |
Method Summary | |
---|---|
short |
getAction()
Indicates the processing state associated with the Forms service result. |
java.util.List |
getAttachments()
Retrieves the file attachments that are rendered with the form. |
java.lang.String |
getCharSet()
Returns the character set encoding value; for example, ISO-8859-1 , UTF-8 , SHIFT_JIS . |
java.lang.String |
getClickedBtn()
Returns an XML Architecture Scripting Object Model (SOM) expression identifying the last button that was clicked on a form. |
java.lang.String |
getContentType()
Returns the content type that describes the data content generated by the Forms service. |
java.lang.String |
getFormQuery()
Retrieves the name of the form design on which the rendered form is based. |
java.lang.String |
getLocale()
Gets a locale value that is used by the Forms service to send validation messsages to client devices, such as web browsers, as part of HTML transformations. |
java.lang.String |
getOption(java.lang.String opt)
For internal use only. |
java.lang.String |
getOptions()
Retrieves run-time options that are applicable to the Forms service. |
Document |
getOutputContent()
Returns data content generated by the Forms service. |
java.lang.String |
getOutputString()
If the content type is text-based, this method returns the data content that is generated by the Forms service as a string; otherwise, it returns an empty string (binary content is accessible using the getOutputContent method). |
int |
getOutputType()
Returns the output type value that specifies how a form that is rendered as HTML is displayed. |
Document |
getOutputXML()
If the content type contains XML or HTML data, the transformation result is stored as well-formed XML, which can be retrieved as this string. |
long |
getPageCount()
Retrieves number of pages that is located within the rendered form. |
long |
getPageNumber()
Retrieves the page number of the rendered form. |
java.lang.String |
getTransformationID()
Although a client application indicates an output format preference, this value represents the actual transformation performed. |
Document |
getValidationErrorsList()
Gets a list of validation errors as UTF8-encoded XML. |
Document |
getXMLData()
Retrieves form XML data. |
void |
setCharSet(java.lang.String charSet)
For internal use only. |
void |
setContentType(java.lang.String contentType)
For internal use only. |
void |
setOutputContent(Document contentDoc,
java.lang.String sContentType)
Sets the output content. |
void |
setOutputXML(Document outputXML)
For internal use only. |
void |
setTransformationID(java.lang.String transformationID)
For internal use only. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FormsResult()
public FormsResult(short action, java.lang.String options, java.lang.String tratransformationID, java.lang.String formQuery, long pageNumber, long pageCount, java.util.List attachments, Document validationErrorsList, java.lang.String clickedBtn, Document xMLData)
Method Detail |
---|
public Document getOutputContent() throws java.io.UnsupportedEncodingException
action
value,
the content may be sent back to the originating client device (such as a web browser)
or may be available for further processing by the client application.
To see this method used in a code example, see the
Rendering an interactive PDF form using the Java API quick start in Programming with LiveCycle ES4.
Document
object representing the data content generated by the Forms service.
The content format may contain XML, HTML, or PDF data.
java.io.UnsupportedEncodingException
FormsResult.getAction()
public java.lang.String getContentType()
text/xml
text/html
application/xml
application/pdf
application/vnd.adobe.xdp+xml
If the content type is text/html
, the character set value is appended;
for example, text/html; charset="ISO-8859-1"
.
public java.lang.String getCharSet()
ISO-8859-1
, UTF-8
, SHIFT_JIS
.
You can set the character set encoding value by invoking the RenderOptionsSpec
object's setCharset
method.
setCharset()
public java.lang.String getClickedBtn()
Untitled[0].main[0].ButtonHello[0]
where Untitled
and main
represent the form's XML hierarchy.
The name of the button on the form is ButtonHello
.
For information about the XML Architecture, go to http://partners.adobe.com/asn/tech/pdf/xmlformspec.jsp.
public java.lang.String getOutputString()
getOutputContent
method).
FormsResult.getOutputContent()
public Document getOutputXML()
IOutputContext
interface, which updates its state to reflect changes. The setOutputXML
method is used for this purpose.
FormsResult.setOutputXML(Document)
public Document getValidationErrorsList()
com.adobe.idp.Document
object containing UTF8 encoded XML data.public short getAction()
0
(Submit) indicates that validated XML data is available.
In this situation, interaction is complete.
However, if the value is 1
(Calculate), the data content contains calculation results that must
be returned to the web browser so that the user can view the results.
These values are valid:
0
(Submit) - Validated XML data is ready to be processed.1
(Calculate) - Calculation results must be written to the web browser.2
(Validate) - Calculations and validations must be written to the web browser.3
(Next) - The current page has changed with results that must be written to the web browser (valid only for HTML transformations). 4
(Previous) - The current page has changed with results that must be written to the web browser (valid only for HTML transformations).To see this method used in a code example, see the Handling submitted forms using the Java API quick start in Programming with LiveCycle ES4.
public java.lang.String getTransformationID()
public java.lang.String getOptions()
renderPDFForm
method, you can set run-time options by invoking methods that
belong to the PDFFormRenderSpec
object.
public Document getXMLData()
Document
object that contains form XML data.public java.lang.String getFormQuery()
public long getPageNumber()
public long getPageCount()
public java.util.List getAttachments()
java.util.List
object that contains file attachments.public java.lang.String getLocale()
public int getOutputType()
0
- The form is rendered within full HTML tags (a complete HTML page).1
- The form is rendered within body tags (not a complete HTML page).
public void setOutputContent(Document contentDoc, java.lang.String sContentType) throws java.lang.Exception
contentDoc
- The output content.sContentType
- The content type.
java.lang.Exception
public java.lang.String getOption(java.lang.String opt)
public void setOutputXML(Document outputXML)
public void setCharSet(java.lang.String charSet)
public void setContentType(java.lang.String contentType)
public void setTransformationID(java.lang.String transformationID)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |