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

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

Syntax

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

Implements

IPersistenceContext..::..DefaultReadOnly

Remarks

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

To change the read-only setting for a particular entity or proxy that is already in the current persistence context, use SetReadOnly(Object, Boolean).

See Also