2026 Class
Changes 7
C

CompoundStructure

Description:
Describes the internal structure of a wall, floor, roof or ceiling.
Remarks:

A compound structure consists a collection of ordered layers, proceeding from exterior to interior for a wall, or from top to bottom for a floor, roof or ceiling. The properties of these layers determine the thickness, material, function and priority of the overall structure of the associated wall, floor, roof or ceiling. Layers can be accessed via the GetLayers() method and completely replaced using SetLayers. Layers can also be accessed and modified individually using the "layer index", which is a value from in the range [0, LayerCount) identifying the layer in the structure.

A structure supports the concept of "core layers" and "shell layers". There are two layer indices which identify where the boundary between core and shell layers occur in the list of layers. The boundaries between shell and core layers are identifiable using GetFirstCoreLayerIndex(), GetLastCoreLayerIndex(), GetCoreBoundaryLayerIndex(ShellLayerType) or GetNumberOfShellLayers(ShellLayerType). The core layer boundary can be changed with SetNumberOfShellLayers(ShellLayerType, Int32).

Compound structures may be vertically compound. If IsVerticallyCompound is false, the CompoundStructure describes a series of parallel layers, each with specified width, function, priority, material and other properties. If IsVerticallyCompound is true (which should apply only for CompoundStructures assigned to walls) then horizontal sections at different elevations may have different layered structures. In this case, the structure describes a vertical section via a rectangle which is divided into polygonal regions whose sides are all vertical or horizontal segments. A map associates each of these regions with the index of a layer in the CompoundStructure which determines the properties of that region.

Inheritance Hierarchy:
System.Object
  Autodesk.Revit.DB.CompoundStructure
