Jet\DataModel_IDController_UniqueString
The class of controller ID that itself generates a random timestamp string to identify a record before saving it.
The class inherits from Jet\DataModel_IDController.
The controller has option id_property_name, which specifies what property represents the element of the identification into which the string should be generated. The default value is: 'id'.
Overview of methods
Method | Meaning of |
---|---|
public beforeSave( ) : void |
The method performs the generation of a timestamped identification string before saving the record if it has not already been generated. |
public generate( ) : void |
ID generation can be called forcibly using this method at any time before saving the record. Useful when you need to know the future ID before you send the record to the database, so to speak. |
public afterSave( mixed $backend_save_result ) : void |
The method does nothing. |