AdaptiveComponentInstanceUtils
Description:
An interface for Adaptive Component Instances.
An interface for Adaptive Component Instances.
Inheritance Hierarchy:
System.Object
Autodesk.Revit.DB.AdaptiveComponentInstanceUtils
System.Object
Autodesk.Revit.DB.AdaptiveComponentInstanceUtils
public static class AdaptiveComponentInstanceUtils
private void CreateAdaptiveComponentInstance(Document document, FamilySymbol symbol)
{
// Create a new instance of an adaptive component family
FamilyInstance instance = AdaptiveComponentInstanceUtils.CreateAdaptiveComponentInstance(document, symbol);
// Get the placement points of this instance
IList<ElementId> placePointIds = new List<ElementId>();
placePointIds = AdaptiveComponentInstanceUtils.GetInstancePlacementPointElementRefIds(instance);
double x = 0;
// Set the position of each placement point
foreach (ElementId id in placePointIds)
{
ReferencePoint point = document.GetElement(id) as ReferencePoint;
point.Position = new Autodesk.Revit.DB.XYZ(10*x, 10*Math.Cos(x), 0);
x += Math.PI/6;
}
}
| Name | Return Type | Description |
|---|---|---|
| CreateAdaptiveComponentInstance(Document, FamilySymbol) | FamilyInstance | Creates a FamilyInstance of Adaptive Component Family. |
| GetInstancePlacementPointElementRefIds(FamilyInstance) | IList<ElementId> | Gets Placement Adaptive Point Element Ref ids to which the instance geometry adapts. |
| GetInstancePointElementRefIds(FamilyInstance) | IList<ElementId> | Gets Adaptive Point Element Ref ids to which the instance geometry adapts. |
| GetInstanceShapeHandlePointElementRefIds(FamilyInstance) | IList<ElementId> | Gets Shape Handle Adaptive Point Element Ref ids to which the instance geometry adapts. |
| HasAdaptiveFamilySymbol(FamilyInstance) | Boolean | Verifies if a FamilyInstance has an Adaptive Family Symbol. |
| IsAdaptiveComponentInstance(FamilyInstance) | Boolean | Verifies if a FamilyInstance is an Adaptive Component Instance. |
| IsAdaptiveFamilySymbol(FamilySymbol) | Boolean | Verifies if a FamilySymbol is a valid Adaptive Family Symbol. |
| IsInstanceFlipped(FamilyInstance) | Boolean | Gets the value of the flip parameter on the adaptive instance. |
| MoveAdaptiveComponentInstance(FamilyInstance, Transform, Boolean) | None | Moves Adaptive Component Instance by the specified transformation. |
| SetInstanceFlipped(FamilyInstance, Boolean) | None | Sets the value of the flip parameter on the adaptive instance. |