The read-only status for entities (and proxies) loaded into this Session.

Namespace: NHibernate
Assembly: NHibernate (in NHibernate.dll) Version: 3.2.0.4000 (3.2.0.4000)

Syntax

C#
bool DefaultReadOnly { get; set; }
Visual Basic
Property DefaultReadOnly As Boolean
	Get
	Set
Visual C++
property bool DefaultReadOnly {
	bool get ();
	void set (bool value);
}

Remarks

When a proxy is initialized, the loaded entity will have the same read-only setting as the uninitialized proxy, regardless of the session's current setting.

To change the read-only setting for a particular entity or proxy that is already in this session, see SetReadOnly(Object, Boolean).

To override this session's read-only setting for entities and proxies loaded by a query, see SetReadOnly(Boolean).

This method is a facade for DefaultReadOnly.

See Also