Package io.protostuff
Class MessageCollectionSchema<V>
- java.lang.Object
-
- io.protostuff.CollectionSchema<V>
-
- io.protostuff.MessageCollectionSchema<V>
-
- All Implemented Interfaces:
Schema<java.util.Collection<V>>
public final class MessageCollectionSchema<V> extends CollectionSchema<V>
A schema for aCollectionwithMessageor pojo values. Does not allow null values.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class io.protostuff.CollectionSchema
CollectionSchema.MessageFactories, CollectionSchema.MessageFactory
-
-
Field Summary
Fields Modifier and Type Field Description Pipe.Schema<V>pipeSchemaThe pipe schema of the member (message).Schema<V>schemaThe schema of the member (message).-
Fields inherited from class io.protostuff.CollectionSchema
FIELD_NAME_NULL, FIELD_NAME_VALUE, MESSAGE_FACTORIES_NAMES, messageFactory, preserveNull
-
-
Constructor Summary
Constructors Constructor Description MessageCollectionSchema(Schema<V> schema, boolean preserveNull)MessageCollectionSchema(Schema<V> schema, Pipe.Schema<V> pipeSchema, boolean preserveNull)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddValueFrom(Input input, java.util.Collection<V> collection)Adds the value from the input into theCollection.protected voidtransferValue(Pipe pipe, Input input, Output output, int number, boolean repeated)Transfers the value from the input to the output.protected voidwriteValueTo(Output output, int fieldNumber, V value, boolean repeated)Writes the value to the output.-
Methods inherited from class io.protostuff.CollectionSchema
fieldName, fieldNumber, getFieldName, getFieldNumber, isInitialized, mergeFrom, messageFullName, messageName, newMessage, typeClass, writeTo
-
-
-
-
Field Detail
-
pipeSchema
public final Pipe.Schema<V> pipeSchema
The pipe schema of the member (message).
-
-
Method Detail
-
addValueFrom
protected void addValueFrom(Input input, java.util.Collection<V> collection) throws java.io.IOException
Description copied from class:CollectionSchemaAdds the value from the input into theCollection.- Specified by:
addValueFromin classCollectionSchema<V>- Throws:
java.io.IOException
-
writeValueTo
protected void writeValueTo(Output output, int fieldNumber, V value, boolean repeated) throws java.io.IOException
Description copied from class:CollectionSchemaWrites the value to the output.- Specified by:
writeValueToin classCollectionSchema<V>- Throws:
java.io.IOException
-
transferValue
protected void transferValue(Pipe pipe, Input input, Output output, int number, boolean repeated) throws java.io.IOException
Description copied from class:CollectionSchemaTransfers the value from the input to the output.- Specified by:
transferValuein classCollectionSchema<V>- Throws:
java.io.IOException
-
-