python-flashmedia
python-flashmedia copied to clipboard
AMFMessage size
class AMFMessage(Packet):
@property
def size(self):
size = 4
size += AMF0String.size(self.target_uri)
size += AMF0String.size(self.response_uri)
size += AMF0Value.size(self.value)
return size
Why size is set that way? And what is 4? According to AMF specification length - property of message body without target-uri and response-uri: (http://wwwimages.adobe.com/content/dam/Adobe/en/devnet/amf/pdf/amf0-file-format-specification.pdf) "The third field of an AMF message is the byte length of the message body"