2.4. Creating a struct

array &create ( string type [, array args] )

Creates a new struct.

Returns the created struct on success, or throws MimDbHandler_Exception on failure.

The arguments for each struct are listed below:

header

This struct cannot be created.

module

There is no agrument for this type.

contact

There is no agrument for this type.

settings

array(
  'module' => &array, // the array of module struct passed by reference
  'contact' => &array, // the array of contact struct passed by reference
  'values' => array(
    0 => &array, // the first setting
    1 => &array, // the second one
    ...
    n => &array, // the last one
  )
)

event

array(
  'module' => &array, // the array of module struct passed by reference
  'contact' => &array, // the array of contact struct passed by reference
  'values' => array(
    'timestamp' => int, // timestamp of event
    'flags' => int, // the flag of event
    'eventType' => int, // module-defined event type
    'blob' => string // blob (module-defined formatting)
  )
)