def toProtocolTreeNode(self): node = super(RetryIncomingReceiptProtocolEntity, self).toProtocolTreeNode() retry = ProtocolTreeNode( "retry", {"count": str(self.count), "id": self.getId(), "v": str(self.v), "t": str(self.retryTimestamp)} ) node.addChild(retry) registration = ProtocolTreeNode( "registration", data=ResultGetKeysIqProtocolEntity._intToBytes(self.remoteRegistrationId) ) node.addChild(registration) return node
def toProtocolTreeNode(self): node = super(RetryOutgoingReceiptProtocolEntity, self).toProtocolTreeNode() node.setAttribute("type", "retry") retryAttribs = { "count": str(self.count), "id":self.getId(), "v":str(self.v), "t": str(self.retryTimestamp) } retry = ProtocolTreeNode("retry", retryAttribs) node.addChild(retry) registration = ProtocolTreeNode("registration", data=ResultGetKeysIqProtocolEntity._intToBytes(self.localRegistrationId)) node.addChild(registration) return node
def toProtocolTreeNode(self): node = super(RetryIncomingReceiptProtocolEntity, self).toProtocolTreeNode() retry = ProtocolTreeNode( "retry", { "count": str(self.count), "id": self.getId(), "v": str(self.v), "t": str(self.retryTimestamp) }) node.addChild(retry) registration = ProtocolTreeNode( "registration", data=ResultGetKeysIqProtocolEntity._intToBytes( self.remoteRegistrationId)) node.addChild(registration) return node
def setRegData(self,regData): ''' In axolotl layer: regData = self.store.getLocalRegistrationId() ''' self.regData = ResultGetKeysIqProtocolEntity._intToBytes(regData)
def setRegData(self, regData): ''' In axolotl layer: regData = self.store.getLocalRegistrationId() ''' self.regData = ResultGetKeysIqProtocolEntity._intToBytes(regData)