|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.dyuproject.protostuff.Pipe.Schema<T>
public abstract static class Pipe.Schema<T>
Schema for transferring data from a source (Input) to a
different sink (Output).
| Field Summary | |
|---|---|
Schema<T> |
wrappedSchema
|
| Constructor Summary | |
|---|---|
Pipe.Schema(Schema<T> wrappedSchema)
|
|
| Method Summary | |
|---|---|
java.lang.String |
getFieldName(int number)
Gets the field name associated with the number. |
int |
getFieldNumber(java.lang.String name)
Gets the field number associated with the name. |
boolean |
isInitialized(Pipe message)
Always returns true since we're just transferring data. |
void |
mergeFrom(Input input,
Pipe pipe)
Deserializes a message/object from the input. |
java.lang.String |
messageFullName()
Returns the full name of the message tied to this schema. |
java.lang.String |
messageName()
Returns the simple name of the message tied to this schema. |
Pipe |
newMessage()
Creates the message/object tied to this schema. |
protected abstract void |
transfer(Pipe pipe,
Input input,
Output output)
Transfer data from the Input to the Output. |
java.lang.Class<Pipe> |
typeClass()
Gets the class of the message. |
void |
writeTo(Output output,
Pipe pipe)
Serializes a message/object to the output. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public final Schema<T> wrappedSchema
| Constructor Detail |
|---|
public Pipe.Schema(Schema<T> wrappedSchema)
| Method Detail |
|---|
public java.lang.String getFieldName(int number)
Schemareturn String.valueOf(number);
getFieldName in interface Schema<Pipe>public int getFieldNumber(java.lang.String name)
Schemareturn Integer.parseInt(name);
getFieldNumber in interface Schema<Pipe>public boolean isInitialized(Pipe message)
isInitialized in interface Schema<Pipe>public java.lang.String messageFullName()
Schema
messageFullName in interface Schema<Pipe>public java.lang.String messageName()
Schema
messageName in interface Schema<Pipe>public Pipe newMessage()
Schema
newMessage in interface Schema<Pipe>public java.lang.Class<Pipe> typeClass()
Schema
typeClass in interface Schema<Pipe>
public final void writeTo(Output output,
Pipe pipe)
throws java.io.IOException
Schemaoutput.
writeTo in interface Schema<Pipe>java.io.IOException
public final void mergeFrom(Input input,
Pipe pipe)
throws java.io.IOException
Schemainput.
mergeFrom in interface Schema<Pipe>java.io.IOException
protected abstract void transfer(Pipe pipe,
Input input,
Output output)
throws java.io.IOException
Input to the Output.
java.io.IOException
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||