Class: DataFoodConsortium::Connector::Address
- Inherits:
-
Object
- Object
- DataFoodConsortium::Connector::Address
- Includes:
- VirtualAssembly::Semantizer::SemanticObject
- Defined in:
- lib/datafoodconsortium/connector/address.rb
Instance Attribute Summary collapse
-
#city ⇒ Object
Returns the value of attribute city.
-
#country ⇒ Object
Returns the value of attribute country.
-
#postalCode ⇒ Object
Returns the value of attribute postalCode.
-
#street ⇒ Object
Returns the value of attribute street.
Instance Method Summary collapse
-
#initialize(street, postalCode, city, country) ⇒ Address
constructor
A new instance of Address.
Constructor Details
#initialize(street, postalCode, city, country) ⇒ Address
Returns a new instance of Address.
35 36 37 38 39 40 41 42 43 44 45 46 47 |
# File 'lib/datafoodconsortium/connector/address.rb', line 35 def initialize(street, postalCode, city, country) super() self.semanticType = "http://static.datafoodconsortium.org/ontologies/DFC_BusinessOntology.owl#Address" self.street = street self.postalCode = postalCode self.city = city self.country = country registerSemanticProperty("http://static.datafoodconsortium.org/ontologies/DFC_BusinessOntology.owl#hasStreet") { self.street } registerSemanticProperty("http://static.datafoodconsortium.org/ontologies/DFC_BusinessOntology.owl#hasPostalCode") { self.postalCode } registerSemanticProperty("http://static.datafoodconsortium.org/ontologies/DFC_BusinessOntology.owl#hasCity") { self.city } registerSemanticProperty("http://static.datafoodconsortium.org/ontologies/DFC_BusinessOntology.owl#hasCountry") { self.country } end |
Instance Attribute Details
#city ⇒ Object
Returns the value of attribute city.
32 33 34 |
# File 'lib/datafoodconsortium/connector/address.rb', line 32 def city @city end |
#country ⇒ Object
Returns the value of attribute country.
33 34 35 |
# File 'lib/datafoodconsortium/connector/address.rb', line 33 def country @country end |
#postalCode ⇒ Object
Returns the value of attribute postalCode.
31 32 33 |
# File 'lib/datafoodconsortium/connector/address.rb', line 31 def postalCode @postalCode end |
#street ⇒ Object
Returns the value of attribute street.
30 31 32 |
# File 'lib/datafoodconsortium/connector/address.rb', line 30 def street @street end |