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

Class to handle zone surfaces. More...

Public Member Functions

Table GetTable (string tableName)
 Returns the site table with the supplied name.
 
void AddTable (string tableName, int fieldCount)
 Adds an empty table to the surface with the supplied name and number of fields.
 
void RemoveTable (string tableName)
 Removes the table with the supplied name from the surface.
 
void RemoveAllTables ()
 Removes all surface 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.
 
void ResetDefaultOpenings ()
 Removes all custom openings from the surface and regenerates default openings using associated attribute data (attribute data from the Openings tab of the DB Model Data Panel).
 
void ConvertOpenings ()
 Converts all surface default openings to custom openings (used as an option to keep existing default openings when adding additional custom openings).
 
void UpdateGeometry ()
 Used to update the geometry of the surface and the geometry of the parent zone if attribute changes are made that affect the geometry (e.g. default glazing attributes, surface construction attributes, etc.).
 
void UpdateTileAttributes ()
 Updates any adjacent surface attributes and display objects if attribute changes are made.
 
void RemoveAllOpenings ()
 Removes all openings from the surface.
 
void ScaleWindows (double factor)
 Used to inflate/deflate windows by the supplied scale factor.
 
void SelectOpening (int index)
 Used to select the opening with the supplied index.
 
void Dispose ()
 

Properties

Collections.Adjacencies Adjacencies [get]
 Returns a collection of surface adjacencies. Surfaces can have multiple adjacencies. Adjacencies can be external or internal to another zone in which case the adjacent zone handle and surface index can be obtained from the adjacency (refer to Adjacency class).
 
Collections.Openings Openings [get]
 Returns a collection of surface openings. Surface openings comprise doors, windows, holes, vents and CFD surface boundaries.
 
Collections.Polygons ShadingPolygons [get]
 Returns a collection of shading polygons. Shading polygons are generated from shading calculations.
 
Collections.HardAttributes HardAttributes [get]
 Instantiate a collection of 'hard' attributes from the Sketch SketchDSurface object. Hard attributes are attributes set at a specific model decomposition level (surface level in this case) and don't inherit from level above.
 
double Tilt [get]
 Returns the surface tilt. A horizontal surface pointing upwards has 0 degrees tilt and a horizontal surface pointing downwards has 180 degrees tilt.
 
double Area [get]
 Returns the area of the surface.
 
double Azimuth [get]
 Returns the surface azimuth. A vertical surface (wall) pointing North has a 0 degree azimuth and a vertical surface pointing East has a 90 degree azimuth.
 
bool IsSelected [get]
 Returns a boolean value indicating whether or not the surface is selected.
 
double GrossArea [get]
 Returns the gross area of the surface including any openings (same as Area method).
 
double NettArea [get]
 Returns the nett area of the surface, i.e. the area of the surface less the area of any contained openings.
 
bool HasConstructionLines [get]
 Deprecated.
 
bool HasDefaultOpenings [get]
 Returns a boolean value indicating whether or not the surface is a “default opening” surface. Default openings are generated automatically from settings on the Openings tab of the UI Model Data panel, whereas custom openings are drawn manually. Note that TRUE may be returned even if the surface does not actually have any default openings when, for example, the Layout attribute is set to the 0-None option, or if there is no space on the surface for the requested default openings.
 
bool HasCustomOpening [get]
 Returns a boolean value indicating whether or not the surface contains a custom opening. Custom openings are drawn manually as distinct from default openings which are generated automatically from settings on the Openings tab of the UI Model Data panel.
 
bool IsInternalPartition [get]
 Returns a boolean value indicating whether or not the surface represents an internal partition.
 
InternalPartitionType InternalPartitionType [get, set]
 This method is used to set or retrieve the type of partition for surfaces that represent internal partitions. Whether or not a surface represents an internal partition may be determined using the IsInternalPartition method. Internal partition type can be either standard or virtual. A virtual partition exists purely to sub-divide a space and has no corresponding wall in the actual building.
 
bool IsOrthogonal [get]
 Returns a boolean value indicating whether or not the surface is orthogonal to the major model axes.
 
bool IsParentZoneMoreExternalThanAdjacentZone [get]
 Returns a boolean value indicating whether or not the parent zone should be considered more of an external zone than the adjacent zone for the purpose of EnergyPlus simulation. First, the "ZoneType" attribute is checked to see whether the zone is more or less external (e.g. 1-Standard is less external that 2-Semi exterior unconditioned). If the zone types are equivalent then the "HeatingOn" attribute is checked for both zones. If the zone is not heated but the adjacent one is then it is more external. If both zones are still equivalent then the "HeatingDesignSetpointTemperature" attributes are compared for both zones. If the zone has a lower heating setpoint than the adjacent zone then it is more external. If the 2 zones are still equivalent then a similar process is carried for cooling (the "ActiveCoolingOn" and "ActiveCoolingDesignSetpointTemperature" attributes are used for this) . The most external zone is the one with the lowest cooling setpoint. If after all these checks, the 2 zones are still equivalent then FALSE is returned. Note that this method only applies to internal partition surfaces (refer to IsInternalPartition method).
 
AdjacencyCondition AdjacencyCondition [get]
 Returns the adjacency condition of the surface (e.g. adjacent to ground) as an AdjacencyCondition object (refer to AdjacencyCondition class for the various surface adjacency conditions).
 
Polygon SurfacePolygon [get]
 Returns the geometry of the surface in the form of a polygon (refer to Polygon class).
 
SurfaceType Type [get]
 Returns the surface type (e.g. floor, roof, etc.) as a SurfaceType object (refer to SurfaceType class for the various surface types).
 

Detailed Description

Class to handle zone surfaces.

Member Function Documentation

◆ AddTable()

void DB.Api.Surface.AddTable ( string  tableName,
int  fieldCount 
)

Adds an empty table to the surface with the supplied name and number of fields.

Parameters
tableNameName of table to be added.
fieldCountNumber of fields in table.
Returns
TRUE if table is successfully added to the surface otherwise FALSE.

◆ GetAttribute()

string DB.Api.Surface.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.Surface.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.Surface.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.Surface.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

◆ GetIntegerAttribute()

int DB.Api.Surface.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

◆ GetTable()

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

Returns the site table with the supplied name.

Parameters
tableNameName of table to be retrieved.
Returns
The required table as a Table object if successful otherwise null.

◆ IsAttributeTrue()

bool DB.Api.Surface.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.Surface.RemoveTable ( string  tableName)

Removes the table with the supplied name from the surface.

Parameters
tableNameName of table to be removed.
Returns
TRUE if table removed successfully otherwise FALSE.

◆ ScaleWindows()

void DB.Api.Surface.ScaleWindows ( double  factor)

Used to inflate/deflate windows by the supplied scale factor.

Parameters
factorFactor by which windows are to be scaled.

◆ SelectOpening()

void DB.Api.Surface.SelectOpening ( int  index)

Used to select the opening with the supplied index.

Parameters
indexIndex of opening to be selected.

◆ SetAttribute()

void DB.Api.Surface.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

Property Documentation

◆ NettArea

double DB.Api.Surface.NettArea
get

Returns the nett area of the surface, i.e. the area of the surface less the area of any contained openings.


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