hpimdm/packet/PacketHPIMSync.py
def bytes(self) -> bytes:
        """
        Obtain entry of Protocol Sync in a format to be transmitted (binary)
        """
        flags_and_sync_sn = (self.master_flag << 31) | (self.more_flag << 30) | self.sync_sequence_number

        msg = struct.pack(self.PIM_HDR_INSTALL_WITHOUT_TREES, self.my_snapshot_sn,
                          self.neighbor_snapshot_sn, self.neighbor_boot_time, flags_and_sync_sn)
        if self.more_flag:
            for t in self.upstream_trees:
                msg += t.bytes()
        else:
            for option in self.options.values():
                msg += option.bytes()
        return msg

        Obtain entry of Protocol Sync in a format to be transmitted (binary)
        
Obtain entry of Protocol Sync in a format to be transmitted (binary)
Obtain entry of Protocol Sync in a format to be transmitted ( binary )
def bytes(self) -> bytes:
        flags_and_sync_sn = (self.master_flag << 31) | (self.more_flag << 30) | self.sync_sequence_number
        msg = struct.pack(self.PIM_HDR_INSTALL_WITHOUT_TREES, self.my_snapshot_sn,
                          self.neighbor_snapshot_sn, self.neighbor_boot_time, flags_and_sync_sn)
        if self.more_flag:
            for t in self.upstream_trees:
                msg += t.bytes()
        else:
            for option in self.options.values():
                msg += option.bytes()
        return msg
def bytes ( self ) -> bytes : flags_and_sync_sn = ( self . master_flag << 31 ) | ( self . more_flag << 30 ) | self . sync_sequence_number msg = struct . pack ( self . PIM_HDR_INSTALL_WITHOUT_TREES , self . my_snapshot_sn , self . neighbor_snapshot_sn , self . neighbor_boot_time , flags_and_sync_sn ) if self . more_flag : for t in self . upstream_trees : msg += t . bytes ( ) else : for option in self . options . values ( ) : msg += option . bytes ( ) return msg
Obtain entry of Protocol Sync in a format to be transmitted (binary)
Obtain entry of Protocol Sync in a format to be transmitted ( binary )
"""
        Obtain entry of Protocol Sync in a format to be transmitted (binary)
        """
self