update 2023-10-10 10:16:07

This commit is contained in:
Robot 2023-10-10 11:39:09 +02:00
parent 11a4167cf9
commit 58b5a8621a
Signed by untrusted user: Robot
GPG Key ID: 14DECD44E7E1BB95
58 changed files with 307 additions and 1624 deletions

View File

@ -28,12 +28,12 @@ This repository contains an index (see below) of all the approved powers within
- **trait Utilities** | [Details](src/79d765b3-7319-4988-9730-446c7f347020) | [Code](src/79d765b3-7319-4988-9730-446c7f347020/code.php) | [Settings](src/79d765b3-7319-4988-9730-446c7f347020/settings.json) | Super__79d765b3_7319_4988_9730_446c7f347020__Power
- **Namespace**: [VDM\Joomla\Abstraction](#vdm-joomla-abstraction)
- **abstract class ActiveStorageRegistry** | [Details](src/43134867-5cb8-4280-9be8-309fd2fd135f) | [Code](src/43134867-5cb8-4280-9be8-309fd2fd135f/code.php) | [Settings](src/43134867-5cb8-4280-9be8-309fd2fd135f/settings.json) | Super__43134867_5cb8_4280_9be8_309fd2fd135f__Power
- **abstract class ActiveRegistry** | [Details](src/43134867-5cb8-4280-9be8-309fd2fd135f) | [Code](src/43134867-5cb8-4280-9be8-309fd2fd135f/code.php) | [Settings](src/43134867-5cb8-4280-9be8-309fd2fd135f/settings.json) | Super__43134867_5cb8_4280_9be8_309fd2fd135f__Power
- **abstract class BaseConfig** | [Details](src/ffbd4e1f-a342-4080-ab7d-1de3741bf319) | [Code](src/ffbd4e1f-a342-4080-ab7d-1de3741bf319/code.php) | [Settings](src/ffbd4e1f-a342-4080-ab7d-1de3741bf319/settings.json) | Super__ffbd4e1f_a342_4080_ab7d_1de3741bf319__Power
- **abstract class BaseTable** | [Details](src/e0f6ddbe-2a35-4537-942c-faff2ebd04f6) | [Code](src/e0f6ddbe-2a35-4537-942c-faff2ebd04f6/code.php) | [Settings](src/e0f6ddbe-2a35-4537-942c-faff2ebd04f6/settings.json) | Super__e0f6ddbe_2a35_4537_942c_faff2ebd04f6__Power
- **abstract class Database** | [Details](src/6cbef8f8-4813-48e3-b05a-65e1aea95171) | [Code](src/6cbef8f8-4813-48e3-b05a-65e1aea95171/code.php) | [Settings](src/6cbef8f8-4813-48e3-b05a-65e1aea95171/settings.json) | Super__6cbef8f8_4813_48e3_b05a_65e1aea95171__Power
- **abstract class Model** | [Details](src/584747d1-3a86-453d-b7a3-a2219de8d777) | [Code](src/584747d1-3a86-453d-b7a3-a2219de8d777/code.php) | [Settings](src/584747d1-3a86-453d-b7a3-a2219de8d777/settings.json) | Super__584747d1_3a86_453d_b7a3_a2219de8d777__Power
- **abstract class StorageRegistry** | [Details](src/7e822c03-1b20-41d1-9427-f5b8d5836af7) | [Code](src/7e822c03-1b20-41d1-9427-f5b8d5836af7/code.php) | [Settings](src/7e822c03-1b20-41d1-9427-f5b8d5836af7/settings.json) | Super__7e822c03_1b20_41d1_9427_f5b8d5836af7__Power
- **abstract class Registry** | [Details](src/7e822c03-1b20-41d1-9427-f5b8d5836af7) | [Code](src/7e822c03-1b20-41d1-9427-f5b8d5836af7/code.php) | [Settings](src/7e822c03-1b20-41d1-9427-f5b8d5836af7/settings.json) | Super__7e822c03_1b20_41d1_9427_f5b8d5836af7__Power
- **Namespace**: [VDM\Joomla\Componentbuilder](#vdm-joomla-componentbuilder)
- **class Table** | [Details](src/bfd1d6d5-56c1-4fe9-9fee-1c5910e1f5d8) | [Code](src/bfd1d6d5-56c1-4fe9-9fee-1c5910e1f5d8/code.php) | [Settings](src/bfd1d6d5-56c1-4fe9-9fee-1c5910e1f5d8/settings.json) | Super__bfd1d6d5_56c1_4fe9_9fee_1c5910e1f5d8__Power
@ -44,12 +44,12 @@ This repository contains an index (see below) of all the approved powers within
- **final class Update** | [Details](src/cce56585-58b0-4f72-a92c-e2635ea52d83) | [Code](src/cce56585-58b0-4f72-a92c-e2635ea52d83/code.php) | [Settings](src/cce56585-58b0-4f72-a92c-e2635ea52d83/settings.json) | Super__cce56585_58b0_4f72_a92c_e2635ea52d83__Power
- **Namespace**: [VDM\Joomla\Interfaces](#vdm-joomla-interfaces)
- **interface Activestorageregistryinterface** | [Details](src/af0eedbe-603b-4671-8e5a-28165d88254b) | [Code](src/af0eedbe-603b-4671-8e5a-28165d88254b/code.php) | [Settings](src/af0eedbe-603b-4671-8e5a-28165d88254b/settings.json) | Super__af0eedbe_603b_4671_8e5a_28165d88254b__Power
- **interface Activeregistryinterface** | [Details](src/af0eedbe-603b-4671-8e5a-28165d88254b) | [Code](src/af0eedbe-603b-4671-8e5a-28165d88254b/code.php) | [Settings](src/af0eedbe-603b-4671-8e5a-28165d88254b/settings.json) | Super__af0eedbe_603b_4671_8e5a_28165d88254b__Power
- **interface FactoryInterface** | [Details](src/caf33c5d-858c-4f9a-894f-ab302ec5445a) | [Code](src/caf33c5d-858c-4f9a-894f-ab302ec5445a/code.php) | [Settings](src/caf33c5d-858c-4f9a-894f-ab302ec5445a/settings.json) | Super__caf33c5d_858c_4f9a_894f_ab302ec5445a__Power
- **interface InsertInterface** | [Details](src/ad12ca1c-d3ce-4e7f-88c5-c6c92bdedc48) | [Code](src/ad12ca1c-d3ce-4e7f-88c5-c6c92bdedc48/code.php) | [Settings](src/ad12ca1c-d3ce-4e7f-88c5-c6c92bdedc48/settings.json) | Super__ad12ca1c_d3ce_4e7f_88c5_c6c92bdedc48__Power
- **interface LoadInterface** | [Details](src/2ad31f74-f579-499d-b98b-c4f54fd615dd) | [Code](src/2ad31f74-f579-499d-b98b-c4f54fd615dd/code.php) | [Settings](src/2ad31f74-f579-499d-b98b-c4f54fd615dd/settings.json) | Super__2ad31f74_f579_499d_b98b_c4f54fd615dd__Power
- **interface ModelInterface** | [Details](src/8aef58c1-3f70-4bd4-b9e4-3f29fcd41cff) | [Code](src/8aef58c1-3f70-4bd4-b9e4-3f29fcd41cff/code.php) | [Settings](src/8aef58c1-3f70-4bd4-b9e4-3f29fcd41cff/settings.json) | Super__8aef58c1_3f70_4bd4_b9e4_3f29fcd41cff__Power
- **interface Storageregistryinterface** | [Details](src/64e291c2-11f1-423d-a44d-837cc12cc017) | [Code](src/64e291c2-11f1-423d-a44d-837cc12cc017/code.php) | [Settings](src/64e291c2-11f1-423d-a44d-837cc12cc017/settings.json) | Super__64e291c2_11f1_423d_a44d_837cc12cc017__Power
- **interface Registryinterface** | [Details](src/64e291c2-11f1-423d-a44d-837cc12cc017) | [Code](src/64e291c2-11f1-423d-a44d-837cc12cc017/code.php) | [Settings](src/64e291c2-11f1-423d-a44d-837cc12cc017/settings.json) | Super__64e291c2_11f1_423d_a44d_837cc12cc017__Power
- **interface Tableinterface** | [Details](src/2da6d6c4-eb29-4d69-8bc2-36d96e916adf) | [Code](src/2da6d6c4-eb29-4d69-8bc2-36d96e916adf/code.php) | [Settings](src/2da6d6c4-eb29-4d69-8bc2-36d96e916adf/settings.json) | Super__2da6d6c4_eb29_4d69_8bc2_36d96e916adf__Power
- **interface UpdateInterface** | [Details](src/7179fde6-1e51-4b51-8545-7ca18f74a0f4) | [Code](src/7179fde6-1e51-4b51-8545-7ca18f74a0f4/code.php) | [Settings](src/7179fde6-1e51-4b51-8545-7ca18f74a0f4/settings.json) | Super__7179fde6_1e51_4b51_8545_7ca18f74a0f4__Power
- **Namespace**: [VDM\Joomla\Utilities](#vdm-joomla-utilities)
@ -57,6 +57,7 @@ This repository contains an index (see below) of all the approved powers within
- **abstract class ArrayHelper** | [Details](src/0a59c65c-9daf-4bc9-baf4-e063ff9e6a8a) | [Code](src/0a59c65c-9daf-4bc9-baf4-e063ff9e6a8a/code.php) | [Settings](src/0a59c65c-9daf-4bc9-baf4-e063ff9e6a8a/settings.json) | Super__0a59c65c_9daf_4bc9_baf4_e063ff9e6a8a__Power
- **abstract class Base64Helper** | [Details](src/64a6ff6c-069c-4a11-a76b-db5e36c27690) | [Code](src/64a6ff6c-069c-4a11-a76b-db5e36c27690/code.php) | [Settings](src/64a6ff6c-069c-4a11-a76b-db5e36c27690/settings.json) | Super__64a6ff6c_069c_4a11_a76b_db5e36c27690__Power
- **abstract class FileHelper** | [Details](src/a223b31e-ea1d-4cdf-92ae-5f9becffaff0) | [Code](src/a223b31e-ea1d-4cdf-92ae-5f9becffaff0/code.php) | [Settings](src/a223b31e-ea1d-4cdf-92ae-5f9becffaff0/settings.json) | Super__a223b31e_ea1d_4cdf_92ae_5f9becffaff0__Power
- **abstract class FormHelper** | [Details](src/1198aecf-84c6-45d2-aea8-d531aa4afdfa) | [Code](src/1198aecf-84c6-45d2-aea8-d531aa4afdfa/code.php) | [Settings](src/1198aecf-84c6-45d2-aea8-d531aa4afdfa/settings.json) | Super__1198aecf_84c6_45d2_aea8_d531aa4afdfa__Power
- **abstract class GetHelper** | [Details](src/db87c339-5bb6-4291-a7ef-2c48ea1b06bc) | [Code](src/db87c339-5bb6-4291-a7ef-2c48ea1b06bc/code.php) | [Settings](src/db87c339-5bb6-4291-a7ef-2c48ea1b06bc/settings.json) | Super__db87c339_5bb6_4291_a7ef_2c48ea1b06bc__Power
- **abstract class GuidHelper** | [Details](src/9c513baf-b279-43fd-ae29-a585c8cbc4f0) | [Code](src/9c513baf-b279-43fd-ae29-a585c8cbc4f0/code.php) | [Settings](src/9c513baf-b279-43fd-ae29-a585c8cbc4f0/settings.json) | Super__9c513baf_b279_43fd_ae29_a585c8cbc4f0__Power
- **abstract class JsonHelper** | [Details](src/4b225c51-d293-48e4-b3f6-5136cf5c3f18) | [Code](src/4b225c51-d293-48e4-b3f6-5136cf5c3f18/code.php) | [Settings](src/4b225c51-d293-48e4-b3f6-5136cf5c3f18/settings.json) | Super__4b225c51_d293_48e4_b3f6_5136cf5c3f18__Power
@ -66,19 +67,12 @@ This repository contains an index (see below) of all the approved powers within
- **Namespace**: [VDM\Joomla\Componentbuilder\Abstraction](#vdm-joomla-componentbuilder-abstraction)
- **abstract class BaseRegistry** | [Details](src/b84e947d-2a13-44f7-ac0f-3902ae55ae0c) | [Code](src/b84e947d-2a13-44f7-ac0f-3902ae55ae0c/code.php) | [Settings](src/b84e947d-2a13-44f7-ac0f-3902ae55ae0c/settings.json) | Super__b84e947d_2a13_44f7_ac0f_3902ae55ae0c__Power
- **abstract class Mapper** | [Details](src/44a3367c-f9e4-406b-b396-0f452bde0f03) | [Code](src/44a3367c-f9e4-406b-b396-0f452bde0f03/code.php) | [Settings](src/44a3367c-f9e4-406b-b396-0f452bde0f03/settings.json) | Super__44a3367c_f9e4_406b_b396_0f452bde0f03__Power
- **abstract class MapperDouble** | [Details](src/4d4e76e9-12d9-4d19-b58c-b88974b2586a) | [Code](src/4d4e76e9-12d9-4d19-b58c-b88974b2586a/code.php) | [Settings](src/4d4e76e9-12d9-4d19-b58c-b88974b2586a/settings.json) | Super__4d4e76e9_12d9_4d19_b58c_b88974b2586a__Power
- **abstract class MapperSingle** | [Details](src/c6bbc3ee-58e7-4463-adba-5c5ae839ee36) | [Code](src/c6bbc3ee-58e7-4463-adba-5c5ae839ee36/code.php) | [Settings](src/c6bbc3ee-58e7-4463-adba-5c5ae839ee36/settings.json) | Super__c6bbc3ee_58e7_4463_adba_5c5ae839ee36__Power
- **Namespace**: [VDM\Joomla\Componentbuilder\Interfaces](#vdm-joomla-componentbuilder-interfaces)
- **interface Mapperdoublejoininterface** | [Details](src/7921a2b3-b58c-4184-af3f-f58094f695a8) | [Code](src/7921a2b3-b58c-4184-af3f-f58094f695a8/code.php) | [Settings](src/7921a2b3-b58c-4184-af3f-f58094f695a8/settings.json) | Super__7921a2b3_b58c_4184_af3f_f58094f695a8__Power
- **Namespace**: [VDM\Joomla\Componentbuilder\Service](#vdm-joomla-componentbuilder-service)
- **class Database** | [Details](src/4815e1c7-a433-443d-a112-d1e03d7df84b) | [Code](src/4815e1c7-a433-443d-a112-d1e03d7df84b/code.php) | [Settings](src/4815e1c7-a433-443d-a112-d1e03d7df84b/settings.json) | Super__4815e1c7_a433_443d_a112_d1e03d7df84b__Power
- **Namespace**: [VDM\Joomla\Componentbuilder\Utilities](#vdm-joomla-componentbuilder-utilities)
- **abstract class FilterHelper** | [Details](src/cddcac51-9a46-47c4-ba59-105c70453bd6) | [Code](src/cddcac51-9a46-47c4-ba59-105c70453bd6/code.php) | [Settings](src/cddcac51-9a46-47c4-ba59-105c70453bd6/settings.json) | Super__cddcac51_9a46_47c4_ba59_105c70453bd6__Power
- **abstract class FormHelper** | [Details](src/1198aecf-84c6-45d2-aea8-d531aa4afdfa) | [Code](src/1198aecf-84c6-45d2-aea8-d531aa4afdfa/code.php) | [Settings](src/1198aecf-84c6-45d2-aea8-d531aa4afdfa/settings.json) | Super__1198aecf_84c6_45d2_aea8_d531aa4afdfa__Power
- **Namespace**: [VDM\Joomla\Utilities\Component](#vdm-joomla-utilities-component)
- **abstract class Helper** | [Details](src/640b5352-fb09-425f-a26e-cd44eda03f15) | [Code](src/640b5352-fb09-425f-a26e-cd44eda03f15/code.php) | [Settings](src/640b5352-fb09-425f-a26e-cd44eda03f15/settings.json) | Super__640b5352_fb09_425f_a26e_cd44eda03f15__Power
@ -89,11 +83,12 @@ This repository contains an index (see below) of all the approved powers within
- **abstract class NamespaceHelper** | [Details](src/ce8cf834-6bac-44fb-941c-861f7e046cc0) | [Code](src/ce8cf834-6bac-44fb-941c-861f7e046cc0/code.php) | [Settings](src/ce8cf834-6bac-44fb-941c-861f7e046cc0/settings.json) | Super__ce8cf834_6bac_44fb_941c_861f7e046cc0__Power
- **abstract class PluginHelper** | [Details](src/3cf76fbf-fd95-4a33-878e-7aff6d36b7f6) | [Code](src/3cf76fbf-fd95-4a33-878e-7aff6d36b7f6/code.php) | [Settings](src/3cf76fbf-fd95-4a33-878e-7aff6d36b7f6/settings.json) | Super__3cf76fbf_fd95_4a33_878e_7aff6d36b7f6__Power
- **abstract class TypeHelper** | [Details](src/a8935cbe-7701-40dc-bfd5-675f2d600954) | [Code](src/a8935cbe-7701-40dc-bfd5-675f2d600954/code.php) | [Settings](src/a8935cbe-7701-40dc-bfd5-675f2d600954/settings.json) | Super__a8935cbe_7701_40dc_bfd5_675f2d600954__Power
- **Namespace**: [VDM\Joomla\Abstraction\StorageRegistry\Traits](#vdm-joomla-abstraction-storageregistry-traits)
- **Namespace**: [VDM\Joomla\Abstraction\Registry\Traits](#vdm-joomla-abstraction-registry-traits)
- **trait Count** | [Details](src/11572d9b-e3d5-4b29-904c-9618d8f2bfd8) | [Code](src/11572d9b-e3d5-4b29-904c-9618d8f2bfd8/code.php) | [Settings](src/11572d9b-e3d5-4b29-904c-9618d8f2bfd8/settings.json) | Super__11572d9b_e3d5_4b29_904c_9618d8f2bfd8__Power
- **trait GetString** | [Details](src/59b1a2ea-d77e-4040-ac8c-e65cd8743e9b) | [Code](src/59b1a2ea-d77e-4040-ac8c-e65cd8743e9b/code.php) | [Settings](src/59b1a2ea-d77e-4040-ac8c-e65cd8743e9b/settings.json) | Super__59b1a2ea_d77e_4040_ac8c_e65cd8743e9b__Power
- **trait InArray** | [Details](src/215b35ac-1b26-4838-bbcf-d1fdbbd9353f) | [Code](src/215b35ac-1b26-4838-bbcf-d1fdbbd9353f/code.php) | [Settings](src/215b35ac-1b26-4838-bbcf-d1fdbbd9353f/settings.json) | Super__215b35ac_1b26_4838_bbcf_d1fdbbd9353f__Power
- **trait IsArray** | [Details](src/c09e8968-c767-4175-bb3d-8432f206a2c7) | [Code](src/c09e8968-c767-4175-bb3d-8432f206a2c7/code.php) | [Settings](src/c09e8968-c767-4175-bb3d-8432f206a2c7/settings.json) | Super__c09e8968_c767_4175_bb3d_8432f206a2c7__Power
- **trait IsString** | [Details](src/ff7d0111-8f79-42aa-ac14-b53ba2c49369) | [Code](src/ff7d0111-8f79-42aa-ac14-b53ba2c49369/code.php) | [Settings](src/ff7d0111-8f79-42aa-ac14-b53ba2c49369/settings.json) | Super__ff7d0111_8f79_42aa_ac14_b53ba2c49369__Power
- **trait ToString** | [Details](src/7d494d91-ab60-43cd-aecf-d50e07f7f30e) | [Code](src/7d494d91-ab60-43cd-aecf-d50e07f7f30e/code.php) | [Settings](src/7d494d91-ab60-43cd-aecf-d50e07f7f30e/settings.json) | Super__7d494d91_ab60_43cd_aecf_d50e07f7f30e__Power
- **trait VarExport** | [Details](src/52a1d14f-304a-431c-8fa4-411179942db5) | [Code](src/52a1d14f-304a-431c-8fa4-411179942db5/code.php) | [Settings](src/52a1d14f-304a-431c-8fa4-411179942db5/settings.json) | Super__52a1d14f_304a_431c_8fa4_411179942db5__Power

View File

@ -7,7 +7,7 @@
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# trait Count (Details)
> namespace: **VDM\Joomla\Abstraction\StorageRegistry\Traits**
> namespace: **VDM\Joomla\Abstraction\Registry\Traits**
```uml
@startuml
class Count << (T,Orange) >> #Turquoise {

View File

@ -9,7 +9,7 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Abstraction\StorageRegistry\Traits;
namespace VDM\Joomla\Abstraction\Registry\Traits;
/**

View File

@ -7,10 +7,10 @@
"load_selection": null,
"name": "Count",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.StorageRegistry.Traits.Count",
"system_name": "VDM.Abstraction.Registry.Traits.Count",
"type": "trait",
"use_selection": null,
"namespace": "VDM\\Joomla\\Abstraction.StorageRegistry.Traits.Count",
"namespace": "VDM\\Joomla\\Abstraction.Registry.Traits.Count",
"description": "Count Values\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",

View File

@ -7,7 +7,7 @@
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# abstract class FormHelper (Details)
> namespace: **VDM\Joomla\Componentbuilder\Utilities**
> namespace: **VDM\Joomla\Utilities**
```uml
@startuml
abstract FormHelper #Orange {

View File

@ -9,12 +9,11 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Componentbuilder\Utilities;
namespace VDM\Joomla\Utilities;
use Joomla\CMS\Form\FormHelper as JoomlaFormHelper;
use Joomla\CMS\Form\FormField;
use VDM\Joomla\Utilities\ArrayHelper;
/**
@ -184,6 +183,5 @@ abstract class FormHelper
return null;
}
}

View File

@ -4,18 +4,17 @@
"extends": "0",
"guid": "1198aecf-84c6-45d2-aea8-d531aa4afdfa",
"implements": null,
"load_selection": null,
"name": "FormHelper",
"power_version": "1.0.0",
"system_name": "JCB.Utilities.FormHelper",
"type": "abstract class",
"use_selection": {
"use_selection0": {
"use": "0a59c65c-9daf-4bc9-baf4-e063ff9e6a8a",
"as": "default"
"load_selection": {
"load_selection0": {
"load": "0a59c65c-9daf-4bc9-baf4-e063ff9e6a8a"
}
},
"namespace": "VDM\\Joomla\\Componentbuilder.Utilities.FormHelper",
"name": "FormHelper",
"power_version": "1.0.0",
"system_name": "Utilities FormHelper",
"type": "abstract class",
"use_selection": null,
"namespace": "VDM\\Joomla\\Utilities.FormHelper",
"description": "Form Helper\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "use Joomla\\CMS\\Form\\FormHelper as JoomlaFormHelper;\r\nuse Joomla\\CMS\\Form\\FormField;",

View File

@ -7,7 +7,7 @@
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# trait InArray (Details)
> namespace: **VDM\Joomla\Abstraction\StorageRegistry\Traits**
> namespace: **VDM\Joomla\Abstraction\Registry\Traits**
```uml
@startuml
class InArray << (T,Orange) >> #Turquoise {

View File

@ -9,7 +9,7 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Abstraction\StorageRegistry\Traits;
namespace VDM\Joomla\Abstraction\Registry\Traits;
/**

View File

@ -7,10 +7,10 @@
"load_selection": null,
"name": "InArray",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.StorageRegistry.Traits.InArray",
"system_name": "VDM.Abstraction.Registry.Traits.InArray",
"type": "trait",
"use_selection": null,
"namespace": "VDM\\Joomla\\Abstraction.StorageRegistry.Traits.InArray",
"namespace": "VDM\\Joomla\\Abstraction.Registry.Traits.InArray",
"description": "Check if a value is in an array\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",

View File

@ -6,11 +6,11 @@
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# abstract class ActiveStorageRegistry (Details)
# abstract class ActiveRegistry (Details)
> namespace: **VDM\Joomla\Abstraction**
```uml
@startuml
abstract ActiveStorageRegistry #Orange {
abstract ActiveRegistry #Orange {
# array $active
+ isActive() : bool
+ allActive() : array
@ -22,29 +22,29 @@ abstract ActiveStorageRegistry #Orange {
# validActiveKeys(array $keys) : bool
}
note right of ActiveStorageRegistry::isActive
Check if the main storage has any content.
note right of ActiveRegistry::isActive
Check if the registry has any content.
since: 3.2.0
return: bool
end note
note left of ActiveStorageRegistry::allActive
Get all value from the active storage.
note left of ActiveRegistry::allActive
Get all value from the active registry.
since: 3.2.0
return: array
end note
note right of ActiveStorageRegistry::setActive
Sets a value into the storage using multiple keys.
note right of ActiveRegistry::setActive
Sets a value into the registry using multiple keys.
since: 3.2.0
return: void
end note
note left of ActiveStorageRegistry::addActive
Adds content into the storage. If a key exists,
note left of ActiveRegistry::addActive
Adds content into the registry. If a key exists,
it either appends or concatenates based on the value's type.
since: 3.2.0
@ -56,28 +56,28 @@ it either appends or concatenates based on the value's type.
$keys
end note
note right of ActiveStorageRegistry::getActive
Retrieves a value (or sub-array) from the storage using multiple keys.
note right of ActiveRegistry::getActive
Retrieves a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: mixed
end note
note left of ActiveStorageRegistry::removeActive
Removes a value (or sub-array) from the storage using multiple keys.
note left of ActiveRegistry::removeActive
Removes a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: void
end note
note right of ActiveStorageRegistry::existsActive
Checks the existence of a particular location in the storage using multiple keys.
note right of ActiveRegistry::existsActive
Checks the existence of a particular location in the registry using multiple keys.
since: 3.2.0
return: bool
end note
note left of ActiveStorageRegistry::validActiveKeys
note left of ActiveRegistry::validActiveKeys
Checks that the keys are valid
since: 3.2.0

View File

@ -12,7 +12,7 @@
namespace VDM\Joomla\Abstraction;
use VDM\Joomla\Interfaces\Activestorageregistryinterface;
use VDM\Joomla\Interfaces\Activeregistryinterface;
/**
@ -22,10 +22,10 @@ use VDM\Joomla\Interfaces\Activestorageregistryinterface;
*
* @since 3.2.0
*/
abstract class ActiveStorageRegistry implements Activestorageregistryinterface
abstract class ActiveRegistry implements Activeregistryinterface
{
/**
* The main storage array.
* The registry array.
*
* @var array
* @since 3.2.0
@ -33,7 +33,7 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
protected array $active = [];
/**
* Check if the main storage has any content.
* Check if the registry has any content.
*
* @return bool Returns true if the active array is not empty, false otherwise.
* @since 3.2.0
@ -44,7 +44,7 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
}
/**
* Get all value from the active storage.
* Get all value from the active registry.
*
* @return array The values or empty array.
* @since 3.2.0
@ -55,7 +55,7 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
}
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param mixed $value The value to set.
* @param string ...$keys The keys to determine the location.
@ -77,6 +77,12 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
{
if (!isset($array[$key]))
{
if (!is_array($array))
{
$path = '[' . implode('][', $keys) . ']';
throw new \InvalidArgumentException("Attempted to use key '{$key}' on a non-array value: {$array}. Path: {$path} Value: {$value}");
}
$array[$key] = [];
}
$array = &$array[$key];
@ -86,7 +92,7 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
}
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on the value's type.
*
* @param mixed $value The value to set.
@ -110,6 +116,12 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
{
if (!isset($array[$key]))
{
if (!is_array($array))
{
$path = '[' . implode('][', $keys) . ']';
throw new \InvalidArgumentException("Attempted to use key '{$key}' on a non-array value: {$array}. Path: {$path} Value: {$value}");
}
$array[$key] = [];
}
$array = &$array[$key];
@ -145,7 +157,7 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
}
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param mixed $default The default value if not set.
* @param string ...$keys The keys to determine the location.
@ -176,7 +188,7 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
}
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*
@ -207,7 +219,7 @@ abstract class ActiveStorageRegistry implements Activestorageregistryinterface
}
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*

View File

@ -1,5 +1,5 @@
/**
* The main storage array.
* The registry array.
*
* @var array
* @since 3.2.0
@ -7,7 +7,7 @@
protected array $active = [];
/**
* Check if the main storage has any content.
* Check if the registry has any content.
*
* @return bool Returns true if the active array is not empty, false otherwise.
* @since 3.2.0
@ -18,7 +18,7 @@
}
/**
* Get all value from the active storage.
* Get all value from the active registry.
*
* @return array The values or empty array.
* @since 3.2.0
@ -29,7 +29,7 @@
}
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param mixed $value The value to set.
* @param string ...$keys The keys to determine the location.
@ -51,6 +51,12 @@
{
if (!isset($array[$key]))
{
if (!is_array($array))
{
$path = '[' . implode('][', $keys) . ']';
throw new \InvalidArgumentException("Attempted to use key '{$key}' on a non-array value: {$array}. Path: {$path} Value: {$value}");
}
$array[$key] = [];
}
$array = &$array[$key];
@ -60,7 +66,7 @@
}
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on the value's type.
*
* @param mixed $value The value to set.
@ -84,6 +90,12 @@
{
if (!isset($array[$key]))
{
if (!is_array($array))
{
$path = '[' . implode('][', $keys) . ']';
throw new \InvalidArgumentException("Attempted to use key '{$key}' on a non-array value: {$array}. Path: {$path} Value: {$value}");
}
$array[$key] = [];
}
$array = &$array[$key];
@ -119,7 +131,7 @@
}
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param mixed $default The default value if not set.
* @param string ...$keys The keys to determine the location.
@ -150,7 +162,7 @@
}
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*
@ -181,7 +193,7 @@
}
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*

View File

@ -7,12 +7,12 @@
"af0eedbe-603b-4671-8e5a-28165d88254b"
],
"load_selection": null,
"name": "ActiveStorageRegistry",
"name": "ActiveRegistry",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.ActiveStorageRegistry",
"system_name": "VDM.Abstraction.ActiveRegistry",
"type": "abstract class",
"use_selection": null,
"namespace": "VDM\\Joomla\\Abstraction.ActiveStorageRegistry",
"namespace": "VDM\\Joomla\\Abstraction.ActiveRegistry",
"description": "Active Storage Registry.\r\n\r\nDon't use this beyond 10 dimensional depth for best performance.\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",

View File

@ -1,166 +0,0 @@
```
██████╗ ██████╗ ██╗ ██╗███████╗██████╗
██╔══██╗██╔═══██╗██║ ██║██╔════╝██╔══██╗
██████╔╝██║ ██║██║ █╗ ██║█████╗ ██████╔╝
██╔═══╝ ██║ ██║██║███╗██║██╔══╝ ██╔══██╗
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# abstract class Mapper (Details)
> namespace: **VDM\Joomla\Componentbuilder\Abstraction**
```uml
@startuml
abstract Mapper #Orange {
+ array $active
+ isActive() : bool
+ set(string $key, mixed $value) : void
+ get(string $key) : mixed
+ exist(string $key) : bool
+ add(string $key, mixed $value, ...) : void
+ remove(string $key) : void
# {abstract} key(string $key) : string
+ isActive_(string $firstKey = null) : bool
+ set_(string $firstKey, string $secondKey, ...) : void
+ get_(string $firstKey, ?string $secondKey = null) : mixed
+ exist_(string $firstKey, ?string $secondKey = null) : bool
+ add_(string $firstKey, string $secondKey, ...) : void
+ remove_(string $firstKey, ?string $secondKey = null) : void
# {abstract} firstKey(string $key) : string
# {abstract} secondKey(string $key) : string
}
note right of Mapper::isActive
Check if any values are set in the active array
since: 3.2.0
return: bool
end note
note left of Mapper::set
Set content
since: 3.2.0
return: void
end note
note right of Mapper::get
Get content
since: 3.2.0
return: mixed
end note
note left of Mapper::exist
Does key exist
since: 3.2.0
return: bool
end note
note right of Mapper::add
Add content
since: 3.2.0
return: void
arguments:
string $key
mixed $value
bool $array = false
end note
note left of Mapper::remove
Remove content
since: 3.2.0
return: void
end note
note right of Mapper::key
Model the key
since: 3.2.0
return: string
end note
note left of Mapper::isActive_
Check if any values are set in the active array.
since: 3.2.0
return: bool
end note
note right of Mapper::set_
Set dynamic content
since: 3.2.0
return: void
arguments:
string $firstKey
string $secondKey
mixed $value
end note
note left of Mapper::get_
Get dynamic content
since: 3.2.0
return: mixed
end note
note right of Mapper::exist_
Does keys exist
since: 3.2.0
return: bool
end note
note left of Mapper::add_
Add dynamic content
since: 3.2.0
return: void
arguments:
string $firstKey
string $secondKey
mixed $value
bool $array = false
end note
note right of Mapper::remove_
Remove dynamic content
since: 3.2.0
return: void
end note
note left of Mapper::firstKey
Model the first key
since: 3.2.0
return: string
end note
note right of Mapper::secondKey
Model the second key
since: 3.2.0
return: string
end note
@enduml
```
---
```
██╗ ██████╗██████╗
██║██╔════╝██╔══██╗
██║██║ ██████╔╝
██ ██║██║ ██╔══██╗
╚█████╔╝╚██████╗██████╔╝
╚════╝ ╚═════╝╚═════╝
```
> Build with [Joomla Component Builder](https://git.vdm.dev/joomla/Component-Builder)

View File

@ -1,328 +0,0 @@
<?php
/**
* @package Joomla.Component.Builder
*
* @created 4th September, 2022
* @author Llewellyn van der Merwe <https://dev.vdm.io>
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Componentbuilder\Abstraction;
use VDM\Joomla\Componentbuilder\Interfaces\Mapperdoublejoininterface;
use VDM\Joomla\Componentbuilder\Interfaces\Mappersingleinterface;
/**
* Compiler Mapper
*
* @since 3.2.0
*/
abstract class Mapper implements Mapperdoublejoininterface, Mappersingleinterface
{
/**
* The Content
*
* @var array
* @since 3.2.0
**/
public array $active = [];
/**
* Check if any values are set in the active array
*
* @return bool Returns true if the active array is not empty, false otherwise
* @since 3.2.0
*/
public function isActive(): bool
{
return !empty($this->active);
}
/**
* Set content
*
* @param string $key The main string key
* @param mixed $value The values to set
*
* @return void
* @since 3.2.0
*/
public function set(string $key, $value): void
{
$this->active[$this->key($key)] = $value;
}
/**
* Get content
*
* @param string $key The main string key
*
* @return mixed
* @since 3.2.0
*/
public function get(string $key)
{
return $this->active[$this->key($key)] ?? null;
}
/**
* Does key exist
*
* @param string $key The main string key
*
* @return bool
* @since 3.2.0
*/
public function exist(string $key): bool
{
if (isset($this->active[$this->key($key)]))
{
return true;
}
return false;
}
/**
* Add content
*
* @param string $key The main string key
* @param mixed $value The values to set
* @param bool $array The is array switch
*
* @return void
* @since 3.2.0
*/
public function add(string $key, $value, bool $array = false): void
{
if (isset($this->active[$this->key($key)]))
{
if (is_array($this->active[$this->key($key)]))
{
$this->active[$this->key($key)][] = $value;
}
else
{
$this->active[$this->key($key)] .= $value;
}
}
else
{
if ($array)
{
$this->active[$this->key($key)] = [$value];
}
else
{
$this->active[$this->key($key)] = $value;
}
}
}
/**
* Remove content
*
* @param string $key The main string key
*
* @return void
* @since 3.2.0
*/
public function remove(string $key): void
{
unset($this->active[$this->key($key)]);
}
/**
* Model the key
*
* @param string $key The key to model
*
* @return string
* @since 3.2.0
*/
abstract protected function key(string $key): string;
/**
* The Dynamic Content
*
* @var array
* @since 3.2.0
**/
public array $_active = [];
/**
* Check if any values are set in the active array.
*
* @param string|null $firstKey Optional. The first key to check for values.
*
* @return bool True if the active array or the specified subarray is not empty, false otherwise.
* @since 3.2.0
*/
public function isActive_(string $firstKey = null): bool
{
// If a firstKey is provided, check if it has any values.
if (is_string($firstKey))
{
// Get the first key from the input parameter and check if it exists in the active array.
$firstKey = $this->firstKey($firstKey);
if (isset($this->_active[$firstKey]))
{
return !empty($this->_active[$firstKey]);
}
return false;
}
// If no firstKey is provided, check if the entire active array has any values.
return !empty($this->_active);
}
/**
* Set dynamic content
*
* @param string $firstKey The first key
* @param string $secondKey The second key
* @param mixed $value The values to set
*
* @return void
* @since 3.2.0
*/
public function set_(string $firstKey, string $secondKey, $value): void
{
$this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] = $value;
}
/**
* Get dynamic content
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return mixed
* @since 3.2.0
*/
public function get_(string $firstKey, ?string $secondKey = null)
{
if (is_string($secondKey))
{
return $this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] ?? null;
}
return $this->_active[$this->firstKey($firstKey)] ?? null;
}
/**
* Does keys exist
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return bool
* @since 3.2.0
*/
public function exist_(string $firstKey, ?string $secondKey = null): bool
{
if (is_string($secondKey) && isset($this->_active[$this->firstKey($firstKey)]) &&
isset($this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]))
{
return true;
}
elseif ($secondKey === null && isset($this->_active[$this->firstKey($firstKey)]))
{
return true;
}
return false;
}
/**
* Add dynamic content
*
* @param string $firstKey The first key
* @param string $secondKey The second key
* @param mixed $value The values to set
* @param bool $array The is array switch
*
* @return void
* @since 3.2.0
*/
public function add_(string $firstKey, string $secondKey, $value, bool $array = false): void
{
if (isset($this->_active[$this->firstKey($firstKey)]) &&
isset($this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]))
{
if (is_array($this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]))
{
$this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)][] = $value;
}
else
{
$this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] .= $value;
}
}
else
{
if ($array)
{
$this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] = [$value];
}
else
{
$this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] = $value;
}
}
}
/**
* Remove dynamic content
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return void
* @since 3.2.0
*/
public function remove_(string $firstKey, ?string $secondKey = null): void
{
if (is_string($secondKey))
{
unset($this->_active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]);
}
else
{
unset($this->_active[$this->firstKey($firstKey)]);
}
}
/**
* Model the first key
*
* @param string $key The first key to model
*
* @return string
* @since 3.2.0
*/
abstract protected function firstKey(string $key): string;
/**
* Model the second key
*
* @param string $key The second key to model
*
* @return string
* @since 3.2.0
*/
abstract protected function secondKey(string $key): string;
}

View File

@ -1,2 +0,0 @@
[CUSTOMCODE=abstractionMapperSingle]
[CUSTOMCODE=abstractionMapperDouble+_]

View File

@ -1,21 +0,0 @@
{
"add_head": "0",
"add_licensing_template": "2",
"extends": "0",
"guid": "44a3367c-f9e4-406b-b396-0f452bde0f03",
"implements": [
"7921a2b3-b58c-4184-af3f-f58094f695a8",
"78527c29-24ad-4735-ad4c-ec33a4952d9b"
],
"load_selection": null,
"name": "Mapper",
"power_version": "1.0.0",
"system_name": "JCB.Abstraction.Mapper",
"type": "abstract class",
"use_selection": null,
"namespace": "VDM\\Joomla\\Componentbuilder.Abstraction.Mapper",
"description": "Compiler Mapper\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",
"composer": ""
}

View File

@ -1,105 +0,0 @@
```
██████╗ ██████╗ ██╗ ██╗███████╗██████╗
██╔══██╗██╔═══██╗██║ ██║██╔════╝██╔══██╗
██████╔╝██║ ██║██║ █╗ ██║█████╗ ██████╔╝
██╔═══╝ ██║ ██║██║███╗██║██╔══╝ ██╔══██╗
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# abstract class MapperDouble (Details)
> namespace: **VDM\Joomla\Componentbuilder\Abstraction**
```uml
@startuml
abstract MapperDouble #Orange {
+ array $active
+ isActive(string $firstKey = null) : bool
+ set(string $firstKey, string $secondKey, ...) : void
+ get(string $firstKey, ?string $secondKey = null) : mixed
+ exist(string $firstKey, ?string $secondKey = null) : bool
+ add(string $firstKey, string $secondKey, ...) : void
+ remove(string $firstKey, ?string $secondKey = null) : void
# {abstract} firstKey(string $key) : string
# {abstract} secondKey(string $key) : string
}
note right of MapperDouble::isActive
Check if any values are set in the active array.
since: 3.2.0
return: bool
end note
note left of MapperDouble::set
Set dynamic content
since: 3.2.0
return: void
arguments:
string $firstKey
string $secondKey
mixed $value
end note
note right of MapperDouble::get
Get dynamic content
since: 3.2.0
return: mixed
end note
note left of MapperDouble::exist
Does keys exist
since: 3.2.0
return: bool
end note
note right of MapperDouble::add
Add dynamic content
since: 3.2.0
return: void
arguments:
string $firstKey
string $secondKey
mixed $value
bool $array = false
end note
note left of MapperDouble::remove
Remove dynamic content
since: 3.2.0
return: void
end note
note right of MapperDouble::firstKey
Model the first key
since: 3.2.0
return: string
end note
note left of MapperDouble::secondKey
Model the second key
since: 3.2.0
return: string
end note
@enduml
```
---
```
██╗ ██████╗██████╗
██║██╔════╝██╔══██╗
██║██║ ██████╔╝
██ ██║██║ ██╔══██╗
╚█████╔╝╚██████╗██████╔╝
╚════╝ ╚═════╝╚═════╝
```
> Build with [Joomla Component Builder](https://git.vdm.dev/joomla/Component-Builder)

View File

@ -1,205 +0,0 @@
<?php
/**
* @package Joomla.Component.Builder
*
* @created 4th September, 2022
* @author Llewellyn van der Merwe <https://dev.vdm.io>
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Componentbuilder\Abstraction;
use VDM\Joomla\Componentbuilder\Interfaces\Mapperdoubleinterface;
/**
* Compiler Mapper Double
*
* @since 3.2.0
*/
abstract class MapperDouble implements Mapperdoubleinterface
{
/**
* The Dynamic Content
*
* @var array
* @since 3.2.0
**/
public array $active = [];
/**
* Check if any values are set in the active array.
*
* @param string|null $firstKey Optional. The first key to check for values.
*
* @return bool True if the active array or the specified subarray is not empty, false otherwise.
* @since 3.2.0
*/
public function isActive(string $firstKey = null): bool
{
// If a firstKey is provided, check if it has any values.
if (is_string($firstKey))
{
// Get the first key from the input parameter and check if it exists in the active array.
$firstKey = $this->firstKey($firstKey);
if (isset($this->active[$firstKey]))
{
return !empty($this->active[$firstKey]);
}
return false;
}
// If no firstKey is provided, check if the entire active array has any values.
return !empty($this->active);
}
/**
* Set dynamic content
*
* @param string $firstKey The first key
* @param string $secondKey The second key
* @param mixed $value The values to set
*
* @return void
* @since 3.2.0
*/
public function set(string $firstKey, string $secondKey, $value): void
{
$this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] = $value;
}
/**
* Get dynamic content
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return mixed
* @since 3.2.0
*/
public function get(string $firstKey, ?string $secondKey = null)
{
if (is_string($secondKey))
{
return $this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] ?? null;
}
return $this->active[$this->firstKey($firstKey)] ?? null;
}
/**
* Does keys exist
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return bool
* @since 3.2.0
*/
public function exist(string $firstKey, ?string $secondKey = null): bool
{
if (is_string($secondKey) && isset($this->active[$this->firstKey($firstKey)]) &&
isset($this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]))
{
return true;
}
elseif ($secondKey === null && isset($this->active[$this->firstKey($firstKey)]))
{
return true;
}
return false;
}
/**
* Add dynamic content
*
* @param string $firstKey The first key
* @param string $secondKey The second key
* @param mixed $value The values to set
* @param bool $array The is array switch
*
* @return void
* @since 3.2.0
*/
public function add(string $firstKey, string $secondKey, $value, bool $array = false): void
{
if (isset($this->active[$this->firstKey($firstKey)]) &&
isset($this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]))
{
if (is_array($this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]))
{
$this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)][] = $value;
}
else
{
$this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] .= $value;
}
}
else
{
if ($array)
{
$this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] = [$value];
}
else
{
$this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)] = $value;
}
}
}
/**
* Remove dynamic content
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return void
* @since 3.2.0
*/
public function remove(string $firstKey, ?string $secondKey = null): void
{
if (is_string($secondKey))
{
unset($this->active[$this->firstKey($firstKey)]
[$this->secondKey($secondKey)]);
}
else
{
unset($this->active[$this->firstKey($firstKey)]);
}
}
/**
* Model the first key
*
* @param string $key The first key to model
*
* @return string
* @since 3.2.0
*/
abstract protected function firstKey(string $key): string;
/**
* Model the second key
*
* @param string $key The second key to model
*
* @return string
* @since 3.2.0
*/
abstract protected function secondKey(string $key): string;
}

View File

@ -1 +0,0 @@
[CUSTOMCODE=abstractionMapperDouble+,]

View File

@ -1,20 +0,0 @@
{
"add_head": "0",
"add_licensing_template": "2",
"extends": "0",
"guid": "4d4e76e9-12d9-4d19-b58c-b88974b2586a",
"implements": [
"fbc58009-fa16-4d49-a0dd-419c3b62d42f"
],
"load_selection": null,
"name": "MapperDouble",
"power_version": "1.0.0",
"system_name": "JCB.Abstraction.MapperDouble",
"type": "abstract class",
"use_selection": null,
"namespace": "VDM\\Joomla\\Componentbuilder.Abstraction.MapperDouble",
"description": "Compiler Mapper Double\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",
"composer": ""
}

View File

@ -7,7 +7,7 @@
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# trait VarExport (Details)
> namespace: **VDM\Joomla\Abstraction\StorageRegistry\Traits**
> namespace: **VDM\Joomla\Abstraction\Registry\Traits**
```uml
@startuml
class VarExport << (T,Orange) >> #Turquoise {

