com.ibm.portal.state
Interface DisposableURL

All Superinterfaces:
Disposable, URL
All Known Subinterfaces:
CheckedEngineURL, EngineURL, FriendlyURL, PocURL

public interface DisposableURL
extends URL, Disposable

Representation of a URL object that should be disposed when no longer in use. The writeRelease writes the URL to a stream and disposes it in one single step, so if writeRelease is called, the object must not be disposed additionally.

Since:
5.1

Method Summary
 java.lang.String toString()
          Creates a URL representation of the URL.
 java.io.Writer writeCopy(java.io.Writer out)
          Streams the state represented by this URL object to a writer.
 java.io.Writer writeDispose(java.io.Writer out)
          Streams the state represented by this URL object to a writer.
 
Methods inherited from interface com.ibm.portal.URL
write
 
Methods inherited from interface com.ibm.portal.Disposable
dispose
 

Method Detail

toString

java.lang.String toString()
Creates a URL representation of the URL. Be aware that this is an expensive operation. Try to use one of the streaming methods instead.

Overrides:
toString in class java.lang.Object
Returns:
string representation of the URL

writeCopy

java.io.Writer writeCopy(java.io.Writer out)
                         throws java.io.IOException,
                                OutputMediatorException,
                                PostProcessorException,
                                DocumentModelException
Streams the state represented by this URL object to a writer. The URL's state however is not modified by calling this method, the write method may be used multiple times on the same object without side effects. From a performance perspective a call to this method is more expensive than calling the writeRelease method. If a called only needs to generate one single URL, the writeDispose(Writer) method should be used instead.

Parameters:
out - Destination stream that receives the character representation of the URL (must not be null)
Returns:
Reference to the writer
Throws:
java.io.IOException - - error on the underlying streams
OutputMediatorException - - error during the serialization operation
DocumentModelException - - if an optional temporary copy of the state could not be created
PostProcessorException - - if an optional post processing step failed

writeDispose

java.io.Writer writeDispose(java.io.Writer out)
                            throws java.io.IOException,
                                   OutputMediatorException,
                                   PostProcessorException
Streams the state represented by this URL object to a writer. It is invalid to access the engine URL object after invoking this method, calling Disposable.dispose() is no longer required.

Parameters:
out - Destination stream that receives the character representation of the URL (must not be null)
Returns:
Reference to the writer
Throws:
java.io.IOException - Error on the underlying streams
OutputMediatorException - - error during the serialization operation
PostProcessorException - - if an optional post processing step failed