lithium\data\Source::create()
Create a record. This is the abstract method that is implemented by specific data sources. This method should take a query object and use it to create a record in the data source.
Parameters
-
mixed
$query
An object which defines the update operation(s) that should be performed against the data store. This can be a
Query
, aRecordSet
, aRecord
, or a subclass of one of the three. Alternatively,$query
can be an adapter-specific query string. -
array
$options
The options from Model include,
validate
boolean default: trueevents
string default: createwhitelist
array default: nullcallbacks
boolean default: truelocked
boolean default: true
Returns
booleanReturns true if the operation was a success, otherwise false.
Source
abstract public function create($query, array $options = array());