Class AttributeBase
- Namespace
- The.Attributes
- Assembly
- Instagile.dll
Nongeneric base class for attributes
public abstract class AttributeBase : IProperty, IOwned, IHasChanges, IComparable
- Inheritance
-
AttributeBase
- Implements
- Derived
- Inherited Members
Properties
DynamicTypeDefault
public abstract object? DynamicTypeDefault { get; }
Property Value
DynamicValue
public abstract object? DynamicValue { get; set; }
Property Value
Metadata
public AttributeInfo Metadata { get; }
Property Value
Parent
Owner (if any).
public EntityKernel Parent { get; }
Property Value
ValueType
public abstract Type ValueType { get; }
Property Value
Methods
CalculateAsync()
public abstract Task CalculateAsync()
Returns
CompareTo(object?)
Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
public abstract int CompareTo(object? compareProp)
Parameters
comparePropobject
Returns
- int
A value that indicates the relative order of the objects being compared. The return value has these meanings:
Value Meaning Less than zero This instance precedes objin the sort order.Zero This instance occurs in the same position in the sort order as obj.Greater than zero This instance follows objin the sort order.
Exceptions
- ArgumentException
objis not the same type as this instance.
CopyFrom(EntityKernel)
public void CopyFrom(EntityKernel other)
Parameters
otherEntityKernel
CopyTo(AttributeBase)
public void CopyTo(AttributeBase other)
Parameters
otherAttributeBase
GetOriginalText()
public abstract string GetOriginalText()
Returns
GetText()
public abstract string GetText()
Returns
HasChanges()
true if the current value differs from its original
public abstract bool HasChanges()
Returns
InternalCopy(AttributeBase, AttributeBase)
protected abstract void InternalCopy(AttributeBase from, AttributeBase to)
Parameters
fromAttributeBasetoAttributeBase
MarkUnchanged()
update original data so that it's no longer considered changed
public abstract void MarkUnchanged()
NeedsSave()
true if the value has non-derived changes, ones made deliberately by a user or business logic
public bool NeedsSave()
Returns
RaiseValueChanged()
protected void RaiseValueChanged()
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.
TrySetText(string)
public abstract bool TrySetText(string text)
Parameters
textstring
Returns
Events
ValueChanged
public event EventHandler? ValueChanged