Interface MessageConfig<T>
- Type Parameters:
T- payload type
- All Superinterfaces:
Prototype.Api, Prototype.Factory<Message<T>>
Message construction options.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classFluent API builder forMessage.static classMessageConfig.BuilderBase<T, BUILDER extends MessageConfig.BuilderBase<T, BUILDER, PROTOTYPE>, PROTOTYPE extends MessageConfig<T>>Fluent API builder base forMessageConfig. -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> MessageConfig.Builder<T> builder()Create a new fluent API builder to customize configuration.static <T> MessageConfig.Builder<T> builder(MessageConfig<T> instance) Create a new fluent API builder from an existing instance.entity()Non-null message payload.headers()Ordered portable headers.Metadata local to this message envelope.Methods inherited from interface Prototype.Factory
build
-
Method Details
-
builder
Create a new fluent API builder to customize configuration.- Type Parameters:
T- payload type- Returns:
- a new builder
-
builder
Create a new fluent API builder from an existing instance.- Type Parameters:
T- payload type- Parameters:
instance- an existing instance used as a base for the builder- Returns:
- a builder based on an instance
-
entity
-
headers
List<MessageHeader> headers()Ordered portable headers. Defaults to an empty list. Setting this option replaces the current entries; adding headers preserves their order and duplicate names. The builder accumulates entries in a mutable list and the prototype contains an immutable snapshot.- Returns:
- portable headers
-
localMetadata
Map<String, MessageHeaderValue> localMetadata()Metadata local to this message envelope. Defaults to an empty map. Setting this option replaces the current entries; adding a value replaces the value with the same exact name. The builder accumulates entries in a mutable map and the prototype contains an immutable snapshot. Local metadata remains in-process and is not part of portable headers or generic connector mapping.- Returns:
- local metadata
-