com.google.gwt.user.client.rpc.impl
Class ClientSerializationStreamWriter

java.lang.Object
  extended by com.google.gwt.user.client.rpc.impl.AbstractSerializationStream
      extended by com.google.gwt.user.client.rpc.impl.AbstractSerializationStreamWriter
          extended by com.google.gwt.user.client.rpc.impl.ClientSerializationStreamWriter
All Implemented Interfaces:
SerializationStreamWriter

public final class ClientSerializationStreamWriter
extends AbstractSerializationStreamWriter

For internal use only. Used for server call serialization.


Field Summary
 
Fields inherited from class com.google.gwt.user.client.rpc.impl.AbstractSerializationStream
DEFAULT_FLAGS, FLAG_ELIDE_TYPE_NAMES, RPC_SEPARATOR_CHAR, SERIALIZATION_STREAM_MIN_VERSION, SERIALIZATION_STREAM_VERSION
 
Constructor Summary
ClientSerializationStreamWriter(Serializer serializer, java.lang.String moduleBaseURL, java.lang.String serializationPolicyStrongName)
          Constructs a ClientSerializationStreamWriter using the specified module base URL and the serialization policy.
 
Method Summary
 void prepareToWrite()
          Call this method before attempting to append any tokens.
static java.lang.String quoteString(java.lang.String str)
          Quote characters in a user-supplied string to make sure they are safe to send to the server.
 java.lang.String toString()
          Serializes the contents of this stream into a string.
 void writeLong(long value)
           
 
Methods inherited from class com.google.gwt.user.client.rpc.impl.AbstractSerializationStreamWriter
getAsDoubleArray, writeBoolean, writeByte, writeChar, writeDouble, writeFloat, writeInt, writeObject, writeShort, writeString
 
Methods inherited from class com.google.gwt.user.client.rpc.impl.AbstractSerializationStream
addFlags, getFlags, getVersion, hasFlags, setFlags
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClientSerializationStreamWriter

public ClientSerializationStreamWriter(Serializer serializer,
                                       java.lang.String moduleBaseURL,
                                       java.lang.String serializationPolicyStrongName)
Constructs a ClientSerializationStreamWriter using the specified module base URL and the serialization policy.

Parameters:
serializer - the Serializer to use
moduleBaseURL - the location of the module
serializationPolicyStrongName - the strong name of serialization policy
Method Detail

quoteString

public static java.lang.String quoteString(java.lang.String str)
Quote characters in a user-supplied string to make sure they are safe to send to the server.

Parameters:
str - string to quote
Returns:
quoted string

prepareToWrite

public void prepareToWrite()
Call this method before attempting to append any tokens. This method implementation must be called by any overridden version.

Overrides:
prepareToWrite in class AbstractSerializationStreamWriter

toString

public java.lang.String toString()
Description copied from interface: SerializationStreamWriter
Serializes the contents of this stream into a string.

Specified by:
toString in interface SerializationStreamWriter
Specified by:
toString in class AbstractSerializationStreamWriter
Returns:
a string that is the serialization of the contents of this stream

writeLong

public void writeLong(long value)
Specified by:
writeLong in interface SerializationStreamWriter
Specified by:
writeLong in class AbstractSerializationStreamWriter