__enter__(self) |
|
__exit__(self, type_, value, traceback) |
|
__iter__(self) |
Iterate over all pending or persistent instances within this [extrait de __iter__.__doc__] |
add(self, instance, _warn=True) |
Place an object in the ``Session``. [extrait de add.__doc__] |
add_all(self, instances) |
Add the given collection of instances to this ``Session``. [extrait de add_all.__doc__] |
begin(self, subtransactions=False, nested=False, _subtrans=False) |
Begin a transaction, or nested transaction, [extrait de begin.__doc__] |
begin_nested(self) |
Begin a "nested" transaction on this Session, e.g. SAVEPOINT. [extrait de begin_nested.__doc__] |
bind_mapper(self, mapper, bind) |
Associate a :class:`_orm.Mapper` or arbitrary Python class with a [extrait de bind_mapper.__doc__] |
bind_table(self, table, bind) |
Associate a :class:`_schema.Table` with a "bind", e.g. an [extrait de bind_table.__doc__] |
bulk_insert_mappings(self, mapper, mappings, return_defaults=False, render_nulls=False) |
Perform a bulk insert of the given list of mapping dictionaries. [extrait de bulk_insert_mappings.__doc__] |
bulk_save_objects(self, objects, return_defaults=False, update_changed_only=True, preserve_order=True) |
Perform a bulk save of the given list of objects. [extrait de bulk_save_objects.__doc__] |
bulk_update_mappings(self, mapper, mappings) |
Perform a bulk update of the given list of mapping dictionaries. [extrait de bulk_update_mappings.__doc__] |
close(self) |
Close out the transactional resources and ORM objects used by this [extrait de close.__doc__] |
commit(self) |
Flush pending changes and commit the current transaction. [extrait de commit.__doc__] |
connection(self, bind_arguments=None, close_with_result=False, execution_options=None, **kw) |
Return a :class:`_engine.Connection` object corresponding to this [extrait de connection.__doc__] |
delete(self, instance) |
Mark an instance as deleted. [extrait de delete.__doc__] |
enable_relationship_loading(self, obj) |
Associate an object with this :class:`.Session` for related [extrait de enable_relationship_loading.__doc__] |
execute(self, statement, params=None, execution_options=immutabledict({}), bind_arguments=None, _parent_execute_state=None, _add_event=None, **kw) |
Execute a SQL expression construct. [extrait de execute.__doc__] |
expire(self, instance, attribute_names=None) |
Expire the attributes on an instance. [extrait de expire.__doc__] |
expire_all(self) |
Expires all persistent instances within this Session. [extrait de expire_all.__doc__] |
expunge(self, instance) |
Remove the `instance` from this ``Session``. [extrait de expunge.__doc__] |
expunge_all(self) |
Remove all object instances from this ``Session``. [extrait de expunge_all.__doc__] |
flush(self, objects=None) |
Flush all the object changes to the database. [extrait de flush.__doc__] |
get(self, entity, ident, options=None, populate_existing=False, with_for_update=None, identity_token=None) |
Return an instance based on the given primary key identifier, [extrait de get.__doc__] |
get_bind(self, mapper=None, clause=None, bind=None, _sa_skip_events=None, _sa_skip_for_implicit_returning=False) |
Return a "bind" to which this :class:`.Session` is bound. [extrait de get_bind.__doc__] |
get_nested_transaction(self) |
Return the current nested transaction in progress, if any. [extrait de get_nested_transaction.__doc__] |
get_transaction(self) |
Return the current root transaction in progress, if any. [extrait de get_transaction.__doc__] |
in_nested_transaction(self) |
Return True if this :class:`_orm.Session` has begun a nested [extrait de in_nested_transaction.__doc__] |
in_transaction(self) |
Return True if this :class:`_orm.Session` has begun a transaction. [extrait de in_transaction.__doc__] |
invalidate(self) |
Close this Session, using connection invalidation. [extrait de invalidate.__doc__] |
is_modified(self, instance, include_collections=True) |
Return ``True`` if the given instance has locally [extrait de is_modified.__doc__] |
merge(self, instance, load=True, options=None) |
Copy the state of a given instance into a corresponding instance [extrait de merge.__doc__] |
prepare(self) |
Prepare the current transaction in progress for two phase commit. [extrait de prepare.__doc__] |
query(self, *entities, **kwargs) |
Return a new :class:`_query.Query` object corresponding to this [extrait de query.__doc__] |
refresh(self, instance, attribute_names=None, with_for_update=None) |
Expire and refresh attributes on the given instance. [extrait de refresh.__doc__] |
rollback(self) |
Rollback the current transaction in progress. [extrait de rollback.__doc__] |
scalar(self, statement, params=None, execution_options=immutabledict({}), bind_arguments=None, **kw) |
Execute a statement and return a scalar result. [extrait de scalar.__doc__] |
scalars(self, statement, params=None, execution_options=immutabledict({}), bind_arguments=None, **kw) |
Execute a statement and return the results as scalars. [extrait de scalars.__doc__] |
Améliorations / Corrections
Vous avez des améliorations (ou des corrections) à proposer pour ce document : je vous remerçie par avance de m'en faire part, cela m'aide à améliorer le site.
Emplacement :
Description des améliorations :