@twin.org/engine-types 0.0.2-next.9 → 0.0.3-next.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/components/attestation.js +60 -0
- package/dist/es/components/attestation.js.map +1 -0
- package/dist/es/components/auditableItemGraph.js +44 -0
- package/dist/es/components/auditableItemGraph.js.map +1 -0
- package/dist/es/components/auditableItemStream.js +44 -0
- package/dist/es/components/auditableItemStream.js.map +1 -0
- package/dist/es/components/authenticationGenerator.js +30 -0
- package/dist/es/components/authenticationGenerator.js.map +1 -0
- package/dist/es/components/backgroundTask.js +31 -0
- package/dist/es/components/backgroundTask.js.map +1 -0
- package/dist/es/components/blobStorage.js +143 -0
- package/dist/es/components/blobStorage.js.map +1 -0
- package/dist/es/components/contextIdHandler.js +31 -0
- package/dist/es/components/contextIdHandler.js.map +1 -0
- package/dist/es/components/dataProcessing.js +89 -0
- package/dist/es/components/dataProcessing.js.map +1 -0
- package/dist/es/components/dataSpaceConnector.js +51 -0
- package/dist/es/components/dataSpaceConnector.js.map +1 -0
- package/dist/es/components/documentManagement.js +37 -0
- package/dist/es/components/documentManagement.js.map +1 -0
- package/dist/es/components/entityStorage.js +226 -0
- package/dist/es/components/entityStorage.js.map +1 -0
- package/dist/es/components/eventBus.js +63 -0
- package/dist/es/components/eventBus.js.map +1 -0
- package/dist/es/components/faucet.js +41 -0
- package/dist/es/components/faucet.js.map +1 -0
- package/dist/es/components/federatedCatalogue.js +38 -0
- package/dist/es/components/federatedCatalogue.js.map +1 -0
- package/dist/es/components/federatedCatalogueFilter.js +31 -0
- package/dist/es/components/federatedCatalogueFilter.js.map +1 -0
- package/dist/es/components/identity.js +75 -0
- package/dist/es/components/identity.js.map +1 -0
- package/dist/es/components/identityProfile.js +64 -0
- package/dist/es/components/identityProfile.js.map +1 -0
- package/dist/es/components/identityResolver.js +87 -0
- package/dist/es/components/identityResolver.js.map +1 -0
- package/dist/es/components/immutableProof.js +45 -0
- package/dist/es/components/immutableProof.js.map +1 -0
- package/dist/es/components/logging.js +73 -0
- package/dist/es/components/logging.js.map +1 -0
- package/dist/es/components/messaging.js +177 -0
- package/dist/es/components/messaging.js.map +1 -0
- package/dist/es/components/nft.js +78 -0
- package/dist/es/components/nft.js.map +1 -0
- package/dist/es/components/rightsManagementDap.js +36 -0
- package/dist/es/components/rightsManagementDap.js.map +1 -0
- package/dist/es/components/rightsManagementDarp.js +30 -0
- package/dist/es/components/rightsManagementDarp.js.map +1 -0
- package/dist/es/components/rightsManagementDataAccessHandler.js +27 -0
- package/dist/es/components/rightsManagementDataAccessHandler.js.map +1 -0
- package/dist/es/components/rightsManagementPap.js +41 -0
- package/dist/es/components/rightsManagementPap.js.map +1 -0
- package/dist/es/components/rightsManagementPdp.js +32 -0
- package/dist/es/components/rightsManagementPdp.js.map +1 -0
- package/dist/es/components/rightsManagementPep.js +30 -0
- package/dist/es/components/rightsManagementPep.js.map +1 -0
- package/dist/es/components/rightsManagementPip.js +29 -0
- package/dist/es/components/rightsManagementPip.js.map +1 -0
- package/dist/es/components/rightsManagementPmp.js +30 -0
- package/dist/es/components/rightsManagementPmp.js.map +1 -0
- package/dist/es/components/rightsManagementPnap.js +42 -0
- package/dist/es/components/rightsManagementPnap.js.map +1 -0
- package/dist/es/components/rightsManagementPnp.js +41 -0
- package/dist/es/components/rightsManagementPnp.js.map +1 -0
- package/dist/es/components/rightsManagementPolicyArbiter.js +27 -0
- package/dist/es/components/rightsManagementPolicyArbiter.js.map +1 -0
- package/dist/es/components/rightsManagementPolicyEnforcementProcessor.js +27 -0
- package/dist/es/components/rightsManagementPolicyEnforcementProcessor.js.map +1 -0
- package/dist/es/components/rightsManagementPolicyExecutionAction.js +27 -0
- package/dist/es/components/rightsManagementPolicyExecutionAction.js.map +1 -0
- package/dist/es/components/rightsManagementPolicyInformationSource.js +35 -0
- package/dist/es/components/rightsManagementPolicyInformationSource.js.map +1 -0
- package/dist/es/components/rightsManagementPolicyNegotiator.js +27 -0
- package/dist/es/components/rightsManagementPolicyNegotiator.js.map +1 -0
- package/dist/es/components/rightsManagementPolicyRequester.js +27 -0
- package/dist/es/components/rightsManagementPolicyRequester.js.map +1 -0
- package/dist/es/components/rightsManagementPxp.js +29 -0
- package/dist/es/components/rightsManagementPxp.js.map +1 -0
- package/dist/es/components/synchronisedStorage.js +47 -0
- package/dist/es/components/synchronisedStorage.js.map +1 -0
- package/dist/es/components/taskScheduler.js +27 -0
- package/dist/es/components/taskScheduler.js.map +1 -0
- package/dist/es/components/telemetry.js +71 -0
- package/dist/es/components/telemetry.js.map +1 -0
- package/dist/es/components/tenant.js +32 -0
- package/dist/es/components/tenant.js.map +1 -0
- package/dist/es/components/trust.js +29 -0
- package/dist/es/components/trust.js.map +1 -0
- package/dist/es/components/trustGenerator.js +28 -0
- package/dist/es/components/trustGenerator.js.map +1 -0
- package/dist/es/components/trustVerifier.js +28 -0
- package/dist/es/components/trustVerifier.js.map +1 -0
- package/dist/es/components/vault.js +33 -0
- package/dist/es/components/vault.js.map +1 -0
- package/dist/es/components/verifiableStorage.js +79 -0
- package/dist/es/components/verifiableStorage.js.map +1 -0
- package/dist/es/components/wallet.js +47 -0
- package/dist/es/components/wallet.js.map +1 -0
- package/dist/es/index.js +188 -0
- package/dist/es/index.js.map +1 -0
- package/dist/es/models/IEngineConfig.js +2 -0
- package/dist/es/models/IEngineConfig.js.map +1 -0
- package/dist/es/models/config/attestationComponentConfig.js +2 -0
- package/dist/es/models/config/attestationComponentConfig.js.map +1 -0
- package/dist/es/models/config/attestationConnectorConfig.js +2 -0
- package/dist/es/models/config/attestationConnectorConfig.js.map +1 -0
- package/dist/es/models/config/auditableItemGraphComponentConfig.js +2 -0
- package/dist/es/models/config/auditableItemGraphComponentConfig.js.map +1 -0
- package/dist/es/models/config/auditableItemStreamComponentConfig.js +2 -0
- package/dist/es/models/config/auditableItemStreamComponentConfig.js.map +1 -0
- package/dist/es/models/config/authenticationGeneratorComponentConfig.js +2 -0
- package/dist/es/models/config/authenticationGeneratorComponentConfig.js.map +1 -0
- package/dist/es/models/config/backgroundTaskComponentConfig.js +2 -0
- package/dist/es/models/config/backgroundTaskComponentConfig.js.map +1 -0
- package/dist/es/models/config/blobStorageComponentConfig.js +2 -0
- package/dist/es/models/config/blobStorageComponentConfig.js.map +1 -0
- package/dist/es/models/config/blobStorageConnectorConfig.js +2 -0
- package/dist/es/models/config/blobStorageConnectorConfig.js.map +1 -0
- package/dist/es/models/config/contextIdHandlerComponentConfig.js +2 -0
- package/dist/es/models/config/contextIdHandlerComponentConfig.js.map +1 -0
- package/dist/es/models/config/dataConverterConnectorConfig.js +2 -0
- package/dist/es/models/config/dataConverterConnectorConfig.js.map +1 -0
- package/dist/es/models/config/dataExtractorConnectorConfig.js +2 -0
- package/dist/es/models/config/dataExtractorConnectorConfig.js.map +1 -0
- package/dist/es/models/config/dataProcessingComponentConfig.js +2 -0
- package/dist/es/models/config/dataProcessingComponentConfig.js.map +1 -0
- package/dist/es/models/config/dataSpaceConnectorComponentConfig.js +2 -0
- package/dist/es/models/config/dataSpaceConnectorComponentConfig.js.map +1 -0
- package/dist/es/models/config/dltConfig.js +2 -0
- package/dist/es/models/config/dltConfig.js.map +1 -0
- package/dist/es/models/config/documentManagementComponentConfig.js +2 -0
- package/dist/es/models/config/documentManagementComponentConfig.js.map +1 -0
- package/dist/es/models/config/entityStorageComponentConfig.js +2 -0
- package/dist/es/models/config/entityStorageComponentConfig.js.map +1 -0
- package/dist/es/models/config/entityStorageConnectorConfig.js +2 -0
- package/dist/es/models/config/entityStorageConnectorConfig.js.map +1 -0
- package/dist/es/models/config/eventBusComponentConfig.js +2 -0
- package/dist/es/models/config/eventBusComponentConfig.js.map +1 -0
- package/dist/es/models/config/eventBusConnectorConfig.js +2 -0
- package/dist/es/models/config/eventBusConnectorConfig.js.map +1 -0
- package/dist/es/models/config/faucetConnectorConfig.js +2 -0
- package/dist/es/models/config/faucetConnectorConfig.js.map +1 -0
- package/dist/es/models/config/federatedCatalogueComponentConfig.js +2 -0
- package/dist/es/models/config/federatedCatalogueComponentConfig.js.map +1 -0
- package/dist/es/models/config/federatedCatalogueFilterComponentConfig.js +2 -0
- package/dist/es/models/config/federatedCatalogueFilterComponentConfig.js.map +1 -0
- package/dist/es/models/config/identityComponentConfig.js +2 -0
- package/dist/es/models/config/identityComponentConfig.js.map +1 -0
- package/dist/es/models/config/identityConnectorConfig.js +2 -0
- package/dist/es/models/config/identityConnectorConfig.js.map +1 -0
- package/dist/es/models/config/identityProfileComponentConfig.js +2 -0
- package/dist/es/models/config/identityProfileComponentConfig.js.map +1 -0
- package/dist/es/models/config/identityProfileConnectorConfig.js +2 -0
- package/dist/es/models/config/identityProfileConnectorConfig.js.map +1 -0
- package/dist/es/models/config/identityResolverComponentConfig.js +2 -0
- package/dist/es/models/config/identityResolverComponentConfig.js.map +1 -0
- package/dist/es/models/config/identityResolverConnectorConfig.js +2 -0
- package/dist/es/models/config/identityResolverConnectorConfig.js.map +1 -0
- package/dist/es/models/config/immutableProofComponentConfig.js +2 -0
- package/dist/es/models/config/immutableProofComponentConfig.js.map +1 -0
- package/dist/es/models/config/loggingComponentConfig.js +2 -0
- package/dist/es/models/config/loggingComponentConfig.js.map +1 -0
- package/dist/es/models/config/loggingConnectorConfig.js +2 -0
- package/dist/es/models/config/loggingConnectorConfig.js.map +1 -0
- package/dist/es/models/config/messagingAdminComponentConfig.js +2 -0
- package/dist/es/models/config/messagingAdminComponentConfig.js.map +1 -0
- package/dist/es/models/config/messagingComponentConfig.js +2 -0
- package/dist/es/models/config/messagingComponentConfig.js.map +1 -0
- package/dist/es/models/config/messagingEmailConnectorConfig.js +2 -0
- package/dist/es/models/config/messagingEmailConnectorConfig.js.map +1 -0
- package/dist/es/models/config/messagingPushNotificationConnectorConfig.js +2 -0
- package/dist/es/models/config/messagingPushNotificationConnectorConfig.js.map +1 -0
- package/dist/es/models/config/messagingSmsConnectorConfig.js +2 -0
- package/dist/es/models/config/messagingSmsConnectorConfig.js.map +1 -0
- package/dist/es/models/config/nftComponentConfig.js +2 -0
- package/dist/es/models/config/nftComponentConfig.js.map +1 -0
- package/dist/es/models/config/nftConnectorConfig.js +2 -0
- package/dist/es/models/config/nftConnectorConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementDapComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementDapComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementDarpComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementDarpComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementDataAccessHandlerComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementDataAccessHandlerComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPapComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPapComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPdpComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPdpComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPepComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPepComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPipComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPipComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPmpComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPmpComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPnapComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPnapComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPnpComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPnpComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPolicyArbiterComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPolicyArbiterComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPolicyEnforcementProcessorComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPolicyEnforcementProcessorComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPolicyExecutionActionComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPolicyExecutionActionComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPolicyInformationSourceComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPolicyInformationSourceComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPolicyNegotiatorComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPolicyNegotiatorComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPolicyRequesterComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPolicyRequesterComponentConfig.js.map +1 -0
- package/dist/es/models/config/rightsManagementPxpComponentConfig.js +2 -0
- package/dist/es/models/config/rightsManagementPxpComponentConfig.js.map +1 -0
- package/dist/es/models/config/synchronisedStorageComponentConfig.js +2 -0
- package/dist/es/models/config/synchronisedStorageComponentConfig.js.map +1 -0
- package/dist/es/models/config/taskSchedulerComponentConfig.js +2 -0
- package/dist/es/models/config/taskSchedulerComponentConfig.js.map +1 -0
- package/dist/es/models/config/telemetryComponentConfig.js +2 -0
- package/dist/es/models/config/telemetryComponentConfig.js.map +1 -0
- package/dist/es/models/config/telemetryConnectorConfig.js +2 -0
- package/dist/es/models/config/telemetryConnectorConfig.js.map +1 -0
- package/dist/es/models/config/tenantAdminComponentConfig.js +2 -0
- package/dist/es/models/config/tenantAdminComponentConfig.js.map +1 -0
- package/dist/es/models/config/trustComponentConfig.js +2 -0
- package/dist/es/models/config/trustComponentConfig.js.map +1 -0
- package/dist/es/models/config/trustGeneratorComponentConfig.js +2 -0
- package/dist/es/models/config/trustGeneratorComponentConfig.js.map +1 -0
- package/dist/es/models/config/trustVerifierComponentConfig.js +2 -0
- package/dist/es/models/config/trustVerifierComponentConfig.js.map +1 -0
- package/dist/es/models/config/vaultConnectorConfig.js +2 -0
- package/dist/es/models/config/vaultConnectorConfig.js.map +1 -0
- package/dist/es/models/config/verifiableStorageComponentConfig.js +2 -0
- package/dist/es/models/config/verifiableStorageComponentConfig.js.map +1 -0
- package/dist/es/models/config/verifiableStorageConnectorConfig.js +2 -0
- package/dist/es/models/config/verifiableStorageConnectorConfig.js.map +1 -0
- package/dist/es/models/config/walletConnectorConfig.js +2 -0
- package/dist/es/models/config/walletConnectorConfig.js.map +1 -0
- package/dist/es/models/types/attestationComponentType.js +17 -0
- package/dist/es/models/types/attestationComponentType.js.map +1 -0
- package/dist/es/models/types/attestationConnectorType.js +13 -0
- package/dist/es/models/types/attestationConnectorType.js.map +1 -0
- package/dist/es/models/types/auditableItemGraphComponentType.js +17 -0
- package/dist/es/models/types/auditableItemGraphComponentType.js.map +1 -0
- package/dist/es/models/types/auditableItemStreamComponentType.js +17 -0
- package/dist/es/models/types/auditableItemStreamComponentType.js.map +1 -0
- package/dist/es/models/types/authenticationGeneratorComponentType.js +13 -0
- package/dist/es/models/types/authenticationGeneratorComponentType.js.map +1 -0
- package/dist/es/models/types/backgroundTaskComponentType.js +13 -0
- package/dist/es/models/types/backgroundTaskComponentType.js.map +1 -0
- package/dist/es/models/types/blobStorageComponentType.js +17 -0
- package/dist/es/models/types/blobStorageComponentType.js.map +1 -0
- package/dist/es/models/types/blobStorageConnectorType.js +33 -0
- package/dist/es/models/types/blobStorageConnectorType.js.map +1 -0
- package/dist/es/models/types/contextIdHandlerComponentType.js +17 -0
- package/dist/es/models/types/contextIdHandlerComponentType.js.map +1 -0
- package/dist/es/models/types/dataConverterConnectorType.js +17 -0
- package/dist/es/models/types/dataConverterConnectorType.js.map +1 -0
- package/dist/es/models/types/dataExtractorConnectorType.js +13 -0
- package/dist/es/models/types/dataExtractorConnectorType.js.map +1 -0
- package/dist/es/models/types/dataProcessingComponentType.js +17 -0
- package/dist/es/models/types/dataProcessingComponentType.js.map +1 -0
- package/dist/es/models/types/dataSpaceConnectorComponentType.js +21 -0
- package/dist/es/models/types/dataSpaceConnectorComponentType.js.map +1 -0
- package/dist/es/models/types/dltConfigType.js +13 -0
- package/dist/es/models/types/dltConfigType.js.map +1 -0
- package/dist/es/models/types/documentManagementComponentType.js +17 -0
- package/dist/es/models/types/documentManagementComponentType.js.map +1 -0
- package/dist/es/models/types/entityStorageComponentType.js +17 -0
- package/dist/es/models/types/entityStorageComponentType.js.map +1 -0
- package/dist/es/models/types/entityStorageConnectorType.js +49 -0
- package/dist/es/models/types/entityStorageConnectorType.js.map +1 -0
- package/dist/es/models/types/eventBusComponentType.js +17 -0
- package/dist/es/models/types/eventBusComponentType.js.map +1 -0
- package/dist/es/models/types/eventBusConnectorType.js +13 -0
- package/dist/es/models/types/eventBusConnectorType.js.map +1 -0
- package/dist/es/models/types/faucetConnectorType.js +17 -0
- package/dist/es/models/types/faucetConnectorType.js.map +1 -0
- package/dist/es/models/types/federatedCatalogueComponentType.js +17 -0
- package/dist/es/models/types/federatedCatalogueComponentType.js.map +1 -0
- package/dist/es/models/types/federatedCatalogueFilterComponentType.js +13 -0
- package/dist/es/models/types/federatedCatalogueFilterComponentType.js.map +1 -0
- package/dist/es/models/types/identityComponentType.js +17 -0
- package/dist/es/models/types/identityComponentType.js.map +1 -0
- package/dist/es/models/types/identityConnectorType.js +17 -0
- package/dist/es/models/types/identityConnectorType.js.map +1 -0
- package/dist/es/models/types/identityProfileComponentType.js +17 -0
- package/dist/es/models/types/identityProfileComponentType.js.map +1 -0
- package/dist/es/models/types/identityProfileConnectorType.js +13 -0
- package/dist/es/models/types/identityProfileConnectorType.js.map +1 -0
- package/dist/es/models/types/identityResolverComponentType.js +17 -0
- package/dist/es/models/types/identityResolverComponentType.js.map +1 -0
- package/dist/es/models/types/identityResolverConnectorType.js +21 -0
- package/dist/es/models/types/identityResolverConnectorType.js.map +1 -0
- package/dist/es/models/types/immutableProofComponentType.js +17 -0
- package/dist/es/models/types/immutableProofComponentType.js.map +1 -0
- package/dist/es/models/types/loggingComponentType.js +17 -0
- package/dist/es/models/types/loggingComponentType.js.map +1 -0
- package/dist/es/models/types/loggingConnectorType.js +21 -0
- package/dist/es/models/types/loggingConnectorType.js.map +1 -0
- package/dist/es/models/types/messagingAdminComponentType.js +13 -0
- package/dist/es/models/types/messagingAdminComponentType.js.map +1 -0
- package/dist/es/models/types/messagingComponentType.js +13 -0
- package/dist/es/models/types/messagingComponentType.js.map +1 -0
- package/dist/es/models/types/messagingEmailConnectorType.js +17 -0
- package/dist/es/models/types/messagingEmailConnectorType.js.map +1 -0
- package/dist/es/models/types/messagingPushNotificationConnectorType.js +17 -0
- package/dist/es/models/types/messagingPushNotificationConnectorType.js.map +1 -0
- package/dist/es/models/types/messagingSmsConnectorType.js +17 -0
- package/dist/es/models/types/messagingSmsConnectorType.js.map +1 -0
- package/dist/es/models/types/nftComponentType.js +17 -0
- package/dist/es/models/types/nftComponentType.js.map +1 -0
- package/dist/es/models/types/nftConnectorType.js +17 -0
- package/dist/es/models/types/nftConnectorType.js.map +1 -0
- package/dist/es/models/types/rightsManagementDapComponentType.js +17 -0
- package/dist/es/models/types/rightsManagementDapComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementDarpComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementDarpComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementDataAccessHandlerComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementDataAccessHandlerComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPapComponentType.js +17 -0
- package/dist/es/models/types/rightsManagementPapComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPdpComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPdpComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPepComponentType.js +17 -0
- package/dist/es/models/types/rightsManagementPepComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPipComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPipComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPmpComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPmpComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPnapComponentType.js +17 -0
- package/dist/es/models/types/rightsManagementPnapComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPnpComponentType.js +17 -0
- package/dist/es/models/types/rightsManagementPnpComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPolicyArbiterComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPolicyArbiterComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPolicyEnforcementProcessorComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPolicyEnforcementProcessorComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPolicyExecutionActionComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPolicyExecutionActionComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPolicyInformationSourceComponentType.js +17 -0
- package/dist/es/models/types/rightsManagementPolicyInformationSourceComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPolicyNegotiatorComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPolicyNegotiatorComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPolicyRequesterComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPolicyRequesterComponentType.js.map +1 -0
- package/dist/es/models/types/rightsManagementPxpComponentType.js +13 -0
- package/dist/es/models/types/rightsManagementPxpComponentType.js.map +1 -0
- package/dist/es/models/types/synchronisedStorageComponentType.js +17 -0
- package/dist/es/models/types/synchronisedStorageComponentType.js.map +1 -0
- package/dist/es/models/types/taskSchedulerComponentType.js +13 -0
- package/dist/es/models/types/taskSchedulerComponentType.js.map +1 -0
- package/dist/es/models/types/telemetryComponentType.js +17 -0
- package/dist/es/models/types/telemetryComponentType.js.map +1 -0
- package/dist/es/models/types/telemetryConnectorType.js +13 -0
- package/dist/es/models/types/telemetryConnectorType.js.map +1 -0
- package/dist/es/models/types/tenantAdminComponentType.js +13 -0
- package/dist/es/models/types/tenantAdminComponentType.js.map +1 -0
- package/dist/es/models/types/trustComponentType.js +13 -0
- package/dist/es/models/types/trustComponentType.js.map +1 -0
- package/dist/es/models/types/trustGeneratorComponentType.js +13 -0
- package/dist/es/models/types/trustGeneratorComponentType.js.map +1 -0
- package/dist/es/models/types/trustVerifierComponentType.js +13 -0
- package/dist/es/models/types/trustVerifierComponentType.js.map +1 -0
- package/dist/es/models/types/vaultConnectorType.js +17 -0
- package/dist/es/models/types/vaultConnectorType.js.map +1 -0
- package/dist/es/models/types/verifiableStorageComponentType.js +17 -0
- package/dist/es/models/types/verifiableStorageComponentType.js.map +1 -0
- package/dist/es/models/types/verifiableStorageConnectorType.js +17 -0
- package/dist/es/models/types/verifiableStorageConnectorType.js.map +1 -0
- package/dist/es/models/types/walletConnectorType.js +17 -0
- package/dist/es/models/types/walletConnectorType.js.map +1 -0
- package/dist/es/utils/engineTypeHelper.js +32 -0
- package/dist/es/utils/engineTypeHelper.js.map +1 -0
- package/dist/types/components/attestation.d.ts +17 -11
- package/dist/types/components/auditableItemGraph.d.ts +9 -6
- package/dist/types/components/auditableItemStream.d.ts +9 -6
- package/dist/types/components/authenticationGenerator.d.ts +17 -0
- package/dist/types/components/backgroundTask.d.ts +10 -7
- package/dist/types/components/blobStorage.d.ts +17 -11
- package/dist/types/components/contextIdHandler.d.ts +16 -0
- package/dist/types/components/dataProcessing.d.ts +24 -16
- package/dist/types/components/dataSpaceConnector.d.ts +16 -0
- package/dist/types/components/documentManagement.d.ts +9 -6
- package/dist/types/components/entityStorage.d.ts +12 -8
- package/dist/types/components/eventBus.d.ts +17 -11
- package/dist/types/components/faucet.d.ts +10 -6
- package/dist/types/components/federatedCatalogue.d.ts +9 -6
- package/dist/types/components/federatedCatalogueFilter.d.ts +17 -0
- package/dist/types/components/identity.d.ts +17 -11
- package/dist/types/components/identityProfile.d.ts +17 -11
- package/dist/types/components/identityResolver.d.ts +17 -11
- package/dist/types/components/immutableProof.d.ts +9 -6
- package/dist/types/components/logging.d.ts +17 -11
- package/dist/types/components/messaging.d.ts +44 -21
- package/dist/types/components/nft.d.ts +17 -11
- package/dist/types/components/rightsManagementDap.d.ts +16 -0
- package/dist/types/components/rightsManagementDarp.d.ts +16 -0
- package/dist/types/components/rightsManagementDataAccessHandler.d.ts +17 -0
- package/dist/types/components/rightsManagementPap.d.ts +9 -6
- package/dist/types/components/rightsManagementPdp.d.ts +9 -6
- package/dist/types/components/rightsManagementPep.d.ts +9 -6
- package/dist/types/components/rightsManagementPip.d.ts +9 -6
- package/dist/types/components/rightsManagementPmp.d.ts +9 -6
- package/dist/types/components/rightsManagementPnap.d.ts +16 -0
- package/dist/types/components/rightsManagementPnp.d.ts +16 -0
- package/dist/types/components/rightsManagementPolicyArbiter.d.ts +17 -0
- package/dist/types/components/rightsManagementPolicyEnforcementProcessor.d.ts +17 -0
- package/dist/types/components/rightsManagementPolicyExecutionAction.d.ts +17 -0
- package/dist/types/components/rightsManagementPolicyInformationSource.d.ts +17 -0
- package/dist/types/components/rightsManagementPolicyNegotiator.d.ts +17 -0
- package/dist/types/components/rightsManagementPolicyRequester.d.ts +17 -0
- package/dist/types/components/rightsManagementPxp.d.ts +9 -6
- package/dist/types/components/synchronisedStorage.d.ts +9 -6
- package/dist/types/components/taskScheduler.d.ts +9 -6
- package/dist/types/components/telemetry.d.ts +17 -11
- package/dist/types/components/tenant.d.ts +16 -0
- package/dist/types/components/trust.d.ts +16 -0
- package/dist/types/components/trustGenerator.d.ts +17 -0
- package/dist/types/components/trustVerifier.d.ts +17 -0
- package/dist/types/components/vault.d.ts +10 -6
- package/dist/types/components/verifiableStorage.d.ts +17 -11
- package/dist/types/components/wallet.d.ts +10 -16
- package/dist/types/index.d.ts +185 -128
- package/dist/types/models/IEngineConfig.d.ts +147 -52
- package/dist/types/models/config/attestationComponentConfig.d.ts +1 -1
- package/dist/types/models/config/attestationConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/auditableItemGraphComponentConfig.d.ts +1 -1
- package/dist/types/models/config/auditableItemStreamComponentConfig.d.ts +1 -1
- package/dist/types/models/config/authenticationGeneratorComponentConfig.d.ts +9 -0
- package/dist/types/models/config/backgroundTaskComponentConfig.d.ts +9 -0
- package/dist/types/models/config/blobStorageComponentConfig.d.ts +1 -1
- package/dist/types/models/config/blobStorageConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/contextIdHandlerComponentConfig.d.ts +11 -0
- package/dist/types/models/config/dataConverterConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/dataExtractorConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/dataProcessingComponentConfig.d.ts +1 -1
- package/dist/types/models/config/dataSpaceConnectorComponentConfig.d.ts +17 -0
- package/dist/types/models/config/dltConfig.d.ts +1 -1
- package/dist/types/models/config/documentManagementComponentConfig.d.ts +1 -1
- package/dist/types/models/config/entityStorageComponentConfig.d.ts +4 -2
- package/dist/types/models/config/entityStorageConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/eventBusComponentConfig.d.ts +1 -1
- package/dist/types/models/config/eventBusConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/faucetConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/federatedCatalogueComponentConfig.d.ts +1 -1
- package/dist/types/models/config/federatedCatalogueFilterComponentConfig.d.ts +9 -0
- package/dist/types/models/config/identityComponentConfig.d.ts +1 -1
- package/dist/types/models/config/identityConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/identityProfileComponentConfig.d.ts +1 -1
- package/dist/types/models/config/identityProfileConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/identityResolverComponentConfig.d.ts +1 -1
- package/dist/types/models/config/identityResolverConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/immutableProofComponentConfig.d.ts +1 -1
- package/dist/types/models/config/loggingComponentConfig.d.ts +1 -1
- package/dist/types/models/config/loggingConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/messagingAdminComponentConfig.d.ts +9 -0
- package/dist/types/models/config/messagingComponentConfig.d.ts +1 -1
- package/dist/types/models/config/messagingEmailConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/messagingPushNotificationConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/messagingSmsConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/nftComponentConfig.d.ts +1 -1
- package/dist/types/models/config/nftConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/rightsManagementDapComponentConfig.d.ts +16 -0
- package/dist/types/models/config/rightsManagementDarpComponentConfig.d.ts +9 -0
- package/dist/types/models/config/rightsManagementDataAccessHandlerComponentConfig.d.ts +9 -0
- package/dist/types/models/config/rightsManagementPapComponentConfig.d.ts +7 -3
- package/dist/types/models/config/rightsManagementPdpComponentConfig.d.ts +3 -3
- package/dist/types/models/config/rightsManagementPepComponentConfig.d.ts +3 -3
- package/dist/types/models/config/rightsManagementPipComponentConfig.d.ts +3 -3
- package/dist/types/models/config/rightsManagementPmpComponentConfig.d.ts +3 -3
- package/dist/types/models/config/rightsManagementPnapComponentConfig.d.ts +13 -0
- package/dist/types/models/config/rightsManagementPnpComponentConfig.d.ts +13 -0
- package/dist/types/models/config/rightsManagementPolicyArbiterComponentConfig.d.ts +9 -0
- package/dist/types/models/config/rightsManagementPolicyEnforcementProcessorComponentConfig.d.ts +9 -0
- package/dist/types/models/config/rightsManagementPolicyExecutionActionComponentConfig.d.ts +9 -0
- package/dist/types/models/config/rightsManagementPolicyInformationSourceComponentConfig.d.ts +12 -0
- package/dist/types/models/config/rightsManagementPolicyNegotiatorComponentConfig.d.ts +9 -0
- package/dist/types/models/config/rightsManagementPolicyRequesterComponentConfig.d.ts +9 -0
- package/dist/types/models/config/rightsManagementPxpComponentConfig.d.ts +3 -3
- package/dist/types/models/config/synchronisedStorageComponentConfig.d.ts +1 -1
- package/dist/types/models/config/taskSchedulerComponentConfig.d.ts +1 -1
- package/dist/types/models/config/telemetryComponentConfig.d.ts +1 -1
- package/dist/types/models/config/telemetryConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/tenantAdminComponentConfig.d.ts +9 -0
- package/dist/types/models/config/trustComponentConfig.d.ts +9 -0
- package/dist/types/models/config/trustGeneratorComponentConfig.d.ts +9 -0
- package/dist/types/models/config/trustVerifierComponentConfig.d.ts +9 -0
- package/dist/types/models/config/vaultConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/verifiableStorageComponentConfig.d.ts +1 -1
- package/dist/types/models/config/verifiableStorageConnectorConfig.d.ts +1 -1
- package/dist/types/models/config/walletConnectorConfig.d.ts +1 -1
- package/dist/types/models/types/authenticationGeneratorComponentType.d.ts +13 -0
- package/dist/types/models/types/backgroundTaskComponentType.d.ts +13 -0
- package/dist/types/models/types/contextIdHandlerComponentType.d.ts +17 -0
- package/dist/types/models/types/dataSpaceConnectorComponentType.d.ts +21 -0
- package/dist/types/models/types/federatedCatalogueFilterComponentType.d.ts +13 -0
- package/dist/types/models/types/messagingAdminComponentType.d.ts +13 -0
- package/dist/types/models/types/rightsManagementDapComponentType.d.ts +17 -0
- package/dist/types/models/types/rightsManagementDarpComponentType.d.ts +13 -0
- package/dist/types/models/types/rightsManagementDataAccessHandlerComponentType.d.ts +13 -0
- package/dist/types/models/types/rightsManagementPapComponentType.d.ts +4 -0
- package/dist/types/models/types/rightsManagementPepComponentType.d.ts +4 -0
- package/dist/types/models/types/rightsManagementPnapComponentType.d.ts +17 -0
- package/dist/types/models/types/rightsManagementPnpComponentType.d.ts +17 -0
- package/dist/types/models/types/rightsManagementPolicyArbiterComponentType.d.ts +13 -0
- package/dist/types/models/types/rightsManagementPolicyEnforcementProcessorComponentType.d.ts +13 -0
- package/dist/types/models/types/rightsManagementPolicyExecutionActionComponentType.d.ts +13 -0
- package/dist/types/models/types/rightsManagementPolicyInformationSourceComponentType.d.ts +17 -0
- package/dist/types/models/types/rightsManagementPolicyNegotiatorComponentType.d.ts +13 -0
- package/dist/types/models/types/rightsManagementPolicyRequesterComponentType.d.ts +13 -0
- package/dist/types/models/types/tenantAdminComponentType.d.ts +13 -0
- package/dist/types/models/types/trustComponentType.d.ts +13 -0
- package/dist/types/models/types/trustGeneratorComponentType.d.ts +13 -0
- package/dist/types/models/types/trustVerifierComponentType.d.ts +13 -0
- package/dist/types/utils/engineTypeHelper.d.ts +19 -0
- package/docs/changelog.md +438 -0
- package/docs/reference/classes/EngineTypeHelper.md +61 -0
- package/docs/reference/functions/initialiseAttestationComponent.md +3 -13
- package/docs/reference/functions/initialiseAttestationConnector.md +3 -13
- package/docs/reference/functions/initialiseAuditableItemGraphComponent.md +3 -13
- package/docs/reference/functions/initialiseAuditableItemStreamComponent.md +3 -13
- package/docs/reference/functions/initialiseAuthenticationGeneratorComponent.md +31 -0
- package/docs/reference/functions/initialiseBackgroundTaskComponent.md +31 -0
- package/docs/reference/functions/initialiseBlobStorageComponent.md +3 -13
- package/docs/reference/functions/initialiseBlobStorageConnector.md +3 -13
- package/docs/reference/functions/initialiseContextIdHandlerComponent.md +31 -0
- package/docs/reference/functions/initialiseDataConverterConnector.md +3 -13
- package/docs/reference/functions/initialiseDataExtractorConnector.md +3 -13
- package/docs/reference/functions/initialiseDataProcessingComponent.md +3 -13
- package/docs/reference/functions/initialiseDataSpaceConnectorComponent.md +31 -0
- package/docs/reference/functions/initialiseDocumentManagementComponent.md +3 -13
- package/docs/reference/functions/initialiseEntityStorageComponent.md +3 -13
- package/docs/reference/functions/initialiseEntityStorageConnector.md +8 -2
- package/docs/reference/functions/initialiseEventBusComponent.md +3 -13
- package/docs/reference/functions/initialiseEventBusConnector.md +3 -13
- package/docs/reference/functions/initialiseFaucetConnector.md +3 -13
- package/docs/reference/functions/initialiseFederatedCatalogueComponent.md +3 -13
- package/docs/reference/functions/initialiseFederatedCatalogueFilterComponent.md +31 -0
- package/docs/reference/functions/initialiseIdentityComponent.md +3 -13
- package/docs/reference/functions/initialiseIdentityConnector.md +3 -13
- package/docs/reference/functions/initialiseIdentityProfileComponent.md +3 -13
- package/docs/reference/functions/initialiseIdentityProfileConnector.md +3 -13
- package/docs/reference/functions/initialiseIdentityResolverComponent.md +3 -13
- package/docs/reference/functions/initialiseIdentityResolverConnector.md +3 -13
- package/docs/reference/functions/initialiseImmutableProofComponent.md +3 -13
- package/docs/reference/functions/initialiseLoggingComponent.md +3 -13
- package/docs/reference/functions/initialiseLoggingConnector.md +3 -13
- package/docs/reference/functions/initialiseMessagingAdminComponent.md +31 -0
- package/docs/reference/functions/initialiseMessagingComponent.md +3 -13
- package/docs/reference/functions/initialiseMessagingEmailConnector.md +3 -13
- package/docs/reference/functions/initialiseMessagingPushNotificationConnector.md +3 -13
- package/docs/reference/functions/initialiseMessagingSmsConnector.md +3 -13
- package/docs/reference/functions/initialiseNftComponent.md +3 -13
- package/docs/reference/functions/initialiseNftConnector.md +3 -13
- package/docs/reference/functions/initialiseRightsManagementDapComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementDarpComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementDataAccessHandlerComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPapComponent.md +3 -13
- package/docs/reference/functions/initialiseRightsManagementPdpComponent.md +3 -13
- package/docs/reference/functions/initialiseRightsManagementPepComponent.md +3 -13
- package/docs/reference/functions/initialiseRightsManagementPipComponent.md +3 -13
- package/docs/reference/functions/initialiseRightsManagementPmpComponent.md +3 -13
- package/docs/reference/functions/initialiseRightsManagementPnapComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPnpComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPolicyArbiterComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPolicyEnforcementProcessorComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPolicyExecutionActionComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPolicyInformationSourceComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPolicyNegotiatorComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPolicyRequesterComponent.md +31 -0
- package/docs/reference/functions/initialiseRightsManagementPxpComponent.md +3 -13
- package/docs/reference/functions/initialiseSynchronisedStorageComponent.md +3 -13
- package/docs/reference/functions/initialiseTaskSchedulerComponent.md +3 -13
- package/docs/reference/functions/initialiseTelemetryComponent.md +3 -13
- package/docs/reference/functions/initialiseTelemetryConnector.md +3 -13
- package/docs/reference/functions/initialiseTenantAdminComponent.md +31 -0
- package/docs/reference/functions/initialiseTrustComponent.md +31 -0
- package/docs/reference/functions/initialiseTrustGeneratorComponent.md +31 -0
- package/docs/reference/functions/initialiseTrustVerifierComponent.md +31 -0
- package/docs/reference/functions/initialiseVaultConnector.md +3 -13
- package/docs/reference/functions/initialiseVerifiableStorageComponent.md +3 -13
- package/docs/reference/functions/initialiseVerifiableStorageConnector.md +3 -13
- package/docs/reference/functions/initialiseWalletConnector.md +3 -13
- package/docs/reference/index.md +88 -9
- package/docs/reference/interfaces/IEngineConfig.md +120 -6
- package/docs/reference/type-aliases/AuthenticationGeneratorComponentConfig.md +17 -0
- package/docs/reference/type-aliases/AuthenticationGeneratorComponentType.md +5 -0
- package/docs/reference/type-aliases/BackgroundTaskComponentConfig.md +17 -0
- package/docs/reference/type-aliases/BackgroundTaskComponentType.md +5 -0
- package/docs/reference/type-aliases/ContextIdHandlerComponentConfig.md +5 -0
- package/docs/reference/type-aliases/ContextIdHandlerComponentType.md +5 -0
- package/docs/reference/type-aliases/DataSpaceConnectorComponentConfig.md +5 -0
- package/docs/reference/type-aliases/DataSpaceConnectorComponentType.md +5 -0
- package/docs/reference/type-aliases/EntityStorageComponentConfig.md +1 -1
- package/docs/reference/type-aliases/FederatedCatalogueFilterComponentConfig.md +17 -0
- package/docs/reference/type-aliases/FederatedCatalogueFilterComponentType.md +5 -0
- package/docs/reference/type-aliases/MessagingAdminComponentConfig.md +17 -0
- package/docs/reference/type-aliases/MessagingAdminComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementDapComponentConfig.md +5 -0
- package/docs/reference/type-aliases/RightsManagementDapComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementDarpComponentConfig.md +17 -0
- package/docs/reference/type-aliases/RightsManagementDarpComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementDataAccessHandlerComponentConfig.md +17 -0
- package/docs/reference/type-aliases/RightsManagementDataAccessHandlerComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPapComponentConfig.md +1 -13
- package/docs/reference/type-aliases/RightsManagementPdpComponentConfig.md +1 -1
- package/docs/reference/type-aliases/RightsManagementPepComponentConfig.md +1 -1
- package/docs/reference/type-aliases/RightsManagementPipComponentConfig.md +1 -1
- package/docs/reference/type-aliases/RightsManagementPmpComponentConfig.md +1 -1
- package/docs/reference/type-aliases/RightsManagementPnapComponentConfig.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPnapComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPnpComponentConfig.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPnpComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPolicyArbiterComponentConfig.md +17 -0
- package/docs/reference/type-aliases/RightsManagementPolicyArbiterComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPolicyEnforcementProcessorComponentConfig.md +17 -0
- package/docs/reference/type-aliases/RightsManagementPolicyEnforcementProcessorComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPolicyExecutionActionComponentConfig.md +17 -0
- package/docs/reference/type-aliases/RightsManagementPolicyExecutionActionComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPolicyInformationSourceComponentConfig.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPolicyInformationSourceComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPolicyNegotiatorComponentConfig.md +17 -0
- package/docs/reference/type-aliases/RightsManagementPolicyNegotiatorComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPolicyRequesterComponentConfig.md +17 -0
- package/docs/reference/type-aliases/RightsManagementPolicyRequesterComponentType.md +5 -0
- package/docs/reference/type-aliases/RightsManagementPxpComponentConfig.md +1 -1
- package/docs/reference/type-aliases/TenantAdminComponentConfig.md +17 -0
- package/docs/reference/type-aliases/TenantAdminComponentType.md +5 -0
- package/docs/reference/type-aliases/TrustComponentConfig.md +17 -0
- package/docs/reference/type-aliases/TrustComponentType.md +5 -0
- package/docs/reference/type-aliases/TrustGeneratorComponentConfig.md +17 -0
- package/docs/reference/type-aliases/TrustGeneratorComponentType.md +5 -0
- package/docs/reference/type-aliases/TrustVerifierComponentConfig.md +17 -0
- package/docs/reference/type-aliases/TrustVerifierComponentType.md +5 -0
- package/docs/reference/variables/AttestationComponentType.md +1 -1
- package/docs/reference/variables/AttestationConnectorType.md +1 -1
- package/docs/reference/variables/AuditableItemGraphComponentType.md +1 -1
- package/docs/reference/variables/AuditableItemStreamComponentType.md +1 -1
- package/docs/reference/variables/AuthenticationGeneratorComponentType.md +13 -0
- package/docs/reference/variables/BackgroundTaskComponentType.md +13 -0
- package/docs/reference/variables/BlobStorageComponentType.md +1 -1
- package/docs/reference/variables/BlobStorageConnectorType.md +1 -1
- package/docs/reference/variables/ContextIdHandlerComponentType.md +19 -0
- package/docs/reference/variables/DataConverterConnectorType.md +1 -1
- package/docs/reference/variables/DataExtractorConnectorType.md +1 -1
- package/docs/reference/variables/DataProcessingComponentType.md +1 -1
- package/docs/reference/variables/DataSpaceConnectorComponentType.md +25 -0
- package/docs/reference/variables/DltConfigType.md +1 -1
- package/docs/reference/variables/DocumentManagementComponentType.md +1 -1
- package/docs/reference/variables/EntityStorageComponentType.md +1 -1
- package/docs/reference/variables/EntityStorageConnectorType.md +1 -1
- package/docs/reference/variables/EventBusComponentType.md +1 -1
- package/docs/reference/variables/EventBusConnectorType.md +1 -1
- package/docs/reference/variables/FaucetConnectorType.md +1 -1
- package/docs/reference/variables/FederatedCatalogueComponentType.md +1 -1
- package/docs/reference/variables/FederatedCatalogueFilterComponentType.md +13 -0
- package/docs/reference/variables/IdentityComponentType.md +1 -1
- package/docs/reference/variables/IdentityConnectorType.md +1 -1
- package/docs/reference/variables/IdentityProfileComponentType.md +1 -1
- package/docs/reference/variables/IdentityProfileConnectorType.md +1 -1
- package/docs/reference/variables/IdentityResolverComponentType.md +1 -1
- package/docs/reference/variables/IdentityResolverConnectorType.md +1 -1
- package/docs/reference/variables/ImmutableProofComponentType.md +1 -1
- package/docs/reference/variables/LoggingComponentType.md +1 -1
- package/docs/reference/variables/LoggingConnectorType.md +1 -1
- package/docs/reference/variables/MessagingAdminComponentType.md +13 -0
- package/docs/reference/variables/MessagingComponentType.md +1 -1
- package/docs/reference/variables/MessagingEmailConnectorType.md +1 -1
- package/docs/reference/variables/MessagingPushNotificationConnectorType.md +1 -1
- package/docs/reference/variables/MessagingSmsConnectorType.md +1 -1
- package/docs/reference/variables/NftComponentType.md +1 -1
- package/docs/reference/variables/NftConnectorType.md +1 -1
- package/docs/reference/variables/{RightsManagementComponentType.md → RightsManagementDapComponentType.md} +4 -4
- package/docs/reference/variables/RightsManagementDarpComponentType.md +13 -0
- package/docs/reference/variables/RightsManagementDataAccessHandlerComponentType.md +13 -0
- package/docs/reference/variables/RightsManagementPapComponentType.md +7 -1
- package/docs/reference/variables/RightsManagementPdpComponentType.md +1 -1
- package/docs/reference/variables/RightsManagementPepComponentType.md +7 -1
- package/docs/reference/variables/RightsManagementPipComponentType.md +1 -1
- package/docs/reference/variables/RightsManagementPmpComponentType.md +1 -1
- package/docs/reference/variables/RightsManagementPnapComponentType.md +19 -0
- package/docs/reference/variables/RightsManagementPnpComponentType.md +19 -0
- package/docs/reference/variables/RightsManagementPolicyArbiterComponentType.md +13 -0
- package/docs/reference/variables/RightsManagementPolicyEnforcementProcessorComponentType.md +13 -0
- package/docs/reference/variables/RightsManagementPolicyExecutionActionComponentType.md +13 -0
- package/docs/reference/variables/RightsManagementPolicyInformationSourceComponentType.md +19 -0
- package/docs/reference/variables/RightsManagementPolicyNegotiatorComponentType.md +13 -0
- package/docs/reference/variables/RightsManagementPolicyRequesterComponentType.md +13 -0
- package/docs/reference/variables/RightsManagementPxpComponentType.md +1 -1
- package/docs/reference/variables/SynchronisedStorageComponentType.md +1 -1
- package/docs/reference/variables/TaskSchedulerComponentType.md +1 -1
- package/docs/reference/variables/TelemetryComponentType.md +1 -1
- package/docs/reference/variables/TelemetryConnectorType.md +1 -1
- package/docs/reference/variables/TenantAdminComponentType.md +13 -0
- package/docs/reference/variables/TrustComponentType.md +13 -0
- package/docs/reference/variables/TrustGeneratorComponentType.md +13 -0
- package/docs/reference/variables/TrustVerifierComponentType.md +13 -0
- package/docs/reference/variables/VaultConnectorType.md +1 -1
- package/docs/reference/variables/VerifiableStorageComponentType.md +1 -1
- package/docs/reference/variables/VerifiableStorageConnectorType.md +1 -1
- package/docs/reference/variables/WalletConnectorType.md +1 -1
- package/locales/en.json +14 -1
- package/package.json +37 -10
- package/dist/cjs/index.cjs +0 -3224
- package/dist/esm/index.mjs +0 -3127
- package/dist/types/components/rightsManagement.d.ts +0 -13
- package/dist/types/models/config/backgroundTaskConnectorConfig.d.ts +0 -9
- package/dist/types/models/config/rightsManagementComponentConfig.d.ts +0 -13
- package/dist/types/models/types/backgroundTaskConnectorType.d.ts +0 -13
- package/dist/types/models/types/rightsManagementComponentType.d.ts +0 -17
- package/docs/reference/functions/initialiseBackgroundTaskConnector.md +0 -41
- package/docs/reference/functions/initialiseRightsManagementComponent.md +0 -41
- package/docs/reference/functions/initialiseWalletStorage.md +0 -41
- package/docs/reference/type-aliases/BackgroundTaskConnectorConfig.md +0 -17
- package/docs/reference/type-aliases/BackgroundTaskConnectorType.md +0 -5
- package/docs/reference/type-aliases/RightsManagementComponentConfig.md +0 -5
- package/docs/reference/type-aliases/RightsManagementComponentType.md +0 -5
- package/docs/reference/variables/BackgroundTaskConnectorType.md +0 -13
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"messaging.js","sourceRoot":"","sources":["../../../src/components/messaging.ts"],"names":[],"mappings":"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","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ContextIdHelper, ContextIdKeys } from \"@twin.org/context\";\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport {\n\tAwsMessagingEmailConnector,\n\tAwsMessagingPushNotificationConnector,\n\tAwsMessagingSmsConnector\n} from \"@twin.org/messaging-connector-aws\";\nimport {\n\ttype EmailEntry,\n\tEntityStorageMessagingEmailConnector,\n\tEntityStorageMessagingPushNotificationConnector,\n\tEntityStorageMessagingSmsConnector,\n\tinitSchema,\n\ttype PushNotificationDeviceEntry,\n\ttype PushNotificationMessageEntry,\n\ttype SmsEntry\n} from \"@twin.org/messaging-connector-entity-storage\";\nimport {\n\ttype IMessagingAdminComponent,\n\ttype IMessagingComponent,\n\ttype IMessagingEmailConnector,\n\ttype IMessagingPushNotificationsConnector,\n\ttype IMessagingSmsConnector,\n\tMessagingEmailConnectorFactory,\n\tMessagingPushNotificationsConnectorFactory,\n\tMessagingSmsConnectorFactory\n} from \"@twin.org/messaging-models\";\nimport {\n\tinitSchema as initSchemaMessagingService,\n\tMessagingAdminService,\n\tMessagingService,\n\ttype TemplateEntry\n} from \"@twin.org/messaging-service\";\nimport { nameof, nameofKebabCase } from \"@twin.org/nameof\";\nimport { initialiseEntityStorageConnector } from \"./entityStorage.js\";\nimport type { MessagingAdminComponentConfig } from \"../models/config/messagingAdminComponentConfig.js\";\nimport type { MessagingComponentConfig } from \"../models/config/messagingComponentConfig.js\";\nimport type { MessagingEmailConnectorConfig } from \"../models/config/messagingEmailConnectorConfig.js\";\nimport type { MessagingPushNotificationConnectorConfig } from \"../models/config/messagingPushNotificationConnectorConfig.js\";\nimport type { MessagingSmsConnectorConfig } from \"../models/config/messagingSmsConnectorConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { MessagingAdminComponentType } from \"../models/types/messagingAdminComponentType.js\";\nimport { MessagingComponentType } from \"../models/types/messagingComponentType.js\";\nimport { MessagingEmailConnectorType } from \"../models/types/messagingEmailConnectorType.js\";\nimport { MessagingPushNotificationConnectorType } from \"../models/types/messagingPushNotificationConnectorType.js\";\nimport { MessagingSmsConnectorType } from \"../models/types/messagingSmsConnectorType.js\";\n\n/**\n * Initialise a messaging email connector.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseMessagingEmailConnector(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: MessagingEmailConnectorConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof MessagingEmailConnectorFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IMessagingEmailConnector | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === MessagingEmailConnectorType.EntityStorage) {\n\t\tinitSchema({ email: true, sms: false, pushNotification: false });\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.messagingEmailEntryStorageConnectorType,\n\t\t\tnameof<EmailEntry>(),\n\t\t\tContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [\n\t\t\t\tContextIdKeys.Node,\n\t\t\t\tContextIdKeys.Tenant\n\t\t\t])\n\t\t);\n\t\tcomponent = new EntityStorageMessagingEmailConnector({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = EntityStorageMessagingEmailConnector.NAMESPACE;\n\t} else if (instanceConfig.type === MessagingEmailConnectorType.Aws) {\n\t\tcomponent = new AwsMessagingEmailConnector({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = AwsMessagingEmailConnector.NAMESPACE;\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: MessagingEmailConnectorFactory\n\t};\n}\n\n/**\n * Initialise a messaging sms connector.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseMessagingSmsConnector(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: MessagingSmsConnectorConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof MessagingSmsConnectorFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet connector: IMessagingSmsConnector | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === MessagingSmsConnectorType.EntityStorage) {\n\t\tinitSchema({ email: false, sms: true, pushNotification: false });\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.messagingSmsEntryStorageConnectorType,\n\t\t\tnameof<SmsEntry>(),\n\t\t\tContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [\n\t\t\t\tContextIdKeys.Node,\n\t\t\t\tContextIdKeys.Tenant\n\t\t\t])\n\t\t);\n\t\tconnector = new EntityStorageMessagingSmsConnector({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = EntityStorageMessagingSmsConnector.NAMESPACE;\n\t} else if (instanceConfig.type === MessagingSmsConnectorType.Aws) {\n\t\tconnector = new AwsMessagingSmsConnector({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = AwsMessagingSmsConnector.NAMESPACE;\n\t}\n\n\treturn {\n\t\tinstanceType,\n\t\tfactory: MessagingSmsConnectorFactory,\n\t\tcomponent: connector\n\t};\n}\n\n/**\n * Initialise a messaging push notification connector.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseMessagingPushNotificationConnector(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: MessagingPushNotificationConnectorConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof MessagingPushNotificationsConnectorFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IMessagingPushNotificationsConnector | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === MessagingPushNotificationConnectorType.EntityStorage) {\n\t\tinitSchema({ email: false, sms: false, pushNotification: true });\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.messagingDeviceEntryStorageConnectorType,\n\t\t\tnameof<PushNotificationDeviceEntry>(),\n\t\t\tContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [\n\t\t\t\tContextIdKeys.Node,\n\t\t\t\tContextIdKeys.Tenant\n\t\t\t])\n\t\t);\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.messagingMessageEntryStorageConnectorType,\n\t\t\tnameof<PushNotificationMessageEntry>(),\n\t\t\tContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [\n\t\t\t\tContextIdKeys.Node,\n\t\t\t\tContextIdKeys.Tenant\n\t\t\t])\n\t\t);\n\t\tcomponent = new EntityStorageMessagingPushNotificationConnector({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = EntityStorageMessagingPushNotificationConnector.NAMESPACE;\n\t} else if (instanceConfig.type === MessagingPushNotificationConnectorType.Aws) {\n\t\tcomponent = new AwsMessagingPushNotificationConnector({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = AwsMessagingPushNotificationConnector.NAMESPACE;\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: MessagingPushNotificationsConnectorFactory\n\t};\n}\n\n/**\n * Initialise the messaging component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseMessagingComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: MessagingComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IMessagingComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === MessagingComponentType.Service) {\n\t\tcomponent = new MessagingService({\n\t\t\tmessagingEmailConnectorType:\n\t\t\t\tengineCore.getRegisteredInstanceTypeOptional(\"messagingEmailConnector\"),\n\t\t\tmessagingSmsConnectorType:\n\t\t\t\tengineCore.getRegisteredInstanceTypeOptional(\"messagingSmsConnector\"),\n\t\t\tmessagingPushNotificationConnectorType: engineCore.getRegisteredInstanceTypeOptional(\n\t\t\t\t\"messagingNotificationConnector\"\n\t\t\t),\n\t\t\tmessagingAdminComponentType:\n\t\t\t\tengineCore.getRegisteredInstanceTypeOptional(\"messagingAdminComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(MessagingService);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n\n/**\n * Initialise the messaging admin component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseMessagingAdminComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: MessagingAdminComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IMessagingAdminComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === MessagingAdminComponentType.Service) {\n\t\tinitSchemaMessagingService();\n\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.templateEntryStorageConnectorType,\n\t\t\tnameof<TemplateEntry>(),\n\t\t\tContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [\n\t\t\t\tContextIdKeys.Node,\n\t\t\t\tContextIdKeys.Tenant\n\t\t\t])\n\t\t);\n\n\t\tcomponent = new MessagingAdminService({\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(MessagingAdminService);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ContextIdHelper, ContextIdKeys } from "@twin.org/context";
|
|
4
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
5
|
+
import { EntityStorageNftConnector, initSchema } from "@twin.org/nft-connector-entity-storage";
|
|
6
|
+
import { IotaNftConnector } from "@twin.org/nft-connector-iota";
|
|
7
|
+
import { NftConnectorFactory } from "@twin.org/nft-models";
|
|
8
|
+
import { NftRestClient } from "@twin.org/nft-rest-client";
|
|
9
|
+
import { NftService } from "@twin.org/nft-service";
|
|
10
|
+
import { initialiseEntityStorageConnector } from "./entityStorage.js";
|
|
11
|
+
import { DltConfigType } from "../models/types/dltConfigType.js";
|
|
12
|
+
import { NftComponentType } from "../models/types/nftComponentType.js";
|
|
13
|
+
import { NftConnectorType } from "../models/types/nftConnectorType.js";
|
|
14
|
+
import { EngineTypeHelper } from "../utils/engineTypeHelper.js";
|
|
15
|
+
/**
|
|
16
|
+
* Initialise the NFT connector.
|
|
17
|
+
* @param engineCore The engine core.
|
|
18
|
+
* @param context The context for the engine.
|
|
19
|
+
* @param instanceConfig The instance config.
|
|
20
|
+
* @returns The instance created and the factory for it.
|
|
21
|
+
*/
|
|
22
|
+
export async function initialiseNftConnector(engineCore, context, instanceConfig) {
|
|
23
|
+
let component;
|
|
24
|
+
let instanceType;
|
|
25
|
+
if (instanceConfig.type === NftConnectorType.EntityStorage) {
|
|
26
|
+
initSchema();
|
|
27
|
+
initialiseEntityStorageConnector(engineCore, context, instanceConfig.options?.nftEntityStorageType, "Nft", ContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [
|
|
28
|
+
ContextIdKeys.Node,
|
|
29
|
+
ContextIdKeys.Tenant
|
|
30
|
+
]));
|
|
31
|
+
component = new EntityStorageNftConnector(instanceConfig.options);
|
|
32
|
+
instanceType = EntityStorageNftConnector.NAMESPACE;
|
|
33
|
+
}
|
|
34
|
+
else if (instanceConfig.type === NftConnectorType.Iota) {
|
|
35
|
+
const dltConfig = EngineTypeHelper.getConfigOfType(engineCore.getConfig(), "dltConfig", DltConfigType.Iota);
|
|
36
|
+
component = new IotaNftConnector({
|
|
37
|
+
vaultConnectorType: engineCore.getRegisteredInstanceType("vaultConnector"),
|
|
38
|
+
walletConnectorType: engineCore.getRegisteredInstanceType("walletConnector"),
|
|
39
|
+
loggingComponentType: engineCore.getRegisteredInstanceTypeOptional("loggingComponent"),
|
|
40
|
+
...instanceConfig.options,
|
|
41
|
+
config: {
|
|
42
|
+
...dltConfig?.options?.config,
|
|
43
|
+
...instanceConfig.options.config
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
instanceType = IotaNftConnector.NAMESPACE;
|
|
47
|
+
}
|
|
48
|
+
return {
|
|
49
|
+
component,
|
|
50
|
+
instanceType,
|
|
51
|
+
factory: NftConnectorFactory
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Initialise the NFT component.
|
|
56
|
+
* @param engineCore The engine core.
|
|
57
|
+
* @param context The context for the engine.
|
|
58
|
+
* @param instanceConfig The instance config.
|
|
59
|
+
* @returns The instance created and the factory for it.
|
|
60
|
+
*/
|
|
61
|
+
export async function initialiseNftComponent(engineCore, context, instanceConfig) {
|
|
62
|
+
let component;
|
|
63
|
+
let instanceType;
|
|
64
|
+
if (instanceConfig.type === NftComponentType.Service) {
|
|
65
|
+
component = new NftService(instanceConfig.options);
|
|
66
|
+
instanceType = "nft-service";
|
|
67
|
+
}
|
|
68
|
+
else if (instanceConfig.type === NftComponentType.RestClient) {
|
|
69
|
+
component = new NftRestClient(instanceConfig.options);
|
|
70
|
+
instanceType = "nft-rest-client";
|
|
71
|
+
}
|
|
72
|
+
return {
|
|
73
|
+
component,
|
|
74
|
+
instanceType,
|
|
75
|
+
factory: ComponentFactory
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
//# sourceMappingURL=nft.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nft.js","sourceRoot":"","sources":["../../../src/components/nft.ts"],"names":[],"mappings":"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","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ContextIdHelper, ContextIdKeys } from \"@twin.org/context\";\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameof, nameofKebabCase } from \"@twin.org/nameof\";\nimport {\n\tEntityStorageNftConnector,\n\tinitSchema,\n\ttype Nft\n} from \"@twin.org/nft-connector-entity-storage\";\nimport { IotaNftConnector } from \"@twin.org/nft-connector-iota\";\nimport { NftConnectorFactory, type INftComponent, type INftConnector } from \"@twin.org/nft-models\";\nimport { NftRestClient } from \"@twin.org/nft-rest-client\";\nimport { NftService } from \"@twin.org/nft-service\";\nimport { initialiseEntityStorageConnector } from \"./entityStorage.js\";\nimport type { DltConfig } from \"../models/config/dltConfig.js\";\nimport type { NftComponentConfig } from \"../models/config/nftComponentConfig.js\";\nimport type { NftConnectorConfig } from \"../models/config/nftConnectorConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { DltConfigType } from \"../models/types/dltConfigType.js\";\nimport { NftComponentType } from \"../models/types/nftComponentType.js\";\nimport { NftConnectorType } from \"../models/types/nftConnectorType.js\";\nimport { EngineTypeHelper } from \"../utils/engineTypeHelper.js\";\n\n/**\n * Initialise the NFT connector.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseNftConnector(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: NftConnectorConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof NftConnectorFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: INftConnector | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === NftConnectorType.EntityStorage) {\n\t\tinitSchema();\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.nftEntityStorageType,\n\t\t\tnameof<Nft>(),\n\t\t\tContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [\n\t\t\t\tContextIdKeys.Node,\n\t\t\t\tContextIdKeys.Tenant\n\t\t\t])\n\t\t);\n\t\tcomponent = new EntityStorageNftConnector(instanceConfig.options);\n\t\tinstanceType = EntityStorageNftConnector.NAMESPACE;\n\t} else if (instanceConfig.type === NftConnectorType.Iota) {\n\t\tconst dltConfig = EngineTypeHelper.getConfigOfType<DltConfig>(\n\t\t\tengineCore.getConfig(),\n\t\t\t\"dltConfig\",\n\t\t\tDltConfigType.Iota\n\t\t);\n\t\tcomponent = new IotaNftConnector({\n\t\t\tvaultConnectorType: engineCore.getRegisteredInstanceType(\"vaultConnector\"),\n\t\t\twalletConnectorType: engineCore.getRegisteredInstanceType(\"walletConnector\"),\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceTypeOptional(\"loggingComponent\"),\n\t\t\t...instanceConfig.options,\n\t\t\tconfig: {\n\t\t\t\t...dltConfig?.options?.config,\n\t\t\t\t...instanceConfig.options.config\n\t\t\t}\n\t\t});\n\t\tinstanceType = IotaNftConnector.NAMESPACE;\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: NftConnectorFactory\n\t};\n}\n\n/**\n * Initialise the NFT component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseNftComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: NftComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: INftComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === NftComponentType.Service) {\n\t\tcomponent = new NftService(instanceConfig.options);\n\t\tinstanceType = nameofKebabCase(NftService);\n\t} else if (instanceConfig.type === NftComponentType.RestClient) {\n\t\tcomponent = new NftRestClient(instanceConfig.options);\n\t\tinstanceType = nameofKebabCase(NftRestClient);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
4
|
+
import { DataAccessPointService } from "@twin.org/rights-management-dap-service";
|
|
5
|
+
import { DataAccessPointRestClient } from "@twin.org/rights-management-rest-client";
|
|
6
|
+
import { RightsManagementDapComponentType } from "../models/types/rightsManagementDapComponentType.js";
|
|
7
|
+
/**
|
|
8
|
+
* Initialise the rights management DAP component.
|
|
9
|
+
* @param engineCore The engine core.
|
|
10
|
+
* @param context The context for the engine.
|
|
11
|
+
* @param instanceConfig The instance config.
|
|
12
|
+
* @returns The instance created and the factory for it.
|
|
13
|
+
*/
|
|
14
|
+
export async function initialiseRightsManagementDapComponent(engineCore, context, instanceConfig) {
|
|
15
|
+
let component;
|
|
16
|
+
let instanceType;
|
|
17
|
+
if (instanceConfig.type === RightsManagementDapComponentType.Service) {
|
|
18
|
+
component = new DataAccessPointService({
|
|
19
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
20
|
+
policyEnforcementPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPepComponent"),
|
|
21
|
+
trustComponentType: engineCore.getRegisteredInstanceType("trustComponent"),
|
|
22
|
+
...instanceConfig.options
|
|
23
|
+
});
|
|
24
|
+
instanceType = "data-access-point-service";
|
|
25
|
+
}
|
|
26
|
+
else if (instanceConfig.type === RightsManagementDapComponentType.RestClient) {
|
|
27
|
+
component = new DataAccessPointRestClient(instanceConfig.options);
|
|
28
|
+
instanceType = "data-access-point-rest-client";
|
|
29
|
+
}
|
|
30
|
+
return {
|
|
31
|
+
component,
|
|
32
|
+
instanceType,
|
|
33
|
+
factory: ComponentFactory
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
//# sourceMappingURL=rightsManagementDap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementDap.js","sourceRoot":"","sources":["../../../src/components/rightsManagementDap.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAGnE,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AAEjF,OAAO,EAAE,yBAAyB,EAAE,MAAM,yCAAyC,CAAC;AAGpF,OAAO,EAAE,gCAAgC,EAAE,MAAM,qDAAqD,CAAC;AAEvG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC3D,UAAsC,EACtC,OAA0C,EAC1C,cAAkD;IAMlD,IAAI,SAAgD,CAAC;IACrD,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,OAAO,EAAE,CAAC;QACtE,SAAS,GAAG,IAAI,sBAAsB,CAAC;YACtC,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,mCAAmC,EAAE,UAAU,CAAC,yBAAyB,CACxE,8BAA8B,CAC9B;YACD,kBAAkB,EAAE,UAAU,CAAC,yBAAyB,CAAC,gBAAgB,CAAC;YAC1E,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,8BAA0C,CAAC;IACxD,CAAC;SAAM,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,UAAU,EAAE,CAAC;QAChF,SAAS,GAAG,IAAI,yBAAyB,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC;QAClE,YAAY,kCAA6C,CAAC;IAC3D,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport { DataAccessPointService } from \"@twin.org/rights-management-dap-service\";\nimport type { IDataAccessPointComponent } from \"@twin.org/rights-management-models\";\nimport { DataAccessPointRestClient } from \"@twin.org/rights-management-rest-client\";\nimport type { RightsManagementDapComponentConfig } from \"../models/config/rightsManagementDapComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementDapComponentType } from \"../models/types/rightsManagementDapComponentType.js\";\n\n/**\n * Initialise the rights management DAP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementDapComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementDapComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IDataAccessPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementDapComponentType.Service) {\n\t\tcomponent = new DataAccessPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\tpolicyEnforcementPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPepComponent\"\n\t\t\t),\n\t\t\ttrustComponentType: engineCore.getRegisteredInstanceType(\"trustComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(DataAccessPointService);\n\t} else if (instanceConfig.type === RightsManagementDapComponentType.RestClient) {\n\t\tcomponent = new DataAccessPointRestClient(instanceConfig.options);\n\t\tinstanceType = nameofKebabCase(DataAccessPointRestClient);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
4
|
+
import { DataAccessRequestPointService } from "@twin.org/rights-management-dap-service";
|
|
5
|
+
import { RightsManagementDarpComponentType } from "../models/types/rightsManagementDarpComponentType.js";
|
|
6
|
+
/**
|
|
7
|
+
* Initialise the rights management DARP component.
|
|
8
|
+
* @param engineCore The engine core.
|
|
9
|
+
* @param context The context for the engine.
|
|
10
|
+
* @param instanceConfig The instance config.
|
|
11
|
+
* @returns The instance created and the factory for it.
|
|
12
|
+
*/
|
|
13
|
+
export async function initialiseRightsManagementDarpComponent(engineCore, context, instanceConfig) {
|
|
14
|
+
let component;
|
|
15
|
+
let instanceType;
|
|
16
|
+
if (instanceConfig.type === RightsManagementDarpComponentType.Service) {
|
|
17
|
+
component = new DataAccessRequestPointService({
|
|
18
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
19
|
+
trustComponentType: engineCore.getRegisteredInstanceType("trustComponent"),
|
|
20
|
+
...instanceConfig.options
|
|
21
|
+
});
|
|
22
|
+
instanceType = "data-access-request-point-service";
|
|
23
|
+
}
|
|
24
|
+
return {
|
|
25
|
+
component,
|
|
26
|
+
instanceType,
|
|
27
|
+
factory: ComponentFactory
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=rightsManagementDarp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementDarp.js","sourceRoot":"","sources":["../../../src/components/rightsManagementDarp.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAGnE,OAAO,EAAE,6BAA6B,EAAE,MAAM,yCAAyC,CAAC;AAIxF,OAAO,EAAE,iCAAiC,EAAE,MAAM,sDAAsD,CAAC;AAEzG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,uCAAuC,CAC5D,UAAsC,EACtC,OAA0C,EAC1C,cAAmD;IAMnD,IAAI,SAAuD,CAAC;IAC5D,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,iCAAiC,CAAC,OAAO,EAAE,CAAC;QACvE,SAAS,GAAG,IAAI,6BAA6B,CAAC;YAC7C,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,kBAAkB,EAAE,UAAU,CAAC,yBAAyB,CAAC,gBAAgB,CAAC;YAC1E,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,sCAAiD,CAAC;IAC/D,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport { DataAccessRequestPointService } from \"@twin.org/rights-management-dap-service\";\nimport type { IDataAccessRequestPointComponent } from \"@twin.org/rights-management-models\";\nimport type { RightsManagementDarpComponentConfig } from \"../models/config/rightsManagementDarpComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementDarpComponentType } from \"../models/types/rightsManagementDarpComponentType.js\";\n\n/**\n * Initialise the rights management DARP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementDarpComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementDarpComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IDataAccessRequestPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementDarpComponentType.Service) {\n\t\tcomponent = new DataAccessRequestPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\ttrustComponentType: engineCore.getRegisteredInstanceType(\"trustComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(DataAccessRequestPointService);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { DataAccessHandlerFactory } from "@twin.org/rights-management-models";
|
|
2
|
+
import { ExampleDataAccessHandler } from "@twin.org/rights-management-plugins";
|
|
3
|
+
import { RightsManagementDataAccessHandlerComponentType } from "../models/types/rightsManagementDataAccessHandlerComponentType.js";
|
|
4
|
+
/**
|
|
5
|
+
* Initialise the rights management data access handler component.
|
|
6
|
+
* @param engineCore The engine core.
|
|
7
|
+
* @param context The context for the engine.
|
|
8
|
+
* @param instanceConfig The instance config.
|
|
9
|
+
* @returns The instance created and the factory for it.
|
|
10
|
+
*/
|
|
11
|
+
export async function initialiseRightsManagementDataAccessHandlerComponent(engineCore, context, instanceConfig) {
|
|
12
|
+
let component;
|
|
13
|
+
let instanceType;
|
|
14
|
+
if (instanceConfig.type === RightsManagementDataAccessHandlerComponentType.Example) {
|
|
15
|
+
component = new ExampleDataAccessHandler({
|
|
16
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
17
|
+
...instanceConfig.options
|
|
18
|
+
});
|
|
19
|
+
instanceType = "example-data-access-handler";
|
|
20
|
+
}
|
|
21
|
+
return {
|
|
22
|
+
component,
|
|
23
|
+
instanceType,
|
|
24
|
+
factory: DataAccessHandlerFactory
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=rightsManagementDataAccessHandler.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementDataAccessHandler.js","sourceRoot":"","sources":["../../../src/components/rightsManagementDataAccessHandler.ts"],"names":[],"mappings":"AAKA,OAAO,EAEN,wBAAwB,EACxB,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAG/E,OAAO,EAAE,8CAA8C,EAAE,MAAM,mEAAmE,CAAC;AAEnI;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,oDAAoD,CACzE,UAAsC,EACtC,OAA0C,EAC1C,cAAgE;IAMhE,IAAI,SAAyC,CAAC;IAC9C,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,8CAA8C,CAAC,OAAO,EAAE,CAAC;QACpF,SAAS,GAAG,IAAI,wBAAwB,CAAC;YACxC,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,gCAA4C,CAAC;IAC1D,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,wBAAwB;KACjC,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport type { IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport {\n\ttype IDataAccessHandler,\n\tDataAccessHandlerFactory\n} from \"@twin.org/rights-management-models\";\nimport { ExampleDataAccessHandler } from \"@twin.org/rights-management-plugins\";\nimport type { RightsManagementDataAccessHandlerComponentConfig } from \"../models/config/rightsManagementDataAccessHandlerComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementDataAccessHandlerComponentType } from \"../models/types/rightsManagementDataAccessHandlerComponentType.js\";\n\n/**\n * Initialise the rights management data access handler component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementDataAccessHandlerComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementDataAccessHandlerComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof DataAccessHandlerFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IDataAccessHandler | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementDataAccessHandlerComponentType.Example) {\n\t\tcomponent = new ExampleDataAccessHandler({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(ExampleDataAccessHandler);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: DataAccessHandlerFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ContextIdHelper, ContextIdKeys } from "@twin.org/context";
|
|
4
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
5
|
+
import { initSchema as initSchemaRightsManagementPap, PolicyAdministrationPointService } from "@twin.org/rights-management-pap-service";
|
|
6
|
+
import { PolicyAdministrationPointRestClient } from "@twin.org/rights-management-rest-client";
|
|
7
|
+
import { initialiseEntityStorageConnector } from "./entityStorage.js";
|
|
8
|
+
import { RightsManagementPapComponentType } from "../models/types/rightsManagementPapComponentType.js";
|
|
9
|
+
/**
|
|
10
|
+
* Initialise the rights management PAP component.
|
|
11
|
+
* @param engineCore The engine core.
|
|
12
|
+
* @param context The context for the engine.
|
|
13
|
+
* @param instanceConfig The instance config.
|
|
14
|
+
* @returns The instance created and the factory for it.
|
|
15
|
+
*/
|
|
16
|
+
export async function initialiseRightsManagementPapComponent(engineCore, context, instanceConfig) {
|
|
17
|
+
let component;
|
|
18
|
+
let instanceType;
|
|
19
|
+
if (instanceConfig.type === RightsManagementPapComponentType.Service) {
|
|
20
|
+
initSchemaRightsManagementPap();
|
|
21
|
+
initialiseEntityStorageConnector(engineCore, context, instanceConfig.options?.odrlPolicyEntityStorageType, "OdrlPolicy", ContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [
|
|
22
|
+
ContextIdKeys.Node,
|
|
23
|
+
ContextIdKeys.Tenant
|
|
24
|
+
]));
|
|
25
|
+
component = new PolicyAdministrationPointService({
|
|
26
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
27
|
+
...instanceConfig.options
|
|
28
|
+
});
|
|
29
|
+
instanceType = "policy-administration-point-service";
|
|
30
|
+
}
|
|
31
|
+
else if (instanceConfig.type === RightsManagementPapComponentType.RestClient) {
|
|
32
|
+
component = new PolicyAdministrationPointRestClient(instanceConfig.options);
|
|
33
|
+
instanceType = "policy-administration-point-rest-client";
|
|
34
|
+
}
|
|
35
|
+
return {
|
|
36
|
+
component,
|
|
37
|
+
instanceType,
|
|
38
|
+
factory: ComponentFactory
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=rightsManagementPap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementPap.js","sourceRoot":"","sources":["../../../src/components/rightsManagementPap.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AACnE,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EACN,UAAU,IAAI,6BAA6B,EAE3C,gCAAgC,EAChC,MAAM,yCAAyC,CAAC;AACjD,OAAO,EAAE,mCAAmC,EAAE,MAAM,yCAAyC,CAAC;AAC9F,OAAO,EAAE,gCAAgC,EAAE,MAAM,oBAAoB,CAAC;AAGtE,OAAO,EAAE,gCAAgC,EAAE,MAAM,qDAAqD,CAAC;AAEvG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC3D,UAAsC,EACtC,OAA0C,EAC1C,cAAkD;IAMlD,IAAI,SAA0D,CAAC;IAC/D,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,OAAO,EAAE,CAAC;QACtE,6BAA6B,EAAE,CAAC;QAEhC,gCAAgC,CAC/B,UAAU,EACV,OAAO,EACP,cAAc,CAAC,OAAO,EAAE,2BAA2B,gBAEnD,eAAe,CAAC,qBAAqB,CAAC,UAAU,CAAC,gBAAgB,EAAE,EAAE;YACpE,aAAa,CAAC,IAAI;YAClB,aAAa,CAAC,MAAM;SACpB,CAAC,CACF,CAAC;QAEF,SAAS,GAAG,IAAI,gCAAgC,CAAC;YAChD,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,wCAAoD,CAAC;IAClE,CAAC;SAAM,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,UAAU,EAAE,CAAC;QAChF,SAAS,GAAG,IAAI,mCAAmC,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC;QAC5E,YAAY,4CAAuD,CAAC;IACrE,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ContextIdHelper, ContextIdKeys } from \"@twin.org/context\";\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameof, nameofKebabCase } from \"@twin.org/nameof\";\nimport type { IPolicyAdministrationPointComponent } from \"@twin.org/rights-management-models\";\nimport {\n\tinitSchema as initSchemaRightsManagementPap,\n\ttype OdrlPolicy,\n\tPolicyAdministrationPointService\n} from \"@twin.org/rights-management-pap-service\";\nimport { PolicyAdministrationPointRestClient } from \"@twin.org/rights-management-rest-client\";\nimport { initialiseEntityStorageConnector } from \"./entityStorage.js\";\nimport type { RightsManagementPapComponentConfig } from \"../models/config/rightsManagementPapComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementPapComponentType } from \"../models/types/rightsManagementPapComponentType.js\";\n\n/**\n * Initialise the rights management PAP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementPapComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementPapComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IPolicyAdministrationPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementPapComponentType.Service) {\n\t\tinitSchemaRightsManagementPap();\n\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.odrlPolicyEntityStorageType,\n\t\t\tnameof<OdrlPolicy>(),\n\t\t\tContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [\n\t\t\t\tContextIdKeys.Node,\n\t\t\t\tContextIdKeys.Tenant\n\t\t\t])\n\t\t);\n\n\t\tcomponent = new PolicyAdministrationPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(PolicyAdministrationPointService);\n\t} else if (instanceConfig.type === RightsManagementPapComponentType.RestClient) {\n\t\tcomponent = new PolicyAdministrationPointRestClient(instanceConfig.options);\n\t\tinstanceType = nameofKebabCase(PolicyAdministrationPointRestClient);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
4
|
+
import { PolicyDecisionPointService } from "@twin.org/rights-management-pdp-service";
|
|
5
|
+
import { RightsManagementPdpComponentType } from "../models/types/rightsManagementPdpComponentType.js";
|
|
6
|
+
/**
|
|
7
|
+
* Initialise the rights management PDP component.
|
|
8
|
+
* @param engineCore The engine core.
|
|
9
|
+
* @param context The context for the engine.
|
|
10
|
+
* @param instanceConfig The instance config.
|
|
11
|
+
* @returns The instance created and the factory for it.
|
|
12
|
+
*/
|
|
13
|
+
export async function initialiseRightsManagementPdpComponent(engineCore, context, instanceConfig) {
|
|
14
|
+
let component;
|
|
15
|
+
let instanceType;
|
|
16
|
+
if (instanceConfig.type === RightsManagementPdpComponentType.Service) {
|
|
17
|
+
component = new PolicyDecisionPointService({
|
|
18
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
19
|
+
policyInformationPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPipComponent"),
|
|
20
|
+
policyManagementPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPmpComponent"),
|
|
21
|
+
policyExecutionPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPxpComponent"),
|
|
22
|
+
...instanceConfig.options
|
|
23
|
+
});
|
|
24
|
+
instanceType = "policy-decision-point-service";
|
|
25
|
+
}
|
|
26
|
+
return {
|
|
27
|
+
component,
|
|
28
|
+
instanceType,
|
|
29
|
+
factory: ComponentFactory
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=rightsManagementPdp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementPdp.js","sourceRoot":"","sources":["../../../src/components/rightsManagementPdp.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AAGrF,OAAO,EAAE,gCAAgC,EAAE,MAAM,qDAAqD,CAAC;AAEvG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC3D,UAAsC,EACtC,OAA0C,EAC1C,cAAkD;IAMlD,IAAI,SAAoD,CAAC;IACzD,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,OAAO,EAAE,CAAC;QACtE,SAAS,GAAG,IAAI,0BAA0B,CAAC;YAC1C,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,mCAAmC,EAAE,UAAU,CAAC,yBAAyB,CACxE,8BAA8B,CAC9B;YACD,kCAAkC,EAAE,UAAU,CAAC,yBAAyB,CACvE,8BAA8B,CAC9B;YACD,iCAAiC,EAAE,UAAU,CAAC,yBAAyB,CACtE,8BAA8B,CAC9B;YACD,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,kCAA8C,CAAC;IAC5D,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport type { IPolicyDecisionPointComponent } from \"@twin.org/rights-management-models\";\nimport { PolicyDecisionPointService } from \"@twin.org/rights-management-pdp-service\";\nimport type { RightsManagementPdpComponentConfig } from \"../models/config/rightsManagementPdpComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementPdpComponentType } from \"../models/types/rightsManagementPdpComponentType.js\";\n\n/**\n * Initialise the rights management PDP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementPdpComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementPdpComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IPolicyDecisionPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementPdpComponentType.Service) {\n\t\tcomponent = new PolicyDecisionPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\tpolicyInformationPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPipComponent\"\n\t\t\t),\n\t\t\tpolicyManagementPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPmpComponent\"\n\t\t\t),\n\t\t\tpolicyExecutionPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPxpComponent\"\n\t\t\t),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(PolicyDecisionPointService);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
4
|
+
import { PolicyEnforcementPointService } from "@twin.org/rights-management-pep-service";
|
|
5
|
+
import { RightsManagementPepComponentType } from "../models/types/rightsManagementPepComponentType.js";
|
|
6
|
+
/**
|
|
7
|
+
* Initialise the rights management PEP component.
|
|
8
|
+
* @param engineCore The engine core.
|
|
9
|
+
* @param context The context for the engine.
|
|
10
|
+
* @param instanceConfig The instance config.
|
|
11
|
+
* @returns The instance created and the factory for it.
|
|
12
|
+
*/
|
|
13
|
+
export async function initialiseRightsManagementPepComponent(engineCore, context, instanceConfig) {
|
|
14
|
+
let component;
|
|
15
|
+
let instanceType;
|
|
16
|
+
if (instanceConfig.type === RightsManagementPepComponentType.Service) {
|
|
17
|
+
component = new PolicyEnforcementPointService({
|
|
18
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
19
|
+
policyDecisionPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPdpComponent"),
|
|
20
|
+
...instanceConfig.options
|
|
21
|
+
});
|
|
22
|
+
instanceType = "policy-enforcement-point-service";
|
|
23
|
+
}
|
|
24
|
+
return {
|
|
25
|
+
component,
|
|
26
|
+
instanceType,
|
|
27
|
+
factory: ComponentFactory
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=rightsManagementPep.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementPep.js","sourceRoot":"","sources":["../../../src/components/rightsManagementPep.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EAAE,6BAA6B,EAAE,MAAM,yCAAyC,CAAC;AAGxF,OAAO,EAAE,gCAAgC,EAAE,MAAM,qDAAqD,CAAC;AAEvG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC3D,UAAsC,EACtC,OAA0C,EAC1C,cAAkD;IAMlD,IAAI,SAAuD,CAAC;IAC5D,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,OAAO,EAAE,CAAC;QACtE,SAAS,GAAG,IAAI,6BAA6B,CAAC;YAC7C,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,gCAAgC,EAAE,UAAU,CAAC,yBAAyB,CACrE,8BAA8B,CAC9B;YACD,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,qCAAiD,CAAC;IAC/D,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport type { IPolicyEnforcementPointComponent } from \"@twin.org/rights-management-models\";\nimport { PolicyEnforcementPointService } from \"@twin.org/rights-management-pep-service\";\nimport type { RightsManagementPepComponentConfig } from \"../models/config/rightsManagementPepComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementPepComponentType } from \"../models/types/rightsManagementPepComponentType.js\";\n\n/**\n * Initialise the rights management PEP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementPepComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementPepComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IPolicyEnforcementPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementPepComponentType.Service) {\n\t\tcomponent = new PolicyEnforcementPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\tpolicyDecisionPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPdpComponent\"\n\t\t\t),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(PolicyEnforcementPointService);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
4
|
+
import { PolicyInformationPointService } from "@twin.org/rights-management-pip-service";
|
|
5
|
+
import { RightsManagementPipComponentType } from "../models/types/rightsManagementPipComponentType.js";
|
|
6
|
+
/**
|
|
7
|
+
* Initialise the rights management PIP component.
|
|
8
|
+
* @param engineCore The engine core.
|
|
9
|
+
* @param context The context for the engine.
|
|
10
|
+
* @param instanceConfig The instance config.
|
|
11
|
+
* @returns The instance created and the factory for it.
|
|
12
|
+
*/
|
|
13
|
+
export async function initialiseRightsManagementPipComponent(engineCore, context, instanceConfig) {
|
|
14
|
+
let component;
|
|
15
|
+
let instanceType;
|
|
16
|
+
if (instanceConfig.type === RightsManagementPipComponentType.Service) {
|
|
17
|
+
component = new PolicyInformationPointService({
|
|
18
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
19
|
+
...instanceConfig.options
|
|
20
|
+
});
|
|
21
|
+
instanceType = "policy-information-point-service";
|
|
22
|
+
}
|
|
23
|
+
return {
|
|
24
|
+
component,
|
|
25
|
+
instanceType,
|
|
26
|
+
factory: ComponentFactory
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=rightsManagementPip.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementPip.js","sourceRoot":"","sources":["../../../src/components/rightsManagementPip.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EAAE,6BAA6B,EAAE,MAAM,yCAAyC,CAAC;AAGxF,OAAO,EAAE,gCAAgC,EAAE,MAAM,qDAAqD,CAAC;AAEvG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC3D,UAAsC,EACtC,OAA0C,EAC1C,cAAkD;IAMlD,IAAI,SAAuD,CAAC;IAC5D,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,OAAO,EAAE,CAAC;QACtE,SAAS,GAAG,IAAI,6BAA6B,CAAC;YAC7C,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,qCAAiD,CAAC;IAC/D,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport type { IPolicyInformationPointComponent } from \"@twin.org/rights-management-models\";\nimport { PolicyInformationPointService } from \"@twin.org/rights-management-pip-service\";\nimport type { RightsManagementPipComponentConfig } from \"../models/config/rightsManagementPipComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementPipComponentType } from \"../models/types/rightsManagementPipComponentType.js\";\n\n/**\n * Initialise the rights management PIP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementPipComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementPipComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IPolicyInformationPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementPipComponentType.Service) {\n\t\tcomponent = new PolicyInformationPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(PolicyInformationPointService);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
4
|
+
import { PolicyManagementPointService } from "@twin.org/rights-management-pmp-service";
|
|
5
|
+
import { RightsManagementPmpComponentType } from "../models/types/rightsManagementPmpComponentType.js";
|
|
6
|
+
/**
|
|
7
|
+
* Initialise the rights management PMP component.
|
|
8
|
+
* @param engineCore The engine core.
|
|
9
|
+
* @param context The context for the engine.
|
|
10
|
+
* @param instanceConfig The instance config.
|
|
11
|
+
* @returns The instance created and the factory for it.
|
|
12
|
+
*/
|
|
13
|
+
export async function initialiseRightsManagementPmpComponent(engineCore, context, instanceConfig) {
|
|
14
|
+
let component;
|
|
15
|
+
let instanceType;
|
|
16
|
+
if (instanceConfig.type === RightsManagementPmpComponentType.Service) {
|
|
17
|
+
component = new PolicyManagementPointService({
|
|
18
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
19
|
+
policyAdministrationPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPapComponent"),
|
|
20
|
+
...instanceConfig.options
|
|
21
|
+
});
|
|
22
|
+
instanceType = "policy-management-point-service";
|
|
23
|
+
}
|
|
24
|
+
return {
|
|
25
|
+
component,
|
|
26
|
+
instanceType,
|
|
27
|
+
factory: ComponentFactory
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=rightsManagementPmp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementPmp.js","sourceRoot":"","sources":["../../../src/components/rightsManagementPmp.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EAAE,4BAA4B,EAAE,MAAM,yCAAyC,CAAC;AAGvF,OAAO,EAAE,gCAAgC,EAAE,MAAM,qDAAqD,CAAC;AAEvG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC3D,UAAsC,EACtC,OAA0C,EAC1C,cAAkD;IAMlD,IAAI,SAAsD,CAAC;IAC3D,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,OAAO,EAAE,CAAC;QACtE,SAAS,GAAG,IAAI,4BAA4B,CAAC;YAC5C,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,sCAAsC,EAAE,UAAU,CAAC,yBAAyB,CAC3E,8BAA8B,CAC9B;YACD,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,oCAAgD,CAAC;IAC9D,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport type { IPolicyManagementPointComponent } from \"@twin.org/rights-management-models\";\nimport { PolicyManagementPointService } from \"@twin.org/rights-management-pmp-service\";\nimport type { RightsManagementPmpComponentConfig } from \"../models/config/rightsManagementPmpComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementPmpComponentType } from \"../models/types/rightsManagementPmpComponentType.js\";\n\n/**\n * Initialise the rights management PMP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementPmpComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementPmpComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IPolicyManagementPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementPmpComponentType.Service) {\n\t\tcomponent = new PolicyManagementPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\tpolicyAdministrationPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPapComponent\"\n\t\t\t),\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(PolicyManagementPointService);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ContextIdHelper, ContextIdKeys } from "@twin.org/context";
|
|
4
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
5
|
+
import { PolicyNegotiationAdminPointService, initSchema as initSchemaRightsManagementPnap } from "@twin.org/rights-management-pnp-service";
|
|
6
|
+
import { PolicyNegotiationAdminPointRestClient } from "@twin.org/rights-management-rest-client";
|
|
7
|
+
import { initialiseEntityStorageConnector } from "./entityStorage.js";
|
|
8
|
+
import { RightsManagementPnapComponentType } from "../models/types/rightsManagementPnapComponentType.js";
|
|
9
|
+
/**
|
|
10
|
+
* Initialise the rights management PNAP component.
|
|
11
|
+
* @param engineCore The engine core.
|
|
12
|
+
* @param context The context for the engine.
|
|
13
|
+
* @param instanceConfig The instance config.
|
|
14
|
+
* @returns The instance created and the factory for it.
|
|
15
|
+
*/
|
|
16
|
+
export async function initialiseRightsManagementPnapComponent(engineCore, context, instanceConfig) {
|
|
17
|
+
let component;
|
|
18
|
+
let instanceType;
|
|
19
|
+
if (instanceConfig.type === RightsManagementPnapComponentType.Service) {
|
|
20
|
+
initSchemaRightsManagementPnap();
|
|
21
|
+
const partitionContextIds = ContextIdHelper.pickKeysFromAvailable(engineCore.getContextIdKeys(), [ContextIdKeys.Node, ContextIdKeys.Tenant]);
|
|
22
|
+
initialiseEntityStorageConnector(engineCore, context, instanceConfig.options?.policyNegotiationEntityStorageType, "PolicyNegotiation", partitionContextIds);
|
|
23
|
+
component = new PolicyNegotiationAdminPointService({
|
|
24
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
25
|
+
taskSchedulerComponentType: engineCore.getRegisteredInstanceType("taskSchedulerComponent"),
|
|
26
|
+
policyInformationPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPipComponent"),
|
|
27
|
+
partitionContextIds,
|
|
28
|
+
...instanceConfig.options
|
|
29
|
+
});
|
|
30
|
+
instanceType = "policy-negotiation-admin-point-service";
|
|
31
|
+
}
|
|
32
|
+
else if (instanceConfig.type === RightsManagementPnapComponentType.RestClient) {
|
|
33
|
+
component = new PolicyNegotiationAdminPointRestClient(instanceConfig.options);
|
|
34
|
+
instanceType = "policy-negotiation-admin-point-rest-client";
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
component,
|
|
38
|
+
instanceType,
|
|
39
|
+
factory: ComponentFactory
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
//# sourceMappingURL=rightsManagementPnap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementPnap.js","sourceRoot":"","sources":["../../../src/components/rightsManagementPnap.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AACnE,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EAEN,kCAAkC,EAClC,UAAU,IAAI,8BAA8B,EAC5C,MAAM,yCAAyC,CAAC;AACjD,OAAO,EAAE,qCAAqC,EAAE,MAAM,yCAAyC,CAAC;AAChG,OAAO,EAAE,gCAAgC,EAAE,MAAM,oBAAoB,CAAC;AAGtE,OAAO,EAAE,iCAAiC,EAAE,MAAM,sDAAsD,CAAC;AAEzG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,uCAAuC,CAC5D,UAAsC,EACtC,OAA0C,EAC1C,cAAmD;IAMnD,IAAI,SAA4D,CAAC;IACjE,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,iCAAiC,CAAC,OAAO,EAAE,CAAC;QACvE,8BAA8B,EAAE,CAAC;QAEjC,MAAM,mBAAmB,GAAG,eAAe,CAAC,qBAAqB,CAChE,UAAU,CAAC,gBAAgB,EAAE,EAC7B,CAAC,aAAa,CAAC,IAAI,EAAE,aAAa,CAAC,MAAM,CAAC,CAC1C,CAAC;QAEF,gCAAgC,CAC/B,UAAU,EACV,OAAO,EACP,cAAc,CAAC,OAAO,EAAE,kCAAkC,uBAE1D,mBAAmB,CACnB,CAAC;QAEF,SAAS,GAAG,IAAI,kCAAkC,CAAC;YAClD,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,0BAA0B,EAAE,UAAU,CAAC,yBAAyB,CAAC,wBAAwB,CAAC;YAC1F,mCAAmC,EAAE,UAAU,CAAC,yBAAyB,CACxE,8BAA8B,CAC9B;YACD,mBAAmB;YACnB,GAAG,cAAc,CAAC,OAAO;SACzB,CAAC,CAAC;QACH,YAAY,2CAAsD,CAAC;IACpE,CAAC;SAAM,IAAI,cAAc,CAAC,IAAI,KAAK,iCAAiC,CAAC,UAAU,EAAE,CAAC;QACjF,SAAS,GAAG,IAAI,qCAAqC,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC;QAC9E,YAAY,+CAAyD,CAAC;IACvE,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ContextIdHelper, ContextIdKeys } from \"@twin.org/context\";\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameof, nameofKebabCase } from \"@twin.org/nameof\";\nimport type { IPolicyNegotiationAdminPointComponent } from \"@twin.org/rights-management-models\";\nimport {\n\ttype PolicyNegotiation,\n\tPolicyNegotiationAdminPointService,\n\tinitSchema as initSchemaRightsManagementPnap\n} from \"@twin.org/rights-management-pnp-service\";\nimport { PolicyNegotiationAdminPointRestClient } from \"@twin.org/rights-management-rest-client\";\nimport { initialiseEntityStorageConnector } from \"./entityStorage.js\";\nimport type { RightsManagementPnapComponentConfig } from \"../models/config/rightsManagementPnapComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementPnapComponentType } from \"../models/types/rightsManagementPnapComponentType.js\";\n\n/**\n * Initialise the rights management PNAP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementPnapComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementPnapComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IPolicyNegotiationAdminPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementPnapComponentType.Service) {\n\t\tinitSchemaRightsManagementPnap();\n\n\t\tconst partitionContextIds = ContextIdHelper.pickKeysFromAvailable(\n\t\t\tengineCore.getContextIdKeys(),\n\t\t\t[ContextIdKeys.Node, ContextIdKeys.Tenant]\n\t\t);\n\n\t\tinitialiseEntityStorageConnector(\n\t\t\tengineCore,\n\t\t\tcontext,\n\t\t\tinstanceConfig.options?.policyNegotiationEntityStorageType,\n\t\t\tnameof<PolicyNegotiation>(),\n\t\t\tpartitionContextIds\n\t\t);\n\n\t\tcomponent = new PolicyNegotiationAdminPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\ttaskSchedulerComponentType: engineCore.getRegisteredInstanceType(\"taskSchedulerComponent\"),\n\t\t\tpolicyInformationPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPipComponent\"\n\t\t\t),\n\t\t\tpartitionContextIds,\n\t\t\t...instanceConfig.options\n\t\t});\n\t\tinstanceType = nameofKebabCase(PolicyNegotiationAdminPointService);\n\t} else if (instanceConfig.type === RightsManagementPnapComponentType.RestClient) {\n\t\tcomponent = new PolicyNegotiationAdminPointRestClient(instanceConfig.options);\n\t\tinstanceType = nameofKebabCase(PolicyNegotiationAdminPointRestClient);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
// Copyright 2024 IOTA Stiftung.
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
+
import { ComponentFactory } from "@twin.org/core";
|
|
4
|
+
import { PolicyNegotiationPointService } from "@twin.org/rights-management-pnp-service";
|
|
5
|
+
import { PolicyNegotiationPointRestClient } from "@twin.org/rights-management-rest-client";
|
|
6
|
+
import { RightsManagementPnpComponentType } from "../models/types/rightsManagementPnpComponentType.js";
|
|
7
|
+
/**
|
|
8
|
+
* Initialise the rights management PNP component.
|
|
9
|
+
* @param engineCore The engine core.
|
|
10
|
+
* @param context The context for the engine.
|
|
11
|
+
* @param instanceConfig The instance config.
|
|
12
|
+
* @returns The instance created and the factory for it.
|
|
13
|
+
*/
|
|
14
|
+
export async function initialiseRightsManagementPnpComponent(engineCore, context, instanceConfig) {
|
|
15
|
+
let component;
|
|
16
|
+
let instanceType;
|
|
17
|
+
if (instanceConfig.type === RightsManagementPnpComponentType.Service) {
|
|
18
|
+
component = new PolicyNegotiationPointService({
|
|
19
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
20
|
+
policyNegotiationAdministrationPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPnapComponent"),
|
|
21
|
+
policyAdministrationPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPapComponent"),
|
|
22
|
+
policyInformationPointComponentType: engineCore.getRegisteredInstanceType("rightsManagementPipComponent"),
|
|
23
|
+
trustComponentType: engineCore.getRegisteredInstanceType("trustComponent"),
|
|
24
|
+
...instanceConfig.options,
|
|
25
|
+
config: {
|
|
26
|
+
...instanceConfig.options?.config
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
instanceType = "policy-negotiation-point-service";
|
|
30
|
+
}
|
|
31
|
+
else if (instanceConfig.type === RightsManagementPnpComponentType.RestClient) {
|
|
32
|
+
component = new PolicyNegotiationPointRestClient(instanceConfig.options);
|
|
33
|
+
instanceType = "policy-negotiation-point-rest-client";
|
|
34
|
+
}
|
|
35
|
+
return {
|
|
36
|
+
component,
|
|
37
|
+
instanceType,
|
|
38
|
+
factory: ComponentFactory
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=rightsManagementPnp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rightsManagementPnp.js","sourceRoot":"","sources":["../../../src/components/rightsManagementPnp.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EAAE,6BAA6B,EAAE,MAAM,yCAAyC,CAAC;AACxF,OAAO,EAAE,gCAAgC,EAAE,MAAM,yCAAyC,CAAC;AAG3F,OAAO,EAAE,gCAAgC,EAAE,MAAM,qDAAqD,CAAC;AAEvG;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC3D,UAAsC,EACtC,OAA0C,EAC1C,cAAkD;IAMlD,IAAI,SAAuD,CAAC;IAC5D,IAAI,YAAgC,CAAC;IAErC,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,OAAO,EAAE,CAAC;QACtE,SAAS,GAAG,IAAI,6BAA6B,CAAC;YAC7C,oBAAoB,EAAE,UAAU,CAAC,yBAAyB,CAAC,kBAAkB,CAAC;YAC9E,iDAAiD,EAAE,UAAU,CAAC,yBAAyB,CACtF,+BAA+B,CAC/B;YACD,sCAAsC,EAAE,UAAU,CAAC,yBAAyB,CAC3E,8BAA8B,CAC9B;YACD,mCAAmC,EAAE,UAAU,CAAC,yBAAyB,CACxE,8BAA8B,CAC9B;YACD,kBAAkB,EAAE,UAAU,CAAC,yBAAyB,CAAC,gBAAgB,CAAC;YAC1E,GAAG,cAAc,CAAC,OAAO;YACzB,MAAM,EAAE;gBACP,GAAG,cAAc,CAAC,OAAO,EAAE,MAAM;aACjC;SACD,CAAC,CAAC;QACH,YAAY,qCAAiD,CAAC;IAC/D,CAAC;SAAM,IAAI,cAAc,CAAC,IAAI,KAAK,gCAAgC,CAAC,UAAU,EAAE,CAAC;QAChF,SAAS,GAAG,IAAI,gCAAgC,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC;QACzE,YAAY,yCAAoD,CAAC;IAClE,CAAC;IAED,OAAO;QACN,SAAS;QACT,YAAY;QACZ,OAAO,EAAE,gBAAgB;KACzB,CAAC;AACH,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport { ComponentFactory, type IComponent } from \"@twin.org/core\";\nimport type { IEngineCore, IEngineCoreContext } from \"@twin.org/engine-models\";\nimport { nameofKebabCase } from \"@twin.org/nameof\";\nimport type { IPolicyNegotiationPointComponent } from \"@twin.org/rights-management-models\";\nimport { PolicyNegotiationPointService } from \"@twin.org/rights-management-pnp-service\";\nimport { PolicyNegotiationPointRestClient } from \"@twin.org/rights-management-rest-client\";\nimport type { RightsManagementPnpComponentConfig } from \"../models/config/rightsManagementPnpComponentConfig.js\";\nimport type { IEngineConfig } from \"../models/IEngineConfig.js\";\nimport { RightsManagementPnpComponentType } from \"../models/types/rightsManagementPnpComponentType.js\";\n\n/**\n * Initialise the rights management PNP component.\n * @param engineCore The engine core.\n * @param context The context for the engine.\n * @param instanceConfig The instance config.\n * @returns The instance created and the factory for it.\n */\nexport async function initialiseRightsManagementPnpComponent(\n\tengineCore: IEngineCore<IEngineConfig>,\n\tcontext: IEngineCoreContext<IEngineConfig>,\n\tinstanceConfig: RightsManagementPnpComponentConfig\n): Promise<{\n\tinstanceType?: string;\n\tfactory?: typeof ComponentFactory;\n\tcomponent?: IComponent;\n}> {\n\tlet component: IPolicyNegotiationPointComponent | undefined;\n\tlet instanceType: string | undefined;\n\n\tif (instanceConfig.type === RightsManagementPnpComponentType.Service) {\n\t\tcomponent = new PolicyNegotiationPointService({\n\t\t\tloggingComponentType: engineCore.getRegisteredInstanceType(\"loggingComponent\"),\n\t\t\tpolicyNegotiationAdministrationPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPnapComponent\"\n\t\t\t),\n\t\t\tpolicyAdministrationPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPapComponent\"\n\t\t\t),\n\t\t\tpolicyInformationPointComponentType: engineCore.getRegisteredInstanceType(\n\t\t\t\t\"rightsManagementPipComponent\"\n\t\t\t),\n\t\t\ttrustComponentType: engineCore.getRegisteredInstanceType(\"trustComponent\"),\n\t\t\t...instanceConfig.options,\n\t\t\tconfig: {\n\t\t\t\t...instanceConfig.options?.config\n\t\t\t}\n\t\t});\n\t\tinstanceType = nameofKebabCase(PolicyNegotiationPointService);\n\t} else if (instanceConfig.type === RightsManagementPnpComponentType.RestClient) {\n\t\tcomponent = new PolicyNegotiationPointRestClient(instanceConfig.options);\n\t\tinstanceType = nameofKebabCase(PolicyNegotiationPointRestClient);\n\t}\n\n\treturn {\n\t\tcomponent,\n\t\tinstanceType,\n\t\tfactory: ComponentFactory\n\t};\n}\n"]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { PolicyArbiterFactory } from "@twin.org/rights-management-models";
|
|
2
|
+
import { ExamplePolicyArbiter } from "@twin.org/rights-management-plugins";
|
|
3
|
+
import { RightsManagementPolicyArbiterComponentType } from "../models/types/rightsManagementPolicyArbiterComponentType.js";
|
|
4
|
+
/**
|
|
5
|
+
* Initialise the rights management policy arbiter component.
|
|
6
|
+
* @param engineCore The engine core.
|
|
7
|
+
* @param context The context for the engine.
|
|
8
|
+
* @param instanceConfig The instance config.
|
|
9
|
+
* @returns The instance created and the factory for it.
|
|
10
|
+
*/
|
|
11
|
+
export async function initialiseRightsManagementPolicyArbiterComponent(engineCore, context, instanceConfig) {
|
|
12
|
+
let component;
|
|
13
|
+
let instanceType;
|
|
14
|
+
if (instanceConfig.type === RightsManagementPolicyArbiterComponentType.Example) {
|
|
15
|
+
component = new ExamplePolicyArbiter({
|
|
16
|
+
loggingComponentType: engineCore.getRegisteredInstanceType("loggingComponent"),
|
|
17
|
+
...instanceConfig.options
|
|
18
|
+
});
|
|
19
|
+
instanceType = "example-policy-arbiter";
|
|
20
|
+
}
|
|
21
|
+
return {
|
|
22
|
+
component,
|
|
23
|
+
instanceType,
|
|
24
|
+
factory: PolicyArbiterFactory
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=rightsManagementPolicyArbiter.js.map
|