ArmCarbonOptimizationModelFactory.CarbonEmission Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Initializes a new instance of CarbonEmission.
public static Azure.ResourceManager.CarbonOptimization.Models.CarbonEmission CarbonEmission(string dataType = default, double latestMonthEmissions = 0, double previousMonthEmissions = 0, double? monthOverMonthEmissionsChangeRatio = default, double? monthlyEmissionsChangeValue = default);
static member CarbonEmission : string * double * double * Nullable<double> * Nullable<double> -> Azure.ResourceManager.CarbonOptimization.Models.CarbonEmission
Public Shared Function CarbonEmission (Optional dataType As String = Nothing, Optional latestMonthEmissions As Double = 0, Optional previousMonthEmissions As Double = 0, Optional monthOverMonthEmissionsChangeRatio As Nullable(Of Double) = Nothing, Optional monthlyEmissionsChangeValue As Nullable(Of Double) = Nothing) As CarbonEmission
Parameters
- dataType
- String
The data type of the query result, indicating the format of the returned response.
- latestMonthEmissions
- Double
Total carbon emissions for the specified query parameters, measured in kgCO2E. This value represents total emissions over the specified date range (e.g., March-June).
- previousMonthEmissions
- Double
Total carbon emissions for the previous month’s date range, which is the same period as the specified date range but shifted left by one month (e.g., if the specified range is March - June, the previous month’s range will be Feb - May). The value is measured in kgCO2E.
The percentage change in carbon emissions between the current and previous DateRange. This is calculated as: (latestMonthEmissions - previousMonthEmissions) / previousMonthEmissions.
The change in carbon emissions between the current and previous period, calculated as: latestMonthEmissions - previousMonthEmissions.
Returns
A new CarbonEmission instance for mocking.