Logo Search packages:      
Sourcecode: xcb-proto version File versions

def xcbgen::xtypes::Type::make_member_of (   self,
  module,
  complex_type,
  field_type,
  field_name,
  visible,
  wire,
  auto 
) [inherited]

Default method for making a data type a member of a structure.
Extend this if the data type needs to add an additional length field or something.

module is the global module object.
complex_type is the structure object.
see Field for the meaning of the other parameters.

Reimplemented in xcbgen::xtypes::ListType.

Definition at line 57 of file xtypes.py.

00057                                                                                                :
        '''
        Default method for making a data type a member of a structure.
        Extend this if the data type needs to add an additional length field or something.

        module is the global module object.
        complex_type is the structure object.
        see Field for the meaning of the other parameters.
        '''
        new_field = Field(self, field_type, field_name, visible, wire, auto)

        # We dump the _placeholder_byte if any fields are added.
        for (idx, field) in enumerate(complex_type.fields):
            if field == _placeholder_byte:
                complex_type.fields[idx] = new_field
                return

        complex_type.fields.append(new_field)

class SimpleType(Type):


Generated by  Doxygen 1.6.0   Back to index