Serializes the :attr:`data` object referenced by the `Pointer` field
        to bytes by mapping the :attr:`~Field.value` for each :class:`Field`
        in the :attr:`data` object to a number of bytes in accordance with the
        encoding *byte order* for the serialization and the encoding
        :attr:`byte_order` of each :class:`Field` in the :attr:`data` object.

        A specific encoding :attr:`~Field.byte_order` of a :class:`Field` in
        the :attr:`data` object overrules the encoding *byte order* for the
        serialization.

        Returns a number of bytes for the serialized :attr:`data` object
        referenced by the `Pointer` field.

        :keyword byte_order: encoding byte order for the serialization.
            Default is the :attr:`data_byte_order` of the `Pointer` field.
        :type byte_order: :class:`Byteorder`, :class:`str`

def serialize_data(self, byte_order=None):
        """ Serializes the :attr:`data` object referenced by the `Pointer` field
        to bytes by mapping the :attr:`~Field.value` for each :class:`Field`
        in the :attr:`data` object to a number of bytes in accordance with the
        encoding *byte order* for the serialization and the encoding
        :attr:`byte_order` of each :class:`Field` in the :attr:`data` object.

        A specific encoding :attr:`~Field.byte_order` of a :class:`Field` in
        the :attr:`data` object overrules the encoding *byte order* for the
        serialization.

        Returns a number of bytes for the serialized :attr:`data` object
        referenced by the `Pointer` field.

        :keyword byte_order: encoding byte order for the serialization.
            Default is the :attr:`data_byte_order` of the `Pointer` field.
        :type byte_order: :class:`Byteorder`, :class:`str`
        """
        if self._data is None:
            return bytes()
        if byte_order not in ('little', 'big', Byteorder.little, Byteorder.big):
            byte_order = self.data_byte_order
        buffer = bytearray()
        self._data.serialize(buffer,
                             Index(0, 0,
                                   self.address, self.base_address,
                                   False),
                             byte_order=byte_order)
        return bytes(buffer)