(bytes->string bytes)
Returns a string given a byte-array
Returns a string given a byte-array
Charset used for the string <-> byte-array conversions
Charset used for the string <-> byte-array conversions
(decode bytes)
Inputs: [bytes :- ByteArray] Returns: Message
Returns a message object from a network format message
Inputs: [bytes :- ByteArray] Returns: Message Returns a message object from a network format message
(decode-descriptor byte)
Returns the clojure object for a chunk descriptor from a byte
Returns the clojure object for a chunk descriptor from a byte
(encode message)
Inputs: [message :- Message] Returns: ByteArray
Inputs: [message :- Message] Returns: ByteArray
(encode-descriptor type)
Returns a binary representation of a chunk descriptor
Returns a binary representation of a chunk descriptor
(filter-private message)
Deprecated, use message->envelope if you need
Deprecated, use message->envelope if you need
(get-data message)
Inputs: [message :- Message] Returns: ByteArray
Returns the data from the data frame
Inputs: [message :- Message] Returns: ByteArray Returns the data from the data frame
(get-debug message)
Inputs: [message :- Message] Returns: ByteArray
Returns the data from the debug frame
Inputs: [message :- Message] Returns: ByteArray Returns the data from the debug frame
(get-json-data message)
Inputs: [message :- Message] Returns: s/Any
Returns the data from the data frame decoded from json
Inputs: [message :- Message] Returns: s/Any Returns the data from the data frame decoded from json
(get-json-debug message)
Inputs: [message :- Message] Returns: s/Any
Returns the data from the debug frame decoded from json
Inputs: [message :- Message] Returns: s/Any Returns the data from the debug frame decoded from json
(make-message)
(make-message opts)
(make-message k v & kvs)
Inputs: ([] [k v & kvs] [opts]) Returns: Message
Returns a new empty message structure
Inputs: ([] [k v & kvs] [opts]) Returns: Message Returns a new empty message structure
Defines the message objects we're using
Defines the message objects we're using
(message->envelope message)
Inputs: [message :- Message] Returns: v1-Envelope
Returns the map without any of the known 'private' keys. Should map to an envelope schema.
Inputs: [message :- Message] Returns: v1-Envelope Returns the map without any of the known 'private' keys. Should map to an envelope schema.
(set-data message data)
(set-data message data flags)
Inputs: ([message :- Message data :- ByteArray] [message :- Message data :- ByteArray flags :- FlagSet]) Returns: Message
Sets the data for the data frame
Inputs: ([message :- Message data :- ByteArray] [message :- Message data :- ByteArray flags :- FlagSet]) Returns: Message Sets the data for the data frame
(set-debug message data)
(set-debug message data flags)
Inputs: ([message :- Message data :- ByteArray] [message :- Message data :- ByteArray flags :- FlagSet]) Returns: Message
Sets the data for the debug frame
Inputs: ([message :- Message data :- ByteArray] [message :- Message data :- ByteArray flags :- FlagSet]) Returns: Message Sets the data for the debug frame
(set-expiry message timestamp)
(set-expiry message number unit)
Inputs: ([message :- Message number :- s/Int unit :- s/Keyword] [message :- Message timestamp :- ISO8601]) Returns: Message
Returns a message with new expiry
Inputs: ([message :- Message number :- s/Int unit :- s/Keyword] [message :- Message timestamp :- ISO8601]) Returns: Message Returns a message with new expiry
(set-json-data message data)
Inputs: [message :- Message data :- s/Any] Returns: Message
Sets the data to be the json byte-array version of data
Inputs: [message :- Message data :- s/Any] Returns: Message Sets the data to be the json byte-array version of data
(set-json-debug message data)
Inputs: [message :- Message data :- s/Any] Returns: Message
Sets the debug data to be the json byte-array version of data
Inputs: [message :- Message data :- s/Any] Returns: Message Sets the debug data to be the json byte-array version of data
(string->bytes s)
Returns an array of bytes from a string
Returns an array of bytes from a string
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close