Class: Google::Apis::TravelimpactmodelV1::ComputeScope3FlightEmissionsRequest

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/travelimpactmodel_v1/classes.rb,
lib/google/apis/travelimpactmodel_v1/representations.rb,
lib/google/apis/travelimpactmodel_v1/representations.rb

Overview

A list of flight segments to request the Scope 3 emissions for.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ComputeScope3FlightEmissionsRequest

Returns a new instance of ComputeScope3FlightEmissionsRequest.



85
86
87
# File 'lib/google/apis/travelimpactmodel_v1/classes.rb', line 85

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#flightsArray<Google::Apis::TravelimpactmodelV1::Scope3FlightSegment>

Required. Flights to return emission estimates for. Corresponds to the JSON property flights



77
78
79
# File 'lib/google/apis/travelimpactmodel_v1/classes.rb', line 77

def flights
  @flights
end

#model_versionGoogle::Apis::TravelimpactmodelV1::ModelVersion

Travel Impact Model version. For more information about the model versioning see GitHub. Corresponds to the JSON property modelVersion



83
84
85
# File 'lib/google/apis/travelimpactmodel_v1/classes.rb', line 83

def model_version
  @model_version
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



90
91
92
93
# File 'lib/google/apis/travelimpactmodel_v1/classes.rb', line 90

def update!(**args)
  @flights = args[:flights] if args.key?(:flights)
  @model_version = args[:model_version] if args.key?(:model_version)
end