Class Pipe.Schema<T>
java.lang.Object
io.protostuff.Pipe.Schema<T>
- Direct Known Subclasses:
RuntimePipeSchema
- Enclosing class:
Pipe
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetFieldName(int number) Gets the field name associated with the number.intgetFieldNumber(String name) Gets the field number associated with the name.booleanisInitialized(Pipe message) Always returns true since we're just transferring data.final voidDeserializes a message/object from theinput.Returns the full name of the message tied to this schema.Returns the simple name of the message tied to this schema.Creates the message/object tied to this schema.protected abstract voidGets the class of the message.final voidSerializes a message/object to theoutput.
-
Field Details
-
wrappedSchema
-
-
Constructor Details
-
Schema
-
-
Method Details
-
getFieldName
Description copied from interface:SchemaGets the field name associated with the number. This is particularly useful when serializing to different formats (Eg. JSON). When using numeric field names:return String.valueOf(number);
- Specified by:
getFieldNamein interfaceSchema<T>
-
getFieldNumber
Description copied from interface:SchemaGets the field number associated with the name. This is particularly useful when serializing to different formats (Eg. JSON). When using numeric field names:return Integer.parseInt(name);
- Specified by:
getFieldNumberin interfaceSchema<T>
-
isInitialized
Always returns true since we're just transferring data.- Specified by:
isInitializedin interfaceSchema<T>
-
messageFullName
Description copied from interface:SchemaReturns the full name of the message tied to this schema. Allows custom schemas to provide a custom name other than typeClass().getName();- Specified by:
messageFullNamein interfaceSchema<T>
-
messageName
Description copied from interface:SchemaReturns the simple name of the message tied to this schema. Allows custom schemas to provide a custom name other than typeClass().getSimpleName();- Specified by:
messageNamein interfaceSchema<T>
-
newMessage
Description copied from interface:SchemaCreates the message/object tied to this schema.- Specified by:
newMessagein interfaceSchema<T>
-
typeClass
-
writeTo
-
mergeFrom
-
transfer
- Throws:
IOException
-