[ Index ] |
|
Code source de Symfony 1.0.0 |
[Code source] [Imprimer] [Statistiques]
(pas de description)
Poids: | 57 lignes (2 kb) |
Inclus ou requis: | 0 fois |
Référencé: | 0 fois |
Nécessite: | 0 fichiers |
IdGenerator:: (4 méthodes):
isBeforeInsert()
isAfterInsert()
getIdMethod()
getId()
Interface: IdGenerator - X-Ref
Interface for classes that provide functionality to get SEQUENCE or AUTO-INCREMENT ids from the database.isBeforeInsert() X-Ref |
Convenience method that returns TRUE if id is generated before an INSERT statement. This is the same as checking whether the generator type is SEQUENCE. return: boolean TRUE if gen id method is SEQUENCE |
isAfterInsert() X-Ref |
Convenience method that returns TRUE if id is generated after an INSERT statement. This is the same as checking whether the generator type is AUTOINCREMENT. return: boolean TRUE if gen id method is AUTOINCREMENT |
getIdMethod() X-Ref |
Get the preferred type / style for generating ids for RDBMS. return: int SEQUENCE or AUTOINCREMENT |
getId($keyInfo = null) X-Ref |
Get the autoincrement or sequence id given the current connection and any additional needed info (e.g. sequence name for sequences). <p> Note: if you take advantage of the fact that $keyInfo may not be specified you should make sure that your code is setup in such a way that it will be portable if you change from an RDBMS that uses AUTOINCREMENT to one that uses SEQUENCE (i.e. in which case you would need to specify sequence name). param: mixed $keyInfo Any additional information (e.g. sequence name) needed to fetch the id. return: int The last id / next id. |
Généré le : Fri Mar 16 22:42:14 2007 | par Balluche grâce à PHPXref 0.7 |