PostSharpAPI ReferencePost­Sharp.​Patterns.​ModelIAttachable
Open sandboxFocus

IAttachable Interface

Defines setter methods for the IAggregatable.

Namespace: PostSharp.Patterns.Model
Assembly: PostSharp.Patterns.Aggregation.dll
Syntax
public interface IAttachable : IAggregatable
Remarks

This interface is consumed by the AggregatableAttribute aspect. It should normally not be consumed in user code.

User classes may implement this interface in a class if a custom implementation of IAggregatable is required.

A child object may be attached several times to the same parent through several relationships.

Methods

Name Description
AttachToParent(RelationshipInfo, IAttacher, Object)

Attaches the current object to a parent object.

DetachFromParent()

Detaches the current object from its parent object.

OnDeserialization(Object)

Restores the correct state when the object is being deserialized.

Extension Methods

AggregatableExtensions.IsDescendantOf(IAggregatable, Object)
AggregatableExtensions.GetChildren(IAggregatable, ChildVisitorOptions)
AggregatableExtensions.GetDistinctChildren(IAggregatable, ChildVisitorOptions)
AggregatableExtensions.VisitSelfAndDescendants(IAggregatable, DescendantVisitor, ChildVisitorOptions, Object)