API Reference
Loading...
Searching...
No Matches
Public Member Functions | Properties | List of all members
DB.Api.Zone Class Reference

Class to handle building zones. More...

Public Member Functions

Table AddTable (string tableName, int fieldCount)
 Adds an empty table with specified name and number of fields to the Zone object.
 
Table GetTable (string tableName)
 Returns a Zone table with the supplied name as a Table object.
 
void RemoveTable (string tableName)
 Removes an existing Zone table with specified name.
 
void RemoveAllTables ()
 Removes all Zone tables.
 
void SetAttribute (string attributeName, string value)
 Sets an attribute with the supplied name to the supplied value.
 
string GetAttribute (string attributeName)
 Returns the string value of the attribute with the supplied name.
 
int GetAttributeAsInt (string attributeName)
 Returns the integer value of the attribute with the supplied name (same as GetIntegerAttribute). If the value of the attribute is not an integer value, the return value is undefined. To use this method, foreknowledge is required that the value of the attribute is in fact an integer value.
 
double GetAttributeAsDouble (string attributeName)
 Returns the double value of the attribute with the supplied name. If the value of the attribute is not a double value, the return value is undefined. To use this method, foreknowledge is required that the value of the attribute is in fact an double value.
 
int GetIntegerAttribute (string attributeName)
 Returns the integer value of the attribute with the supplied name (same as GetAttributeAsInt). If the value of the attribute is not an integer value, the return value is undefined. To use this method, foreknowledge is required that the value of the attribute is in fact an integer value.
 
DataObject GetAttributeDataObject (string attributeName)
 Returns a DataObject object associated with the attribute of the supplied name.
 
bool IsAttributeTrue (string attributeName)
 Returns boolean value (TRUE/FALSE) of the attribute with the supplied name.
 
IEnumerable< ZoneGetChildZones (Building parentBuilding)
 Returns a collection of child zones for a zone to which other zones have been merged.
 
Point3d GetDaylightSensorLocation (int idx)
 Zones can contain up to two daylight sensors. This method returns the location of the required sensor as a 3D point in space.
 
Collections.Polygons GetOffsetFloorPolygons (double offset)
 Returns a collection of floor polygons offset from the actual floor Z coordinates by a specified offset. The polygon lists are automatically clipped to the zone geometry.
 
void UpdateGeometry ()
 This method automatically recalculates the zone inner volume geometry to cater for changes in element construction, etc.
 
void UpdateTileAttributes ()
 Updates adjacent zone attributes, default window layouts, etc. after changes are made to the zone attributes via the UI.
 
void ResetDefaultOpenings ()
 This method will automatically remove all custom openings and reset the default zone opening layouts using current attribute settings.
 
bool SelectSurface (int surfaceIdx)
 This method is used to select the required surface.
 
void WriteBodyGeometryToFile (string filePath)
 Writes the zone polyhedron geometry to an ASCII file in GEM format.
 
void Dispose ()
 

Properties

Collections.Surfaces Surfaces [get]
 Instantiates a collection of zone surfaces (refer to Surface class).
 
Collections.Polygons FloorPolygons [get]
 Instantiates a collection of polygons representing the geometry of all floors in the zone (refer to Polygon class).
 
Collections.HardAttributes HardAttributes [get]
 Instantiate a collection of 'hard' attributes from the Sketch SketchDZone object. Hard attributes are attributes set at a specific model decomposition level (zone in this case) and don't inherit from level above.
 
string Name [get, set]
 Used to set/retrieve the name of the zone.
 
string IdfName [get]
 Returns the IDF name of the zone.
 
int SbemCornerCount [get]
 Deprecated.
 
double FloatingPartitionArea [get]
 Returns the area of all disconnected partitions that lie within the zone.
 
double FloorArea [get]
 Returns the total floor area of the zone.
 
double LumpedFloorArea [get]
 Returns the total floor area of the zone and all zones merged with this zone.
 
double Volume [get]
 Returns the volume of the zone. The volume returned depends on the 'volume calculation method' specified through the UI at building level ('Geometry, Areas and Volumes'). If the 'volume calculation method' is set to 'Inner', the volume returned will be the volume of the zone inner volume whereas the zone outer volume will be returned If the 'volume calculation method' is set to 'Outer'. Zone inner volume geometry is automatically calculated for all zones to account for construction thicknesses.
 
