Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseRoutingTags ¶
ParseRoutingTags parse routing tags in metadata. See: https://github.com/rsocket/rsocket/blob/master/Extensions/Routing.md
Types ¶
type CompositeMetadata ¶
type CompositeMetadata interface { io.WriterTo // MIME returns MIME type. MIME() string // Payload returns bytes of Metadata payload. Payload() []byte // contains filtered or unexported methods }
CompositeMetadata provides multi Metadata payloads with different MIME types.
func DecodeCompositeMetadata ¶
func DecodeCompositeMetadata(raw []byte) ([]CompositeMetadata, error)
DecodeCompositeMetadata decode bytes to composite metadata.
func NewCompositeMetadata ¶
func NewCompositeMetadata(mime string, metadataPayload []byte) CompositeMetadata
NewCompositeMetadata returns a new composite metadata.
type MIME ¶
type MIME int8
MIME is MIME types in number. Please see: https://github.com/rsocket/rsocket/blob/master/Extensions/WellKnownMimeTypes.md
const ( ApplicationAvro MIME = iota ApplicationCBOR ApplicationGraphql ApplicationGzip ApplicationJavascript ApplicationJSON ApplicationOctetStream ApplicationPDF ApplicationThrift ApplicationProtobuf ApplicationXML ApplicationZip AudioAAC AudioMP3 AudioMP4 AudioMPEG3 AudioMPEG AudioOGG AudioOpus AudioVorbis ImageBMP ImageGIF ImageHEICSequence ImageHEIC ImageHEIFSequence ImageHEIF ImageJPEG ImagePNG ImageTIFF MultipartMixed TextCSS TextCSV TextHTML TextPlain TextXML VideoH264 VideoH265 VideoVP8 Hessian JavaObject CloudEventsJSON MessageZipkin MIME = 0x7D MessageRouting MIME = 0x7E MessageCompositeMetadata MIME = 0x7F )
All MIMEs
Click to show internal directories.
Click to hide internal directories.