Class: Google::Apis::ContentV2::Amount

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Amount

Returns a new instance of Amount.



1522
1523
1524
# File 'lib/google/apis/content_v2/classes.rb', line 1522

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

Instance Attribute Details

#pretaxGoogle::Apis::ContentV2::Price

[required] Value before taxes. Corresponds to the JSON property pretax



1515
1516
1517
# File 'lib/google/apis/content_v2/classes.rb', line 1515

def pretax
  @pretax
end

#taxGoogle::Apis::ContentV2::Price

[required] Tax value. Corresponds to the JSON property tax



1520
1521
1522
# File 'lib/google/apis/content_v2/classes.rb', line 1520

def tax
  @tax
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1527
1528
1529
1530
# File 'lib/google/apis/content_v2/classes.rb', line 1527

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