Class: Google::Apis::SolarV1::SolarPanel

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

Overview

SolarPanel describes the position, orientation, and production of a single solar panel. See the panel_height_meters, panel_width_meters, and panel_capacity_watts fields in SolarPotential for information on the parameters of the panel.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ SolarPanel

Returns a new instance of SolarPanel.



975
976
977
# File 'lib/google/apis/solar_v1/classes.rb', line 975

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

Instance Attribute Details

#centerGoogle::Apis::SolarV1::LatLng

An object that represents a latitude/longitude pair. This is expressed as a pair of doubles to represent degrees latitude and degrees longitude. Unless specified otherwise, this object must conform to the WGS84 standard. Values must be within normalized ranges. Corresponds to the JSON property center



956
957
958
# File 'lib/google/apis/solar_v1/classes.rb', line 956

def center
  @center
end

#orientationString

The orientation of the panel. Corresponds to the JSON property orientation

Returns:

  • (String)


961
962
963
# File 'lib/google/apis/solar_v1/classes.rb', line 961

def orientation
  @orientation
end

#segment_indexFixnum

Index in roof_segment_stats of the RoofSegmentSizeAndSunshineStats which corresponds to the roof segment that this panel is placed on. Corresponds to the JSON property segmentIndex

Returns:

  • (Fixnum)


967
968
969
# File 'lib/google/apis/solar_v1/classes.rb', line 967

def segment_index
  @segment_index
end

#yearly_energy_dc_kwhFloat

How much sunlight energy this layout captures over the course of a year, in DC kWh. Corresponds to the JSON property yearlyEnergyDcKwh

Returns:

  • (Float)


973
974
975
# File 'lib/google/apis/solar_v1/classes.rb', line 973

def yearly_energy_dc_kwh
  @yearly_energy_dc_kwh
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



980
981
982
983
984
985
# File 'lib/google/apis/solar_v1/classes.rb', line 980

def update!(**args)
  @center = args[:center] if args.key?(:center)
  @orientation = args[:orientation] if args.key?(:orientation)
  @segment_index = args[:segment_index] if args.key?(:segment_index)
  @yearly_energy_dc_kwh = args[:yearly_energy_dc_kwh] if args.key?(:yearly_energy_dc_kwh)
end