View File

@ -9,7 +9,7 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Abstraction\StorageRegistry\Traits;
namespace VDM\Joomla\Abstraction\Registry\Traits;
use VDM\Joomla\Componentbuilder\Compiler\Utilities\Indent;

View File

@ -7,7 +7,7 @@
"load_selection": null,
"name": "VarExport",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.StorageRegistry.Traits.VarExport",
"system_name": "VDM.Abstraction.Registry.Traits.VarExport",
"type": "trait",
"use_selection": {
"use_selection0": {
@ -15,7 +15,7 @@
"as": "default"
}
},
"namespace": "VDM\\Joomla\\Abstraction.StorageRegistry.Traits.VarExport",
"namespace": "VDM\\Joomla\\Abstraction.Registry.Traits.VarExport",
"description": "Var Export Values\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",

View File

@ -7,7 +7,7 @@
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# trait GetString (Details)
> namespace: **VDM\Joomla\Abstraction\StorageRegistry\Traits**
> namespace: **VDM\Joomla\Abstraction\Registry\Traits**
```uml
@startuml
class GetString << (T,Orange) >> #Turquoise {

View File

@ -9,7 +9,7 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Abstraction\StorageRegistry\Traits;
namespace VDM\Joomla\Abstraction\Registry\Traits;
/**

View File

@ -7,10 +7,10 @@
"load_selection": null,
"name": "GetString",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.StorageRegistry.Traits.GetString",
"system_name": "VDM.Abstraction.Registry.Traits.GetString",
"type": "trait",
"use_selection": null,
"namespace": "VDM\\Joomla\\Abstraction.StorageRegistry.Traits.GetString",
"namespace": "VDM\\Joomla\\Abstraction.Registry.Traits.GetString",
"description": "Get String Values\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",

View File

@ -6,11 +6,11 @@
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# interface Storageregistryinterface (Details)
# interface Registryinterface (Details)
> namespace: **VDM\Joomla\Interfaces**
```uml
@startuml
interface Storageregistryinterface #Lavender {
interface Registryinterface #Lavender {
+ set(string $path, mixed $value) : void
+ add(string $path, mixed $value, ...) : void
+ get(string $path, mixed $default = null) : mixed
@ -19,15 +19,15 @@ interface Storageregistryinterface #Lavender {
+ setSeparator(?string $value) : void
}
note right of Storageregistryinterface::set
Sets a value into the storage using multiple keys.
note right of Registryinterface::set
Sets a value into the registry using multiple keys.
since: 3.2.0
return: void
end note
note right of Storageregistryinterface::add
Adds content into the storage. If a key exists,
note right of Registryinterface::add
Adds content into the registry. If a key exists,
it either appends or concatenates based on $asArray switch.
since: 3.2.0
@ -39,28 +39,28 @@ it either appends or concatenates based on $asArray switch.
bool $asArray = false
end note
note right of Storageregistryinterface::get
Retrieves a value (or sub-array) from the storage using multiple keys.
note right of Registryinterface::get
Retrieves a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: mixed
end note
note right of Storageregistryinterface::remove
Removes a value (or sub-array) from the storage using multiple keys.
note right of Registryinterface::remove
Removes a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: void
end note
note right of Storageregistryinterface::exists
Checks the existence of a particular location in the storage using multiple keys.
note right of Registryinterface::exists
Checks the existence of a particular location in the registry using multiple keys.
since: 3.2.0
return: bool
end note
note right of Storageregistryinterface::setSeparator
note right of Registryinterface::setSeparator
Sets a separator value
since: 3.2.0

