From e654daf4a501deb25d9941c43054d1ba6106e729 Mon Sep 17 00:00:00 2001 From: Benjamin Dalsass Date: Wed, 5 Jul 2023 14:24:05 +0200 Subject: [PATCH] =?UTF-8?q?N=C2=B06516=20-=20Add=20@experimental=20PHP=20a?= =?UTF-8?q?nnotation=20on=20temporary=20objects=20features?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/attributedef.class.inc.php | 2 +- core/dbobject.class.php | 35 +++++++++++++++++-- .../src/Model/TemporaryObjectDescriptor.php | 5 +++ .../TemporaryObjectController.php | 2 ++ .../TemporaryObjectConfig.php | 9 +++++ .../TemporaryObjects/TemporaryObjectGC.php | 2 ++ .../TemporaryObjectHelper.php | 2 ++ .../TemporaryObjectManager.php | 2 ++ .../TemporaryObjectRepository.php | 2 ++ .../TemporaryObjectsEvents.php | 9 +++++ 10 files changed, 67 insertions(+), 3 deletions(-) diff --git a/core/attributedef.class.inc.php b/core/attributedef.class.inc.php index e51d9b6b3..d9980100b 100644 --- a/core/attributedef.class.inc.php +++ b/core/attributedef.class.inc.php @@ -10,7 +10,6 @@ use Combodo\iTop\Form\Field\LabelField; use Combodo\iTop\Form\Field\TextAreaField; use Combodo\iTop\Form\Form; use Combodo\iTop\Form\Validator\CustomRegexpValidator; -use Combodo\iTop\Form\Validator\LinkedSetValidator; use Combodo\iTop\Renderer\BlockRenderer; use Combodo\iTop\Renderer\Console\ConsoleBlockRenderer; use Combodo\iTop\Service\Links\LinkSetModel; @@ -7228,6 +7227,7 @@ class AttributeExternalKey extends AttributeDBFieldVoid return (int)$proposedValue; } + /** @inheritdoc @since 3.1 */ public function WriteExternalValues(DBObject $oHostObject): void { $sTargetKey = $oHostObject->Get($this->GetCode()); diff --git a/core/dbobject.class.php b/core/dbobject.class.php index 8e1ec6b89..d94759f4c 100644 --- a/core/dbobject.class.php +++ b/core/dbobject.class.php @@ -6399,10 +6399,19 @@ abstract class DBObject implements iDisplay } /** - * @param $aContext + * Handle temporary descriptors. * * @return void - * @since 3.1.0 + * + * @throws \ArchivedObjectException + * @throws \CoreException + * @throws \CoreUnexpectedValue + * @throws \MySQLException + * @throws \OQLException + * + * @experimental do not use, this feature will be part of a future version + * + * @since 3.1 */ private function HandleTemporaryDescriptor() { @@ -6412,7 +6421,13 @@ abstract class DBObject implements iDisplay } /** + * Return context information. + * * @return array + * + * @experimental do not use, this feature will be part of a future version + * + * @since 3.1 */ public function GetContext(): array { @@ -6425,6 +6440,10 @@ abstract class DBObject implements iDisplay * @param string $sSection * @param $value * + * @experimental do not use, this feature will be part of a future version + * + * @since 3.1 + * */ public function SetContextSection(string $sSection, $value) { @@ -6432,9 +6451,15 @@ abstract class DBObject implements iDisplay } /** + * Get context section data. + * * @param string $sSection * * @return mixed + * + * experimental do not use, this feature will be part of a future version + * + * @since 3.1 */ public function GetContextSection(string $sSection) { @@ -6446,9 +6471,15 @@ abstract class DBObject implements iDisplay } /** + * Test context section existence. + * * @param string $sSection * * @return bool + * + * experimental do not use, this feature will be part of a future version + * + * @since 3.1 */ public function HasContextSection(string $sSection): bool { diff --git a/datamodels/2.x/itop-structure/src/Model/TemporaryObjectDescriptor.php b/datamodels/2.x/itop-structure/src/Model/TemporaryObjectDescriptor.php index f9b2b1920..89edf4735 100644 --- a/datamodels/2.x/itop-structure/src/Model/TemporaryObjectDescriptor.php +++ b/datamodels/2.x/itop-structure/src/Model/TemporaryObjectDescriptor.php @@ -5,6 +5,11 @@ */ /** + * Class TemporaryObjectDescriptor + * + * Descriptor to track a temporary object. + * + * @experimental do not use, this feature will be part of a future version * * @since 3.1 */ diff --git a/sources/Controller/TemporaryObjects/TemporaryObjectController.php b/sources/Controller/TemporaryObjects/TemporaryObjectController.php index a7cf862d1..7cbfdc55c 100644 --- a/sources/Controller/TemporaryObjects/TemporaryObjectController.php +++ b/sources/Controller/TemporaryObjects/TemporaryObjectController.php @@ -16,6 +16,8 @@ use utils; * * Temporary object endpoints. * + * @experimental do not use, this feature will be part of a future version + * * @since 3.1 */ class TemporaryObjectController extends AbstractController diff --git a/sources/Service/TemporaryObjects/TemporaryObjectConfig.php b/sources/Service/TemporaryObjects/TemporaryObjectConfig.php index 967157eb9..c5b0d81da 100644 --- a/sources/Service/TemporaryObjects/TemporaryObjectConfig.php +++ b/sources/Service/TemporaryObjects/TemporaryObjectConfig.php @@ -8,6 +8,15 @@ namespace Combodo\iTop\Service\TemporaryObjects; use MetaModel; +/** + * TemporaryObjectConfig. + * + * Handle temporary object configuration. + * + * @experimental do not use, this feature will be part of a future version + * + * @since 3.1 + */ class TemporaryObjectConfig { diff --git a/sources/Service/TemporaryObjects/TemporaryObjectGC.php b/sources/Service/TemporaryObjects/TemporaryObjectGC.php index 67b02e8b1..0c59b51ae 100644 --- a/sources/Service/TemporaryObjects/TemporaryObjectGC.php +++ b/sources/Service/TemporaryObjects/TemporaryObjectGC.php @@ -13,6 +13,8 @@ use iBackgroundProcess; * * Background task to collect and garbage expired temporary objects.. * + * @experimental do not use, this feature will be part of a future version + * * @since 3.1 */ class TemporaryObjectGC implements iBackgroundProcess diff --git a/sources/Service/TemporaryObjects/TemporaryObjectHelper.php b/sources/Service/TemporaryObjects/TemporaryObjectHelper.php index fe1f8f44f..0759981b6 100644 --- a/sources/Service/TemporaryObjects/TemporaryObjectHelper.php +++ b/sources/Service/TemporaryObjects/TemporaryObjectHelper.php @@ -11,6 +11,8 @@ namespace Combodo\iTop\Service\TemporaryObjects; * * Helper with useful functions. * + * @experimental do not use, this feature will be part of a future version + * * @since 3.1 */ class TemporaryObjectHelper diff --git a/sources/Service/TemporaryObjects/TemporaryObjectManager.php b/sources/Service/TemporaryObjects/TemporaryObjectManager.php index 9f1a54415..74228df1d 100644 --- a/sources/Service/TemporaryObjects/TemporaryObjectManager.php +++ b/sources/Service/TemporaryObjects/TemporaryObjectManager.php @@ -21,6 +21,8 @@ use utils; * * Manager class to perform global temporary objects tasks. * + * @experimental do not use, this feature will be part of a future version + * * @since 3.1 */ class TemporaryObjectManager diff --git a/sources/Service/TemporaryObjects/TemporaryObjectRepository.php b/sources/Service/TemporaryObjects/TemporaryObjectRepository.php index 1f3a76b99..26215d9ee 100644 --- a/sources/Service/TemporaryObjects/TemporaryObjectRepository.php +++ b/sources/Service/TemporaryObjects/TemporaryObjectRepository.php @@ -19,6 +19,8 @@ use TemporaryObjectDescriptor; * * Repository class to perform ORM tasks. * + * @experimental do not use, this feature will be part of a future version + * * @since 3.1 */ class TemporaryObjectRepository diff --git a/sources/Service/TemporaryObjects/TemporaryObjectsEvents.php b/sources/Service/TemporaryObjects/TemporaryObjectsEvents.php index 1d0408e59..5bcc743e2 100644 --- a/sources/Service/TemporaryObjects/TemporaryObjectsEvents.php +++ b/sources/Service/TemporaryObjects/TemporaryObjectsEvents.php @@ -11,6 +11,15 @@ use Combodo\iTop\Service\Events\Description\EventDescription; use Combodo\iTop\Service\Events\EventService; use Combodo\iTop\Service\Events\iEventServiceSetup; +/** + * TemporaryObjectsEvents. + * + * Handle temporary objects events + * + * @experimental do not use, this feature will be part of a future version + * + * @since 3.1 + */ class TemporaryObjectsEvents implements iEventServiceSetup {