Class Workbook
Main scripting data model class. Static properties expose the data model to scripting.
Namespace: Scripting
Syntax
public class Workbook
Properties
BuildingRegions
Gets the building regions.
Declaration
public static IEnumerable<BuildingRegion> BuildingRegions { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<BuildingRegion> |
CalculationScenarios
Gets the calculation scenarios (there will be one scenario in this list once a calculation has run).
Declaration
public static IEnumerable<EnergyYieldCalculationScenario> CalculationScenarios { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<EnergyYieldCalculationScenario> |
CalculationSettings
Gets the SolarFarmer CalculationSettings object
Declaration
public static CalculationSettings CalculationSettings { get; }
Property Value
Type | Description |
---|---|
CalculationSettings |
Climate
Gets the climate.
Declaration
public static Climate Climate { get; }
Property Value
Type | Description |
---|---|
Climate |
ComponentLibrary
Gets the component library.
Declaration
public static ComponentLibrary ComponentLibrary { get; }
Property Value
Type | Description |
---|---|
ComponentLibrary |
Domain
Get the SolarFarmer Domain object
Declaration
public static Domain Domain { get; }
Property Value
Type | Description |
---|---|
Domain |
ShadingRegions
Gets the shading regions.
Declaration
public static IEnumerable<ShadingRegion> ShadingRegions { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<ShadingRegion> |
WorkbookSettings
Gets the workbook settings.
Declaration
public static WorkbookSettings WorkbookSettings { get; }
Property Value
Type | Description |
---|---|
WorkbookSettings |
Methods
AddBuildingRegion(String, IEnumerable<I2DLocation>, Double, BuildingBoundaryType)
Adds a new building region to the workbook.
Declaration
public static BuildingRegion AddBuildingRegion(string name, IEnumerable<I2DLocation> points, double height, BuildingBoundaryType buildingBoundaryType)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name to give to the building region. |
System.Collections.Generic.IEnumerable<I2DLocation> | points | The points of the building region (in workbook projection). |
System.Double | height | The height (in metres) of the building region. |
BuildingBoundaryType | buildingBoundaryType | The type of the building region. |
Returns
Type | Description |
---|---|
BuildingRegion | The newly added building region. |
AddShadingRegion(String, IEnumerable<I2DLocation>, Double, ShadingBoundaryType)
Adds a new shading region to the workbook.
Declaration
public static ShadingRegion AddShadingRegion(string name, IEnumerable<I2DLocation> points, double height, ShadingBoundaryType shadingBoundaryType)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name to give to the shading region. |
System.Collections.Generic.IEnumerable<I2DLocation> | points | The points of the shading region (in workbook projection). |
System.Double | height | The height (in metres) of the shading region. |
ShadingBoundaryType | shadingBoundaryType | The type of the shading region. |
Returns
Type | Description |
---|---|
ShadingRegion | The newly added shading region. |
RemoveAllBuildingRegions()
Removes all the building regions in the workbook.
Declaration
public static void RemoveAllBuildingRegions()
RemoveAllShadingRegions()
Removes all the shading regions in the workbook.
Declaration
public static void RemoveAllShadingRegions()
RemoveBuildingRegion(BuildingRegion)
Removes the specified building region from the site layout.
Declaration
public static void RemoveBuildingRegion(BuildingRegion buildingRegion)
Parameters
Type | Name | Description |
---|---|---|
BuildingRegion | buildingRegion | The building region to remove. |
RemoveShadingRegion(ShadingRegion)
Removes the specified shading region from the site layout.
Declaration
public static void RemoveShadingRegion(ShadingRegion shadingRegion)
Parameters
Type | Name | Description |
---|---|---|
ShadingRegion | shadingRegion | The shading region to remove. |