Package org.apache.cassandra.net
Class Message.Builder<T>
- java.lang.Object
-
- org.apache.cassandra.net.Message.Builder<T>
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Message<T>
build()
Message.Builder<T>
from(InetAddressAndPort from)
Message.Builder<T>
ofVerb(Verb verb)
Message.Builder<T>
withCreatedAt(long createdAtNanos)
Message.Builder<T>
withCustomParam(java.lang.String name, byte[] value)
Message.Builder<T>
withExpiresAt(long expiresAtNanos)
Message.Builder<T>
withFlag(MessageFlag flag)
Message.Builder<T>
withFlags(int flags)
Message.Builder<T>
withId(long id)
Message.Builder<T>
withoutParam(ParamType type)
Message.Builder<T>
withParam(ParamType type, java.lang.Object value)
Message.Builder<T>
withParams(java.util.Map<ParamType,java.lang.Object> params)
Message.Builder<T>
withPayload(T payload)
Message.Builder<T>
withTracingParams()
A shortcut to add tracing params.
-
-
-
Method Detail
-
from
public Message.Builder<T> from(InetAddressAndPort from)
-
withPayload
public Message.Builder<T> withPayload(T payload)
-
withFlag
public Message.Builder<T> withFlag(MessageFlag flag)
-
withFlags
public Message.Builder<T> withFlags(int flags)
-
withParam
public Message.Builder<T> withParam(ParamType type, java.lang.Object value)
-
withCustomParam
public Message.Builder<T> withCustomParam(java.lang.String name, byte[] value)
-
withTracingParams
public Message.Builder<T> withTracingParams()
A shortcut to add tracing params. Effectively, it is the same as callingwithParam(ParamType, Object)
with tracing params If there is already tracing params, calling this method overrides any existing ones.
-
withoutParam
public Message.Builder<T> withoutParam(ParamType type)
-
withParams
public Message.Builder<T> withParams(java.util.Map<ParamType,java.lang.Object> params)
-
ofVerb
public Message.Builder<T> ofVerb(Verb verb)
-
withCreatedAt
public Message.Builder<T> withCreatedAt(long createdAtNanos)
-
withExpiresAt
public Message.Builder<T> withExpiresAt(long expiresAtNanos)
-
withId
public Message.Builder<T> withId(long id)
-
-