This document describes the current stable version of py-amqp (2.2). For development docs, go here.

amqp.serialization

Convert between bytestreams and higher-level AMQP types.

2007-11-05 Barry Pederson <bp@barryp.org>

class amqp.serialization.GenericContent(frame_method=None, frame_args=None, **props)[source]

Abstract base class for AMQP content.

Subclasses should override the PROPERTIES attribute.

CLASS_ID = None
PROPERTIES = [(u'dummy', u's')]
inbound_body(buf)[source]
inbound_header(buf, offset=0)[source]
amqp.serialization.decode_properties_basic(buf, offset=0, unpack_from=<built-in function unpack_from>, pstr_t=<function bytes_to_str>)[source]

Decode basic properties.

amqp.serialization.dumps(format, values)[source]

“Serialize AMQP arguments.

Notes:
bit = b octet = o short = B long = l long long = L shortstr = s longstr = S table = F array = A
amqp.serialization.loads(format, buf, offset=0, ord=<built-in function ord>, unpack_from=<built-in function unpack_from>, _read_item=<function _read_item>, pstr_t=<function bytes_to_str>)[source]

Deserialize amqp format.

bit = b octet = o short = B long = l long long = L float = f shortstr = s longstr = S table = F array = A timestamp = T