![]() |
VOOZH | about |
dotnet add package BrickSchema.Net --version 1.3.30
NuGet\Install-Package BrickSchema.Net -Version 1.3.30
<PackageReference Include="BrickSchema.Net" Version="1.3.30" />
<PackageVersion Include="BrickSchema.Net" Version="1.3.30" />Directory.Packages.props
<PackageReference Include="BrickSchema.Net" />Project file
paket add BrickSchema.Net --version 1.3.30
#r "nuget: BrickSchema.Net, 1.3.30"
#:package BrickSchema.Net@1.3.30
#addin nuget:?package=BrickSchema.Net&version=1.3.30Install as a Cake Addin
#tool nuget:?package=BrickSchema.Net&version=1.3.30Install as a Cake Tool
The BrickSchema.Net is a C# library implimentation of Brick Schema. This user manual will guide you through the process of setting up, importing, and working with the Brick Schema.
For more information about Brick Schema, please visit https://brickschema.org/
As of 4/20/2023 - The library implemented 80% of Brick Schema v1.3.
The package version format is a.b.x (1.3.1). a.b = Brick Schema version. https://brickschema.org/ontology x = package revision
To use the BrickSchema.Net, you need to have the following software installed:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using BrickSchema.Net.Classes;
using BrickSchema.Net.Classes.Collection;
using BrickSchema.Net.Classes.Collection.Loop;
using BrickSchema.Net.Classes.Equipment;
using BrickSchema.Net.Classes.Location;
using BrickSchema.Net.Classes.Measureable;
using BrickSchema.Net.Classes.Point;
To load a Brick schema froma JSON-LD file:
var manager = new BrickSchemaManager();
manager.LoadSchema("path/to/your/brick-schema.jsonld");
To save a Brick schema to a JSON-LD file:
manager.SaveSchema("path/to/save/brick-schema.jsonld");
Entities in the Brick schema are represented as objects of classes that inherit from the BrickEntity class. Each entity has an Id, Type, Properties, and Relationships.
To access the entities managed by the BrickSchemaManager:
var entities = manager.Entities;
To search for entities in the Brick schema, use the SearchEntities method and provide a predicate function:
var entityToUpdate = new Sensor
{
Id = "existing-entity-id",
Type = "NewType",
Properties = newProperties,
Relationships = newRelationships,
};
bool success = manager.UpdateEntity(entityToUpdate);
To update an existing entity in the Brick schema, use the UpdateEntity method:
var entityToUpdate = new Sensor
{
Id = "existing-entity-id",
Type = "NewType",
Properties = newProperties,
Relationships = newRelationships,
};
bool success = manager.UpdateEntity(entityToUpdate);
To add a new entity to the Brick schema, use one of the AddEntity methods for the specific entity type:
// Add a new floor location entity
var floor = manager.AddLocationFloor();
// Add a HVAC AHU entity
var ahu = manager.AddEquipmentHVACAHU();
// Add a HVAC VAV entity
var vav = manager.AddEquipmentHVACTerminalUnitVAV();
// Add a new sensor point entity
var sensor = manager.AddPointSensor();
// Add a new floor location entity
var floor = manager.AddLocationFloor();
//Add property relating to this entity
foor.AddProperty("Name", "Level 1");
// Add a HVAC AHU entity
var ahu = manager.AddEquipmentHVACAHU();
//Add property relating to this entity
ahu.AddProperty("Name", "AHU1");
//Add ahu to Level 1 floor location (relationship)
ahu.AddRelationshipLocationOf(floor.Id);
// Add a HVAC VAV entity
var vav = manager AddEquipmentHVACTerminalUnitVAV();
//Add property relating to this entity
vav.AddProperty("Name", "VAV1-1");
//Add vav to Level 1 floor locatio (relationship)
vav.AddRelationshipLocationOf(floor.Id);
//Add vav feed from AHU (relationship)
vav.AddRelationshipFedBy(ahu.Id);
// Add a new sensor point entity
var sensor = manager.AddPointSensor();
// Associate the point with VAV
sensor.AddRelationshipAssociatedWith(vav.Id);
// sensor is point of VAV
sensor.AddRelationshipPointOf(vav.Id);
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net7.0 net7.0 is compatible. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 was computed. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
Showing the top 1 NuGet packages that depend on BrickSchema.Net:
| Package | Downloads |
|---|---|
|
LisaCore
CSharp dynamic runtime code execution |
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.3.30 | 447 | 7/14/2023 |
| 1.3.29 | 372 | 7/14/2023 |
| 1.3.28 | 338 | 7/14/2023 |
| 1.3.27 | 337 | 7/13/2023 |
| 1.3.26 | 385 | 6/19/2023 |
| 1.3.25 | 320 | 6/19/2023 |
| 1.3.24 | 356 | 6/15/2023 |
| 1.3.23 | 350 | 6/15/2023 |
| 1.3.22 | 344 | 6/15/2023 |
| 1.3.21 | 373 | 6/8/2023 |
| 1.3.20 | 538 | 6/8/2023 |
| 1.3.19 | 319 | 6/8/2023 |
| 1.3.18 | 430 | 6/7/2023 |
| 1.3.17 | 370 | 6/6/2023 |
| 1.3.16 | 393 | 6/2/2023 |
| 1.3.15 | 423 | 6/1/2023 |
| 1.3.14 | 392 | 6/1/2023 |
| 1.3.13 | 306 | 6/1/2023 |
| 1.3.12 | 325 | 6/1/2023 |
| 1.3.11 | 303 | 6/1/2023 |