ImmutableObjectAutoBaseT Class

Represents an object that can be configured as read only and thus made immutable. This class will automatically clone any field that implements IImmutableObject

Definition

Namespace: SnapDB.Immutables
Assembly: SnapDB (in SnapDB.dll) Version: 1.0.102.0 -- Release Build+29075351d0e5aa4dea46a5c520805222f672dc2e
public abstract class ImmutableObjectAutoBase<T> : ImmutableObjectBase<T>
where T : ImmutableObjectAutoBase<T>
Inheritance
Object    ImmutableObjectBaseT    ImmutableObjectAutoBaseT
Derived

Type Parameters

T
Object type.

Constructors

ImmutableObjectAutoBaseTInitializes a new instance of the ImmutableObjectAutoBaseT class

Properties

IsReadOnly Gets or sets if this class is immutable and thus read-only. Once setting to read-only, the class becomes immutable.
(Inherited from ImmutableObjectBaseT)

Methods

Clone Creates a clone of the object, either as a read-only instance or an editable one.
(Inherited from ImmutableObjectBaseT)
CloneEditable Creates a clone of this class that is editable. A clone is always created, even if this class is already editable.
(Inherited from ImmutableObjectBaseT)
CloneMembersAsEditable Request that member fields be cloned and marked as editable.
(Overrides ImmutableObjectBaseTCloneMembersAsEditable)
CloneReadonly Creates a read-only clone of the object.
(Inherited from ImmutableObjectBaseT)
EqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
FinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
GetHashCodeServes as the default hash function.
(Inherited from Object)
GetTypeGets the Type of the current instance.
(Inherited from Object)
MemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
SetMembersAsReadOnly Requests that member fields be set to "read-only".
(Overrides ImmutableObjectBaseTSetMembersAsReadOnly)
TestForEditable Test if the class has been marked as read-only. Throws an exception if editing cannot occur.
(Inherited from ImmutableObjectBaseT)
ToStringReturns a string that represents the current object.
(Inherited from Object)

See Also