partLots = new ArrayCollection(); $this->orderdetails = new ArrayCollection(); } /** * Returns the ID as an string, defined by the element class. * This should have a form like P000014, for a part with ID 14. * * @return string The ID as a string; */ public function getIDString(): string { return 'P'.sprintf('%06d', $this->getID()); } /** * Get all devices which uses this part. * * @return Device[] * all devices which uses this part as a one-dimensional array of Device objects * (empty array if there are no ones) * * the array is sorted by the devices names */ public function getDevices(): array { return $this->devices; } }