| /** |
| * Copyright (c) 2011, 2014 - Lunifera GmbH (Gross Enzersdorf), Loetz GmbH&Co.KG (Heidelberg) |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License v1.0 |
| * which accompanies this distribution, and is available at |
| * http://www.eclipse.org/legal/epl-v10.html |
| */ |
| package org.eclipse.osbp.dsl.^entity.xtext.tests.model.testcarstore2{ |
| |
| datatype long jvmType Long as primitive; |
| datatype int jvmType Integer as primitive; |
| datatype String jvmType String; |
| datatype datetype dateType date; |
| datatype timetype dateType time; |
| datatype bool jvmType Boolean as primitive; |
| |
| entity Person { |
| schemaName Testcarstore2; |
| id long id; |
| var String firstname; |
| var String lastname; |
| var datetype birthdate; |
| } |
| |
| bean Address { |
| var String streetname; |
| var int housenumber; |
| var String city; |
| var int zipcode; |
| } |
| |
| entity Manufacturer { |
| schemaName Testcarstore2; |
| id long id; |
| var String name; |
| var Address address; |
| ref cascade Car[*] cars opposite manufacturer; |
| } |
| |
| entity Car { |
| schemaName Testcarstore2; |
| id long id; |
| var String modelname; |
| var timetype constructiondate; |
| var int price; |
| ref Manufacturer[1] manufacturer opposite cars; |
| } |
| |
| entity Customer extends Person { |
| schemaName Testcarstore2; |
| var bool isseller; |
| var bool isbuyer; |
| var String phonenumber; |
| var String iban; |
| var int discount; |
| } |
| |
| entity Employee extends Person { |
| schemaName Testcarstore2; |
| var long employeenumber; |
| var timetype employeesince; |
| var int salary; |
| var String jobdescription; |
| ref Employee[1] boss opposite subordinates; |
| ref cascade Employee[*] subordinates opposite boss; |
| } |
| |
| entity UsedCar extends Car { |
| schemaName Testcarstore2; |
| var String state; |
| var int mileage; |
| ref Customer[1] seller; |
| } |
| |
| |
| } |