double LumpedVolume [get]
 Returns the volume of the zone plus all zones merged with this zone. The volume returned depends on the 'volume calculation method' specified through the UI at building level ('Geometry, Areas and Volumes'). If the 'volume calculation method' is set to 'Inner', the volume returned will be the volume of the zone inner volume whereas the zone outer volume will be returned If the 'volume calculation method' is set to 'Outer'. Zone inner volume geometry is automatically calculated for all zones to account for construction thicknesses.
 
double FloorVoidVolume [get]
 Deprecated.
 
double LumpedFloorVoidVolume [get]
 Deprecated.
 
double CeilingVoidVolume [get]
 Deprecated.
 
double LumpedCeilingVoidVolume [get]
 Deprecated.
 
double LinkZoneVolume [get]
 Deprecated.
 
bool IsLumpedOut [get]
 Returns a boolean value that determines whether or not the zone is merged with other zones. Groups of zones can be merged to form a single entity using a number of methods via the merge tool (merge by holes between zones, merge by selection, etc.).
 
bool IsOpenManifold [get]
 Determines whether or not the geometry of the zone is open manifold or not. Closed manifold zone geometry consists of surfaces where each edge is shared with one and only one other surface edge. Open manifold zone objects can only arise when importing geometry from external files (gbXML). While open manifold zones can be included in EnergyPlus simulations, they cannot be included in CFD simulations which require closed manifold geometries.
 
int Handle [get]
 Returns the handle of the zone.
 
int LumpedHandle [get]
 Returns the handle of a merged zone entity.
 
int InheritedHandle [get]
 After a building block has been re-zoned (due to new partition layouts, etc.), attributes of zones prior to re-zoning are automatically assigned to the new zones subsewquent to re-zoning using a geometry comparison algorithm. Where this assignment takes place, the handle of the old zone (prior to re-zoning) is assigned to the new zone via an 'inherited' handle. This method returns the inherited handle.
 
bool IsSelected [get]
 Returns a boolean value indicating whether or not the zone is selected.
 
bool IsConvex [get]
 Returns a boolean value indicating whether or not the polyhedron defining the geometry of the zone is convex.
 
bool HasConstructionLines [get]
 Deprecated.
 
int ParentBuildingBlockIndex [get]
 Returns the handle of the building block in which the zone resides.
 
bool IsChildZone [get]
 Returns a boolean value indicating whether or not the zone is a child zone of a merged group of zones.
 
ZoneBridgingLengths ThermalBridgingLengths [get]
 Returns a collection of thermal bridging lengths for all zone surface edges (refer to ZoneBridgingLengths class).
 
ZoneBridgingLengths ExposedGroundFloorThermalBridgingLengths [get]
 Returns a collection of thermal bridging lengths for exposed ground floor zone surface edges (refer to ZoneBridgingLengths class).
 
BoundingBox3d Bounds [get]
 Returns a bounding box for the zone, the dimensions of which are derived from the X, Y and Z maximum dimemsions of the zone.
 
BoundingBox3d InnerVolumeBounds [get]
 Returns a bounding box for the inner volume of the zone, the dimensions of which are derived from the X, Y and Z maximum dimemsions of the zone inner volume geometry.
 
InnerSurfaceMode InnerSurfaceMode [get]
 When a zone is created after a building block zoning process (or changes in zone surface construction, etc.), an inner volume polyhedron is automatically generated using the thickness of the various zone elements (partitions, external wall, ceilings, etc.). Correspondingly, the surfaces of the inner volume polyhedron represent the inner surfaces of the zone. The inner volume polyhedron can therefore be used for accurate determination of the zone air volume and inner surface areas. The creation of the inner volume uses a deflation algorithm that can fail if zone vertices have more than three adjacent surfaces. If the deflation fails, an approximate method is employed to derive the zone inner volume and internal surface areas. Additionally, a simpler geometry can be adopted whereby the inner volume polyhedron is coincident with the parent zone polyhedron. This method is used to obtain the mode used for the inner volume (1-coincident, 2-deflation, 2-approximate).
 

Detailed Description

Class to handle building zones.

Member Function Documentation

◆ AddTable()

Table DB.Api.Zone.AddTable ( string  tableName,
int  fieldCount 
)

Adds an empty table with specified name and number of fields to the Zone object.

Parameters
tableNameName of table
fieldCountNumber of fields (columns) in table.
Returns
TRUE if table added successfully otherwise FALSE.

◆ GetAttribute()

string DB.Api.Zone.GetAttribute ( string  attributeName)

Returns the string value of the attribute with the supplied name.

