nhibernate - Check if a session is dirty but don't flush -


i'm sure i've seen discussed, must not using right keywords because can't find on now:

i have desktop application using nhibernate persistence. i'd use session's isdirty property notify user whether persistent data has been changed, showing him either close button or apply , cancel button, depending.

the problem calling isdirty causes @ least data flushed database, despite fact flushmode never. i'm interested in knowing why isdirty feels has flush changes, more importantly want know how can information without flushing.

as aside: since don't have transaction wrapping whole time user edits information on form, assume changes flushed there stay, whether end committing else or not.

so, can tell me how functionality want without functionality don't?

i did dirty state tracking within viewmodel properties. on each propertychanged call markasdirty() of viewmodelbase class. reflects property bound onto save button command.

but if want use nh tracking, sessionextension fit requirements.


Comments

Popular posts from this blog

python - pip install -U PySide error -

arrays - C++ error: a brace-enclosed initializer is not allowed here before ‘{’ token -

cytoscape.js - How to add nodes to Dagre layout with Cytoscape -