You are here

public function WsConfigTypeController::create in Web Service Data 7

Create a wsconfig type - we first set up the values that are specific to our wsconfig type schema but then also go through the EntityAPIController function.

Parameters

$type: The machine-readable type of the wsconfig.

Return value

A wsconfig type object with all default fields initialized.

Overrides EntityAPIController::create

File

modules/wsconfig/wsconfig.entity.inc, line 524
Entity classes

Class

WsConfigTypeController
The Controller for wsconfig type entities

Code

public function create(array $values = array()) {

  // Add values that are specific to our Web Service Configuration
  $values += array(
    'id' => '',
    'is_new' => TRUE,
    'data' => array(),
  );
  $wsconfig_type = parent::create($values);
  return $wsconfig_type;
}