From 2a1f3bd2642faf5b84708c34a6657174cfc2c1be Mon Sep 17 00:00:00 2001 From: Kevin Frantz Date: Thu, 6 Sep 2018 12:58:36 +0200 Subject: [PATCH] Entity draft --- application/src/Entity/AbstractSource.php | 29 ++++--------------- application/src/Entity/Configuration.php | 3 +- application/src/Entity/NodeInterface.php | 7 ++--- application/src/Entity/SourceInterface.php | 12 +++----- application/src/Entity/User.php | 9 +----- application/src/Entity/UserInterface.php | 13 --------- .../src/Entity/attribut/IdAttribut.php | 27 +++++++++++++++++ .../Entity/attribut/IdAttributInterface.php | 15 ++++++++++ .../src/Entity/attribut/NodeAttribut.php | 28 ++++++++++++++++++ .../Entity/attribut/NodeAttributInterface.php | 17 +++++++++++ .../src/Entity/attribut/SourceAttribut.php | 25 ++++++++++++++++ .../attribut/SourceAttributInterface.php | 17 +++++++++++ 12 files changed, 143 insertions(+), 59 deletions(-) delete mode 100644 application/src/Entity/UserInterface.php create mode 100644 application/src/Entity/attribut/IdAttribut.php create mode 100644 application/src/Entity/attribut/IdAttributInterface.php create mode 100644 application/src/Entity/attribut/NodeAttribut.php create mode 100644 application/src/Entity/attribut/NodeAttributInterface.php create mode 100644 application/src/Entity/attribut/SourceAttribut.php create mode 100644 application/src/Entity/attribut/SourceAttributInterface.php diff --git a/application/src/Entity/AbstractSource.php b/application/src/Entity/AbstractSource.php index 67b6a42..c417aba 100644 --- a/application/src/Entity/AbstractSource.php +++ b/application/src/Entity/AbstractSource.php @@ -1,18 +1,17 @@ id = $id; + } + + public function getId(): int + { + return $this->id; + } +} + diff --git a/application/src/Entity/attribut/IdAttributInterface.php b/application/src/Entity/attribut/IdAttributInterface.php new file mode 100644 index 0000000..93beeb1 --- /dev/null +++ b/application/src/Entity/attribut/IdAttributInterface.php @@ -0,0 +1,15 @@ +node = $node; + } + + public function getNode(): NodeInterface + { + return $this->node; + } + +} + diff --git a/application/src/Entity/attribut/NodeAttributInterface.php b/application/src/Entity/attribut/NodeAttributInterface.php new file mode 100644 index 0000000..cfa1731 --- /dev/null +++ b/application/src/Entity/attribut/NodeAttributInterface.php @@ -0,0 +1,17 @@ +source; + } + + public function setSource(SourceInterface $source):void{ + $this->source = $source; + } +} + diff --git a/application/src/Entity/attribut/SourceAttributInterface.php b/application/src/Entity/attribut/SourceAttributInterface.php new file mode 100644 index 0000000..25a6eca --- /dev/null +++ b/application/src/Entity/attribut/SourceAttributInterface.php @@ -0,0 +1,17 @@ +