Parameters
attributeNameName of attribute from which value is to be retrieved.
Returns
TRUE if attribute is retrieved successfully otherwise FALSE.

◆ GetAttributeAsDouble()

double DB.Api.Zone.GetAttributeAsDouble ( string  attributeName)

Returns the double value of the attribute with the supplied name. If the value of the attribute is not a double value, the return value is undefined. To use this method, foreknowledge is required that the value of the attribute is in fact an double value.

Parameters
attributeNameName of attribute from which double value is to be retrieved.
Returns
Double value of attribute.

◆ GetAttributeAsInt()

int DB.Api.Zone.GetAttributeAsInt ( string  attributeName)

Returns the integer value of the attribute with the supplied name (same as GetIntegerAttribute). If the value of the attribute is not an integer value, the return value is undefined. To use this method, foreknowledge is required that the value of the attribute is in fact an integer value.

Parameters
attributeNameName of attribute from which integer value is to be retrieved.
Returns
Integer value of attribute.

◆ GetAttributeDataObject()

DataObject DB.Api.Zone.GetAttributeDataObject ( string  attributeName)

Returns a DataObject object associated with the attribute of the supplied name.

Parameters
attributeNameName of attribute from which DataObject object is to be retrieved.
Returns
DataObject object.

◆ GetChildZones()

IEnumerable< Zone > DB.Api.Zone.GetChildZones ( Building  parentBuilding)

Returns a collection of child zones for a zone to which other zones have been merged.

Parameters
parentBuildingBuilding object in which zone(s) reside.
Returns
TRUE if the zone has child zones otherwise FALSE.

◆ GetDaylightSensorLocation()

Point3d DB.Api.Zone.GetDaylightSensorLocation ( int  idx)

Zones can contain up to two daylight sensors. This method returns the location of the required sensor as a 3D point in space.

Parameters
idxThe index of the sensor for which the location is required (may be 0 or 1).
Returns
Returns the location of the reqired sensor as a 3D point in space.

◆ GetIntegerAttribute()

int DB.Api.Zone.GetIntegerAttribute ( string  attributeName)

Returns the integer value of the attribute with the supplied name (same as GetAttributeAsInt). If the value of the attribute is not an integer value, the return value is undefined. To use this method, foreknowledge is required that the value of the attribute is in fact an integer value.

Parameters
attributeNameName of attribute from which integer value is to be retrieved.
Returns
Integer value of attribute.

◆ GetOffsetFloorPolygons()

Collections.Polygons DB.Api.Zone.GetOffsetFloorPolygons ( double  offset)

Returns a collection of floor polygons offset from the actual floor Z coordinates by a specified offset. The polygon lists are automatically clipped to the zone geometry.

Parameters
offsetThe distance by which the floor polygonas are to be offset from the actual floor Z coordinates.
Returns
Collection of offset floor polygons or NULL if the method should fail for any reason.

◆ GetTable()

Table DB.Api.Zone.GetTable ( string  tableName)

Returns a Zone table with the supplied name as a Table object.

Parameters
tableNameName of table to be retrieved.
Returns
Building table as Table object.

◆ IsAttributeTrue()

bool DB.Api.Zone.IsAttributeTrue ( string  attributeName)

Returns boolean value (TRUE/FALSE) of the attribute with the supplied name.

Parameters
attributeNameAttribute name.
Returns
TRUE if boolean value of attribute is true otherwise FALSE.

◆ RemoveTable()

void DB.Api.Zone.RemoveTable ( string  tableName)

Removes an existing Zone table with specified name.

Parameters
tableNameName of table to be removed.

◆ SelectSurface()

bool DB.Api.Zone.SelectSurface ( int  surfaceIdx)

This method is used to select the required surface.

Parameters
surfaceIdxIndex of the surface to be selected.
Returns
TRUE if the required surface is selected successfully otherwise FALSE.

◆ SetAttribute()

void DB.Api.Zone.SetAttribute ( string  attributeName,
string  value 
)

Sets an attribute with the supplied name to the supplied value.

Parameters
attributeNameName of attribute to be set.
valueValue to which attribute is to be set.
Returns
TRUE if attribute is set successfully otherwise FALSE.

◆ WriteBodyGeometryToFile()

void DB.Api.Zone.WriteBodyGeometryToFile ( string  filePath)

Writes the zone polyhedron geometry to an ASCII file in GEM format.

Parameters
filePathFull path of file to which geometry is to be written.

The documentation for this class was generated from the following file: