VICUS Library
Documentation of Vicus library
Loading...
Searching...
No Matches
VICUS Namespace Reference

Classes

class  AbstractDBElement
 
class  AcousticTemplate
 
class  ArgsParser
 
class  BoundaryCondition
 
class  BTFReader
 
class  Building
 
class  BuildingLevel
 
class  Component
 
class  ComponentInstance
 
class  Construction
 
class  ConstructionInstanceModelGenerator
 
class  ControlledShadingModelGenerator
 
class  DailyCycle
 
class  Database
 
class  DataSurfaceHeating
 
class  EmbeddedDatabase
 
class  EPDCategroySet
 
class  EPDDataset
 
class  GridPlane
 
class  IdealHeatingCoolingModelGenerator
 
class  IdealSurfaceHeatingCoolingModelGenerator
 
class  Infiltration
 
class  InterfaceHeatConduction
 
class  InternalLoad
 
class  InternalLoadsModelGenerator
 
class  KeywordList
 
class  Material
 
class  MaterialLayer
 
class  ModelGeneratorBase
 
class  Network
 
class  NetworkBuriedPipeProperties
 
class  NetworkComponent
 
class  NetworkController
 
class  NetworkEdge
 
class  NetworkElement
 
class  NetworkFluid
 
class  NetworkLine
 geometric resolution in m, points closer than that are assumed equal More...
 
class  NetworkNode
 
class  NetworkPipe
 
class  Object
 
class  OutputDefinition
 
class  Outputs
 
class  PlainGeometry
 
class  PlaneGeometry
 
class  PlaneTriangulationData
 
class  Polygon2D
 
class  Polygon3D
 
class  PolyLine
 
class  Project
 
class  Room
 
class  RotationMatrix
 
class  Schedule
 
class  ScheduleInterval
 
class  SubNetwork
 
class  SubSurface
 
class  SubSurfaceComponent
 
class  SubSurfaceComponentInstance
 
class  SupplySystem
 
class  SupplySystemNetworkModelGenerator
 
class  Surface
 
class  SurfaceHeating
 
class  ThermostatModelGenerator
 
class  VentilationModelGenerator
 
class  VentilationNatural
 
class  ViewSettings
 
class  Window
 
class  WindowDivider
 
class  WindowFrame
 
class  WindowGlazingSystem
 
class  ZoneControlNaturalVentilation
 
class  ZoneControlShading
 
class  ZoneControlThermostat
 
class  ZoneIdealHeatingCooling
 
class  ZoneTemplate
 

Functions

int enum2index (const std::string &enumtype)
 
const char * theKeyword (int typenum, int t)
 
const char * allKeywords (int typenum, int t)
 
bool selectionCheck (const VICUS::Object &o, bool takeSelected, bool takeVisible)
 
std::string createUniqueNandradObjListName (const std::map< std::string, std::vector< unsigned int > > &objListNames, const std::string &name)
 
std::string createUniqueNandradObjListAndName (const std::string &name, const std::vector< unsigned int > &roomIds, NANDRAD::Project &p, const NANDRAD::ModelInputReference::referenceType_t &type)
 
std::vector< NANDRAD::Schedule::ScheduledDayType > mergeDayType (const std::vector< int > &dts)
 
QString MultiLangString2QString (const IBK::MultiLanguageString &mls)
 
template<typename T >
bool isValidTemplate (const std::vector< T > elements, QStringList &errorStack, const QString &name)
 
const VICUS::RoomcheckForSurfaceParent (const VICUS::Object *obj)
 
QString uniqueName (const QString &baseName, const std::set< QString > &existingNames)
 
QString camelCase2ReadableString (const std::string &original)
 
template<typename T >
T * element (std::vector< T > &vec, unsigned int id)
 
template<typename T >
bool contains (const std::vector< T > &vec, unsigned int id)
 
template<typename T >
const T * element (const std::vector< T > &vec, unsigned int id)
 
template<typename T >
const T * element (const std::vector< T > &vec, const std::string &name)
 
template<typename T >
unsigned int elementIndex (const std::vector< T > &vec, unsigned int id)
 
template<typename T >
unsigned int elementIndex (const std::vector< T > &vec, const std::string &name, bool caseSensitiv=true)
 
template<typename T >
unsigned int uniqueId (const std::vector< T > &vec)
 
template<>
unsigned int uniqueId (const std::vector< unsigned int > &vec)
 
template<typename T >
unsigned int uniqueId (const std::set< T > &vec)
 
template<>
unsigned int uniqueId (const std::set< unsigned int > &vec)
 
template<typename T >
unsigned int uniqueIdAdd (std::vector< T > &vec)
 
template<typename T >
unsigned int uniqueIdWithPredef (std::vector< T > &vec, unsigned int newId)
 
template<typename T >
unsigned int uniqueIdWithPredef (std::vector< T > &vec, unsigned int id, std::map< T, T > mapOldToNewId)
 
template<typename T >
unsigned int largestUniqueId (const std::vector< T > &vec)
 
template<typename T >
void checkForUniqueIDs (const std::vector< T > &vec, std::set< unsigned int > &usedIDs)
 
template<typename T >
void checkForUniqueIDs (const std::vector< const T * > &vec, std::set< unsigned int > &usedIDs)
 

Variables

const char *const VERSION = "1.0"
 
const char *const LONG_VERSION = "1.0.4"
 
unsigned int INVALID_ID = 0xFFFFFFFF
 
const double MIN_AREA_FOR_EXPORTED_SURFACES = 0.1
 
const char * XML_READ_ERROR = "Error in XML file, line %1: %2"
 
const char * XML_READ_UNKNOWN_ATTRIBUTE = "Unknown/unsupported attribute '%1' in line %2."
 
const char * XML_READ_UNKNOWN_ELEMENT = "Unknown/unsupported tag '%1' in line %2."
 
const char * XML_READ_UNKNOWN_NAME = "Name '%1' for tag '%2' in line %3 is invalid/unknown."
 
const char * DATABASE_PLACEHOLDER_NAME = "Database"
 
const char * USER_DATABASE_PLACEHOLDER_NAME = "User Database"
 
const char *const INVALID_KEYWORD_INDEX_STRING = "KEYWORD_ERROR_STRING: Invalid type index"
 
const char *const ENUM_TYPES [58]
 
const double GeometricResolution = 0.01
 

Function Documentation

◆ allKeywords()

const char * VICUS::allKeywords ( int  typenum,
int  t 
)

Returns all keywords including deprecated for a given category (typenum) and type number (t).

◆ camelCase2ReadableString()

QString VICUS::camelCase2ReadableString ( const std::string &  original)

Takes a string in camel case notation as input and returns a QString whith a space before each capital letter.

◆ checkForSurfaceParent()

const VICUS::Room * VICUS::checkForSurfaceParent ( const VICUS::Object obj)

◆ checkForUniqueIDs() [1/2]

template<typename T >
void VICUS::checkForUniqueIDs ( const std::vector< const T * > &  vec,
std::set< unsigned int > &  usedIDs 
)

Same as function above, but for containers holding const pointers instead of objects.

◆ checkForUniqueIDs() [2/2]

template<typename T >
void VICUS::checkForUniqueIDs ( const std::vector< T > &  vec,
std::set< unsigned int > &  usedIDs 
)

Test function that checks that all objects in the given vector have unique m_id parameters. The set passed as second argument is used for comparison. Pass an empty set if only the elements in the vector itself shall be tested. You can re-use the populated set for another call to this function, if you want to ensure uniqueness of several object vectors.

◆ contains()

template<typename T >
bool VICUS::contains ( const std::vector< T > &  vec,
unsigned int  id 
)

Checks if an object with m_id matching the searched id exists in the vector.

◆ createUniqueNandradObjListAndName()

std::string VICUS::createUniqueNandradObjListAndName ( const std::string &  name,
const std::vector< unsigned int > &  roomIds,
NANDRAD::Project &  p,
const NANDRAD::ModelInputReference::referenceType_t &  type 
)

◆ createUniqueNandradObjListName()

std::string VICUS::createUniqueNandradObjListName ( const std::map< std::string, std::vector< unsigned int > > &  objListNames,
const std::string &  name 
)

◆ element() [1/3]

template<typename T >
const T * VICUS::element ( const std::vector< T > &  vec,
const std::string &  name 
)

Utility function to find a vector element by name.

◆ element() [2/3]

template<typename T >
const T * VICUS::element ( const std::vector< T > &  vec,
unsigned int  id 
)

Function to find an element by ID (const-version).

◆ element() [3/3]

template<typename T >
T * VICUS::element ( std::vector< T > &  vec,
unsigned int  id 
)

Function to find an element by ID.

◆ elementIndex() [1/2]

template<typename T >
unsigned int VICUS::elementIndex ( const std::vector< T > &  vec,
const std::string &  name,
bool  caseSensitiv = true 
)

Utility function to find a vector element's index by name.

◆ elementIndex() [2/2]

template<typename T >
unsigned int VICUS::elementIndex ( const std::vector< T > &  vec,
unsigned int  id 
)

Utility function to find a vector element by name.

◆ enum2index()

int VICUS::enum2index ( const std::string &  enumtype)

Converts a category string to respective enumeration value.

◆ isValidTemplate()

template<typename T >
bool VICUS::isValidTemplate ( const std::vector< T >  elements,
QStringList &  errorStack,
const QString &  name 
)

Simple valid function.

◆ largestUniqueId()

template<typename T >
unsigned int VICUS::largestUniqueId ( const std::vector< T > &  vec)

Function to generate a unique ID that is larger than all the other IDs used. This is useful if a series of objects with newly generated IDs shall be added to a container.

◆ mergeDayType()

std::vector< NANDRAD::Schedule::ScheduledDayType > VICUS::mergeDayType ( const std::vector< int > &  dts)

◆ MultiLangString2QString()

QString VICUS::MultiLangString2QString ( const IBK::MultiLanguageString &  mls)
inline

◆ selectionCheck()

bool VICUS::selectionCheck ( const VICUS::Object o,
bool  takeSelected,
bool  takeVisible 
)

◆ theKeyword()

const char * VICUS::theKeyword ( int  typenum,
int  t 
)

Returns a keyword string for a given category (typenum) and type number t.

◆ uniqueId() [1/4]

template<typename T >
unsigned int VICUS::uniqueId ( const std::set< T > &  vec)

Function to generate unique (lowest not yet used) ID.

◆ uniqueId() [2/4]

template<>
unsigned int VICUS::uniqueId ( const std::set< unsigned int > &  vec)
inline

Function to generate unique (lowest not yet used) ID.

◆ uniqueId() [3/4]

template<typename T >
unsigned int VICUS::uniqueId ( const std::vector< T > &  vec)

Function to generate unique (lowest not yet used) ID.

◆ uniqueId() [4/4]

template<>
unsigned int VICUS::uniqueId ( const std::vector< unsigned int > &  vec)
inline

Function to generate unique (lowest not yet used) ID.

◆ uniqueIdAdd()

template<typename T >
unsigned int VICUS::uniqueIdAdd ( std::vector< T > &  vec)

Function to generate unique ID and add this ID to the vector.

◆ uniqueIdWithPredef() [1/2]

template<typename T >
unsigned int VICUS::uniqueIdWithPredef ( std::vector< T > &  vec,
unsigned int  id,
std::map< T, T >  mapOldToNewId 
)

Function to generate unique ID. First check predefined id. Add the Id to the container.

◆ uniqueIdWithPredef() [2/2]

template<typename T >
unsigned int VICUS::uniqueIdWithPredef ( std::vector< T > &  vec,
unsigned int  newId 
)

Function to generate unique ID. First check predefined id. And the Id to the container.

◆ uniqueName()

QString VICUS::uniqueName ( const QString &  baseName,
const std::set< QString > &  existingNames 
)

Generates a new unique name in format "basename" or "basename (<nr>)" with increasing numbers until the name no longer exists in set existingNames. NOTE: we cannot use [<nr>] because when generating output variable names, this interferes with the unit specification.

NOTE: basename is always trimmed.

Parameters
baseNameContains the original name, which may include already "(<nr>)"

Variable Documentation

◆ DATABASE_PLACEHOLDER_NAME

const char * VICUS::DATABASE_PLACEHOLDER_NAME = "Database"

◆ ENUM_TYPES

const char* const VICUS::ENUM_TYPES[58]

Holds a list of all enum types/categories.

◆ GeometricResolution

const double VICUS::GeometricResolution = 0.01
extern

Line is a helper class that implements a range of line operations. It is meant to be constructed from an edge definition. It stores the line internally in vector form a*lambda + b.

◆ INVALID_ID

unsigned int VICUS::INVALID_ID = 0xFFFFFFFF

Defines an invalid id

◆ INVALID_KEYWORD_INDEX_STRING

const char* const VICUS::INVALID_KEYWORD_INDEX_STRING = "KEYWORD_ERROR_STRING: Invalid type index"

Holds the string to print as error when an invalid keyword is encountered.

◆ LONG_VERSION

const char *const VICUS::LONG_VERSION = "1.0.4"

Long version number of the data model and project file.

◆ MIN_AREA_FOR_EXPORTED_SURFACES

const double VICUS::MIN_AREA_FOR_EXPORTED_SURFACES = 0.1

Minimum area for export of surfaces.

◆ USER_DATABASE_PLACEHOLDER_NAME

const char * VICUS::USER_DATABASE_PLACEHOLDER_NAME = "User Database"

◆ VERSION

const char *const VICUS::VERSION = "1.0"

Version number of the data model and project file.

◆ XML_READ_ERROR

const char * VICUS::XML_READ_ERROR = "Error in XML file, line %1: %2"

◆ XML_READ_UNKNOWN_ATTRIBUTE

const char * VICUS::XML_READ_UNKNOWN_ATTRIBUTE = "Unknown/unsupported attribute '%1' in line %2."

◆ XML_READ_UNKNOWN_ELEMENT

const char * VICUS::XML_READ_UNKNOWN_ELEMENT = "Unknown/unsupported tag '%1' in line %2."

◆ XML_READ_UNKNOWN_NAME

const char * VICUS::XML_READ_UNKNOWN_NAME = "Name '%1' for tag '%2' in line %3 is invalid/unknown."