public class CompoundStructure : IDisposable
Name Return Type Description Inherited From
M AddWallSweep(WallSweepInfo) None Adds a new wall sweep or reveal to the compound structure.
M AssociateRegionWithLayer(Int32, Int32) None Associates a region with a layer.
M CanLayerBeStructuralMaterial(Int32) Boolean Identifies if the input layer can be designated as defining the structural material for this structure.
M CanLayerBeVariable(Int32) Boolean Identifies if the input layer can be designated as a variable thickness layer.
M CanLayerWidthBeNonZero(Int32) Boolean Identifies if changing the width of an existing layer from zero to a positive value will create a rectangular region.
M CanSplitAndMergeRegionsBeUsed() Boolean Checks whether split and merge regions operations can be used for this compound structure.
M ChangeRegionWidth(Int32, Double) Boolean Adjust the width of an existing simple region.
M ClearWallSweeps(WallSweepType) None Removes all sweeps or reveals from the compound structure.
M CreateSimpleCompoundStructure(IList<CompoundStructureLayer>) CompoundStructure
M CreateSingleLayerCompoundStructure(MaterialFunctionAssignment, Double, ElementId) CompoundStructure Creates a CompoundStructure containing a single layer.
M CreateSingleLayerCompoundStructure(Double, MaterialFunctionAssignment, Double, ElementId) CompoundStructure Creates a vertically compound CompoundStructure with one layer.
M DeleteLayer(Int32) Boolean Deletes the specified layer from this CompoundStructure.
M Dispose() None Releases all resources used by the CompoundStructure
M Equals None Determines whether the specified object is equal to the current object. (Inherited from Object ) Object
M FindEnclosingRegionAndSegments(UV, RectangularGridSegmentOrientation, Int32%, Int32%) Int32 Given a pair of grid coordinates, and a direction for splitting, returns the enclosing region and the two segments intersected by a line through the grid point.
M GetAdjacentRegions(Int32) IList<Int32> Gets the ids of region bound to a specified segment.
M GetCoreBoundaryLayerIndex(ShellLayerType) Int32 Returns the index of the layer just below the core boundary.
M GetDeckEmbeddingType(Int32) StructDeckEmbeddingType Retrieves the deck embedding type used for the specified structural deck.
M GetDeckProfileId(Int32) ElementId Retrieves the profile loop used for the specified structural deck.
M GetExtendableRegionIds(Boolean) IList<Int32> Gets the extendable region ids for the compound structure.
M GetFirstCoreLayerIndex() Int32 Gets the index of the first core layer.
M GetHashCode None Serves as the default hash function. (Inherited from Object ) Object
M GetLastCoreLayerIndex() Int32 Gets the index of the last core layer.
M GetLayerAssociatedToRegion(Int32) Int32 Gets the layer associated to a particular region.
M GetLayerFunction(Int32) MaterialFunctionAssignment Retrieves the function of the specified layer.
M GetLayerPriority(Int32) Int32 Retrieves the priority of the specified layer. Index of a layer in the CompoundStructure. The layer index is zero based. It counts from the exterior of wall and from the top of roofs, floors and ceilings.
M GetLayers() IList<CompoundStructureLayer> A copy of the layers which define this compound structure.
M GetLayerWidth(Int32) Double Retrieves the width of a specified layer.
M GetMaterialId(Int32) ElementId Retrieves the material element id of a specified layer.
M GetMinimumLayerThickness() Double Get the minimum allowable layer thickness.
M GetNumberOfShellLayers(ShellLayerType) Int32 Retrieves the number of interior or exterior shell layers.
M GetOffsetForLocationLine(WallLocationLine) Double Returns the offset from the center of the compound structure to the given location line value.
M GetPreviousNonZeroLayerIndex(Int32) Int32 Returns the index of the nearest non-zero width layer before this layer.
M GetRegionEnvelope(Int32) BoundingBoxUV Gets the envelope that a specified region spans.
M GetRegionIds() IList<Int32> Gets the region ids of this compound structure.
M GetRegionsAlongLevel(Double) IList<Int32> Returns the ids of the regions encountered as the vertically compound structure is traversed at a constant height above the bottom a wall to which this structure is applied.
M GetRegionsAssociatedToLayer(Int32) IList<Int32> Gets the set of region ids associated to a particular layer.
M GetSegmentCoordinate(Int32) Double Gets the coordinate of a segment.
M GetSegmentEndPoints(Int32, Int32, UV%, UV%) None Gets the end points of a segment.
M GetSegmentIds() IList<Int32> Gets the segment ids of this compound structure.
M GetSegmentOrientation(Int32) RectangularGridSegmentOrientation Gets the orientation of a segment.
M GetSimpleCompoundStructure(Double, Double) CompoundStructure Takes a horizontal slice through a sample wall to which this CompoundStructure is applied and returns a simple compound structure which describes that slice, i.e. a series of parallel layers.
M GetType None Gets the Type of the current instance. (Inherited from Object ) Object
M GetWallSweepsInfo(WallSweepType) IList<WallSweepInfo> Obtains a list of the intrinsic wall sweeps or reveals in this CompoundStructure.
M GetWidth() Double The width implied by this compound structure.
M GetWidth(Int32) Double Computes the width of the envelope (2d bounding box) of the specified region.
M IsCoreLayer(Int32) Boolean Checks if the specified layer is a core layer.
M IsEqual(CompoundStructure) Boolean Checks whether this CompoundStructure is the same as another CompoundStructure.
M IsLayerValid(Int32, CompoundStructureLayer) Boolean Verifies that the data in this layer is internally consistent.
M IsRectangularRegion(Int32) Boolean Determines whether the specified region is rectangular.
M IsSimpleRegion(Int32) Boolean Determines whether the region is a simple region in this CompoundStructure.
M IsStructuralDeck(Int32) Boolean Determines whether a specified layer is a structural deck.
M IsValid(Document, IDictionary<Int32CompoundStructureError>, IDictionary<Int32Int32>) Boolean
M IsValidLayerPriority(Int32, Int32) Boolean Checks if the layer priority is valid to match the function.
M IsValidRegionId(Int32) Boolean Determines whether the specified integer is actually the id of a region in this CompoundStructure.
M IsValidSampleHeight(Double) Boolean Is the specified height a valid sample height for this compound structure?
M IsValidSegmentId(Int32) Boolean Determines whether the specified integer is actually the id of a segment in this CompoundStructure.
M IsVerticallyHomogeneous() Boolean Indicates whether this CompoundStructure represents a single set of parallel layers.
M MergeRegionsAdjacentToSegment(Int32, Int32) Int32 Merges the two regions which share the specified segment.
M ParticipatesInWrapping(Int32) Boolean Identifies if a layer is included in wrapping at inserts and ends.
M RemoveWallSweep(WallSweepType, Int32) None Removes a single sweep or reveal from the compound structure.
M ResetAllLayersPriorities() None Resets all the priorities of all layers to the default priorities defined by their functions.
M ResetLayerPriority(Int32) None Resets the priority of the specific layer to the default priority defined by its function.
M SetDeckEmbeddingType(Int32, StructDeckEmbeddingType) None Sets the deck embedding type to use for the specified structural deck.
M SetDeckProfileId(Int32, ElementId) None Sets the profile loop to use for the specified structural deck.
M SetExtendableRegionIds(Boolean, IList<Int32>) None
M SetLayer(Int32, CompoundStructureLayer) None Sets a single layer for this CompoundStructure.
M SetLayerFunction(Int32, MaterialFunctionAssignment) None Sets the function of the specified layer.
M SetLayerPriority(Int32, Int32) None Sets the priority of the specific layer.
M SetLayers(IList<CompoundStructureLayer>) None
M SetLayerWidth(Int32, Double) None Sets the width of a specified layer.
M SetMaterialId(Int32, ElementId) None Sets a material element for a specified layer.
M SetNumberOfShellLayers(ShellLayerType, Int32) None Sets the number of interior or exterior shell layers.
M SetParticipatesInWrapping(Int32, Boolean) None Assigns if a layer is included in wrapping at inserts and ends.
M SplitRegion(UV, RectangularGridSegmentOrientation) Int32 Splits the region which contains the specified grid point by a line with the specified direction.
M SplitRegion(UV, RectangularGridSegmentOrientation, Int32%) Int32 Splits the region which contains the specified grid point by a line with the specified direction.
M ToString None Returns a string that represents the current object. (Inherited from Object ) Object
Name Return Type Description Inherited From
P CutoffHeight double Horizontal segments below or at the cutoff height have their distance to the wall bottom fixed, those above have their distance to the wall top fixed.
P EndCap EndCapCondition Indicates the end cap condition defining which shell layers will participate in end wrapping.
P HasStructuralDeck bool Checks if the compound structure has a structural deck.
P IsEmpty bool Checks whether this CompoundStructure is empty.
P IsValidObject Boolean Specifies whether the .NET object represents a valid Revit entity.
P IsVerticallyCompound bool Identifies if this CompoundStructure represents a layout that is more complicated than a simple set of parallel layers.
P LayerCount int Returns the number of layers contained in this CompoundStructure.
P MinimumSampleHeight double The minimum sample height determined by the current sample height and the horizontal segments.
P OpeningWrapping OpeningWrappingCondition Indicates the opening wrapping condition defining which shell layers of a wall, in plan view, wrap at inserts and openings.
P SampleHeight double The sample height is the presumed height of the wall to which the data in this CompoundStructure is applied.
P StructuralMaterialIndex int Indicates the layer whose material defines the structural properties of the type for the purposes of analysis.
P VariableLayerIndex int Indicates the index of the layer which is designated as variable.