Module: SchemaOrg::Mixins::MenuItem
- Includes:
- Intangible
- Included in:
- SchemaOrg::MenuItem
- Defined in:
- lib/schema_org/mixins/menu_item.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#menu_add_on ⇒ Object
Additional menu item(s) such as a side dish of salad or side order of fries that can be added to this menu item.
-
#menu_add_on=(value) ⇒ Object
Additional menu item(s) such as a side dish of salad or side order of fries that can be added to this menu item.
-
#nutrition ⇒ Object
Nutrition information about the recipe or menu item.
-
#nutrition=(value) ⇒ Object
Nutrition information about the recipe or menu item.
-
#offers ⇒ Object
An offer to provide this item—for example, an offer to sell a product, rent the DVD of a movie, perform a service, or give away tickets to an event.
-
#offers=(value) ⇒ Object
An offer to provide this item—for example, an offer to sell a product, rent the DVD of a movie, perform a service, or give away tickets to an event.
-
#suitable_for_diet ⇒ Object
Indicates a dietary restriction or guideline for which this recipe or menu item is suitable, e.g.
-
#suitable_for_diet=(value) ⇒ Object
Indicates a dietary restriction or guideline for which this recipe or menu item is suitable, e.g.
Methods included from Thing
#additional_type, #additional_type=, #alternate_name, #alternate_name=, #description, #description=, #disambiguating_description, #disambiguating_description=, #identifier, #identifier=, #image, #image=, #main_entity_of_page, #main_entity_of_page=, #name, #name=, #owner, #owner=, #potential_action, #potential_action=, #same_as, #same_as=, #subject_of, #subject_of=, #url, #url=
Class Method Details
.schema_property_definitions ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/schema_org/mixins/menu_item.rb', line 11 def self.schema_property_definitions { menu_add_on: { schema_name: "menuAddOn", schema_url: "https://schema.org/menuAddOn", comment_lines: ["Additional menu item(s) such as a side dish of salad or side order of fries that can be added to this menu item. Additionally it can be a menu section containing allowed add-on menu items for this menu item."].freeze, ranges: ["MenuItem", "MenuSection"].freeze, external_ranges: [].freeze, inverse_of: nil, superseded_by: nil, supersedes: nil }.freeze, nutrition: { schema_name: "nutrition", schema_url: "https://schema.org/nutrition", comment_lines: ["Nutrition information about the recipe or menu item."].freeze, ranges: ["NutritionInformation"].freeze, external_ranges: [].freeze, inverse_of: nil, superseded_by: nil, supersedes: nil }.freeze, offers: { schema_name: "offers", schema_url: "https://schema.org/offers", comment_lines: ["An offer to provide this item—for example, an offer to sell a product, rent the DVD of a movie, perform a service, or give away tickets to an event. Use [[businessFunction]] to indicate the kind of transaction offered, i.e. sell, lease, etc. This property can also be used to describe a [[Demand]]. While this property is listed as expected on a number of common types, it can be used in others. In that case, using a second type, such as Product or a subtype of Product, can clarify the nature of the offer."].freeze, ranges: ["Demand", "Offer"].freeze, external_ranges: [].freeze, inverse_of: "itemOffered", superseded_by: nil, supersedes: nil }.freeze, suitable_for_diet: { schema_name: "suitableForDiet", schema_url: "https://schema.org/suitableForDiet", comment_lines: ["Indicates a dietary restriction or guideline for which this recipe or menu item is suitable, e.g. diabetic, halal etc."].freeze, ranges: ["Diet", "RestrictedDiet"].freeze, external_ranges: [].freeze, inverse_of: nil, superseded_by: nil, supersedes: nil }.freeze }.freeze end |
Instance Method Details
#menu_add_on ⇒ Object
Additional menu item(s) such as a side dish of salad or side order of fries that can be added to this menu item. Additionally it can be a menu section containing allowed add-on menu items for this menu item.
57 58 59 |
# File 'lib/schema_org/mixins/menu_item.rb', line 57 def read_property(:menu_add_on) end |
#menu_add_on=(value) ⇒ Object
Additional menu item(s) such as a side dish of salad or side order of fries that can be added to this menu item. Additionally it can be a menu section containing allowed add-on menu items for this menu item.
62 63 64 |
# File 'lib/schema_org/mixins/menu_item.rb', line 62 def (value) write_property(:menu_add_on, value) end |
#nutrition ⇒ Object
Nutrition information about the recipe or menu item.
67 68 69 |
# File 'lib/schema_org/mixins/menu_item.rb', line 67 def nutrition read_property(:nutrition) end |
#nutrition=(value) ⇒ Object
Nutrition information about the recipe or menu item.
72 73 74 |
# File 'lib/schema_org/mixins/menu_item.rb', line 72 def nutrition=(value) write_property(:nutrition, value) end |
#offers ⇒ Object
An offer to provide this item—for example, an offer to sell a product, rent the DVD of a movie, perform a service, or give away tickets to an event. Use [[businessFunction]] to indicate the kind of transaction offered, i.e. sell, lease, etc. This property can also be used to describe a [[Demand]]. While this property is listed as expected on a number of common types, it can be used in others. In that case, using a second type, such as Product or a subtype of Product, can clarify the nature of the offer.
Inverse-property: itemOffered.
78 79 80 |
# File 'lib/schema_org/mixins/menu_item.rb', line 78 def offers read_property(:offers) end |
#offers=(value) ⇒ Object
An offer to provide this item—for example, an offer to sell a product, rent the DVD of a movie, perform a service, or give away tickets to an event. Use [[businessFunction]] to indicate the kind of transaction offered, i.e. sell, lease, etc. This property can also be used to describe a [[Demand]]. While this property is listed as expected on a number of common types, it can be used in others. In that case, using a second type, such as Product or a subtype of Product, can clarify the nature of the offer.
Inverse-property: itemOffered.
84 85 86 |
# File 'lib/schema_org/mixins/menu_item.rb', line 84 def offers=(value) write_property(:offers, value) end |
#suitable_for_diet ⇒ Object
Indicates a dietary restriction or guideline for which this recipe or menu item is suitable, e.g. diabetic, halal etc.
89 90 91 |
# File 'lib/schema_org/mixins/menu_item.rb', line 89 def suitable_for_diet read_property(:suitable_for_diet) end |
#suitable_for_diet=(value) ⇒ Object
Indicates a dietary restriction or guideline for which this recipe or menu item is suitable, e.g. diabetic, halal etc.
94 95 96 |
# File 'lib/schema_org/mixins/menu_item.rb', line 94 def suitable_for_diet=(value) write_property(:suitable_for_diet, value) end |