public class TvWriter
extends java.lang.Object
Used for server side implementation.
This class mimics the PrintWriter class, but writes
a tag-value list to the stream.
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String[] |
DEP_LIST
Class dependencies
|
static java.lang.String |
VERSION
Class version
|
| Constructor and Description |
|---|
TvWriter(java.io.PrintWriter writer)
Create a TvWriter for MT_APP_URLENC.
|
TvWriter(java.io.PrintWriter writer,
int mimeTypeId)
Create a TvWriter for the specified MIME Type.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkError()
Flush the underlying stream and check its error state.
|
void |
close()
Close the underlying data stream.
|
int |
getMimeTypeId()
Get the MIME type of the output.
|
java.io.PrintWriter |
getWriter()
Get the underlying PrintWriter to the output stream.
|
void |
println(java.lang.String tag,
java.lang.String value)
Print a tag-value pair to the destination.
|
void |
println(TvList data)
Print a tag-value list to the destination.
|
public static final java.lang.String VERSION
public static final java.lang.String[] DEP_LIST
public TvWriter(java.io.PrintWriter writer)
writer - A PrintWriter to the data destination.public TvWriter(java.io.PrintWriter writer,
int mimeTypeId)
writer - A PrintWriter to the data destination.mimeTypeId - MIME type to write.public void close()
public boolean checkError()
public void println(java.lang.String tag,
java.lang.String value)
tag - The tag to write.value - The value to write.public void println(TvList data)
data - The tag-value list to write.public java.io.PrintWriter getWriter()
public int getMimeTypeId()