Class: Google::Apis::ManufacturersV1::Nutrition

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Nutrition

Returns a new instance of Nutrition.



868
869
870
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 868

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

Instance Attribute Details

#added_sugarsGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property addedSugars



656
657
658
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 656

def added_sugars
  @added_sugars
end

#added_sugars_daily_percentageFloat

Added sugars daily percentage. Corresponds to the JSON property addedSugarsDailyPercentage

Returns:

  • (Float)


661
662
663
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 661

def added_sugars_daily_percentage
  @added_sugars_daily_percentage
end

#calciumGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property calcium



666
667
668
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 666

def calcium
  @calcium
end

#calcium_daily_percentageFloat

Calcium daily percentage. Corresponds to the JSON property calciumDailyPercentage

Returns:

  • (Float)


671
672
673
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 671

def calcium_daily_percentage
  @calcium_daily_percentage
end

#cholesterolGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property cholesterol



676
677
678
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 676

def cholesterol
  @cholesterol
end

#cholesterol_daily_percentageFloat

Cholesterol daily percentage. Corresponds to the JSON property cholesterolDailyPercentage

Returns:

  • (Float)


681
682
683
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 681

def cholesterol_daily_percentage
  @cholesterol_daily_percentage
end

#dietary_fiberGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property dietaryFiber



686
687
688
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 686

def dietary_fiber
  @dietary_fiber
end

#dietary_fiber_daily_percentageFloat

Dietary fiber daily percentage. Corresponds to the JSON property dietaryFiberDailyPercentage

Returns:

  • (Float)


691
692
693
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 691

def dietary_fiber_daily_percentage
  @dietary_fiber_daily_percentage
end

#energyGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property energy



696
697
698
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 696

def energy
  @energy
end

#energy_from_fatGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property energyFromFat



701
702
703
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 701

def energy_from_fat
  @energy_from_fat
end

#folate_daily_percentageFloat

Folate daily percentage. Corresponds to the JSON property folateDailyPercentage

Returns:

  • (Float)


706
707
708
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 706

def folate_daily_percentage
  @folate_daily_percentage
end

#folate_folic_acidGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property folateFolicAcid



711
712
713
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 711

def folate_folic_acid
  @folate_folic_acid
end

#folate_mcg_dfeFloat

Folate mcg DFE. Corresponds to the JSON property folateMcgDfe

Returns:

  • (Float)


716
717
718
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 716

def folate_mcg_dfe
  @folate_mcg_dfe
end

#ironGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property iron



721
722
723
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 721

def iron
  @iron
end

#iron_daily_percentageFloat

Iron daily percentage. Corresponds to the JSON property ironDailyPercentage

Returns:

  • (Float)


726
727
728
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 726

def iron_daily_percentage
  @iron_daily_percentage
end

#monounsaturated_fatGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property monounsaturatedFat



731
732
733
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 731

def monounsaturated_fat
  @monounsaturated_fat
end

#nutrition_fact_measureString

Nutrition fact measure. Corresponds to the JSON property nutritionFactMeasure

Returns:

  • (String)


736
737
738
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 736

def nutrition_fact_measure
  @nutrition_fact_measure
end

#polyolsGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property polyols



741
742
743
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 741

def polyols
  @polyols
end

#polyunsaturated_fatGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property polyunsaturatedFat



746
747
748
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 746

def polyunsaturated_fat
  @polyunsaturated_fat
end

#potassiumGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property potassium



751
752
753
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 751

def potassium
  @potassium
end

#potassium_daily_percentageFloat

Potassium daily percentage. Corresponds to the JSON property potassiumDailyPercentage

Returns:

  • (Float)


756
757
758
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 756

def potassium_daily_percentage
  @potassium_daily_percentage
end

#prepared_size_descriptionString

Prepared size description. Corresponds to the JSON property preparedSizeDescription

Returns:

  • (String)


761
762
763
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 761

def prepared_size_description
  @prepared_size_description
end

#proteinGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property protein



766
767
768
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 766

def protein
  @protein
end

#protein_daily_percentageFloat

Protein daily percentage. Corresponds to the JSON property proteinDailyPercentage

Returns:

  • (Float)


771
772
773
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 771

def protein_daily_percentage
  @protein_daily_percentage
end

#saturated_fatGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property saturatedFat



776
777
778
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 776

def saturated_fat
  @saturated_fat
end

#saturated_fat_daily_percentageFloat

Saturated fat daily percentage. Corresponds to the JSON property saturatedFatDailyPercentage

Returns:

  • (Float)


781
782
783
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 781

def saturated_fat_daily_percentage
  @saturated_fat_daily_percentage
end

#serving_size_descriptionString

Food Serving Size. Serving size description. Corresponds to the JSON property servingSizeDescription

Returns:

  • (String)


786
787
788
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 786

def serving_size_description
  @serving_size_description
end

#serving_size_measureGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property servingSizeMeasure



791
792
793
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 791

def serving_size_measure
  @serving_size_measure
end

#servings_per_containerString

Servings per container. Corresponds to the JSON property servingsPerContainer

Returns:

  • (String)


796
797
798
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 796

def servings_per_container
  @servings_per_container
end

#sodiumGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property sodium



801
802
803
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 801

def sodium
  @sodium
end

#sodium_daily_percentageFloat

Sodium daily percentage. Corresponds to the JSON property sodiumDailyPercentage

Returns:

  • (Float)


806
807
808
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 806

def sodium_daily_percentage
  @sodium_daily_percentage
end

#starchGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property starch



811
812
813
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 811

def starch
  @starch
end

#total_carbohydrateGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property totalCarbohydrate



816
817
818
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 816

def total_carbohydrate
  @total_carbohydrate
end

#total_carbohydrate_daily_percentageFloat

Total carbohydrate daily percentage. Corresponds to the JSON property totalCarbohydrateDailyPercentage

Returns:

  • (Float)


821
822
823
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 821

def total_carbohydrate_daily_percentage
  @total_carbohydrate_daily_percentage
end

#total_fatGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property totalFat



826
827
828
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 826

def total_fat
  @total_fat
end

#total_fat_daily_percentageFloat

Total fat daily percentage. Corresponds to the JSON property totalFatDailyPercentage

Returns:

  • (Float)


831
832
833
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 831

def total_fat_daily_percentage
  @total_fat_daily_percentage
end

#total_sugarsGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property totalSugars



836
837
838
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 836

def total_sugars
  @total_sugars
end

#total_sugars_daily_percentageFloat

Total sugars daily percentage. Corresponds to the JSON property totalSugarsDailyPercentage

Returns:

  • (Float)


841
842
843
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 841

def total_sugars_daily_percentage
  @total_sugars_daily_percentage
end

#trans_fatGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property transFat



846
847
848
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 846

def trans_fat
  @trans_fat
end

#trans_fat_daily_percentageFloat

Trans fat daily percentage. Corresponds to the JSON property transFatDailyPercentage

Returns:

  • (Float)


851
852
853
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 851

def trans_fat_daily_percentage
  @trans_fat_daily_percentage
end

#vitamin_dGoogle::Apis::ManufacturersV1::FloatUnit

Combination of float amout and unit. Corresponds to the JSON property vitaminD



856
857
858
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 856

def vitamin_d
  @vitamin_d
end

#vitamin_d_daily_percentageFloat

Vitamin D daily percentage. Corresponds to the JSON property vitaminDDailyPercentage

Returns:

  • (Float)


861
862
863
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 861

def vitamin_d_daily_percentage
  @vitamin_d_daily_percentage
end

#voluntary_nutrition_factArray<Google::Apis::ManufacturersV1::VoluntaryNutritionFact>

Voluntary nutrition fact. Corresponds to the JSON property voluntaryNutritionFact



866
867
868
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 866

def voluntary_nutrition_fact
  @voluntary_nutrition_fact
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
# File 'lib/google/apis/manufacturers_v1/classes.rb', line 873

def update!(**args)
  @added_sugars = args[:added_sugars] if args.key?(:added_sugars)
  @added_sugars_daily_percentage = args[:added_sugars_daily_percentage] if args.key?(:added_sugars_daily_percentage)
  @calcium = args[:calcium] if args.key?(:calcium)
  @calcium_daily_percentage = args[:calcium_daily_percentage] if args.key?(:calcium_daily_percentage)
  @cholesterol = args[:cholesterol] if args.key?(:cholesterol)
  @cholesterol_daily_percentage = args[:cholesterol_daily_percentage] if args.key?(:cholesterol_daily_percentage)
  @dietary_fiber = args[:dietary_fiber] if args.key?(:dietary_fiber)
  @dietary_fiber_daily_percentage = args[:dietary_fiber_daily_percentage] if args.key?(:dietary_fiber_daily_percentage)
  @energy = args[:energy] if args.key?(:energy)
  @energy_from_fat = args[:energy_from_fat] if args.key?(:energy_from_fat)
  @folate_daily_percentage = args[:folate_daily_percentage] if args.key?(:folate_daily_percentage)
  @folate_folic_acid = args[:folate_folic_acid] if args.key?(:folate_folic_acid)
  @folate_mcg_dfe = args[:folate_mcg_dfe] if args.key?(:folate_mcg_dfe)
  @iron = args[:iron] if args.key?(:iron)
  @iron_daily_percentage = args[:iron_daily_percentage] if args.key?(:iron_daily_percentage)
  @monounsaturated_fat = args[:monounsaturated_fat] if args.key?(:monounsaturated_fat)
  @nutrition_fact_measure = args[:nutrition_fact_measure] if args.key?(:nutrition_fact_measure)
  @polyols = args[:polyols] if args.key?(:polyols)
  @polyunsaturated_fat = args[:polyunsaturated_fat] if args.key?(:polyunsaturated_fat)
  @potassium = args[:potassium] if args.key?(:potassium)
  @potassium_daily_percentage = args[:potassium_daily_percentage] if args.key?(:potassium_daily_percentage)
  @prepared_size_description = args[:prepared_size_description] if args.key?(:prepared_size_description)
  @protein = args[:protein] if args.key?(:protein)
  @protein_daily_percentage = args[:protein_daily_percentage] if args.key?(:protein_daily_percentage)
  @saturated_fat = args[:saturated_fat] if args.key?(:saturated_fat)
  @saturated_fat_daily_percentage = args[:saturated_fat_daily_percentage] if args.key?(:saturated_fat_daily_percentage)
  @serving_size_description = args[:serving_size_description] if args.key?(:serving_size_description)
  @serving_size_measure = args[:serving_size_measure] if args.key?(:serving_size_measure)
  @servings_per_container = args[:servings_per_container] if args.key?(:servings_per_container)
  @sodium = args[:sodium] if args.key?(:sodium)
  @sodium_daily_percentage = args[:sodium_daily_percentage] if args.key?(:sodium_daily_percentage)
  @starch = args[:starch] if args.key?(:starch)
  @total_carbohydrate = args[:total_carbohydrate] if args.key?(:total_carbohydrate)
  @total_carbohydrate_daily_percentage = args[:total_carbohydrate_daily_percentage] if args.key?(:total_carbohydrate_daily_percentage)
  @total_fat = args[:total_fat] if args.key?(:total_fat)
  @total_fat_daily_percentage = args[:total_fat_daily_percentage] if args.key?(:total_fat_daily_percentage)
  @total_sugars = args[:total_sugars] if args.key?(:total_sugars)
  @total_sugars_daily_percentage = args[:total_sugars_daily_percentage] if args.key?(:total_sugars_daily_percentage)
  @trans_fat = args[:trans_fat] if args.key?(:trans_fat)
  @trans_fat_daily_percentage = args[:trans_fat_daily_percentage] if args.key?(:trans_fat_daily_percentage)
  @vitamin_d = args[:vitamin_d] if args.key?(:vitamin_d)
  @vitamin_d_daily_percentage = args[:vitamin_d_daily_percentage] if args.key?(:vitamin_d_daily_percentage)
  @voluntary_nutrition_fact = args[:voluntary_nutrition_fact] if args.key?(:voluntary_nutrition_fact)
end