|
Foundation |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.services.publish.HTMLEntry
public class HTMLEntry
Represents an HTML entry that can then be added to a result package for publishing. See Constructing a Result Package to Publish for an example of how this class is used.
An HTML entry is a container for various files that implement
HTMLFileInterface
. Within MVA SAS, the ODS HTML statement generates
HTML files. The body file contains the results from the procedure. The
contents file is a table of contents that links to the body file. The pages file is
a table of pages that links to the body file.
The frame file is a frame that displays the table of contents, the table of pages and the body
file. The HTML entry provides a way to identify each of these files,
and encapsulate them into one entry.
The HTML entry contains a main HTML file. If a frame file exists, it should be designated as the main file; otherwise, the body file should be designated as the main file for the HTML entry. The HTML entry can also contain any number of companion files. The companion files are any files other than the main HTML file. The companion files can include, body, frame, contents and page files, as well as any miscellaneous files (such as HTML, GIF, JPG) needed by the HTML entry.
HTMLFile
,
Serialized FormField Summary |
---|
Fields inherited from class com.sas.services.publish.AbstractEntry |
---|
BINARY_COMPAT_VERSION, CATALOG_COMPAT_VERSION, DATASET_COMPAT_VERSION, DEFAULT_ENTRY_VERSION, HTML_COMPAT_VERSION, MDDB_COMPAT_VERSION, NESTEDPACKAGE_COMPAT_VERSION, REFERENCE_COMPAT_VERSION, SQLVIEW_COMPAT_VERSION, TEXT_COMPAT_VERSION, VIEWER_COMPAT_VERSION |
Constructor Summary | |
---|---|
HTMLEntry()
Constructs an instance which will export a remote object using RMI socket factories associated with HTMLEntry.class. |
|
HTMLEntry(HTMLFileInterface main,
HTMLFileInterface[] companions)
Constructs an instance which will export a remote object using RMI socket factories associated with HTMLEntry.class for the specified HTML file and companions. |
Method Summary | |
---|---|
void |
addCompanionFile(HTMLFileInterface companion)
Adds a companion to file to the HTML entry. |
protected void |
closeEntry()
Remove any temporary files needed for inputstream re-use and mark this entry as closed. |
HTMLFileInterface[] |
getCompanionFiles()
Returns an array of all companion files included in this HTML entry. |
HTMLFileInterface |
getFile()
Returns the main file for this HTML entry. |
HTMLFileInterface |
getFile(java.lang.String uniqueId)
Returns the file identified by the entity key. |
void |
setCompanionFiles(HTMLFileInterface[] companions)
Sets the companion to files for this HTML entry. |
void |
setFile(HTMLFileInterface mainFile)
Sets the main file for this HTML entry. |
Methods inherited from class com.sas.services.publish.AbstractEntry |
---|
getDescription, getEntityKey, getNameValuePairs, getURL, isClosed, isReadOnly, sameEntity, setClosed, setDescription, setEntityKey, setNameValuePairs, setRead, throwExceptionIfClosed |
Methods inherited from interface com.sas.services.publish.EntryInterface |
---|
getDescription, getNameValuePairs, getURL, isReadOnly, setDescription, setNameValuePairs |
Constructor Detail |
---|
public HTMLEntry() throws java.rmi.RemoteException
java.rmi.RemoteException
- If a network anomaly is encountered.public HTMLEntry(HTMLFileInterface main, HTMLFileInterface[] companions) throws java.rmi.RemoteException
main
- The main HTML file for this HTML entry.companions
- The companion files for this HTML entry.
java.lang.IllegalArgumentException
- If an invalid role is specified for any
of the companion files or the main file. The main file must have a role of
HTMLFileInterface.MAIN_BODY_FILE
or HTMLFileInterface.MAIN_FRAME_FILE
.
The companion files must have a role of
HTMLFileInterface.BODY_COMPANION
, HTMLFileInterface.FRAME_COMPANION
,
HTMLFileInterface.CONTENTS_COMPANION
, HTMLFileInterface.PAGE_COMPANION
or
HTMLFileInterface.MISC_COMPANION
.
java.rmi.RemoteException
- If a network anomaly is encountered.Method Detail |
---|
public HTMLFileInterface getFile() throws java.rmi.RemoteException, TransportException, java.lang.IllegalStateException
getFile
in interface HTMLEntryInterface
HTMLFileInterface
The main HTML file for this set.
TransportException
- If the transport encounters an error
getting the file.
java.rmi.RemoteException
- If a network anomaly is encountered.
java.lang.IllegalStateException
- if the result package containing this
entry has already been closed.public void setFile(HTMLFileInterface mainFile) throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.rmi.RemoteException
setFile
in interface HTMLEntryInterface
mainFile
- The main HTML file for this HTML entry.
java.lang.IllegalArgumentException
- If the file type is anything other
than HTMLFileInterface.MAIN_BODY_FILE
or HTMLFileInterface.MAIN_FRAME_FILE
.
java.lang.IllegalStateException
- If the entry is read only or if the
result package containing this entry has already been closed.
java.rmi.RemoteException
- If a network anomaly is encountered.public HTMLFileInterface getFile(java.lang.String uniqueId) throws java.lang.IllegalStateException, java.rmi.RemoteException, TransportException
getFile
in interface HTMLEntryInterface
uniqueId
- The unique identifier of the desired file. This unique identifier
can identify the main file or any companion file within the
HTML entry.
HTMLFileInterface
The file within the HTML entry. This may be null
if no file is found with the specified identifier.
java.lang.IllegalStateException
- If the result package containing this entry
has already been closed.
TransportException
- If the transport encounters an error
getting the entry.
java.rmi.RemoteException
- If a network anomaly is encountered.public HTMLFileInterface[] getCompanionFiles() throws java.rmi.RemoteException, TransportException, java.lang.IllegalStateException
addCompanionFile(com.sas.services.publish.HTMLFileInterface)
and getCompanionFiles()
.
getCompanionFiles
in interface HTMLEntryInterface
HTMLFileInterface[]
An array of HTMLFileInterface
objects.
java.lang.IllegalStateException
- if the result package containing this
entry has already been closed.
TransportException
- If the transport encounters an error
getting the companion files.
java.rmi.RemoteException
- If a network anomaly is encountered.public void addCompanionFile(HTMLFileInterface companion) throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.rmi.RemoteException
addCompanionFile(com.sas.services.publish.HTMLFileInterface)
and getCompanionFiles()
.
addCompanionFile
in interface HTMLEntryInterface
companion
- The companion file to add to the existing HTML entry.
java.lang.IllegalArgumentException
- If the file type added is
HTMLFileInterface.MAIN_BODY_FILE
or HTMLFileInterface.MAIN_FRAME_FILE
.
java.lang.IllegalStateException
- If the entry is read only or if the result
package containing this entry has already been closed.
java.rmi.RemoteException
- If a network anomaly is encountered.public void setCompanionFiles(HTMLFileInterface[] companions) throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.rmi.RemoteException
setCompanionFiles
in interface HTMLEntryInterface
companions
- The companion files to set for this HTML entry.
java.lang.IllegalArgumentException
- If any of the companion files have a role of
HTMLFileInterface.MAIN_BODY_FILE
or HTMLFileInterface.MAIN_FRAME_FILE
.
java.lang.IllegalStateException
- If the entry is read only or if the package
containing this entry has already been closed.
java.rmi.RemoteException
- If a network anomaly is encountered.protected void closeEntry()
|
Foundation |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |