public abstract class BaseMessage<T> extends java.lang.Object implements Message<T>
| Modifier and Type | Field and Description |
|---|---|
protected int |
memoizedSerializedSize |
| Constructor and Description |
|---|
BaseMessage() |
| Modifier and Type | Method and Description |
|---|---|
protected static <T> void |
addAll(java.lang.Iterable<T> values,
java.util.Collection<? super T> list) |
T |
assertInitialized() |
protected T |
checktInitialized() |
void |
clear() |
abstract T |
clone() |
protected static int |
computeGroupSize(int tag,
BaseMessage message) |
protected static int |
computeMessageSize(int tag,
BaseMessage message) |
boolean |
isInitialized() |
protected void |
load() |
protected void |
loadAndClear() |
T |
mergeFramed(Buffer data) |
T |
mergeFramed(byte[] data) |
T |
mergeFramed(CodedInputStream input) |
T |
mergeFramed(java.io.InputStream input) |
T |
mergeFrom(T other) |
T |
mergeUnframed(Buffer data) |
T |
mergeUnframed(byte[] data) |
T |
mergeUnframed(java.io.InputStream input) |
java.util.ArrayList<java.lang.String> |
missingFields() |
protected java.util.List<java.lang.String> |
prefix(java.util.List<java.lang.String> missingFields,
java.lang.String prefix) |
protected static <T extends BaseMessage> |
readGroup(CodedInputStream input,
int tag,
T group) |
protected static byte |
readRawByte(java.io.InputStream is) |
static int |
readRawVarint32(java.io.InputStream is)
Read a raw Varint from the stream.
|
int |
serializedSizeFramed() |
Buffer |
toFramedBuffer() |
byte[] |
toFramedByteArray() |
Buffer |
toUnframedBuffer() |
byte[] |
toUnframedByteArray() |
void |
writeFramed(CodedOutputStream output) |
void |
writeFramed(java.io.OutputStream output) |
protected static void |
writeGroup(CodedOutputStream output,
int tag,
BaseMessage message) |
protected static void |
writeMessage(CodedOutputStream output,
int tag,
BaseMessage message) |
void |
writeUnframed(CodedOutputStream output) |
void |
writeUnframed(java.io.OutputStream output) |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitmergeUnframed, serializedSizeUnframedpublic abstract T clone() throws java.lang.CloneNotSupportedException
public boolean isInitialized()
public T assertInitialized() throws UninitializedMessageException
assertInitialized in interface Message<T>UninitializedMessageExceptionprotected T checktInitialized() throws InvalidProtocolBufferException
InvalidProtocolBufferExceptionpublic java.util.ArrayList<java.lang.String> missingFields()
protected void loadAndClear()
protected void load()
public void writeUnframed(CodedOutputStream output) throws java.io.IOException
writeUnframed in interface Message<T>java.io.IOExceptionpublic void writeFramed(CodedOutputStream output) throws java.io.IOException
writeFramed in interface Message<T>java.io.IOExceptionpublic Buffer toUnframedBuffer()
toUnframedBuffer in interface Message<T>public Buffer toFramedBuffer()
toFramedBuffer in interface Message<T>public byte[] toUnframedByteArray()
toUnframedByteArray in interface Message<T>public byte[] toFramedByteArray()
toFramedByteArray in interface Message<T>public void writeFramed(java.io.OutputStream output)
throws java.io.IOException
writeFramed in interface Message<T>java.io.IOExceptionpublic void writeUnframed(java.io.OutputStream output)
throws java.io.IOException
writeUnframed in interface Message<T>java.io.IOExceptionpublic int serializedSizeFramed()
serializedSizeFramed in interface Message<T>public T mergeFramed(CodedInputStream input) throws java.io.IOException
mergeFramed in interface Message<T>java.io.IOExceptionpublic T mergeUnframed(Buffer data) throws InvalidProtocolBufferException
mergeUnframed in interface Message<T>InvalidProtocolBufferExceptionpublic T mergeFramed(Buffer data) throws InvalidProtocolBufferException
mergeFramed in interface Message<T>InvalidProtocolBufferExceptionpublic T mergeUnframed(byte[] data) throws InvalidProtocolBufferException
mergeUnframed in interface Message<T>InvalidProtocolBufferExceptionpublic T mergeFramed(byte[] data) throws InvalidProtocolBufferException
mergeFramed in interface Message<T>InvalidProtocolBufferExceptionpublic T mergeUnframed(java.io.InputStream input) throws java.io.IOException
mergeUnframed in interface Message<T>java.io.IOExceptionpublic T mergeFramed(java.io.InputStream input) throws java.io.IOException
mergeFramed in interface Message<T>java.io.IOExceptionprotected static <T> void addAll(java.lang.Iterable<T> values,
java.util.Collection<? super T> list)
protected static void writeGroup(CodedOutputStream output, int tag, BaseMessage message) throws java.io.IOException
java.io.IOExceptionprotected static <T extends BaseMessage> T readGroup(CodedInputStream input, int tag, T group) throws java.io.IOException
java.io.IOExceptionprotected static int computeGroupSize(int tag,
BaseMessage message)
protected static void writeMessage(CodedOutputStream output, int tag, BaseMessage message) throws java.io.IOException
java.io.IOExceptionprotected static int computeMessageSize(int tag,
BaseMessage message)
protected java.util.List<java.lang.String> prefix(java.util.List<java.lang.String> missingFields,
java.lang.String prefix)
public static int readRawVarint32(java.io.InputStream is)
throws java.io.IOException
java.io.IOExceptionprotected static byte readRawByte(java.io.InputStream is)
throws java.io.IOException
java.io.IOExceptionCopyright © 2010-2014 FuseSource, Corp.. All Rights Reserved.