View File

@ -13,16 +13,16 @@ namespace VDM\Joomla\Interfaces;
/**
* The Storage Registry Interface
* The Registry Interface
*
* @since 3.2.0
*/
interface Storageregistryinterface
interface Registryinterface
{
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -32,10 +32,10 @@ interface Storageregistryinterface
public function set(string $path, $value): void;
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on $asArray switch.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
* @param bool $asArray Determines if the new value should be treated as an array. Default is false.
*
@ -46,9 +46,9 @@ interface Storageregistryinterface
public function add(string $path, $value, bool $asArray = false): void;
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $default Optional default value, returned if the internal doesn't exist.
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -58,9 +58,9 @@ interface Storageregistryinterface
public function get(string $path, $default = null);
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return void
@ -69,9 +69,9 @@ interface Storageregistryinterface
public function remove(string $path): void;
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return bool True if the location exists, false otherwise.

View File

@ -1,7 +1,7 @@
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -11,10 +11,10 @@
public function set(string $path, $value): void;
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on $asArray switch.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
* @param bool $asArray Determines if the new value should be treated as an array. Default is false.
*
@ -25,9 +25,9 @@
public function add(string $path, $value, bool $asArray = false): void;
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $default Optional default value, returned if the internal doesn't exist.
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -37,9 +37,9 @@
public function get(string $path, $default = null);
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return void
@ -48,9 +48,9 @@
public function remove(string $path): void;
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return bool True if the location exists, false otherwise.

View File

@ -5,13 +5,13 @@
"guid": "64e291c2-11f1-423d-a44d-837cc12cc017",
"implements": null,
"load_selection": null,
"name": "Storageregistryinterface",
"name": "Registryinterface",
"power_version": "1.0.0",
"system_name": "VDM.Interfaces.Storageregistryinterface",
"system_name": "VDM.Interfaces.Registryinterface",
"type": "interface",
"use_selection": null,
"namespace": "VDM\\Joomla\\Interfaces.Storageregistryinterface",
"description": "The Storage Registry Interface\r\n\r\n@since 3.2.0",
"namespace": "VDM\\Joomla\\Interfaces.Registryinterface",
"description": "The Registry Interface\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",
"composer": ""

View File

@ -1,88 +0,0 @@
```
██████╗ ██████╗ ██╗ ██╗███████╗██████╗
██╔══██╗██╔═══██╗██║ ██║██╔════╝██╔══██╗
██████╔╝██║ ██║██║ █╗ ██║█████╗ ██████╔╝
██╔═══╝ ██║ ██║██║███╗██║██╔══╝ ██╔══██╗
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# interface Mapperdoublejoininterface (Details)
> namespace: **VDM\Joomla\Componentbuilder\Interfaces**
```uml
@startuml
interface Mapperdoublejoininterface #Lavender {
+ isActive_(string $firstKey = null) : bool
+ set_(string $firstKey, string $secondKey, ...) : void
+ get_(string $firstKey, ?string $secondKey = null) : mixed
+ exist_(string $firstKey, ?string $secondKey = null) : bool
+ add_(string $firstKey, string $secondKey, ...) : void
+ remove_(string $firstKey, ?string $secondKey = null) : void
}
note right of Mapperdoublejoininterface::isActive_
Check if any values are set in the active array.
since: 3.2.0
return: bool
end note
note right of Mapperdoublejoininterface::set_
Set dynamic content
since: 3.2.0
return: void
arguments:
string $firstKey
string $secondKey
mixed $value
end note
note right of Mapperdoublejoininterface::get_
Get dynamic content
since: 3.2.0
return: mixed
end note
note right of Mapperdoublejoininterface::exist_
Does keys exist
since: 3.2.0
return: bool
end note
note right of Mapperdoublejoininterface::add_
Add dynamic content
since: 3.2.0
return: void
arguments:
string $firstKey
string $secondKey
mixed $value
bool $array = false
end note
note right of Mapperdoublejoininterface::remove_
Remove dynamic content
since: 3.2.0
return: void
end note
@enduml
```
---
```
██╗ ██████╗██████╗
██║██╔════╝██╔══██╗
██║██║ ██████╔╝
██ ██║██║ ██╔══██╗
╚█████╔╝╚██████╗██████╔╝
╚════╝ ╚═════╝╚═════╝
```
> Build with [Joomla Component Builder](https://git.vdm.dev/joomla/Component-Builder)

View File

@ -1,89 +0,0 @@
<?php
/**
* @package Joomla.Component.Builder
*
* @created 4th September, 2022
* @author Llewellyn van der Merwe <https://dev.vdm.io>
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Componentbuilder\Interfaces;
/**
* The Double Jointed Mapper Interface
*/
interface Mapperdoublejoininterface
{
/**
* Check if any values are set in the active array.
*
* @param string|null $firstKey Optional. The first key to check for values.
*
* @return bool True if the active array or the specified subarray is not empty, false otherwise.
* @since 3.2.0
*/
public function isActive_(string $firstKey = null): bool;
/**
* Set dynamic content
*
* @param string $firstKey The first key
* @param string $secondKey The second key
* @param mixed $value The values to set
*
* @return void
* @since 3.2.0
*/
public function set_(string $firstKey, string $secondKey, $value): void;
/**
* Get dynamic content
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return mixed
* @since 3.2.0
*/
public function get_(string $firstKey, ?string $secondKey = null);
/**
* Does keys exist
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return bool
* @since 3.2.0
*/
public function exist_(string $firstKey, ?string $secondKey = null): bool;
/**
* Add dynamic content
*
* @param string $firstKey The first key
* @param string $secondKey The second key
* @param mixed $value The values to set
* @param bool $array The is array switch
*
* @return void
* @since 3.2.0
*/
public function add_(string $firstKey, string $secondKey, $value, bool $array = false): void;
/**
* Remove dynamic content
*
* @param string $firstKey The first key
* @param string|null $secondKey The second key
*
* @return void
* @since 3.2.0
*/
public function remove_(string $firstKey, ?string $secondKey = null): void;
}

View File

@ -1 +0,0 @@
[CUSTOMCODE=interfacesMapperDouble+_]

View File

@ -1,18 +0,0 @@
{
"add_head": "0",
"add_licensing_template": "2",
"extends": "0",
"guid": "7921a2b3-b58c-4184-af3f-f58094f695a8",
"implements": null,
"load_selection": null,
"name": "Mapperdoublejoininterface",
"power_version": "1.0.0",
"system_name": "JCB.Interfaces.Mapperdoublejoininterface",
"type": "interface",
"use_selection": null,
"namespace": "VDM\\Joomla\\Componentbuilder.Interfaces.Mapperdoublejoininterface",
"description": "The Double Jointed Mapper Interface",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",
"composer": ""
}

View File

@ -4,7 +4,11 @@
"extends": "0",
"guid": "79d765b3-7319-4988-9730-446c7f347020",
"implements": null,
"load_selection": null,
"load_selection": {
"load_selection0": {
"load": "1198aecf-84c6-45d2-aea8-d531aa4afdfa"
}
},
"name": "Utilities",
"power_version": "1.0.0",
"system_name": "Utilities",

View File

@ -7,7 +7,7 @@
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# trait ToString (Details)
> namespace: **VDM\Joomla\Abstraction\StorageRegistry\Traits**
> namespace: **VDM\Joomla\Abstraction\Registry\Traits**
```uml
@startuml
class ToString << (T,Orange) >> #Turquoise {

View File

@ -9,7 +9,7 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Abstraction\StorageRegistry\Traits;
namespace VDM\Joomla\Abstraction\Registry\Traits;
/**

View File

@ -7,10 +7,10 @@
"load_selection": null,
"name": "ToString",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.StorageRegistry.Traits.ToString",
"system_name": "VDM.Abstraction.Registry.Traits.ToString",
"type": "trait",
"use_selection": null,
"namespace": "VDM\\Joomla\\Abstraction.StorageRegistry.Traits.ToString",
"namespace": "VDM\\Joomla\\Abstraction.Registry.Traits.ToString",
"description": "To String Values\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",

View File

@ -6,12 +6,12 @@
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# abstract class StorageRegistry (Details)
# abstract class Registry (Details)
> namespace: **VDM\Joomla\Abstraction**
> extends: **ActiveStorageRegistry**
> extends: **ActiveRegistry**
```uml
@startuml
abstract StorageRegistry #Orange {
abstract Registry #Orange {
# ?string $separator
+ set(string $path, mixed $value) : void
+ add(string $path, mixed $value, ...) : void
@ -22,15 +22,15 @@ abstract StorageRegistry #Orange {
# getActiveKeys(string $path) : ?array
}
note right of StorageRegistry::set
Sets a value into the storage using multiple keys.
note right of Registry::set
Sets a value into the registry using multiple keys.
since: 3.2.0
return: void
end note
note right of StorageRegistry::add
Adds content into the storage. If a key exists,
note right of Registry::add
Adds content into the registry. If a key exists,
it either appends or concatenates based on $asArray switch.
since: 3.2.0
@ -42,35 +42,35 @@ it either appends or concatenates based on $asArray switch.
bool $asArray = false
end note
note right of StorageRegistry::get
Retrieves a value (or sub-array) from the storage using multiple keys.
note right of Registry::get
Retrieves a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: mixed
end note
note right of StorageRegistry::remove
Removes a value (or sub-array) from the storage using multiple keys.
note right of Registry::remove
Removes a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: void
end note
note right of StorageRegistry::exists
Checks the existence of a particular location in the storage using multiple keys.
note right of Registry::exists
Checks the existence of a particular location in the registry using multiple keys.
since: 3.2.0
return: bool
end note
note right of StorageRegistry::setSeparator
note right of Registry::setSeparator
Sets a separator value
since: 3.2.0
return: void
end note
note right of StorageRegistry::getActiveKeys
note right of Registry::getActiveKeys
Get that the active keys from a path
since: 3.2.0

View File

@ -12,19 +12,19 @@
namespace VDM\Joomla\Abstraction;
use VDM\Joomla\Interfaces\Activestorageregistryinterface;
use VDM\Joomla\Interfaces\Storageregistryinterface;
use VDM\Joomla\Abstraction\ActiveStorageRegistry;
use VDM\Joomla\Interfaces\Activeregistryinterface;
use VDM\Joomla\Interfaces\Registryinterface;
use VDM\Joomla\Abstraction\ActiveRegistry;
/**
* Storage Registry.
* VDM Basic Registry.
*
* Don't use this beyond 10 dimensional depth for best performance.
*
* @since 3.2.0
*/
abstract class StorageRegistry extends ActiveStorageRegistry implements Activestorageregistryinterface, Storageregistryinterface
abstract class Registry extends ActiveRegistry implements Activeregistryinterface, Registryinterface
{
/**
* Path separator
@ -35,9 +35,9 @@ abstract class StorageRegistry extends ActiveStorageRegistry implements Activest
protected ?string $separator = '.';
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -55,10 +55,10 @@ abstract class StorageRegistry extends ActiveStorageRegistry implements Activest
}
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on $asArray switch.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
* @param bool $asArray Determines if the new value should be treated as an array. Default is false.
*
@ -77,9 +77,9 @@ abstract class StorageRegistry extends ActiveStorageRegistry implements Activest
}
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $default Optional default value, returned if the internal doesn't exist.
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -97,9 +97,9 @@ abstract class StorageRegistry extends ActiveStorageRegistry implements Activest
}
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return void
@ -116,9 +116,9 @@ abstract class StorageRegistry extends ActiveStorageRegistry implements Activest
}
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return bool True if the location exists, false otherwise.
@ -150,7 +150,7 @@ abstract class StorageRegistry extends ActiveStorageRegistry implements Activest
/**
* Get that the active keys from a path
*
* @param string $path The path to determine the location storage.
* @param string $path The path to determine the location registry.
*
* @return array|null The valid array of keys
* @since 3.2.0

View File

@ -7,9 +7,9 @@
protected ?string $separator = '.';
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -27,10 +27,10 @@
}
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on $asArray switch.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $value Value of entry
* @param bool $asArray Determines if the new value should be treated as an array. Default is false.
*
@ -49,9 +49,9 @@
}
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
* @param mixed $default Optional default value, returned if the internal doesn't exist.
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
@ -69,9 +69,9 @@
}
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return void
@ -88,9 +88,9 @@
}
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string $path Storage path (e.g. vdm.content.builder)
* @param string $path Registry path (e.g. vdm.content.builder)
*
* @throws \InvalidArgumentException If any of the path values are not a number or string.
* @return bool True if the location exists, false otherwise.
@ -122,7 +122,7 @@
/**
* Get that the active keys from a path
*
* @param string $path The path to determine the location storage.
* @param string $path The path to determine the location registry.
*
* @return array|null The valid array of keys
* @since 3.2.0

View File

@ -8,13 +8,13 @@
"64e291c2-11f1-423d-a44d-837cc12cc017"
],
"load_selection": null,
"name": "StorageRegistry",
"name": "Registry",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.StorageRegistry",
"system_name": "VDM.Abstraction.Registry",
"type": "abstract class",
"use_selection": null,
"namespace": "VDM\\Joomla\\Abstraction.StorageRegistry",
"description": "Storage Registry.\r\n\r\nDon't use this beyond 10 dimensional depth for best performance.\r\n\r\n@since 3.2.0",
"namespace": "VDM\\Joomla\\Abstraction.Registry",
"description": "VDM Basic Registry.\r\n\r\nDon't use this beyond 10 dimensional depth for best performance.\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",
"composer": ""

View File

@ -6,11 +6,11 @@
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# interface Activestorageregistryinterface (Details)
# interface Activeregistryinterface (Details)
> namespace: **VDM\Joomla\Interfaces**
```uml
@startuml
interface Activestorageregistryinterface #Lavender {
interface Activeregistryinterface #Lavender {
+ isActive() : bool
+ allActive() : array
+ setActive(mixed $value, $keys) : void
@ -20,29 +20,29 @@ interface Activestorageregistryinterface #Lavender {
+ existsActive($keys) : bool
}
note right of Activestorageregistryinterface::isActive
Check if the main storage has any content.
note right of Activeregistryinterface::isActive
Check if the registry has any content.
since: 3.2.0
return: bool
end note
note right of Activestorageregistryinterface::allActive
Retrieves all value from the storage.
note right of Activeregistryinterface::allActive
Retrieves all value from the registry.
since: 3.2.0
return: array
end note
note right of Activestorageregistryinterface::setActive
Sets a value into the storage using multiple keys.
note right of Activeregistryinterface::setActive
Sets a value into the registry using multiple keys.
since: 3.2.0
return: void
end note
note right of Activestorageregistryinterface::addActive
Adds content into the storage. If a key exists,
note right of Activeregistryinterface::addActive
Adds content into the registry. If a key exists,
it either appends or concatenates based on the value's type.
since: 3.2.0
@ -54,22 +54,22 @@ it either appends or concatenates based on the value's type.
$keys
end note
note right of Activestorageregistryinterface::getActive
Retrieves a value (or sub-array) from the storage using multiple keys.
note right of Activeregistryinterface::getActive
Retrieves a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: mixed
end note
note right of Activestorageregistryinterface::removeActive
Removes a value (or sub-array) from the storage using multiple keys.
note right of Activeregistryinterface::removeActive
Removes a value (or sub-array) from the registry using multiple keys.
since: 3.2.0
return: void
end note
note right of Activestorageregistryinterface::existsActive
Checks the existence of a particular location in the storage using multiple keys.
note right of Activeregistryinterface::existsActive
Checks the existence of a particular location in the registry using multiple keys.
since: 3.2.0
return: bool

View File

@ -13,14 +13,14 @@ namespace VDM\Joomla\Interfaces;
/**
* The Active Storage Registry Interface
* The Active Registry Interface
*
* @since 3.2.0
*/
interface Activestorageregistryinterface
interface Activeregistryinterface
{
/**
* Check if the main storage has any content.
* Check if the registry has any content.
*
* @return bool Returns true if the active array is not empty, false otherwise.
* @since 3.2.0
@ -28,7 +28,7 @@ interface Activestorageregistryinterface
public function isActive(): bool;
/**
* Retrieves all value from the storage.
* Retrieves all value from the registry.
*
* @return array The values.
* @since 3.2.0
@ -36,7 +36,7 @@ interface Activestorageregistryinterface
public function allActive(): array;
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param mixed $value The value to set.
* @param string ...$keys The keys to determine the location.
@ -48,7 +48,7 @@ interface Activestorageregistryinterface
public function setActive($value, string ...$keys): void;
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on the value's type.
*
* @param mixed $value The value to set.
@ -62,7 +62,7 @@ interface Activestorageregistryinterface
public function addActive($value, bool $asArray, string ...$keys): void;
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param mixed $default The default value if not set.
* @param string ...$keys The keys to determine the location.
@ -74,7 +74,7 @@ interface Activestorageregistryinterface
public function getActive($default, string ...$keys);
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*
@ -85,7 +85,7 @@ interface Activestorageregistryinterface
public function removeActive(string ...$keys): void;
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*

View File

@ -1,5 +1,5 @@
/**
* Check if the main storage has any content.
* Check if the registry has any content.
*
* @return bool Returns true if the active array is not empty, false otherwise.
* @since 3.2.0
@ -7,7 +7,7 @@
public function isActive(): bool;
/**
* Retrieves all value from the storage.
* Retrieves all value from the registry.
*
* @return array The values.
* @since 3.2.0
@ -15,7 +15,7 @@
public function allActive(): array;
/**
* Sets a value into the storage using multiple keys.
* Sets a value into the registry using multiple keys.
*
* @param mixed $value The value to set.
* @param string ...$keys The keys to determine the location.
@ -27,7 +27,7 @@
public function setActive($value, string ...$keys): void;
/**
* Adds content into the storage. If a key exists,
* Adds content into the registry. If a key exists,
* it either appends or concatenates based on the value's type.
*
* @param mixed $value The value to set.
@ -41,7 +41,7 @@
public function addActive($value, bool $asArray, string ...$keys): void;
/**
* Retrieves a value (or sub-array) from the storage using multiple keys.
* Retrieves a value (or sub-array) from the registry using multiple keys.
*
* @param mixed $default The default value if not set.
* @param string ...$keys The keys to determine the location.
@ -53,7 +53,7 @@
public function getActive($default, string ...$keys);
/**
* Removes a value (or sub-array) from the storage using multiple keys.
* Removes a value (or sub-array) from the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*
@ -64,7 +64,7 @@
public function removeActive(string ...$keys): void;
/**
* Checks the existence of a particular location in the storage using multiple keys.
* Checks the existence of a particular location in the registry using multiple keys.
*
* @param string ...$keys The keys to determine the location.
*

View File

@ -5,13 +5,13 @@
"guid": "af0eedbe-603b-4671-8e5a-28165d88254b",
"implements": null,
"load_selection": null,
"name": "Activestorageregistryinterface",
"name": "Activeregistryinterface",
"power_version": "1.0.0",
"system_name": "VDM.Interfaces.Activestorageregistryinterface",
"system_name": "VDM.Interfaces.Activeregistryinterface",
"type": "interface",
"use_selection": null,
"namespace": "VDM\\Joomla\\Interfaces.Activestorageregistryinterface",
"description": "The Active Storage Registry Interface\r\n\r\n@since 3.2.0",
"namespace": "VDM\\Joomla\\Interfaces.Activeregistryinterface",
"description": "The Active Registry Interface\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",
"composer": ""

View File

@ -4295,15 +4295,6 @@ class Table extends BaseTable implements Tableinterface
'store' => NULL,
'tab_name' => 'Set Properties',
],
'on_get_model_field' => [
'name' => 'on_get_model_field',
'label' => 'COM_COMPONENTBUILDER_FIELD_ON_GET_MODEL_FIELD_LABEL',
'type' => 'textarea',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Database',
],
'on_save_model_field' => [
'name' => 'on_save_model_field',
'label' => 'COM_COMPONENTBUILDER_FIELD_ON_SAVE_MODEL_FIELD_LABEL',
@ -4322,6 +4313,24 @@ class Table extends BaseTable implements Tableinterface
'store' => 'base64',
'tab_name' => 'Database',
],
'initiator_on_save_model' => [
'name' => 'initiator_on_save_model',
'label' => 'COM_COMPONENTBUILDER_FIELD_INITIATOR_ON_SAVE_MODEL_LABEL',
'type' => 'textarea',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Database',
],
'xml' => [
'name' => 'xml',
'label' => '',
'type' => 'hidden',
'title' => false,
'list' => 'fields',
'store' => 'json',
'tab_name' => 'Type Info',
],
'datalenght' => [
'name' => 'datalenght',
'label' => 'COM_COMPONENTBUILDER_FIELD_DATALENGHT_LABEL',
@ -4331,24 +4340,6 @@ class Table extends BaseTable implements Tableinterface
'store' => NULL,
'tab_name' => 'Database',
],
'css_view' => [
'name' => 'css_view',
'label' => 'COM_COMPONENTBUILDER_FIELD_CSS_VIEW_LABEL',
'type' => 'editor',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Scripts',
],
'javascript_view_footer' => [
'name' => 'javascript_view_footer',
'label' => 'COM_COMPONENTBUILDER_FIELD_JAVASCRIPT_VIEW_FOOTER_LABEL',
'type' => 'editor',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Scripts',
],
'css_views' => [
'name' => 'css_views',
'label' => 'COM_COMPONENTBUILDER_FIELD_CSS_VIEWS_LABEL',
@ -4358,6 +4349,15 @@ class Table extends BaseTable implements Tableinterface
'store' => 'base64',
'tab_name' => 'Scripts',
],
'css_view' => [
'name' => 'css_view',
'label' => 'COM_COMPONENTBUILDER_FIELD_CSS_VIEW_LABEL',
'type' => 'editor',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Scripts',
],
'datadefault_other' => [
'name' => 'datadefault_other',
'label' => 'COM_COMPONENTBUILDER_FIELD_DATADEFAULT_OTHER_LABEL',
@ -4385,6 +4385,24 @@ class Table extends BaseTable implements Tableinterface
'store' => NULL,
'tab_name' => 'Database',
],
'on_get_model_field' => [
'name' => 'on_get_model_field',
'label' => 'COM_COMPONENTBUILDER_FIELD_ON_GET_MODEL_FIELD_LABEL',
'type' => 'textarea',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Database',
],
'javascript_view_footer' => [
'name' => 'javascript_view_footer',
'label' => 'COM_COMPONENTBUILDER_FIELD_JAVASCRIPT_VIEW_FOOTER_LABEL',
'type' => 'editor',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Scripts',
],
'javascript_views_footer' => [
'name' => 'javascript_views_footer',
'label' => 'COM_COMPONENTBUILDER_FIELD_JAVASCRIPT_VIEWS_FOOTER_LABEL',
@ -4403,15 +4421,6 @@ class Table extends BaseTable implements Tableinterface
'store' => NULL,
'tab_name' => 'Scripts',
],
'xml' => [
'name' => 'xml',
'label' => '',
'type' => 'hidden',
'title' => false,
'list' => 'fields',
'store' => 'json',
'tab_name' => 'Type Info',
],
'add_css_views' => [
'name' => 'add_css_views',
'label' => 'COM_COMPONENTBUILDER_FIELD_ADD_CSS_VIEWS_LABEL',
@ -4439,15 +4448,6 @@ class Table extends BaseTable implements Tableinterface
'store' => NULL,
'tab_name' => 'Scripts',
],
'initiator_on_save_model' => [
'name' => 'initiator_on_save_model',
'label' => 'COM_COMPONENTBUILDER_FIELD_INITIATOR_ON_SAVE_MODEL_LABEL',
'type' => 'textarea',
'title' => false,
'list' => 'fields',
'store' => 'base64',
'tab_name' => 'Database',
],
'guid' => [
'name' => 'guid',
'label' => 'COM_COMPONENTBUILDER_FIELD_GUID_LABEL',
@ -4513,15 +4513,6 @@ class Table extends BaseTable implements Tableinterface
'store' => NULL,
'tab_name' => 'Database (defaults)',
],
'datalenght_other' => [
'name' => 'datalenght_other',
'label' => 'COM_COMPONENTBUILDER_FIELDTYPE_DATALENGHT_OTHER_LABEL',
'type' => 'text',
'title' => false,
'list' => 'fieldtypes',
'store' => NULL,
'tab_name' => 'Database (defaults)',
],
'short_description' => [
'name' => 'short_description',
'label' => 'COM_COMPONENTBUILDER_FIELDTYPE_SHORT_DESCRIPTION_LABEL',
@ -4576,6 +4567,15 @@ class Table extends BaseTable implements Tableinterface
'store' => NULL,
'tab_name' => 'Database (defaults)',
],
'datalenght_other' => [
'name' => 'datalenght_other',
'label' => 'COM_COMPONENTBUILDER_FIELDTYPE_DATALENGHT_OTHER_LABEL',
'type' => 'text',
'title' => false,
'list' => 'fieldtypes',
'store' => NULL,
'tab_name' => 'Database (defaults)',
],
'guid' => [
'name' => 'guid',
'label' => 'COM_COMPONENTBUILDER_FIELDTYPE_GUID_LABEL',

View File

@ -1,91 +0,0 @@
```
██████╗ ██████╗ ██╗ ██╗███████╗██████╗
██╔══██╗██╔═══██╗██║ ██║██╔════╝██╔══██╗
██████╔╝██║ ██║██║ █╗ ██║█████╗ ██████╔╝
██╔═══╝ ██║ ██║██║███╗██║██╔══╝ ██╔══██╗
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# abstract class MapperSingle (Details)
> namespace: **VDM\Joomla\Componentbuilder\Abstraction**
```uml
@startuml
abstract MapperSingle #Orange {
+ array $active
+ isActive() : bool
+ set(string $key, mixed $value) : void
+ get(string $key) : mixed
+ exist(string $key) : bool
+ add(string $key, mixed $value, ...) : void
+ remove(string $key) : void
# {abstract} key(string $key) : string
}
note right of MapperSingle::isActive
Check if any values are set in the active array
since: 3.2.0
return: bool
end note
note right of MapperSingle::set
Set content
since: 3.2.0
return: void
end note
note right of MapperSingle::get
Get content
since: 3.2.0
return: mixed
end note
note right of MapperSingle::exist
Does key exist
since: 3.2.0
return: bool
end note
note right of MapperSingle::add
Add content
since: 3.2.0
return: void
arguments:
string $key
mixed $value
bool $array = false
end note
note right of MapperSingle::remove
Remove content
since: 3.2.0
return: void
end note
note right of MapperSingle::key
Model the key
since: 3.2.0
return: string
end note
@enduml
```
---
```
██╗ ██████╗██████╗
██║██╔════╝██╔══██╗
██║██║ ██████╔╝
██ ██║██║ ██╔══██╗
╚█████╔╝╚██████╗██████╔╝
╚════╝ ╚═════╝╚═════╝
```
> Build with [Joomla Component Builder](https://git.vdm.dev/joomla/Component-Builder)

View File

@ -1,148 +0,0 @@
<?php
/**
* @package Joomla.Component.Builder
*
* @created 4th September, 2022
* @author Llewellyn van der Merwe <https://dev.vdm.io>
* @git Joomla Component Builder <https://git.vdm.dev/joomla/Component-Builder>
* @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Componentbuilder\Abstraction;
use VDM\Joomla\Componentbuilder\Interfaces\Mappersingleinterface;
/**
* Compiler Mapper Single
*
* @since 3.2.0
*/
abstract class MapperSingle implements Mappersingleinterface
{
/**
* The Content
*
* @var array
* @since 3.2.0
**/
public array $active = [];
/**
* Check if any values are set in the active array
*
* @return bool Returns true if the active array is not empty, false otherwise
* @since 3.2.0
*/
public function isActive(): bool
{
return !empty($this->active);
}
/**
* Set content
*
* @param string $key The main string key
* @param mixed $value The values to set
*
* @return void
* @since 3.2.0
*/
public function set(string $key, $value): void
{
$this->active[$this->key($key)] = $value;
}
/**
* Get content
*
* @param string $key The main string key
*
* @return mixed
* @since 3.2.0
*/
public function get(string $key)
{
return $this->active[$this->key($key)] ?? null;
}
/**
* Does key exist
*
* @param string $key The main string key
*
* @return bool
* @since 3.2.0
*/
public function exist(string $key): bool
{
if (isset($this->active[$this->key($key)]))
{
return true;
}
return false;
}
/**
* Add content
*
* @param string $key The main string key
* @param mixed $value The values to set
* @param bool $array The is array switch
*
* @return void
* @since 3.2.0
*/
public function add(string $key, $value, bool $array = false): void
{
if (isset($this->active[$this->key($key)]))
{
if (is_array($this->active[$this->key($key)]))
{
$this->active[$this->key($key)][] = $value;
}
else
{
$this->active[$this->key($key)] .= $value;
}
}
else
{
if ($array)
{
$this->active[$this->key($key)] = [$value];
}
else
{
$this->active[$this->key($key)] = $value;
}
}
}
/**
* Remove content
*
* @param string $key The main string key
*
* @return void
* @since 3.2.0
*/
public function remove(string $key): void
{
unset($this->active[$this->key($key)]);
}
/**
* Model the key
*
* @param string $key The key to model
*
* @return string
* @since 3.2.0
*/
abstract protected function key(string $key): string;
}

View File

@ -1 +0,0 @@
[CUSTOMCODE=abstractionMapperSingle]

View File

@ -1,20 +0,0 @@
{
"add_head": "0",
"add_licensing_template": "2",
"extends": "0",
"guid": "c6bbc3ee-58e7-4463-adba-5c5ae839ee36",
"implements": [
"78527c29-24ad-4735-ad4c-ec33a4952d9b"
],
"load_selection": null,
"name": "MapperSingle",
"power_version": "1.0.0",
"system_name": "JCB.Abstraction.MapperSingle",
"type": "abstract class",
"use_selection": null,
"namespace": "VDM\\Joomla\\Componentbuilder.Abstraction.MapperSingle",
"description": "Compiler Mapper Single\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",
"composer": ""
}

View File

@ -7,7 +7,7 @@
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
```
# trait IsString (Details)
> namespace: **VDM\Joomla\Abstraction\StorageRegistry\Traits**
> namespace: **VDM\Joomla\Abstraction\Registry\Traits**
```uml
@startuml
class IsString << (T,Orange) >> #Turquoise {

View File

@ -9,7 +9,7 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace VDM\Joomla\Abstraction\StorageRegistry\Traits;
namespace VDM\Joomla\Abstraction\Registry\Traits;
/**

View File

@ -7,10 +7,10 @@
"load_selection": null,
"name": "IsString",
"power_version": "1.0.0",
"system_name": "VDM.Abstraction.StorageRegistry.Traits.IsString",
"system_name": "VDM.Abstraction.Registry.Traits.IsString",
"type": "trait",
"use_selection": null,
"namespace": "VDM\\Joomla\\Abstraction.StorageRegistry.Traits.IsString",
"namespace": "VDM\\Joomla\\Abstraction.Registry.Traits.IsString",
"description": "Is String Values\r\n\r\n@since 3.2.0",
"licensing_template": "\/**\r\n * @package Joomla.Component.Builder\r\n *\r\n * @created 4th September, 2022\r\n * @author Llewellyn van der Merwe <https:\/\/dev.vdm.io>\r\n * @git Joomla Component Builder <https:\/\/git.vdm.dev\/joomla\/Component-Builder>\r\n * @copyright Copyright (C) 2015 Vast Development Method. All rights reserved.\r\n * @license GNU General Public License version 2 or later; see LICENSE.txt\r\n *\/\r\n",
"head": "",

View File

@ -24,7 +24,7 @@
"11572d9b-e3d5-4b29-904c-9618d8f2bfd8": {
"name": "Count",
"type": "trait",
"namespace": "VDM\\Joomla\\Abstraction\\StorageRegistry\\Traits",
"namespace": "VDM\\Joomla\\Abstraction\\Registry\\Traits",
"code": "src\/11572d9b-e3d5-4b29-904c-9618d8f2bfd8\/code.php",
"power": "src\/11572d9b-e3d5-4b29-904c-9618d8f2bfd8\/code.power",
"settings": "src\/11572d9b-e3d5-4b29-904c-9618d8f2bfd8\/settings.json",
@ -35,7 +35,7 @@
"1198aecf-84c6-45d2-aea8-d531aa4afdfa": {
"name": "FormHelper",
"type": "abstract class",
"namespace": "VDM\\Joomla\\Componentbuilder\\Utilities",
"namespace": "VDM\\Joomla\\Utilities",
"code": "src\/1198aecf-84c6-45d2-aea8-d531aa4afdfa\/code.php",
"power": "src\/1198aecf-84c6-45d2-aea8-d531aa4afdfa\/code.power",
"settings": "src\/1198aecf-84c6-45d2-aea8-d531aa4afdfa\/settings.json",
@ -68,7 +68,7 @@
"215b35ac-1b26-4838-bbcf-d1fdbbd9353f": {
"name": "InArray",
"type": "trait",
"namespace": "VDM\\Joomla\\Abstraction\\StorageRegistry\\Traits",
"namespace": "VDM\\Joomla\\Abstraction\\Registry\\Traits",
"code": "src\/215b35ac-1b26-4838-bbcf-d1fdbbd9353f\/code.php",
"power": "src\/215b35ac-1b26-4838-bbcf-d1fdbbd9353f\/code.power",
"settings": "src\/215b35ac-1b26-4838-bbcf-d1fdbbd9353f\/settings.json",
@ -121,7 +121,7 @@
"guid": "3cf76fbf-fd95-4a33-878e-7aff6d36b7f6"
},
"43134867-5cb8-4280-9be8-309fd2fd135f": {
"name": "ActiveStorageRegistry",
"name": "ActiveRegistry",
"type": "abstract class",
"namespace": "VDM\\Joomla\\Abstraction",
"code": "src\/43134867-5cb8-4280-9be8-309fd2fd135f\/code.php",
@ -131,17 +131,6 @@
"spk": "Super__43134867_5cb8_4280_9be8_309fd2fd135f__Power",
"guid": "43134867-5cb8-4280-9be8-309fd2fd135f"
},
"44a3367c-f9e4-406b-b396-0f452bde0f03": {
"name": "Mapper",
"type": "abstract class",
"namespace": "VDM\\Joomla\\Componentbuilder\\Abstraction",
"code": "src\/44a3367c-f9e4-406b-b396-0f452bde0f03\/code.php",
"power": "src\/44a3367c-f9e4-406b-b396-0f452bde0f03\/code.power",
"settings": "src\/44a3367c-f9e4-406b-b396-0f452bde0f03\/settings.json",
"path": "src\/44a3367c-f9e4-406b-b396-0f452bde0f03",
"spk": "Super__44a3367c_f9e4_406b_b396_0f452bde0f03__Power",
"guid": "44a3367c-f9e4-406b-b396-0f452bde0f03"
},
"4815e1c7-a433-443d-a112-d1e03d7df84b": {
"name": "Database",
"type": "class",
@ -164,17 +153,6 @@
"spk": "Super__4b225c51_d293_48e4_b3f6_5136cf5c3f18__Power",
"guid": "4b225c51-d293-48e4-b3f6-5136cf5c3f18"
},
"4d4e76e9-12d9-4d19-b58c-b88974b2586a": {
"name": "MapperDouble",
"type": "abstract class",
"namespace": "VDM\\Joomla\\Componentbuilder\\Abstraction",
"code": "src\/4d4e76e9-12d9-4d19-b58c-b88974b2586a\/code.php",
"power": "src\/4d4e76e9-12d9-4d19-b58c-b88974b2586a\/code.power",
"settings": "src\/4d4e76e9-12d9-4d19-b58c-b88974b2586a\/settings.json",
"path": "src\/4d4e76e9-12d9-4d19-b58c-b88974b2586a",
"spk": "Super__4d4e76e9_12d9_4d19_b58c_b88974b2586a__Power",
"guid": "4d4e76e9-12d9-4d19-b58c-b88974b2586a"
},
"524eb8f6-38d4-47dc-92ad-98b94e099ac0": {
"name": "Insert",
"type": "final class",
@ -189,7 +167,7 @@
"52a1d14f-304a-431c-8fa4-411179942db5": {
"name": "VarExport",
"type": "trait",
"namespace": "VDM\\Joomla\\Abstraction\\StorageRegistry\\Traits",
"namespace": "VDM\\Joomla\\Abstraction\\Registry\\Traits",
"code": "src\/52a1d14f-304a-431c-8fa4-411179942db5\/code.php",
"power": "src\/52a1d14f-304a-431c-8fa4-411179942db5\/code.power",
"settings": "src\/52a1d14f-304a-431c-8fa4-411179942db5\/settings.json",
@ -211,7 +189,7 @@
"59b1a2ea-d77e-4040-ac8c-e65cd8743e9b": {
"name": "GetString",
"type": "trait",
"namespace": "VDM\\Joomla\\Abstraction\\StorageRegistry\\Traits",
"namespace": "VDM\\Joomla\\Abstraction\\Registry\\Traits",
"code": "src\/59b1a2ea-d77e-4040-ac8c-e65cd8743e9b\/code.php",
"power": "src\/59b1a2ea-d77e-4040-ac8c-e65cd8743e9b\/code.power",
"settings": "src\/59b1a2ea-d77e-4040-ac8c-e65cd8743e9b\/settings.json",
@ -242,7 +220,7 @@
"guid": "64a6ff6c-069c-4a11-a76b-db5e36c27690"
},
"64e291c2-11f1-423d-a44d-837cc12cc017": {
"name": "Storageregistryinterface",
"name": "Registryinterface",
"type": "interface",
"namespace": "VDM\\Joomla\\Interfaces",
"code": "src\/64e291c2-11f1-423d-a44d-837cc12cc017\/code.php",
@ -274,17 +252,6 @@
"spk": "Super__7179fde6_1e51_4b51_8545_7ca18f74a0f4__Power",
"guid": "7179fde6-1e51-4b51-8545-7ca18f74a0f4"
},
"7921a2b3-b58c-4184-af3f-f58094f695a8": {
"name": "Mapperdoublejoininterface",
"type": "interface",
"namespace": "VDM\\Joomla\\Componentbuilder\\Interfaces",
"code": "src\/7921a2b3-b58c-4184-af3f-f58094f695a8\/code.php",
"power": "src\/7921a2b3-b58c-4184-af3f-f58094f695a8\/code.power",
"settings": "src\/7921a2b3-b58c-4184-af3f-f58094f695a8\/settings.json",
"path": "src\/7921a2b3-b58c-4184-af3f-f58094f695a8",
"spk": "Super__7921a2b3_b58c_4184_af3f_f58094f695a8__Power",
"guid": "7921a2b3-b58c-4184-af3f-f58094f695a8"
},
"79d765b3-7319-4988-9730-446c7f347020": {
"name": "Utilities",
"type": "trait",
@ -299,7 +266,7 @@
"7d494d91-ab60-43cd-aecf-d50e07f7f30e": {
"name": "ToString",
"type": "trait",
"namespace": "VDM\\Joomla\\Abstraction\\StorageRegistry\\Traits",
"namespace": "VDM\\Joomla\\Abstraction\\Registry\\Traits",
"code": "src\/7d494d91-ab60-43cd-aecf-d50e07f7f30e\/code.php",
"power": "src\/7d494d91-ab60-43cd-aecf-d50e07f7f30e\/code.power",
"settings": "src\/7d494d91-ab60-43cd-aecf-d50e07f7f30e\/settings.json",
@ -308,7 +275,7 @@
"guid": "7d494d91-ab60-43cd-aecf-d50e07f7f30e"
},
"7e822c03-1b20-41d1-9427-f5b8d5836af7": {
"name": "StorageRegistry",
"name": "Registry",
"type": "abstract class",
"namespace": "VDM\\Joomla\\Abstraction",
"code": "src\/7e822c03-1b20-41d1-9427-f5b8d5836af7\/code.php",
@ -396,7 +363,7 @@
"guid": "ad12ca1c-d3ce-4e7f-88c5-c6c92bdedc48"
},
"af0eedbe-603b-4671-8e5a-28165d88254b": {
"name": "Activestorageregistryinterface",
"name": "Activeregistryinterface",
"type": "interface",
"namespace": "VDM\\Joomla\\Interfaces",
"code": "src\/af0eedbe-603b-4671-8e5a-28165d88254b\/code.php",
@ -428,16 +395,16 @@
"spk": "Super__bfd1d6d5_56c1_4fe9_9fee_1c5910e1f5d8__Power",
"guid": "bfd1d6d5-56c1-4fe9-9fee-1c5910e1f5d8"
},
"c6bbc3ee-58e7-4463-adba-5c5ae839ee36": {
"name": "MapperSingle",
"type": "abstract class",
"namespace": "VDM\\Joomla\\Componentbuilder\\Abstraction",
"code": "src\/c6bbc3ee-58e7-4463-adba-5c5ae839ee36\/code.php",
"power": "src\/c6bbc3ee-58e7-4463-adba-5c5ae839ee36\/code.power",
"settings": "src\/c6bbc3ee-58e7-4463-adba-5c5ae839ee36\/settings.json",
"path": "src\/c6bbc3ee-58e7-4463-adba-5c5ae839ee36",
"spk": "Super__c6bbc3ee_58e7_4463_adba_5c5ae839ee36__Power",
"guid": "c6bbc3ee-58e7-4463-adba-5c5ae839ee36"
"c09e8968-c767-4175-bb3d-8432f206a2c7": {
"name": "IsArray",
"type": "trait",
"namespace": "VDM\\Joomla\\Abstraction\\Registry\\Traits",
"code": "src\/c09e8968-c767-4175-bb3d-8432f206a2c7\/code.php",
"power": "src\/c09e8968-c767-4175-bb3d-8432f206a2c7\/code.power",
"settings": "src\/c09e8968-c767-4175-bb3d-8432f206a2c7\/settings.json",
"path": "src\/c09e8968-c767-4175-bb3d-8432f206a2c7",
"spk": "Super__c09e8968_c767_4175_bb3d_8432f206a2c7__Power",
"guid": "c09e8968-c767-4175-bb3d-8432f206a2c7"
},
"caf33c5d-858c-4f9a-894f-ab302ec5445a": {
"name": "FactoryInterface",
@ -508,7 +475,7 @@
"ff7d0111-8f79-42aa-ac14-b53ba2c49369": {
"name": "IsString",
"type": "trait",
"namespace": "VDM\\Joomla\\Abstraction\\StorageRegistry\\Traits",
"namespace": "VDM\\Joomla\\Abstraction\\Registry\\Traits",
"code": "src\/ff7d0111-8f79-42aa-ac14-b53ba2c49369\/code.php",
"power": "src\/ff7d0111-8f79-42aa-ac14-b53ba2c49369\/code.power",
"settings": "src\/ff7d0111-8f79-42aa-ac14-b53ba2c49369\/settings.json",