diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonAssetAdministrationShellDescriptorDeserializerTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonAssetAdministrationShellDescriptorDeserializerTest.java index 0422c2e2d..9b383e70d 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonAssetAdministrationShellDescriptorDeserializerTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonAssetAdministrationShellDescriptorDeserializerTest.java @@ -51,12 +51,12 @@ public static AssetAdministrationShellDescriptor createAasDescriptor() { .administration(TestDataHelper.DEFAULT_ADMINISTRATIVE_INFORMATION) .description(TestDataHelper.DEFAULT_DESCRIPTION) .displayName(TestDataHelper.DEFAULT_DISPLAY_NAME) - .identification(TestDataHelper.DEFAULT_IDENTIFICATION) + .id(TestDataHelper.DEFAULT_IDENTIFICATION) .idShort(TestDataHelper.DEFAULT_ID_SHORT) - .specificAssetId(specificAssetId) + .specificAssetIds(specificAssetId) .endpoints(List.of(TestDataHelper.createEndpointBuilder().build())) - .globalAssetId(TestDataHelper.createReference(ReferenceTypes.MODEL_REFERENCE, KeyTypes.ASSET_ADMINISTRATION_SHELL, "defaultGlobalAssetId")) - .submodelDescriptor(List.of(JsonSubmodelDescriptorDeserializerTest.getDefaultSubmodelDescriptor())).build(); + .globalAssetId("defaultGlobalAssetId") + .submodelDescriptors(List.of(JsonSubmodelDescriptorDeserializerTest.getDefaultSubmodelDescriptor())).build(); } @Test diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/TestDataHelper.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/TestDataHelper.java index 8f1ab22d8..9339e59c8 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/TestDataHelper.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/TestDataHelper.java @@ -55,7 +55,7 @@ public static DefaultEndpoint.Builder createEndpointBuilder() { return new DefaultEndpoint.Builder() .protocolInformation(createProtocolInformationBuilder().build()) - .withInterface(DEFAULT_INTERFACE_VALUE); + ._interface(DEFAULT_INTERFACE_VALUE); } public static Key createKey(KeyTypes type, String value) { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AasSubmodelElements.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AasSubmodelElements.java index 311f54a79..d11c62e38 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AasSubmodelElements.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AasSubmodelElements.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AbstractLangString.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AbstractLangString.java index 7689f9526..d20808f99 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AbstractLangString.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AbstractLangString.java @@ -19,17 +19,19 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** * Strings with language tags */ @KnownSubtypes({ + @KnownSubtypes.Type(value = LangStringTextType.class), + @KnownSubtypes.Type(value = LangStringNameType.class), @KnownSubtypes.Type(value = LangStringPreferredNameTypeIec61360.class), @KnownSubtypes.Type(value = LangStringShortNameTypeIec61360.class), - @KnownSubtypes.Type(value = LangStringDefinitionTypeIec61360.class), - @KnownSubtypes.Type(value = LangStringNameType.class), - @KnownSubtypes.Type(value = LangStringTextType.class) + @KnownSubtypes.Type(value = LangStringDefinitionTypeIec61360.class) }) public interface AbstractLangString { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AdministrativeInformation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AdministrativeInformation.java index 25e8457fd..feea7db28 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AdministrativeInformation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AdministrativeInformation.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAdministrativeInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElement.java index 987cc7a15..ad4175959 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElement.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAnnotatedRelationshipElement; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElementMetadata.java new file mode 100644 index 000000000..e605dd7d4 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElementMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultAnnotatedRelationshipElementMetadata.class) +}) +public interface AnnotatedRelationshipElementMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElementValue.java new file mode 100644 index 000000000..380959b82 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AnnotatedRelationshipElementValue.java @@ -0,0 +1,87 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultAnnotatedRelationshipElementValue.class) +}) +public interface AnnotatedRelationshipElementValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/first + * + * @return Returns the ReferenceValue for the property first. + */ + @IRI("https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/first") + ReferenceValue getFirst(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/first + * + * @param first desired value for the property first. + */ + void setFirst(ReferenceValue first); + + /** + * + * More information under https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/second + * + * @return Returns the ReferenceValue for the property second. + */ + @IRI("https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/second") + ReferenceValue getSecond(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/second + * + * @param second desired value for the property second. + */ + void setSecond(ReferenceValue second); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/annotation + * + * @return Returns the List of Strings for the property annotation. + */ + @IRI("https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/annotation") + List getAnnotation(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/annotation + * + * @param annotations desired value for the property annotation. + */ + void setAnnotation(List annotations); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShell.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShell.java index 2b51a7a67..bce30a8f3 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShell.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShell.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAssetAdministrationShell; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** @@ -28,7 +30,7 @@ @KnownSubtypes({ @KnownSubtypes.Type(value = DefaultAssetAdministrationShell.class) }) -public interface AssetAdministrationShell extends HasDataSpecification, Identifiable { +public interface AssetAdministrationShell extends Identifiable, HasDataSpecification { /** * The reference to the AAS the AAS was derived from. diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java index 8fcb1be17..5db592f32 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java @@ -1,7 +1,7 @@ /* - * Copyright (c) 2023 SAP SE - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -15,11 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAssetAdministrationShellDescriptor; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; -import java.util.List; /** */ @@ -30,16 +33,18 @@ public interface AssetAdministrationShellDescriptor extends Descriptor { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/administration * * @return Returns the AdministrativeInformation for the property administration. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration") + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/administration") AdministrativeInformation getAdministration(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/administration * * @param administration desired value for the property administration. */ @@ -47,68 +52,92 @@ public interface AssetAdministrationShellDescriptor extends Descriptor { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetKind + * + * @return Returns the AssetKind for the property assetKind. + */ + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetKind") + AssetKind getAssetKind(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetKind * - * @return Returns the LangStringSet for the property description. + * @param assetKind desired value for the property assetKind. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description") - List getDescription(); + void setAssetKind(AssetKind assetKind); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetType * - * @param description desired value for the property description. + * @return Returns the String for the property assetType. */ - void setDescription(List description); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetType") + String getAssetType(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetType * - * @return Returns the LangStringSet for the property displayName. + * @param assetType desired value for the property assetType. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName") - List getDisplayName(); + void setAssetType(String assetType); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/endpoints * - * @param displayName desired value for the property displayName. + * @return Returns the List of Endpoints for the property endpoints. */ - void setDisplayName(List displayName); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/endpoints") + List getEndpoints(); + /** + * + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/endpoints + * + * @param endpoints desired value for the property endpoints. + */ + void setEndpoints(List endpoints); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/globalAssetId * - * @return Returns the String for the property idShort. + * @return Returns the String for the property globalAssetId. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId") - Reference getGlobalAssetId(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/globalAssetId") + String getGlobalAssetId(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/globalAssetId * * @param globalAssetId desired value for the property globalAssetId. */ - void setGlobalAssetId(Reference globalAssetId); + void setGlobalAssetId(String globalAssetId); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/idShort * * @return Returns the String for the property idShort. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort") + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/idShort") String getIdShort(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/idShort * * @param idShort desired value for the property idShort. */ @@ -116,54 +145,57 @@ public interface AssetAdministrationShellDescriptor extends Descriptor { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/identification + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/id * - * @return Returns the String for the property identification. + * @return Returns the String for the property id. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/identification") - String getIdentification(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/id") + String getId(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/identification + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/id * - * @param identification desired value for the property identification. + * @param id desired value for the property id. */ - void setIdentification(String identification); - + void setId(String id); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetId + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/specificAssetIds * - * @return Returns the String for the property specificAssetId. + * @return Returns the List of SpecificAssetIds for the property specificAssetIds. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds") - SpecificAssetId getSpecificAssetIds(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/specificAssetIds") + List getSpecificAssetIds(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/specificAssetIds * * @param specificAssetIds desired value for the property specificAssetIds. */ - void setSpecificAssetIds(SpecificAssetId specificAssetIds); + void setSpecificAssetIds(List specificAssetIds); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/submodelDescriptors * - * @return Returns the String for the property submodelDescriptor. + * @return Returns the List of SubmodelDescriptors for the property submodelDescriptors. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor") - List getSubmodelDescriptor(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/submodelDescriptors") + List getSubmodelDescriptors(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/submodelDescriptors * - * @param submodelDescriptor desired value for the property submodelDescriptor. + * @param submodelDescriptors desired value for the property submodelDescriptors. */ - void setSubmodelDescriptor(List submodelDescriptor); + void setSubmodelDescriptors(List submodelDescriptors); } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellMetadata.java new file mode 100644 index 000000000..e67c00d7e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellMetadata.java @@ -0,0 +1,53 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultAssetAdministrationShellMetadata.class) +}) +public interface AssetAdministrationShellMetadata extends Identifiable, HasDataSpecification { + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellMetadata/derivedFrom + * + * @return Returns the List of References for the property derivedFrom. + */ + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellMetadata/derivedFrom") + List getDerivedFrom(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/AssetAdministrationShellMetadata/derivedFrom + * + * @param derivedFroms desired value for the property derivedFrom. + */ + void setDerivedFrom(List derivedFroms); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetInformation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetInformation.java index 61ce8f421..62446eb0a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetInformation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetInformation.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAssetInformation; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetKind.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetKind.java index 80401d406..9167faa1d 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetKind.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetKind.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElement.java index b4544ceef..a3711ed09 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElement.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultBasicEventElement; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElementMetadata.java new file mode 100644 index 000000000..0f9266596 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElementMetadata.java @@ -0,0 +1,153 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultBasicEventElementMetadata.class) +}) +public interface BasicEventElementMetadata extends SubmodelElementAttributes { + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/direction + * + * @return Returns the List of Directions for the property direction. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/direction") + List getDirection(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/direction + * + * @param directions desired value for the property direction. + */ + void setDirection(List directions); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/state + * + * @return Returns the List of StateOfEvents for the property state. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/state") + List getState(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/state + * + * @param states desired value for the property state. + */ + void setState(List states); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageBroker + * + * @return Returns the List of References for the property messageBroker. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageBroker") + List getMessageBroker(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageBroker + * + * @param messageBrokers desired value for the property messageBroker. + */ + void setMessageBroker(List messageBrokers); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageTopic + * + * @return Returns the List of Strings for the property messageTopic. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageTopic") + List getMessageTopic(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageTopic + * + * @param messageTopics desired value for the property messageTopic. + */ + void setMessageTopic(List messageTopics); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/lastUpdate + * + * @return Returns the List of Strings for the property lastUpdate. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/lastUpdate") + List getLastUpdate(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/lastUpdate + * + * @param lastUpdates desired value for the property lastUpdate. + */ + void setLastUpdate(List lastUpdates); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/minInterval + * + * @return Returns the List of Strings for the property minInterval. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/minInterval") + List getMinInterval(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/minInterval + * + * @param minIntervals desired value for the property minInterval. + */ + void setMinInterval(List minIntervals); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/maxInterval + * + * @return Returns the List of Strings for the property maxInterval. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/maxInterval") + List getMaxInterval(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementMetadata/maxInterval + * + * @param maxIntervals desired value for the property maxInterval. + */ + void setMaxInterval(List maxIntervals); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElementValue.java new file mode 100644 index 000000000..5821d0683 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BasicEventElementValue.java @@ -0,0 +1,51 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultBasicEventElementValue.class) +}) +public interface BasicEventElementValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementValue/observed + * + * @return Returns the List of ReferenceValues for the property observed. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementValue/observed") + List getObserved(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElementValue/observed + * + * @param observeds desired value for the property observed. + */ + void setObserved(List observeds); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Blob.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Blob.java index 1edb58bed..0b5f00142 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Blob.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Blob.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultBlob; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BlobMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BlobMetadata.java new file mode 100644 index 000000000..a8618e898 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BlobMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultBlobMetadata.class) +}) +public interface BlobMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BlobValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BlobValue.java new file mode 100644 index 000000000..6f44bab2e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/BlobValue.java @@ -0,0 +1,67 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultBlobValue.class) +}) +public interface BlobValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/BlobValue/mimeType + * + * @return Returns the String for the property mimeType. + */ + @IRI("https://admin-shell.io/aas/3/0/BlobValue/mimeType") + String getMimeType(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BlobValue/mimeType + * + * @param mimeType desired value for the property mimeType. + */ + void setMimeType(String mimeType); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BlobValue/value + * + * @return Returns the String for the property value. + */ + @IRI("https://admin-shell.io/aas/3/0/BlobValue/value") + String getValue(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/BlobValue/value + * + * @param value desired value for the property value. + */ + void setValue(String value); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Capability.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Capability.java index 0dc242c2f..d7bde51c4 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Capability.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Capability.java @@ -16,8 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultCapability; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/CapabilityMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/CapabilityMetadata.java new file mode 100644 index 000000000..419061f90 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/CapabilityMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultCapabilityMetadata.class) +}) +public interface CapabilityMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ConceptDescription.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ConceptDescription.java index 724d31fed..2e50360a6 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ConceptDescription.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ConceptDescription.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultConceptDescription; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** @@ -29,7 +31,7 @@ @KnownSubtypes({ @KnownSubtypes.Type(value = DefaultConceptDescription.class) }) -public interface ConceptDescription extends HasDataSpecification, Identifiable { +public interface ConceptDescription extends Identifiable, HasDataSpecification { /** * Reference to an external definition the concept is compatible to or was derived from. diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataElement.java index 628d658af..8778ba3d7 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataElement.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationContent.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationContent.java index e2933c187..f4e56cc03 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationContent.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationContent.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationIec61360.java index 182a70102..01a398b69 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataSpecificationIec61360.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultDataSpecificationIec61360; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeDefXsd.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeDefXsd.java index cb41effbd..086da3f52 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeDefXsd.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeDefXsd.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeIec61360.java index d0ddfa144..841aa9552 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/DataTypeIec61360.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.java index a06e883fc..66c980c48 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -17,33 +17,71 @@ import java.util.List; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultDescriptor; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + /** */ @KnownSubtypes({ @KnownSubtypes.Type(value = DefaultDescriptor.class), + @KnownSubtypes.Type(value = AssetAdministrationShellDescriptor.class), @KnownSubtypes.Type(value = SubmodelDescriptor.class) }) public interface Descriptor { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints + * More information under https://admin-shell.io/aas/3/0/Descriptor/description + * + * @return Returns the List of LangStringTextTypes for the property description. + */ + @IRI("https://admin-shell.io/aas/3/0/Descriptor/description") + List getDescription(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Descriptor/description + * + * @param descriptions desired value for the property description. + */ + void setDescription(List descriptions); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Descriptor/displayName + * + * @return Returns the List of LangStringNameTypes for the property displayName. + */ + @IRI("https://admin-shell.io/aas/3/0/Descriptor/displayName") + List getDisplayName(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Descriptor/displayName + * + * @param displayNames desired value for the property displayName. + */ + void setDisplayName(List displayNames); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Descriptor/extensions * - * @return Returns the List of Endpoints for the property endpoints. + * @return Returns the List of Extensions for the property extensions. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") - List getEndpoints(); + @IRI("https://admin-shell.io/aas/3/0/Descriptor/extensions") + List getExtensions(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints + * More information under https://admin-shell.io/aas/3/0/Descriptor/extensions * - * @param endpoints desired value for the property endpoints. + * @param extensions desired value for the property extensions. */ - void setEndpoints(List endpoints); + void setExtensions(List extensions); } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Direction.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Direction.java index dcc154a6c..7d5a87c34 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Direction.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Direction.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EmbeddedDataSpecification.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EmbeddedDataSpecification.java index 48c3a2ccb..7b4116345 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EmbeddedDataSpecification.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EmbeddedDataSpecification.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultEmbeddedDataSpecification; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java index fa8b8fee6..35a90ca9a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -15,10 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultEndpoint; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + +/** +*/ @KnownSubtypes({ @KnownSubtypes.Type(value = DefaultEndpoint.class) }) @@ -26,33 +32,33 @@ public interface Endpoint { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/interface + * More information under https://admin-shell.io/aas/3/0/Endpoint/_interface * - * @return Returns the String for the property interface. + * @return Returns the String for the property _interface. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/interface") - String getInterface(); + @IRI("https://admin-shell.io/aas/3/0/Endpoint/_interface") + String get_interface(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/interface + * More information under https://admin-shell.io/aas/3/0/Endpoint/_interface * - * @param interfaceValue desired value for the property interface. + * @param _interface desired value for the property _interface. */ - void setInterface(String interfaceValue); + void set_interface(String _interface); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation + * More information under https://admin-shell.io/aas/3/0/Endpoint/protocolInformation * * @return Returns the ProtocolInformation for the property protocolInformation. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation") + @IRI("https://admin-shell.io/aas/3/0/Endpoint/protocolInformation") ProtocolInformation getProtocolInformation(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation + * More information under https://admin-shell.io/aas/3/0/Endpoint/protocolInformation * * @param protocolInformation desired value for the property protocolInformation. */ diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Entity.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Entity.java index c29c453e2..bd30d4bf3 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Entity.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Entity.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultEntity; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityMetadata.java new file mode 100644 index 000000000..bd64f2d0f --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultEntityMetadata.class) +}) +public interface EntityMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityType.java index 233102815..5455d6325 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityType.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityType.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityValue.java new file mode 100644 index 000000000..1b0b79f48 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityValue.java @@ -0,0 +1,102 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultEntityValue.class) +}) +public interface EntityValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/entityType + * + * @return Returns the EntityType for the property entityType. + */ + @IRI("https://admin-shell.io/aas/3/0/EntityValue/entityType") + EntityType getEntityType(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/entityType + * + * @param entityType desired value for the property entityType. + */ + void setEntityType(EntityType entityType); + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/globalAssetId + * + * @return Returns the ReferenceValue for the property globalAssetId. + */ + @IRI("https://admin-shell.io/aas/3/0/EntityValue/globalAssetId") + ReferenceValue getGlobalAssetId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/globalAssetId + * + * @param globalAssetId desired value for the property globalAssetId. + */ + void setGlobalAssetId(ReferenceValue globalAssetId); + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/specificAssetIds + * + * @return Returns the List of Strings for the property specificAssetIds. + */ + @IRI("https://admin-shell.io/aas/3/0/EntityValue/specificAssetIds") + List getSpecificAssetIds(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/specificAssetIds + * + * @param specificAssetIds desired value for the property specificAssetIds. + */ + void setSpecificAssetIds(List specificAssetIds); + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/statements + * + * @return Returns the List of Strings for the property statements. + */ + @IRI("https://admin-shell.io/aas/3/0/EntityValue/statements") + List getStatements(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/EntityValue/statements + * + * @param statements desired value for the property statements. + */ + void setStatements(List statements); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Environment.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Environment.java index e41524972..e6c9602a4 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Environment.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Environment.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultEnvironment; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventElement.java index a134a0289..de036b8b1 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventElement.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventPayload.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventPayload.java index 42720b37c..831625266 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventPayload.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EventPayload.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultEventPayload; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ExecutionState.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ExecutionState.java new file mode 100644 index 000000000..f3a6208a2 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ExecutionState.java @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@IRI("aas:ExecutionState") +public enum ExecutionState { + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ExecutionState/Canceled") + CANCELED, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ExecutionState/Completed") + COMPLETED, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ExecutionState/Failed") + FAILED, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ExecutionState/Initiated") + INITIATED, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ExecutionState/Running") + RUNNING, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ExecutionState/Timeout") + TIMEOUT; + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Extension.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Extension.java index c3c5f2659..60eac5536 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Extension.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Extension.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultExtension; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/File.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/File.java index ed40d2d1e..3f63ede40 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/File.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/File.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultFile; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/FileMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/FileMetadata.java new file mode 100644 index 000000000..3847ea8e0 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/FileMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultFileMetadata.class) +}) +public interface FileMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/FileValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/FileValue.java new file mode 100644 index 000000000..d8afd59bb --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/FileValue.java @@ -0,0 +1,67 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultFileValue.class) +}) +public interface FileValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/FileValue/contentType + * + * @return Returns the String for the property contentType. + */ + @IRI("https://admin-shell.io/aas/3/0/FileValue/contentType") + String getContentType(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/FileValue/contentType + * + * @param contentType desired value for the property contentType. + */ + void setContentType(String contentType); + + /** + * + * More information under https://admin-shell.io/aas/3/0/FileValue/value + * + * @return Returns the String for the property value. + */ + @IRI("https://admin-shell.io/aas/3/0/FileValue/value") + String getValue(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/FileValue/value + * + * @param value desired value for the property value. + */ + void setValue(String value); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasDataSpecification.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasDataSpecification.java index 5887c38e5..f47141a40 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasDataSpecification.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasDataSpecification.java @@ -15,10 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** @@ -26,6 +29,9 @@ */ @KnownSubtypes({ @KnownSubtypes.Type(value = AdministrativeInformation.class), + @KnownSubtypes.Type(value = AssetAdministrationShellMetadata.class), + @KnownSubtypes.Type(value = SubmodelElementAttributes.class), + @KnownSubtypes.Type(value = SubmodelMetadata.class), @KnownSubtypes.Type(value = AssetAdministrationShell.class), @KnownSubtypes.Type(value = ConceptDescription.class), @KnownSubtypes.Type(value = SubmodelElement.class), diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasExtensions.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasExtensions.java index 761b5baca..708fdaf96 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasExtensions.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasExtensions.java @@ -15,10 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasKind.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasKind.java index 452c60ee1..a2cbddf95 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasKind.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasKind.java @@ -19,6 +19,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasSemantics.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasSemantics.java index 41f9b9978..7a4234138 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasSemantics.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/HasSemantics.java @@ -15,10 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** @@ -26,9 +29,11 @@ */ @KnownSubtypes({ @KnownSubtypes.Type(value = SpecificAssetId.class), + @KnownSubtypes.Type(value = SubmodelElementAttributes.class), + @KnownSubtypes.Type(value = SubmodelMetadata.class), + @KnownSubtypes.Type(value = Extension.class), @KnownSubtypes.Type(value = SubmodelElement.class), @KnownSubtypes.Type(value = Submodel.class), - @KnownSubtypes.Type(value = Extension.class), @KnownSubtypes.Type(value = Qualifier.class) }) public interface HasSemantics { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Identifiable.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Identifiable.java index 6cf22f3bf..b11e8c126 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Identifiable.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Identifiable.java @@ -19,12 +19,16 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** * An element that has a globally unique identifier. */ @KnownSubtypes({ + @KnownSubtypes.Type(value = AssetAdministrationShellMetadata.class), + @KnownSubtypes.Type(value = SubmodelMetadata.class), @KnownSubtypes.Type(value = AssetAdministrationShell.class), @KnownSubtypes.Type(value = ConceptDescription.class), @KnownSubtypes.Type(value = Submodel.class) diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Key.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Key.java index f91b08a96..cbc52210a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Key.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Key.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultKey; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/KeyTypes.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/KeyTypes.java index 84d18f137..a4ec782f9 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/KeyTypes.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/KeyTypes.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangString.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangString.java new file mode 100644 index 000000000..3c0210a9e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangString.java @@ -0,0 +1,96 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.io.Serializable; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +@IRI("rdf:langString") +public class LangString implements Serializable { + + private String language = null; + private String value = null; + + public LangString() { + super(); + } + + public LangString(String valueAndLanguage) { + if (valueAndLanguage.contains("@")) { + String[] splitString = valueAndLanguage.split("@"); + this.value = splitString[0]; + this.language = splitString[1]; + } else { + this.value = valueAndLanguage; + } + } + + public LangString(String value, String language) { + this.value = value; + this.language = language; + } + + public String getLanguage() { + return language; + } + + public void setLanguage(String language) { + this.language = language; + } + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + LangString other = (LangString) obj; + return Objects.equals(this.language, other.language) && Objects.equals(this.value, other.value); + } + } + + @Override + public int hashCode() { + return Objects.hash(this.language, this.value); + } + + @Override + public String toString() { + String result = this.value; + if (this.language != null && !this.language.isEmpty()) { + return "\"" + result + "\"@" + this.language; + } + return result; + } + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringDefinitionTypeIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringDefinitionTypeIec61360.java index fb49700bd..265aa039e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringDefinitionTypeIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringDefinitionTypeIec61360.java @@ -16,8 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultLangStringDefinitionTypeIec61360; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringNameType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringNameType.java index 1fe4604ef..464e95aef 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringNameType.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringNameType.java @@ -16,8 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultLangStringNameType; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringPreferredNameTypeIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringPreferredNameTypeIec61360.java index e03afda72..40168c841 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringPreferredNameTypeIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringPreferredNameTypeIec61360.java @@ -16,8 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultLangStringPreferredNameTypeIec61360; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringShortNameTypeIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringShortNameTypeIec61360.java index 98fcdaf14..141eae315 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringShortNameTypeIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringShortNameTypeIec61360.java @@ -16,8 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultLangStringShortNameTypeIec61360; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringTextType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringTextType.java index 2ff44c065..78a0df8e9 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringTextType.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangStringTextType.java @@ -16,8 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultLangStringTextType; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LevelType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LevelType.java index 4f3931d96..7a9b37528 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LevelType.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LevelType.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultLevelType; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Message.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Message.java new file mode 100644 index 000000000..300e7cf84 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Message.java @@ -0,0 +1,101 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultMessage.class) +}) +public interface Message { + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/code + * + * @return Returns the String for the property code. + */ + @IRI("https://admin-shell.io/aas/3/0/Message/code") + String getCode(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/code + * + * @param code desired value for the property code. + */ + void setCode(String code); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/messageType + * + * @return Returns the MessageType for the property messageType. + */ + @IRI("https://admin-shell.io/aas/3/0/Message/messageType") + MessageType getMessageType(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/messageType + * + * @param messageType desired value for the property messageType. + */ + void setMessageType(MessageType messageType); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/text + * + * @return Returns the String for the property text. + */ + @IRI("https://admin-shell.io/aas/3/0/Message/text") + String getText(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/text + * + * @param text desired value for the property text. + */ + void setText(String text); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/timestamp + * + * @return Returns the String for the property timestamp. + */ + @IRI("https://admin-shell.io/aas/3/0/Message/timestamp") + String getTimestamp(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Message/timestamp + * + * @param timestamp desired value for the property timestamp. + */ + void setTimestamp(String timestamp); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MessageType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MessageType.java new file mode 100644 index 000000000..056035fcd --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MessageType.java @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@IRI("aas:MessageType") +public enum MessageType { + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/MessageType/Error") + ERROR, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/MessageType/Exception") + EXCEPTION, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/MessageType/Info") + INFO, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/MessageType/Undefined") + UNDEFINED, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/MessageType/Warning") + WARNING; + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ModelType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ModelType.java new file mode 100644 index 000000000..3997cf660 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ModelType.java @@ -0,0 +1,125 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@IRI("aas:ModelType") +public enum ModelType { + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/AnnotatedRelationshipElement") + ANNOTATED_RELATIONSHIP_ELEMENT, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/AssetAdministrationShell") + ASSET_ADMINISTRATION_SHELL, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/BasicEventElement") + BASIC_EVENT_ELEMENT, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Blob") + BLOB, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Capability") + CAPABILITY, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/ConceptDescription") + CONCEPT_DESCRIPTION, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Entity") + ENTITY, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/File") + FILE, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/MultiLanguageProperty") + MULTI_LANGUAGE_PROPERTY, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Operation") + OPERATION, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Property") + PROPERTY, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Qualifier") + QUALIFIER, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Range") + RANGE, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Reference") + REFERENCE, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/ReferenceElement") + REFERENCE_ELEMENT, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/RelationshipElement") + RELATIONSHIP_ELEMENT, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/Submodel") + SUBMODEL, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/SubmodelElementCollection") + SUBMODEL_ELEMENT_COLLECTION, + + /** + */ + @IRI("https://admin-shell.io/aas/3/0/ModelType/SubmodelElementList") + SUBMODEL_ELEMENT_LIST; + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ModellingKind.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ModellingKind.java index aba02a581..fb51c79d6 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ModellingKind.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ModellingKind.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguageProperty.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguageProperty.java index 5058811c4..95e1ea322 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguageProperty.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguageProperty.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultMultiLanguageProperty; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguagePropertyMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguagePropertyMetadata.java new file mode 100644 index 000000000..c6fb480b3 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguagePropertyMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultMultiLanguagePropertyMetadata.class) +}) +public interface MultiLanguagePropertyMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguagePropertyValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguagePropertyValue.java new file mode 100644 index 000000000..055ddbfef --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/MultiLanguagePropertyValue.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultMultiLanguagePropertyValue.class) +}) +public interface MultiLanguagePropertyValue { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/NumberValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/NumberValue.java new file mode 100644 index 000000000..d228e3deb --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/NumberValue.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultNumberValue.class) +}) +public interface NumberValue { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Operation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Operation.java index 093835165..3e5c44d7d 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Operation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Operation.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultOperation; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationHandle.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationHandle.java new file mode 100644 index 000000000..27518cff5 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationHandle.java @@ -0,0 +1,67 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultOperationHandle.class) +}) +public interface OperationHandle { + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationHandle/handleId + * + * @return Returns the String for the property handleId. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationHandle/handleId") + String getHandleId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationHandle/handleId + * + * @param handleId desired value for the property handleId. + */ + void setHandleId(String handleId); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationHandle/requestId + * + * @return Returns the String for the property requestId. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationHandle/requestId") + String getRequestId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationHandle/requestId + * + * @param requestId desired value for the property requestId. + */ + void setRequestId(String requestId); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationMetadata.java new file mode 100644 index 000000000..de6132fcf --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultOperationMetadata.class) +}) +public interface OperationMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationRequest.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationRequest.java new file mode 100644 index 000000000..e3dadf435 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationRequest.java @@ -0,0 +1,102 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.math.BigInteger; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultOperationRequest.class) +}) +public interface OperationRequest { + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/inoutputArguments + * + * @return Returns the OperationVariable for the property inoutputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/inoutputArguments") + OperationVariable getInoutputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/inoutputArguments + * + * @param inoutputArguments desired value for the property inoutputArguments. + */ + void setInoutputArguments(OperationVariable inoutputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/inputArguments + * + * @return Returns the OperationVariable for the property inputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/inputArguments") + OperationVariable getInputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/inputArguments + * + * @param inputArguments desired value for the property inputArguments. + */ + void setInputArguments(OperationVariable inputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/requestId + * + * @return Returns the String for the property requestId. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/requestId") + String getRequestId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/requestId + * + * @param requestId desired value for the property requestId. + */ + void setRequestId(String requestId); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/timeout + * + * @return Returns the BigInteger for the property timeout. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/timeout") + BigInteger getTimeout(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequest/timeout + * + * @param timeout desired value for the property timeout. + */ + void setTimeout(BigInteger timeout); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationRequestValueOnly.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationRequestValueOnly.java new file mode 100644 index 000000000..716877b3f --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationRequestValueOnly.java @@ -0,0 +1,102 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.math.BigInteger; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultOperationRequestValueOnly.class) +}) +public interface OperationRequestValueOnly { + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inoutputArguments + * + * @return Returns the String for the property inoutputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inoutputArguments") + String getInoutputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inoutputArguments + * + * @param inoutputArguments desired value for the property inoutputArguments. + */ + void setInoutputArguments(String inoutputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inputArguments + * + * @return Returns the String for the property inputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inputArguments") + String getInputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inputArguments + * + * @param inputArguments desired value for the property inputArguments. + */ + void setInputArguments(String inputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/requestId + * + * @return Returns the String for the property requestId. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/requestId") + String getRequestId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/requestId + * + * @param requestId desired value for the property requestId. + */ + void setRequestId(String requestId); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/timeout + * + * @return Returns the BigInteger for the property timeout. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/timeout") + BigInteger getTimeout(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationRequestValueOnly/timeout + * + * @param timeout desired value for the property timeout. + */ + void setTimeout(BigInteger timeout); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationResult.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationResult.java new file mode 100644 index 000000000..132522a70 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationResult.java @@ -0,0 +1,118 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultOperationResult.class) +}) +public interface OperationResult { + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/executionResult + * + * @return Returns the Result for the property executionResult. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResult/executionResult") + Result getExecutionResult(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/executionResult + * + * @param executionResult desired value for the property executionResult. + */ + void setExecutionResult(Result executionResult); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/executionState + * + * @return Returns the ExecutionState for the property executionState. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResult/executionState") + ExecutionState getExecutionState(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/executionState + * + * @param executionState desired value for the property executionState. + */ + void setExecutionState(ExecutionState executionState); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/inoutputArguments + * + * @return Returns the OperationVariable for the property inoutputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResult/inoutputArguments") + OperationVariable getInoutputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/inoutputArguments + * + * @param inoutputArguments desired value for the property inoutputArguments. + */ + void setInoutputArguments(OperationVariable inoutputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/outputArguments + * + * @return Returns the OperationVariable for the property outputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResult/outputArguments") + OperationVariable getOutputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/outputArguments + * + * @param outputArguments desired value for the property outputArguments. + */ + void setOutputArguments(OperationVariable outputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/requestId + * + * @return Returns the String for the property requestId. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResult/requestId") + String getRequestId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResult/requestId + * + * @param requestId desired value for the property requestId. + */ + void setRequestId(String requestId); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationResultValueOnly.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationResultValueOnly.java new file mode 100644 index 000000000..e0f9d87a7 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationResultValueOnly.java @@ -0,0 +1,119 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultOperationResultValueOnly.class) +}) +public interface OperationResultValueOnly { + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionResult + * + * @return Returns the List of Results for the property executionResult. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionResult") + List getExecutionResult(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionResult + * + * @param executionResults desired value for the property executionResult. + */ + void setExecutionResult(List executionResults); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionState + * + * @return Returns the List of ExecutionStates for the property executionState. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionState") + List getExecutionState(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionState + * + * @param executionStates desired value for the property executionState. + */ + void setExecutionState(List executionStates); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/inoutputArguments + * + * @return Returns the List of Strings for the property inoutputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/inoutputArguments") + List getInoutputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/inoutputArguments + * + * @param inoutputArguments desired value for the property inoutputArguments. + */ + void setInoutputArguments(List inoutputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/outputArguments + * + * @return Returns the List of Strings for the property outputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/outputArguments") + List getOutputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/outputArguments + * + * @param outputArguments desired value for the property outputArguments. + */ + void setOutputArguments(List outputArguments); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/requestId + * + * @return Returns the List of Strings for the property requestId. + */ + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/requestId") + List getRequestId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/OperationResultValueOnly/requestId + * + * @param requestIds desired value for the property requestId. + */ + void setRequestId(List requestIds); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationVariable.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationVariable.java index c61563481..3b3a93ba6 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationVariable.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/OperationVariable.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultOperationVariable; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/PackageDescription.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/PackageDescription.java new file mode 100644 index 000000000..40d24e8cc --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/PackageDescription.java @@ -0,0 +1,68 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultPackageDescription.class) +}) +public interface PackageDescription { + + /** + * + * More information under https://admin-shell.io/aas/3/0/PackageDescription/items + * + * @return Returns the List of Strings for the property items. + */ + @IRI("https://admin-shell.io/aas/3/0/PackageDescription/items") + List getItems(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/PackageDescription/items + * + * @param items desired value for the property items. + */ + void setItems(List items); + + /** + * + * More information under https://admin-shell.io/aas/3/0/PackageDescription/packageId + * + * @return Returns the String for the property packageId. + */ + @IRI("https://admin-shell.io/aas/3/0/PackageDescription/packageId") + String getPackageId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/PackageDescription/packageId + * + * @param packageId desired value for the property packageId. + */ + void setPackageId(String packageId); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Property.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Property.java index 72fc83156..4b9859893 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Property.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Property.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultProperty; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/PropertyMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/PropertyMetadata.java new file mode 100644 index 000000000..7faf7300f --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/PropertyMetadata.java @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultPropertyMetadata.class) +}) +public interface PropertyMetadata extends SubmodelElementAttributes { + + /** + * + * More information under https://admin-shell.io/aas/3/0/PropertyMetadata/valueType + * + * @return Returns the DataTypeDefXsd for the property valueType. + */ + @IRI("https://admin-shell.io/aas/3/0/PropertyMetadata/valueType") + DataTypeDefXsd getValueType(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/PropertyMetadata/valueType + * + * @param valueType desired value for the property valueType. + */ + void setValueType(DataTypeDefXsd valueType); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java index 8b4527f69..037c9c2fd 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -15,9 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultProtocolInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + /** */ @@ -28,16 +32,16 @@ public interface ProtocolInformation { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/endpointAddress * * @return Returns the String for the property endpointAddress. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/endpointAddress") String getEndpointAddress(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/endpointAddress * * @param endpointAddress desired value for the property endpointAddress. */ @@ -45,16 +49,16 @@ public interface ProtocolInformation { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocol * * @return Returns the String for the property endpointProtocol. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocol") String getEndpointProtocol(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocol * * @param endpointProtocol desired value for the property endpointProtocol. */ @@ -62,18 +66,16 @@ public interface ProtocolInformation { /** * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocolVersion * * @return Returns the String for the property endpointProtocolVersion. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocolVersion") String getEndpointProtocolVersion(); /** * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocolVersion * * @param endpointProtocolVersion desired value for the property endpointProtocolVersion. */ @@ -81,16 +83,16 @@ public interface ProtocolInformation { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocol * * @return Returns the String for the property subprotocol. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocol") String getSubprotocol(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocol * * @param subprotocol desired value for the property subprotocol. */ @@ -98,16 +100,16 @@ public interface ProtocolInformation { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBody * * @return Returns the String for the property subprotocolBody. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBody") String getSubprotocolBody(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBody * * @param subprotocolBody desired value for the property subprotocolBody. */ @@ -115,18 +117,16 @@ public interface ProtocolInformation { /** * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBodyEncoding * * @return Returns the String for the property subprotocolBodyEncoding. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBodyEncoding") String getSubprotocolBodyEncoding(); /** * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding + * More information under https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBodyEncoding * * @param subprotocolBodyEncoding desired value for the property subprotocolBodyEncoding. */ diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifiable.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifiable.java index d8f0e2e84..d62f20704 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifiable.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifiable.java @@ -15,16 +15,21 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** * The value of a qualifiable element may be further qualified by one or more qualifiers. */ @KnownSubtypes({ + @KnownSubtypes.Type(value = SubmodelElementAttributes.class), + @KnownSubtypes.Type(value = SubmodelMetadata.class), @KnownSubtypes.Type(value = SubmodelElement.class), @KnownSubtypes.Type(value = Submodel.class) }) diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifier.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifier.java index fd3876c9d..084218df8 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifier.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Qualifier.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultQualifier; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/QualifierKind.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/QualifierKind.java index 3f34d3abd..0cf38b450 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/QualifierKind.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/QualifierKind.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Range.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Range.java index 9c9c60f51..182b9d34a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Range.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Range.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultRange; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RangeMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RangeMetadata.java new file mode 100644 index 000000000..748fb4cde --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RangeMetadata.java @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultRangeMetadata.class) +}) +public interface RangeMetadata extends SubmodelElementAttributes { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RangeMetadata/valueType + * + * @return Returns the DataTypeDefXsd for the property valueType. + */ + @IRI("https://admin-shell.io/aas/3/0/RangeMetadata/valueType") + DataTypeDefXsd getValueType(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RangeMetadata/valueType + * + * @param valueType desired value for the property valueType. + */ + void setValueType(DataTypeDefXsd valueType); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RangeValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RangeValue.java new file mode 100644 index 000000000..dc0b8f1c0 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RangeValue.java @@ -0,0 +1,68 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.math.BigInteger; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultRangeValue.class) +}) +public interface RangeValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RangeValue/max + * + * @return Returns the BigInteger for the property max. + */ + @IRI("https://admin-shell.io/aas/3/0/RangeValue/max") + BigInteger getMax(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RangeValue/max + * + * @param max desired value for the property max. + */ + void setMax(BigInteger max); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RangeValue/min + * + * @return Returns the BigInteger for the property min. + */ + @IRI("https://admin-shell.io/aas/3/0/RangeValue/min") + BigInteger getMin(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RangeValue/min + * + * @param min desired value for the property min. + */ + void setMin(BigInteger min); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Referable.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Referable.java index 71c5e6ad8..6800bdb6e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Referable.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Referable.java @@ -15,18 +15,22 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** * An element that is referable by its 'idShort'. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = SubmodelElement.class), - @KnownSubtypes.Type(value = Identifiable.class) + @KnownSubtypes.Type(value = SubmodelElementAttributes.class), + @KnownSubtypes.Type(value = Identifiable.class), + @KnownSubtypes.Type(value = SubmodelElement.class) }) public interface Referable extends HasExtensions { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Reference.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Reference.java index ee6ceffda..0fa5eb431 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Reference.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Reference.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultReference; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElement.java index 40a6de3a5..bb2bae46b 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElement.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultReferenceElement; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElementMetadata.java new file mode 100644 index 000000000..0ae63f8a9 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElementMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultReferenceElementMetadata.class) +}) +public interface ReferenceElementMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElementValue.java new file mode 100644 index 000000000..20a03f4fc --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceElementValue.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultReferenceElementValue.class) +}) +public interface ReferenceElementValue extends ReferenceValue { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceTypes.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceTypes.java index 99ded8f49..0298bfd5f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceTypes.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceTypes.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceValue.java new file mode 100644 index 000000000..439c072fc --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ReferenceValue.java @@ -0,0 +1,52 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultReferenceValue.class), + @KnownSubtypes.Type(value = ReferenceElementValue.class) +}) +public interface ReferenceValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/ReferenceValue/outputArguments + * + * @return Returns the List of Keys for the property outputArguments. + */ + @IRI("https://admin-shell.io/aas/3/0/ReferenceValue/outputArguments") + List getOutputArguments(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/ReferenceValue/outputArguments + * + * @param outputArguments desired value for the property outputArguments. + */ + void setOutputArguments(List outputArguments); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElement.java index 986c78aa2..124e7d1f9 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElement.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultRelationshipElement; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElementMetadata.java new file mode 100644 index 000000000..f25f0c56d --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElementMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultRelationshipElementMetadata.class) +}) +public interface RelationshipElementMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElementValue.java new file mode 100644 index 000000000..623499f0c --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/RelationshipElementValue.java @@ -0,0 +1,67 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultRelationshipElementValue.class) +}) +public interface RelationshipElementValue { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RelationshipElementValue/first + * + * @return Returns the ReferenceValue for the property first. + */ + @IRI("https://admin-shell.io/aas/3/0/RelationshipElementValue/first") + ReferenceValue getFirst(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RelationshipElementValue/first + * + * @param first desired value for the property first. + */ + void setFirst(ReferenceValue first); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RelationshipElementValue/second + * + * @return Returns the ReferenceValue for the property second. + */ + @IRI("https://admin-shell.io/aas/3/0/RelationshipElementValue/second") + ReferenceValue getSecond(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RelationshipElementValue/second + * + * @param second desired value for the property second. + */ + void setSecond(ReferenceValue second); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Resource.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Resource.java index 4534c1408..51090767f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Resource.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Resource.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultResource; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Result.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Result.java new file mode 100644 index 000000000..306347927 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Result.java @@ -0,0 +1,68 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultResult.class) +}) +public interface Result { + + /** + * + * More information under https://admin-shell.io/aas/3/0/Result/messages + * + * @return Returns the List of Messages for the property messages. + */ + @IRI("https://admin-shell.io/aas/3/0/Result/messages") + List getMessages(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Result/messages + * + * @param messages desired value for the property messages. + */ + void setMessages(List messages); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Result/success + * + * @return Returns the boolean for the property success. + */ + @IRI("https://admin-shell.io/aas/3/0/Result/success") + boolean getSuccess(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/Result/success + * + * @param success desired value for the property success. + */ + void setSuccess(boolean success); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SpecificAssetId.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SpecificAssetId.java index c868e3e2b..40e6aac22 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SpecificAssetId.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SpecificAssetId.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetId; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/StateOfEvent.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/StateOfEvent.java index c71416c94..e5c4a31e3 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/StateOfEvent.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/StateOfEvent.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/StringValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/StringValue.java new file mode 100644 index 000000000..842937b3b --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/StringValue.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultStringValue.class) +}) +public interface StringValue { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Submodel.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Submodel.java index 4e8fd3266..576af0d66 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Submodel.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Submodel.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodel; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** @@ -28,7 +30,7 @@ @KnownSubtypes({ @KnownSubtypes.Type(value = DefaultSubmodel.class) }) -public interface Submodel extends HasDataSpecification, HasKind, HasSemantics, Identifiable, Qualifiable { +public interface Submodel extends Identifiable, HasDataSpecification, HasSemantics, Qualifiable, HasKind { /** * A submodel consists of zero or more submodel elements. diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java index b4173aa09..f0f858480 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -15,11 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelDescriptor; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; -import java.util.List; /** */ @@ -30,16 +33,16 @@ public interface SubmodelDescriptor extends Descriptor { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/administration * * @return Returns the AdministrativeInformation for the property administration. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration") + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/administration") AdministrativeInformation getAdministration(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/administration * * @param administration desired value for the property administration. */ @@ -47,87 +50,87 @@ public interface SubmodelDescriptor extends Descriptor { /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/endpoints * - * @return Returns the LangStringSet for the property description. + * @return Returns the List of Endpoints for the property endpoints. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description") - List getDescription(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/endpoints") + List getEndpoints(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/endpoints * - * @param description desired value for the property description. + * @param endpoints desired value for the property endpoints. */ - void setDescription(List description); + void setEndpoints(List endpoints); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/idShort * - * @return Returns the LangStringSet for the property displayName. + * @return Returns the String for the property idShort. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName") - List getDisplayName(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/idShort") + String getIdShort(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/idShort * - * @param displayName desired value for the property displayName. + * @param idShort desired value for the property idShort. */ - void setDisplayName(List displayName); + void setIdShort(String idShort); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/id * - * @return Returns the String for the property idShort. + * @return Returns the String for the property id. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort") - String getIdShort(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/id") + String getId(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/id * - * @param idShort desired value for the property idShort. + * @param id desired value for the property id. */ - void setIdShort(String idShort); + void setId(String id); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/identification + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/semanticId * - * @return Returns the String for the property identification. + * @return Returns the Reference for the property semanticId. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/identification") - String getIdentification(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/semanticId") + Reference getSemanticId(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/identification + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/semanticId * - * @param identification desired value for the property identification. + * @param semanticId desired value for the property semanticId. */ - void setIdentification(String identification); + void setSemanticId(Reference semanticId); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/supplementalSemanticId * - * @return Returns the Reference for the property semanticId. + * @return Returns the List of References for the property supplementalSemanticId. */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId") - Reference getSemanticId(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/supplementalSemanticId") + List getSupplementalSemanticId(); /** * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId + * More information under https://admin-shell.io/aas/3/0/SubmodelDescriptor/supplementalSemanticId * - * @param semanticId desired value for the property semanticId. + * @param supplementalSemanticIds desired value for the property supplementalSemanticId. */ - void setSemanticId(Reference semanticId); + void setSupplementalSemanticId(List supplementalSemanticIds); } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElement.java index 5c19158d9..d2d9f3b29 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElement.java @@ -18,6 +18,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** @@ -33,6 +35,6 @@ @KnownSubtypes.Type(value = SubmodelElementCollection.class), @KnownSubtypes.Type(value = SubmodelElementList.class) }) -public interface SubmodelElement extends HasDataSpecification, HasSemantics, Qualifiable, Referable { +public interface SubmodelElement extends HasDataSpecification, Referable, HasSemantics, Qualifiable { } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementAttributes.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementAttributes.java new file mode 100644 index 000000000..d2b6f99ce --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementAttributes.java @@ -0,0 +1,64 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultSubmodelElementAttributes.class), + @KnownSubtypes.Type(value = AnnotatedRelationshipElementMetadata.class), + @KnownSubtypes.Type(value = BasicEventElementMetadata.class), + @KnownSubtypes.Type(value = BlobMetadata.class), + @KnownSubtypes.Type(value = CapabilityMetadata.class), + @KnownSubtypes.Type(value = EntityMetadata.class), + @KnownSubtypes.Type(value = FileMetadata.class), + @KnownSubtypes.Type(value = MultiLanguagePropertyMetadata.class), + @KnownSubtypes.Type(value = OperationMetadata.class), + @KnownSubtypes.Type(value = PropertyMetadata.class), + @KnownSubtypes.Type(value = RangeMetadata.class), + @KnownSubtypes.Type(value = ReferenceElementMetadata.class), + @KnownSubtypes.Type(value = RelationshipElementMetadata.class), + @KnownSubtypes.Type(value = SubmodelElementListMetadata.class), + @KnownSubtypes.Type(value = SubmodelElementCollectionMetadata.class) +}) +public interface SubmodelElementAttributes extends HasDataSpecification, Referable, HasSemantics, Qualifiable { + + /** + * + * More information under https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind + * + * @return Returns the ModellingKind for the property kind. + */ + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + ModellingKind getKind(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind + * + * @param kind desired value for the property kind. + */ + void setKind(ModellingKind kind); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementCollection.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementCollection.java index 2080567bd..d963cbb44 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementCollection.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementCollection.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementCollection; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementCollectionMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementCollectionMetadata.java new file mode 100644 index 000000000..47762424e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementCollectionMetadata.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultSubmodelElementCollectionMetadata.class) +}) +public interface SubmodelElementCollectionMetadata extends SubmodelElementAttributes { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementList.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementList.java index 7e94212b4..dabdc7c61 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementList.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementList.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementList; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementListMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementListMetadata.java new file mode 100644 index 000000000..0c1bee9e4 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementListMetadata.java @@ -0,0 +1,107 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultSubmodelElementListMetadata.class) +}) +public interface SubmodelElementListMetadata extends SubmodelElementAttributes { + + /** + * + * More information under https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/orderRelevant + * + * @return Returns the boolean for the property orderRelevant. + */ + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/orderRelevant") + boolean getOrderRelevant(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/orderRelevant + * + * @param orderRelevant desired value for the property orderRelevant. + */ + void setOrderRelevant(boolean orderRelevant); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/semanticIdListElement + * + * @return Returns the Reference for the property semanticIdListElement. + */ + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/semanticIdListElement") + Reference getSemanticIdListElement(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/semanticIdListElement + * + * @param semanticIdListElement desired value for the property semanticIdListElement. + */ + void setSemanticIdListElement(Reference semanticIdListElement); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/typeValueListElement + * + * @return Returns the ModelType for the property typeValueListElement. + */ + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/typeValueListElement") + ModelType getTypeValueListElement(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/typeValueListElement + * + * @param typeValueListElement desired value for the property typeValueListElement. + */ + void setTypeValueListElement(ModelType typeValueListElement); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/valueTypeListElement + * + * @return Returns the DataTypeDefXsd for the property valueTypeListElement. + */ + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/valueTypeListElement") + DataTypeDefXsd getValueTypeListElement(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/valueTypeListElement + * + * @param valueTypeListElement desired value for the property valueTypeListElement. + */ + void setValueTypeListElement(DataTypeDefXsd valueTypeListElement); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementListValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementListValue.java new file mode 100644 index 000000000..2269efa0a --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelElementListValue.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultSubmodelElementListValue.class) +}) +public interface SubmodelElementListValue { + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelMetadata.java new file mode 100644 index 000000000..7c9246d04 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelMetadata.java @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultSubmodelMetadata.class) +}) +public interface SubmodelMetadata extends Identifiable, HasDataSpecification, HasSemantics, Qualifiable { + + /** + * + * More information under https://admin-shell.io/aas/3/0/SubmodelMetadata/kind + * + * @return Returns the ModellingKind for the property kind. + */ + @IRI("https://admin-shell.io/aas/3/0/SubmodelMetadata/kind") + ModellingKind getKind(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/SubmodelMetadata/kind + * + * @param kind desired value for the property kind. + */ + void setKind(ModellingKind kind); + +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueList.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueList.java index 9313bc322..e5b9a797a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueList.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueList.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultValueList; - -import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueReferencePair.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueReferencePair.java index 53d12d3bf..3bee19c69 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueReferencePair.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ValueReferencePair.java @@ -16,9 +16,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model; + import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultValueReferencePair; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/KnownSubtypes.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/KnownSubtypes.java index 1c13de81d..535f8e991 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/KnownSubtypes.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/KnownSubtypes.java @@ -28,7 +28,7 @@ * * @return List of known implementing subtypes */ - public Type[] value(); + public KnownSubtypes.Type[] value(); public @interface Type { Class value(); diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AdministrativeInformationBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AdministrativeInformationBuilder.java index f75faf333..a49262f2d 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AdministrativeInformationBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AdministrativeInformationBuilder.java @@ -15,13 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.AdministrativeInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.EmbeddedDataSpecification; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class AdministrativeInformationBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementBuilder.java index f26548cc2..2f55d377a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class AnnotatedRelationshipElementBuilder> extends ExtendableBuilder { @@ -89,61 +91,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -231,4 +178,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementMetadataBuilder.java new file mode 100644 index 000000000..cae15bcb2 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class AnnotatedRelationshipElementMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementValueBuilder.java new file mode 100644 index 000000000..5facc51d8 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AnnotatedRelationshipElementValueBuilder.java @@ -0,0 +1,71 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class AnnotatedRelationshipElementValueBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for first + * + * @param first desired value to be set + * @return Builder object with new value for first + */ + public B first(ReferenceValue first) { + getBuildingInstance().setFirst(first); + return getSelf(); + } + + /** + * This function allows setting a value for second + * + * @param second desired value to be set + * @return Builder object with new value for second + */ + public B second(ReferenceValue second) { + getBuildingInstance().setSecond(second); + return getSelf(); + } + + /** + * This function allows setting a value for annotation + * + * @param annotations desired value to be set + * @return Builder object with new value for annotation + */ + public B annotation(List annotations) { + getBuildingInstance().setAnnotation(annotations); + return getSelf(); + } + + /** + * This function allows adding a value to the List annotation + * + * @param annotation desired value to be added + * @return Builder object with new value for annotation + */ + public B annotation(String annotation) { + getBuildingInstance().getAnnotation().add(annotation); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellBuilder.java index 51e9059c1..166b2625f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class AssetAdministrationShellBuilder> extends ExtendableBuilder { @@ -67,28 +69,6 @@ public B submodels(Reference submodels) { return getSelf(); } - /** - * This function allows setting a value for embeddedDataSpecifications - * - * @param embeddedDataSpecifications desired value to be set - * @return Builder object with new value for embeddedDataSpecifications - */ - public B embeddedDataSpecifications(List embeddedDataSpecifications) { - getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); - return getSelf(); - } - - /** - * This function allows adding a value to the List embeddedDataSpecifications - * - * @param embeddedDataSpecifications desired value to be added - * @return Builder object with new value for embeddedDataSpecifications - */ - public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { - getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); - return getSelf(); - } - /** * This function allows setting a value for administration * @@ -198,4 +178,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.java index 950eb0017..6b58294b8 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -15,9 +15,12 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; +import java.util.List; + + import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; -import java.util.List; public abstract class AssetAdministrationShellDescriptorBuilder> extends ExtendableBuilder { @@ -34,24 +37,57 @@ public B administration(AdministrativeInformation administration) { } /** - * This function allows setting a value for description + * This function allows setting a value for assetKind * - * @param description desired value to be set - * @return Builder object with new value for description + * @param assetKind desired value to be set + * @return Builder object with new value for assetKind */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B assetKind(AssetKind assetKind) { + getBuildingInstance().setAssetKind(assetKind); return getSelf(); } /** - * This function allows setting a value for displayName + * This function allows setting a value for assetType * - * @param displayName desired value to be set - * @return Builder object with new value for displayName + * @param assetType desired value to be set + * @return Builder object with new value for assetType + */ + public B assetType(String assetType) { + getBuildingInstance().setAssetType(assetType); + return getSelf(); + } + + /** + * This function allows setting a value for endpoints + * + * @param endpoints desired value to be set + * @return Builder object with new value for endpoints */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B endpoints(List endpoints) { + getBuildingInstance().setEndpoints(endpoints); + return getSelf(); + } + + /** + * This function allows adding a value to the List endpoints + * + * @param endpoints desired value to be added + * @return Builder object with new value for endpoints + */ + public B endpoints(Endpoint endpoints) { + getBuildingInstance().getEndpoints().add(endpoints); + return getSelf(); + } + + /** + * This function allows setting a value for globalAssetId + * + * @param globalAssetId desired value to be set + * @return Builder object with new value for globalAssetId + */ + public B globalAssetId(String globalAssetId) { + getBuildingInstance().setGlobalAssetId(globalAssetId); return getSelf(); } @@ -67,68 +103,123 @@ public B idShort(String idShort) { } /** - * This function allows setting a value for identification + * This function allows setting a value for id * - * @param identification desired value to be set - * @return Builder object with new value for identification + * @param id desired value to be set + * @return Builder object with new value for id */ - public B identification(String identification) { - getBuildingInstance().setIdentification(identification); + public B id(String id) { + getBuildingInstance().setId(id); return getSelf(); } /** - * This function allows setting a value for specificAssetId + * This function allows setting a value for specificAssetIds * - * @param specificAssetId desired value to be set - * @return Builder object with new value for specificAssetId + * @param specificAssetIds desired value to be set + * @return Builder object with new value for specificAssetIds */ - public B specificAssetId(SpecificAssetId specificAssetId) { - getBuildingInstance().setSpecificAssetIds(specificAssetId); + public B specificAssetIds(List specificAssetIds) { + getBuildingInstance().setSpecificAssetIds(specificAssetIds); return getSelf(); } /** - * This function allows setting a value for globalAssetId - * - * @param globalAssetId desired value to be set - * @return Builder object with new value for globalAssetId + * This function allows adding a value to the List specificAssetIds + * + * @param specificAssetIds desired value to be added + * @return Builder object with new value for specificAssetIds */ - public B globalAssetId(Reference globalAssetId) { - getBuildingInstance().setGlobalAssetId(globalAssetId); + public B specificAssetIds(SpecificAssetId specificAssetIds) { + getBuildingInstance().getSpecificAssetIds().add(specificAssetIds); return getSelf(); } /** - * This function allows setting a value for submodelDescriptor - * - * @param submodelDescriptor desired value to be set - * @return Builder object with new value for submodelDescriptor + * This function allows setting a value for submodelDescriptors + * + * @param submodelDescriptors desired value to be set + * @return Builder object with new value for submodelDescriptors */ - public B submodelDescriptor(List submodelDescriptor) { - getBuildingInstance().setSubmodelDescriptor(submodelDescriptor); + public B submodelDescriptors(List submodelDescriptors) { + getBuildingInstance().setSubmodelDescriptors(submodelDescriptors); return getSelf(); } /** - * This function allows setting a value for endpoints + * This function allows adding a value to the List submodelDescriptors * - * @param endpoints desired value to be set - * @return Builder object with new value for endpoints + * @param submodelDescriptors desired value to be added + * @return Builder object with new value for submodelDescriptors */ - public B endpoints(List endpoints) { - getBuildingInstance().setEndpoints(endpoints); + public B submodelDescriptors(SubmodelDescriptor submodelDescriptors) { + getBuildingInstance().getSubmodelDescriptors().add(submodelDescriptors); return getSelf(); } /** - * This function allows adding a value to the List endpoints + * This function allows setting a value for description * - * @param endpoints desired value to be added - * @return Builder object with new value for endpoints + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B endpoints(Endpoint endpoints) { - getBuildingInstance().getEndpoints().add(endpoints); + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); return getSelf(); } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellMetadataBuilder.java new file mode 100644 index 000000000..6830021eb --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellMetadataBuilder.java @@ -0,0 +1,181 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class AssetAdministrationShellMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for derivedFrom + * + * @param derivedFroms desired value to be set + * @return Builder object with new value for derivedFrom + */ + public B derivedFrom(List derivedFroms) { + getBuildingInstance().setDerivedFrom(derivedFroms); + return getSelf(); + } + + /** + * This function allows adding a value to the List derivedFrom + * + * @param derivedFrom desired value to be added + * @return Builder object with new value for derivedFrom + */ + public B derivedFrom(Reference derivedFrom) { + getBuildingInstance().getDerivedFrom().add(derivedFrom); + return getSelf(); + } + + /** + * This function allows setting a value for administration + * + * @param administration desired value to be set + * @return Builder object with new value for administration + */ + public B administration(AdministrativeInformation administration) { + getBuildingInstance().setAdministration(administration); + return getSelf(); + } + + /** + * This function allows setting a value for id + * + * @param id desired value to be set + * @return Builder object with new value for id + */ + public B id(String id) { + getBuildingInstance().setId(id); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetInformationBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetInformationBuilder.java index 974bbcae2..53662764f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetInformationBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetInformationBuilder.java @@ -15,14 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; -import org.eclipse.digitaltwin.aas4j.v3.model.Resource; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class AssetInformationBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementBuilder.java index 718767d8b..45e9546cf 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class BasicEventElementBuilder> extends ExtendableBuilder { @@ -133,61 +135,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -275,4 +222,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementMetadataBuilder.java new file mode 100644 index 000000000..1265fe728 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementMetadataBuilder.java @@ -0,0 +1,357 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class BasicEventElementMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for direction + * + * @param directions desired value to be set + * @return Builder object with new value for direction + */ + public B direction(List directions) { + getBuildingInstance().setDirection(directions); + return getSelf(); + } + + /** + * This function allows adding a value to the List direction + * + * @param direction desired value to be added + * @return Builder object with new value for direction + */ + public B direction(Direction direction) { + getBuildingInstance().getDirection().add(direction); + return getSelf(); + } + + /** + * This function allows setting a value for state + * + * @param states desired value to be set + * @return Builder object with new value for state + */ + public B state(List states) { + getBuildingInstance().setState(states); + return getSelf(); + } + + /** + * This function allows adding a value to the List state + * + * @param state desired value to be added + * @return Builder object with new value for state + */ + public B state(StateOfEvent state) { + getBuildingInstance().getState().add(state); + return getSelf(); + } + + /** + * This function allows setting a value for messageBroker + * + * @param messageBrokers desired value to be set + * @return Builder object with new value for messageBroker + */ + public B messageBroker(List messageBrokers) { + getBuildingInstance().setMessageBroker(messageBrokers); + return getSelf(); + } + + /** + * This function allows adding a value to the List messageBroker + * + * @param messageBroker desired value to be added + * @return Builder object with new value for messageBroker + */ + public B messageBroker(Reference messageBroker) { + getBuildingInstance().getMessageBroker().add(messageBroker); + return getSelf(); + } + + /** + * This function allows setting a value for messageTopic + * + * @param messageTopics desired value to be set + * @return Builder object with new value for messageTopic + */ + public B messageTopic(List messageTopics) { + getBuildingInstance().setMessageTopic(messageTopics); + return getSelf(); + } + + /** + * This function allows adding a value to the List messageTopic + * + * @param messageTopic desired value to be added + * @return Builder object with new value for messageTopic + */ + public B messageTopic(String messageTopic) { + getBuildingInstance().getMessageTopic().add(messageTopic); + return getSelf(); + } + + /** + * This function allows setting a value for lastUpdate + * + * @param lastUpdates desired value to be set + * @return Builder object with new value for lastUpdate + */ + public B lastUpdate(List lastUpdates) { + getBuildingInstance().setLastUpdate(lastUpdates); + return getSelf(); + } + + /** + * This function allows adding a value to the List lastUpdate + * + * @param lastUpdate desired value to be added + * @return Builder object with new value for lastUpdate + */ + public B lastUpdate(String lastUpdate) { + getBuildingInstance().getLastUpdate().add(lastUpdate); + return getSelf(); + } + + /** + * This function allows setting a value for minInterval + * + * @param minIntervals desired value to be set + * @return Builder object with new value for minInterval + */ + public B minInterval(List minIntervals) { + getBuildingInstance().setMinInterval(minIntervals); + return getSelf(); + } + + /** + * This function allows adding a value to the List minInterval + * + * @param minInterval desired value to be added + * @return Builder object with new value for minInterval + */ + public B minInterval(String minInterval) { + getBuildingInstance().getMinInterval().add(minInterval); + return getSelf(); + } + + /** + * This function allows setting a value for maxInterval + * + * @param maxIntervals desired value to be set + * @return Builder object with new value for maxInterval + */ + public B maxInterval(List maxIntervals) { + getBuildingInstance().setMaxInterval(maxIntervals); + return getSelf(); + } + + /** + * This function allows adding a value to the List maxInterval + * + * @param maxInterval desired value to be added + * @return Builder object with new value for maxInterval + */ + public B maxInterval(String maxInterval) { + getBuildingInstance().getMaxInterval().add(maxInterval); + return getSelf(); + } + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementValueBuilder.java new file mode 100644 index 000000000..38b0bc07b --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BasicEventElementValueBuilder.java @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class BasicEventElementValueBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for observed + * + * @param observeds desired value to be set + * @return Builder object with new value for observed + */ + public B observed(List observeds) { + getBuildingInstance().setObserved(observeds); + return getSelf(); + } + + /** + * This function allows adding a value to the List observed + * + * @param observed desired value to be added + * @return Builder object with new value for observed + */ + public B observed(ReferenceValue observed) { + getBuildingInstance().getObserved().add(observed); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobBuilder.java index 6fe946097..346a56288 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class BlobBuilder> extends ExtendableBuilder { /** @@ -66,61 +68,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -208,4 +155,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobMetadataBuilder.java new file mode 100644 index 000000000..1299a06af --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobMetadataBuilder.java @@ -0,0 +1,202 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class BlobMetadataBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobValueBuilder.java new file mode 100644 index 000000000..96dbcd667 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobValueBuilder.java @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class BlobValueBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for mimeType + * + * @param mimeType desired value to be set + * @return Builder object with new value for mimeType + */ + public B mimeType(String mimeType) { + getBuildingInstance().setMimeType(mimeType); + return getSelf(); + } + + /** + * This function allows setting a value for value + * + * @param value desired value to be set + * @return Builder object with new value for value + */ + public B value(String value) { + getBuildingInstance().setValue(value); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/CapabilityBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/CapabilityBuilder.java index 2264c9c68..bbd759434 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/CapabilityBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/CapabilityBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class CapabilityBuilder> extends ExtendableBuilder { /** @@ -44,61 +46,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -186,4 +133,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/CapabilityMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/CapabilityMetadataBuilder.java new file mode 100644 index 000000000..6c4f7b48a --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/CapabilityMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class CapabilityMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ConceptDescriptionBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ConceptDescriptionBuilder.java index 85c3f259b..574301a42 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ConceptDescriptionBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ConceptDescriptionBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class ConceptDescriptionBuilder> extends ExtendableBuilder { @@ -45,28 +47,6 @@ public B isCaseOf(Reference isCaseOf) { return getSelf(); } - /** - * This function allows setting a value for embeddedDataSpecifications - * - * @param embeddedDataSpecifications desired value to be set - * @return Builder object with new value for embeddedDataSpecifications - */ - public B embeddedDataSpecifications(List embeddedDataSpecifications) { - getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); - return getSelf(); - } - - /** - * This function allows adding a value to the List embeddedDataSpecifications - * - * @param embeddedDataSpecifications desired value to be added - * @return Builder object with new value for embeddedDataSpecifications - */ - public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { - getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); - return getSelf(); - } - /** * This function allows setting a value for administration * @@ -176,4 +156,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DataSpecificationIec61360Builder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DataSpecificationIec61360Builder.java index 41ce802e4..5c562038f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DataSpecificationIec61360Builder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DataSpecificationIec61360Builder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class DataSpecificationIec61360Builder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java index 85175e975..02596330a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -17,30 +17,76 @@ import java.util.List; -import org.eclipse.digitaltwin.aas4j.v3.model.Descriptor; -import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + public abstract class DescriptorBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for endpoints + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for extensions * - * @param endpoints desired value to be set - * @return Builder object with new value for endpoints + * @param extensions desired value to be set + * @return Builder object with new value for extensions */ - public B endpoints(List endpoints) { - getBuildingInstance().setEndpoints(endpoints); + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); return getSelf(); } /** - * This function allows adding a value to the List endpoints + * This function allows adding a value to the List extensions * - * @param endpoints desired value to be added - * @return Builder object with new value for endpoints + * @param extensions desired value to be added + * @return Builder object with new value for extensions */ - public B endpoints(Endpoint endpoints) { - getBuildingInstance().getEndpoints().add(endpoints); + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); return getSelf(); } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EmbeddedDataSpecificationBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EmbeddedDataSpecificationBuilder.java index f92f45fe4..f62900b87 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EmbeddedDataSpecificationBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EmbeddedDataSpecificationBuilder.java @@ -16,9 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.DataSpecificationContent; -import org.eclipse.digitaltwin.aas4j.v3.model.EmbeddedDataSpecification; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class EmbeddedDataSpecificationBuilder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java index 22c99fe99..7ce0d31ca 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -17,19 +17,20 @@ -import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; -import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + public abstract class EndpointBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for interface + * This function allows setting a value for _interface * - * @param interfaceValue desired value to be set - * @return Builder object with new value for interface + * @param _interface desired value to be set + * @return Builder object with new value for _interface */ - public B withInterface(String interfaceValue) { - getBuildingInstance().setInterface(interfaceValue); + public B _interface(String _interface) { + getBuildingInstance().set_interface(_interface); return getSelf(); } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityBuilder.java index fda9f062c..3fe84907d 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class EntityBuilder> extends ExtendableBuilder { /** @@ -110,61 +112,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -252,4 +199,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityMetadataBuilder.java new file mode 100644 index 000000000..04d897fcd --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class EntityMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityValueBuilder.java new file mode 100644 index 000000000..98d930124 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EntityValueBuilder.java @@ -0,0 +1,92 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class EntityValueBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for entityType + * + * @param entityType desired value to be set + * @return Builder object with new value for entityType + */ + public B entityType(EntityType entityType) { + getBuildingInstance().setEntityType(entityType); + return getSelf(); + } + + /** + * This function allows setting a value for globalAssetId + * + * @param globalAssetId desired value to be set + * @return Builder object with new value for globalAssetId + */ + public B globalAssetId(ReferenceValue globalAssetId) { + getBuildingInstance().setGlobalAssetId(globalAssetId); + return getSelf(); + } + + /** + * This function allows setting a value for specificAssetIds + * + * @param specificAssetIds desired value to be set + * @return Builder object with new value for specificAssetIds + */ + public B specificAssetIds(List specificAssetIds) { + getBuildingInstance().setSpecificAssetIds(specificAssetIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List specificAssetIds + * + * @param specificAssetIds desired value to be added + * @return Builder object with new value for specificAssetIds + */ + public B specificAssetIds(String specificAssetIds) { + getBuildingInstance().getSpecificAssetIds().add(specificAssetIds); + return getSelf(); + } + + /** + * This function allows setting a value for statements + * + * @param statements desired value to be set + * @return Builder object with new value for statements + */ + public B statements(List statements) { + getBuildingInstance().setStatements(statements); + return getSelf(); + } + + /** + * This function allows adding a value to the List statements + * + * @param statements desired value to be added + * @return Builder object with new value for statements + */ + public B statements(String statements) { + getBuildingInstance().getStatements().add(statements); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EnvironmentBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EnvironmentBuilder.java index 60288ffc2..30e5d8358 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EnvironmentBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EnvironmentBuilder.java @@ -15,14 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; -import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.Environment; -import org.eclipse.digitaltwin.aas4j.v3.model.Submodel; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class EnvironmentBuilder> extends ExtendableBuilder { /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EventPayloadBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EventPayloadBuilder.java index b3e691032..ab2396475 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EventPayloadBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EventPayloadBuilder.java @@ -16,8 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.EventPayload; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class EventPayloadBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtensionBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtensionBuilder.java index d6dc6f4b4..5d31378f9 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtensionBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtensionBuilder.java @@ -15,13 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; -import org.eclipse.digitaltwin.aas4j.v3.model.Extension; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class ExtensionBuilder> extends ExtendableBuilder { /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileBuilder.java index 4bca2a16f..2bcafa605 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class FileBuilder> extends ExtendableBuilder { /** @@ -66,61 +68,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -208,4 +155,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileMetadataBuilder.java new file mode 100644 index 000000000..0646384b0 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileMetadataBuilder.java @@ -0,0 +1,202 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class FileMetadataBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileValueBuilder.java new file mode 100644 index 000000000..804f47734 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/FileValueBuilder.java @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class FileValueBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for contentType + * + * @param contentType desired value to be set + * @return Builder object with new value for contentType + */ + public B contentType(String contentType) { + getBuildingInstance().setContentType(contentType); + return getSelf(); + } + + /** + * This function allows setting a value for value + * + * @param value desired value to be set + * @return Builder object with new value for value + */ + public B value(String value) { + getBuildingInstance().setValue(value); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/KeyBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/KeyBuilder.java index 131e0ee5d..499f60c7a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/KeyBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/KeyBuilder.java @@ -16,8 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.Key; -import org.eclipse.digitaltwin.aas4j.v3.model.KeyTypes; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class KeyBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringDefinitionTypeIec61360Builder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringDefinitionTypeIec61360Builder.java index b6d43e28e..b69f9705d 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringDefinitionTypeIec61360Builder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringDefinitionTypeIec61360Builder.java @@ -16,7 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringDefinitionTypeIec61360; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class LangStringDefinitionTypeIec61360Builder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringNameTypeBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringNameTypeBuilder.java index 2df57ae9c..c08831b1e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringNameTypeBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringNameTypeBuilder.java @@ -16,7 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringNameType; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class LangStringNameTypeBuilder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringPreferredNameTypeIec61360Builder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringPreferredNameTypeIec61360Builder.java index 685de3530..665bc48c9 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringPreferredNameTypeIec61360Builder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringPreferredNameTypeIec61360Builder.java @@ -16,7 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringPreferredNameTypeIec61360; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class LangStringPreferredNameTypeIec61360Builder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringShortNameTypeIec61360Builder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringShortNameTypeIec61360Builder.java index 2b37bb3d5..a7fd17d27 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringShortNameTypeIec61360Builder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringShortNameTypeIec61360Builder.java @@ -16,7 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringShortNameTypeIec61360; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class LangStringShortNameTypeIec61360Builder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringTextTypeBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringTextTypeBuilder.java index 55e927566..3056435e3 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringTextTypeBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LangStringTextTypeBuilder.java @@ -16,7 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringTextType; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class LangStringTextTypeBuilder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LevelTypeBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LevelTypeBuilder.java index 47bc13d6c..7f1efd6f7 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LevelTypeBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/LevelTypeBuilder.java @@ -16,7 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.LevelType; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class LevelTypeBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MessageBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MessageBuilder.java new file mode 100644 index 000000000..e81d13651 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MessageBuilder.java @@ -0,0 +1,69 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class MessageBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for code + * + * @param code desired value to be set + * @return Builder object with new value for code + */ + public B code(String code) { + getBuildingInstance().setCode(code); + return getSelf(); + } + + /** + * This function allows setting a value for messageType + * + * @param messageType desired value to be set + * @return Builder object with new value for messageType + */ + public B messageType(MessageType messageType) { + getBuildingInstance().setMessageType(messageType); + return getSelf(); + } + + /** + * This function allows setting a value for text + * + * @param text desired value to be set + * @return Builder object with new value for text + */ + public B text(String text) { + getBuildingInstance().setText(text); + return getSelf(); + } + + /** + * This function allows setting a value for timestamp + * + * @param timestamp desired value to be set + * @return Builder object with new value for timestamp + */ + public B timestamp(String timestamp) { + getBuildingInstance().setTimestamp(timestamp); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyBuilder.java index 706314092..573f36f2d 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class MultiLanguagePropertyBuilder> extends ExtendableBuilder { @@ -78,61 +80,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -220,4 +167,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyMetadataBuilder.java new file mode 100644 index 000000000..c76450090 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class MultiLanguagePropertyMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyValueBuilder.java new file mode 100644 index 000000000..45ef870bb --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/MultiLanguagePropertyValueBuilder.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class MultiLanguagePropertyValueBuilder> + extends ExtendableBuilder { +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/NumberValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/NumberValueBuilder.java new file mode 100644 index 000000000..0bf588699 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/NumberValueBuilder.java @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class NumberValueBuilder> extends ExtendableBuilder { +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationBuilder.java index 8c8b23f59..e3970b269 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class OperationBuilder> extends ExtendableBuilder { /** @@ -110,61 +112,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -252,4 +199,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationHandleBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationHandleBuilder.java new file mode 100644 index 000000000..694240089 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationHandleBuilder.java @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class OperationHandleBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for handleId + * + * @param handleId desired value to be set + * @return Builder object with new value for handleId + */ + public B handleId(String handleId) { + getBuildingInstance().setHandleId(handleId); + return getSelf(); + } + + /** + * This function allows setting a value for requestId + * + * @param requestId desired value to be set + * @return Builder object with new value for requestId + */ + public B requestId(String requestId) { + getBuildingInstance().setRequestId(requestId); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationMetadataBuilder.java new file mode 100644 index 000000000..0d60e7a03 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class OperationMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationRequestBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationRequestBuilder.java new file mode 100644 index 000000000..ea03d1ac9 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationRequestBuilder.java @@ -0,0 +1,71 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.math.BigInteger; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class OperationRequestBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for inoutputArguments + * + * @param inoutputArguments desired value to be set + * @return Builder object with new value for inoutputArguments + */ + public B inoutputArguments(OperationVariable inoutputArguments) { + getBuildingInstance().setInoutputArguments(inoutputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for inputArguments + * + * @param inputArguments desired value to be set + * @return Builder object with new value for inputArguments + */ + public B inputArguments(OperationVariable inputArguments) { + getBuildingInstance().setInputArguments(inputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for requestId + * + * @param requestId desired value to be set + * @return Builder object with new value for requestId + */ + public B requestId(String requestId) { + getBuildingInstance().setRequestId(requestId); + return getSelf(); + } + + /** + * This function allows setting a value for timeout + * + * @param timeout desired value to be set + * @return Builder object with new value for timeout + */ + public B timeout(BigInteger timeout) { + getBuildingInstance().setTimeout(timeout); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationRequestValueOnlyBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationRequestValueOnlyBuilder.java new file mode 100644 index 000000000..88d173741 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationRequestValueOnlyBuilder.java @@ -0,0 +1,71 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.math.BigInteger; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class OperationRequestValueOnlyBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for inoutputArguments + * + * @param inoutputArguments desired value to be set + * @return Builder object with new value for inoutputArguments + */ + public B inoutputArguments(String inoutputArguments) { + getBuildingInstance().setInoutputArguments(inoutputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for inputArguments + * + * @param inputArguments desired value to be set + * @return Builder object with new value for inputArguments + */ + public B inputArguments(String inputArguments) { + getBuildingInstance().setInputArguments(inputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for requestId + * + * @param requestId desired value to be set + * @return Builder object with new value for requestId + */ + public B requestId(String requestId) { + getBuildingInstance().setRequestId(requestId); + return getSelf(); + } + + /** + * This function allows setting a value for timeout + * + * @param timeout desired value to be set + * @return Builder object with new value for timeout + */ + public B timeout(BigInteger timeout) { + getBuildingInstance().setTimeout(timeout); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationResultBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationResultBuilder.java new file mode 100644 index 000000000..02cba6e4c --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationResultBuilder.java @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class OperationResultBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for executionResult + * + * @param executionResult desired value to be set + * @return Builder object with new value for executionResult + */ + public B executionResult(Result executionResult) { + getBuildingInstance().setExecutionResult(executionResult); + return getSelf(); + } + + /** + * This function allows setting a value for executionState + * + * @param executionState desired value to be set + * @return Builder object with new value for executionState + */ + public B executionState(ExecutionState executionState) { + getBuildingInstance().setExecutionState(executionState); + return getSelf(); + } + + /** + * This function allows setting a value for inoutputArguments + * + * @param inoutputArguments desired value to be set + * @return Builder object with new value for inoutputArguments + */ + public B inoutputArguments(OperationVariable inoutputArguments) { + getBuildingInstance().setInoutputArguments(inoutputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for outputArguments + * + * @param outputArguments desired value to be set + * @return Builder object with new value for outputArguments + */ + public B outputArguments(OperationVariable outputArguments) { + getBuildingInstance().setOutputArguments(outputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for requestId + * + * @param requestId desired value to be set + * @return Builder object with new value for requestId + */ + public B requestId(String requestId) { + getBuildingInstance().setRequestId(requestId); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationResultValueOnlyBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationResultValueOnlyBuilder.java new file mode 100644 index 000000000..de25954ac --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationResultValueOnlyBuilder.java @@ -0,0 +1,137 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class OperationResultValueOnlyBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for executionResult + * + * @param executionResults desired value to be set + * @return Builder object with new value for executionResult + */ + public B executionResult(List executionResults) { + getBuildingInstance().setExecutionResult(executionResults); + return getSelf(); + } + + /** + * This function allows adding a value to the List executionResult + * + * @param executionResult desired value to be added + * @return Builder object with new value for executionResult + */ + public B executionResult(Result executionResult) { + getBuildingInstance().getExecutionResult().add(executionResult); + return getSelf(); + } + + /** + * This function allows setting a value for executionState + * + * @param executionStates desired value to be set + * @return Builder object with new value for executionState + */ + public B executionState(List executionStates) { + getBuildingInstance().setExecutionState(executionStates); + return getSelf(); + } + + /** + * This function allows adding a value to the List executionState + * + * @param executionState desired value to be added + * @return Builder object with new value for executionState + */ + public B executionState(ExecutionState executionState) { + getBuildingInstance().getExecutionState().add(executionState); + return getSelf(); + } + + /** + * This function allows setting a value for inoutputArguments + * + * @param inoutputArguments desired value to be set + * @return Builder object with new value for inoutputArguments + */ + public B inoutputArguments(List inoutputArguments) { + getBuildingInstance().setInoutputArguments(inoutputArguments); + return getSelf(); + } + + /** + * This function allows adding a value to the List inoutputArguments + * + * @param inoutputArguments desired value to be added + * @return Builder object with new value for inoutputArguments + */ + public B inoutputArguments(String inoutputArguments) { + getBuildingInstance().getInoutputArguments().add(inoutputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for outputArguments + * + * @param outputArguments desired value to be set + * @return Builder object with new value for outputArguments + */ + public B outputArguments(List outputArguments) { + getBuildingInstance().setOutputArguments(outputArguments); + return getSelf(); + } + + /** + * This function allows adding a value to the List outputArguments + * + * @param outputArguments desired value to be added + * @return Builder object with new value for outputArguments + */ + public B outputArguments(String outputArguments) { + getBuildingInstance().getOutputArguments().add(outputArguments); + return getSelf(); + } + + /** + * This function allows setting a value for requestId + * + * @param requestIds desired value to be set + * @return Builder object with new value for requestId + */ + public B requestId(List requestIds) { + getBuildingInstance().setRequestId(requestIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List requestId + * + * @param requestId desired value to be added + * @return Builder object with new value for requestId + */ + public B requestId(String requestId) { + getBuildingInstance().getRequestId().add(requestId); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationVariableBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationVariableBuilder.java index cddb89a47..5f96bb319 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationVariableBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationVariableBuilder.java @@ -16,8 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.OperationVariable; -import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class OperationVariableBuilder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PackageDescriptionBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PackageDescriptionBuilder.java new file mode 100644 index 000000000..d9fbb3afb --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PackageDescriptionBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class PackageDescriptionBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for items + * + * @param items desired value to be set + * @return Builder object with new value for items + */ + public B items(List items) { + getBuildingInstance().setItems(items); + return getSelf(); + } + + /** + * This function allows adding a value to the List items + * + * @param items desired value to be added + * @return Builder object with new value for items + */ + public B items(String items) { + getBuildingInstance().getItems().add(items); + return getSelf(); + } + + /** + * This function allows setting a value for packageId + * + * @param packageId desired value to be set + * @return Builder object with new value for packageId + */ + public B packageId(String packageId) { + getBuildingInstance().setPackageId(packageId); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PropertyBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PropertyBuilder.java index 9ceee2daa..bce47d1e0 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PropertyBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PropertyBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class PropertyBuilder> extends ExtendableBuilder { /** @@ -77,61 +79,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -219,4 +166,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PropertyMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PropertyMetadataBuilder.java new file mode 100644 index 000000000..4558f267f --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/PropertyMetadataBuilder.java @@ -0,0 +1,214 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class PropertyMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for valueType + * + * @param valueType desired value to be set + * @return Builder object with new value for valueType + */ + public B valueType(DataTypeDefXsd valueType) { + getBuildingInstance().setValueType(valueType); + return getSelf(); + } + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java index e158128d3..599501227 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -15,7 +15,11 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + public abstract class ProtocolInformationBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/QualifierBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/QualifierBuilder.java index 24427c217..6a233dbe9 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/QualifierBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/QualifierBuilder.java @@ -15,14 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; -import org.eclipse.digitaltwin.aas4j.v3.model.Qualifier; -import org.eclipse.digitaltwin.aas4j.v3.model.QualifierKind; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class QualifierBuilder> extends ExtendableBuilder { /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeBuilder.java index e9bae46c4..06c9d6e0c 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class RangeBuilder> extends ExtendableBuilder { /** @@ -77,61 +79,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -219,4 +166,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeMetadataBuilder.java new file mode 100644 index 000000000..4ae38c2af --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeMetadataBuilder.java @@ -0,0 +1,213 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class RangeMetadataBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for valueType + * + * @param valueType desired value to be set + * @return Builder object with new value for valueType + */ + public B valueType(DataTypeDefXsd valueType) { + getBuildingInstance().setValueType(valueType); + return getSelf(); + } + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeValueBuilder.java new file mode 100644 index 000000000..6563cf167 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RangeValueBuilder.java @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.math.BigInteger; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class RangeValueBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for max + * + * @param max desired value to be set + * @return Builder object with new value for max + */ + public B max(BigInteger max) { + getBuildingInstance().setMax(max); + return getSelf(); + } + + /** + * This function allows setting a value for min + * + * @param min desired value to be set + * @return Builder object with new value for min + */ + public B min(BigInteger min) { + getBuildingInstance().setMin(min); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceBuilder.java index afec436d6..f17c03fe0 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceBuilder.java @@ -15,13 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.Key; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.ReferenceTypes; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class ReferenceBuilder> extends ExtendableBuilder { /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementBuilder.java index a34e8526f..b3db4d653 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class ReferenceElementBuilder> extends ExtendableBuilder { @@ -56,61 +58,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -198,4 +145,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementMetadataBuilder.java new file mode 100644 index 000000000..3a479dfc7 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class ReferenceElementMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementValueBuilder.java new file mode 100644 index 000000000..95baf96d3 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceElementValueBuilder.java @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class ReferenceElementValueBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for outputArguments + * + * @param outputArguments desired value to be set + * @return Builder object with new value for outputArguments + */ + public B outputArguments(List outputArguments) { + getBuildingInstance().setOutputArguments(outputArguments); + return getSelf(); + } + + /** + * This function allows adding a value to the List outputArguments + * + * @param outputArguments desired value to be added + * @return Builder object with new value for outputArguments + */ + public B outputArguments(Key outputArguments) { + getBuildingInstance().getOutputArguments().add(outputArguments); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceValueBuilder.java new file mode 100644 index 000000000..83f240f86 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceValueBuilder.java @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class ReferenceValueBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for outputArguments + * + * @param outputArguments desired value to be set + * @return Builder object with new value for outputArguments + */ + public B outputArguments(List outputArguments) { + getBuildingInstance().setOutputArguments(outputArguments); + return getSelf(); + } + + /** + * This function allows adding a value to the List outputArguments + * + * @param outputArguments desired value to be added + * @return Builder object with new value for outputArguments + */ + public B outputArguments(Key outputArguments) { + getBuildingInstance().getOutputArguments().add(outputArguments); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementBuilder.java index 1d6208913..1f7aba79f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class RelationshipElementBuilder> extends ExtendableBuilder { @@ -67,61 +69,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -209,4 +156,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementMetadataBuilder.java new file mode 100644 index 000000000..0e72abffb --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class RelationshipElementMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementValueBuilder.java new file mode 100644 index 000000000..ae3f82297 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementValueBuilder.java @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class RelationshipElementValueBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for first + * + * @param first desired value to be set + * @return Builder object with new value for first + */ + public B first(ReferenceValue first) { + getBuildingInstance().setFirst(first); + return getSelf(); + } + + /** + * This function allows setting a value for second + * + * @param second desired value to be set + * @return Builder object with new value for second + */ + public B second(ReferenceValue second) { + getBuildingInstance().setSecond(second); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResourceBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResourceBuilder.java index 9fd9b7d69..ff11a497e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResourceBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResourceBuilder.java @@ -16,7 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.Resource; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class ResourceBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResultBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResultBuilder.java new file mode 100644 index 000000000..fe33a5a75 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResultBuilder.java @@ -0,0 +1,59 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class ResultBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for messages + * + * @param messages desired value to be set + * @return Builder object with new value for messages + */ + public B messages(List messages) { + getBuildingInstance().setMessages(messages); + return getSelf(); + } + + /** + * This function allows adding a value to the List messages + * + * @param messages desired value to be added + * @return Builder object with new value for messages + */ + public B messages(Message messages) { + getBuildingInstance().getMessages().add(messages); + return getSelf(); + } + + /** + * This function allows setting a value for success + * + * @param success desired value to be set + * @return Builder object with new value for success + */ + public B success(boolean success) { + getBuildingInstance().setSuccess(success); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SpecificAssetIdBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SpecificAssetIdBuilder.java index 508446f79..9f210a566 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SpecificAssetIdBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SpecificAssetIdBuilder.java @@ -15,12 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class SpecificAssetIdBuilder> extends ExtendableBuilder { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/StringValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/StringValueBuilder.java new file mode 100644 index 000000000..349929422 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/StringValueBuilder.java @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class StringValueBuilder> extends ExtendableBuilder { +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelBuilder.java index 9b5b784b5..192bc915e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class SubmodelBuilder> extends ExtendableBuilder { /** @@ -44,72 +46,6 @@ public B submodelElements(SubmodelElement submodelElements) { return getSelf(); } - /** - * This function allows setting a value for embeddedDataSpecifications - * - * @param embeddedDataSpecifications desired value to be set - * @return Builder object with new value for embeddedDataSpecifications - */ - public B embeddedDataSpecifications(List embeddedDataSpecifications) { - getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); - return getSelf(); - } - - /** - * This function allows adding a value to the List embeddedDataSpecifications - * - * @param embeddedDataSpecifications desired value to be added - * @return Builder object with new value for embeddedDataSpecifications - */ - public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { - getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); - return getSelf(); - } - - /** - * This function allows setting a value for kind - * - * @param kind desired value to be set - * @return Builder object with new value for kind - */ - public B kind(ModellingKind kind) { - getBuildingInstance().setKind(kind); - return getSelf(); - } - - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - /** * This function allows setting a value for administration * @@ -220,6 +156,61 @@ public B extensions(Extension extensions) { return getSelf(); } + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + /** * This function allows setting a value for qualifiers * @@ -241,4 +232,15 @@ public B qualifiers(Qualifier qualifiers) { getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java index 178fcb391..53e4b472a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java @@ -1,7 +1,7 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * @@ -17,12 +17,10 @@ import java.util.List; -import org.eclipse.digitaltwin.aas4j.v3.model.AdministrativeInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringTextType; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringNameType; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelDescriptor; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + public abstract class SubmodelDescriptorBuilder> extends ExtendableBuilder { @@ -39,24 +37,24 @@ public B administration(AdministrativeInformation administration) { } /** - * This function allows setting a value for description + * This function allows setting a value for endpoints * - * @param description desired value to be set - * @return Builder object with new value for description + * @param endpoints desired value to be set + * @return Builder object with new value for endpoints */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B endpoints(List endpoints) { + getBuildingInstance().setEndpoints(endpoints); return getSelf(); } /** - * This function allows setting a value for displayName + * This function allows adding a value to the List endpoints * - * @param displayName desired value to be set - * @return Builder object with new value for displayName + * @param endpoints desired value to be added + * @return Builder object with new value for endpoints */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B endpoints(Endpoint endpoints) { + getBuildingInstance().getEndpoints().add(endpoints); return getSelf(); } @@ -72,13 +70,13 @@ public B idShort(String idShort) { } /** - * This function allows setting a value for identification + * This function allows setting a value for id * - * @param identification desired value to be set - * @return Builder object with new value for identification + * @param id desired value to be set + * @return Builder object with new value for id */ - public B identification(String identification) { - getBuildingInstance().setIdentification(identification); + public B id(String id) { + getBuildingInstance().setId(id); return getSelf(); } @@ -94,24 +92,90 @@ public B semanticId(Reference semanticId) { } /** - * This function allows setting a value for endpoints + * This function allows setting a value for supplementalSemanticId * - * @param endpoints desired value to be set - * @return Builder object with new value for endpoints + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticId */ - public B endpoints(List endpoints) { - getBuildingInstance().setEndpoints(endpoints); + public B supplementalSemanticId(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticId(supplementalSemanticIds); return getSelf(); } /** - * This function allows adding a value to the List endpoints + * This function allows adding a value to the List supplementalSemanticId * - * @param endpoints desired value to be added - * @return Builder object with new value for endpoints + * @param supplementalSemanticId desired value to be added + * @return Builder object with new value for supplementalSemanticId */ - public B endpoints(Endpoint endpoints) { - getBuildingInstance().getEndpoints().add(endpoints); + public B supplementalSemanticId(Reference supplementalSemanticId) { + getBuildingInstance().getSupplementalSemanticId().add(supplementalSemanticId); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); return getSelf(); } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementAttributesBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementAttributesBuilder.java new file mode 100644 index 000000000..9e15c34d6 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementAttributesBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class SubmodelElementAttributesBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementCollectionBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementCollectionBuilder.java index b13efa3e8..aff87bb17 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementCollectionBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementCollectionBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class SubmodelElementCollectionBuilder> extends ExtendableBuilder { @@ -67,61 +69,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -209,4 +156,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementCollectionMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementCollectionMetadataBuilder.java new file mode 100644 index 000000000..57c3c363e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementCollectionMetadataBuilder.java @@ -0,0 +1,203 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class SubmodelElementCollectionMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListBuilder.java index f52ed9b36..6c80f5560 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListBuilder.java @@ -15,11 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.*; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class SubmodelElementListBuilder> extends ExtendableBuilder { @@ -111,61 +113,6 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif return getSelf(); } - /** - * This function allows setting a value for semanticId - * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId - */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); - return getSelf(); - } - - /** - * This function allows setting a value for supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows adding a value to the List supplementalSemanticIds - * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds - */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); - return getSelf(); - } - - /** - * This function allows setting a value for qualifiers - * - * @param qualifiers desired value to be set - * @return Builder object with new value for qualifiers - */ - public B qualifiers(List qualifiers) { - getBuildingInstance().setQualifiers(qualifiers); - return getSelf(); - } - - /** - * This function allows adding a value to the List qualifiers - * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers - */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); - return getSelf(); - } - /** * This function allows setting a value for category * @@ -253,4 +200,59 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); return getSelf(); } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListMetadataBuilder.java new file mode 100644 index 000000000..90f89019e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListMetadataBuilder.java @@ -0,0 +1,247 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class SubmodelElementListMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for orderRelevant + * + * @param orderRelevant desired value to be set + * @return Builder object with new value for orderRelevant + */ + public B orderRelevant(boolean orderRelevant) { + getBuildingInstance().setOrderRelevant(orderRelevant); + return getSelf(); + } + + /** + * This function allows setting a value for semanticIdListElement + * + * @param semanticIdListElement desired value to be set + * @return Builder object with new value for semanticIdListElement + */ + public B semanticIdListElement(Reference semanticIdListElement) { + getBuildingInstance().setSemanticIdListElement(semanticIdListElement); + return getSelf(); + } + + /** + * This function allows setting a value for typeValueListElement + * + * @param typeValueListElement desired value to be set + * @return Builder object with new value for typeValueListElement + */ + public B typeValueListElement(ModelType typeValueListElement) { + getBuildingInstance().setTypeValueListElement(typeValueListElement); + return getSelf(); + } + + /** + * This function allows setting a value for valueTypeListElement + * + * @param valueTypeListElement desired value to be set + * @return Builder object with new value for valueTypeListElement + */ + public B valueTypeListElement(DataTypeDefXsd valueTypeListElement) { + getBuildingInstance().setValueTypeListElement(valueTypeListElement); + return getSelf(); + } + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListValueBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListValueBuilder.java new file mode 100644 index 000000000..16a2bdd47 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelElementListValueBuilder.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class SubmodelElementListValueBuilder> + extends ExtendableBuilder { +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelMetadataBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelMetadataBuilder.java new file mode 100644 index 000000000..cb5f552e2 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelMetadataBuilder.java @@ -0,0 +1,225 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.builder; + +import java.util.List; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + +public abstract class SubmodelMetadataBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for kind + * + * @param kind desired value to be set + * @return Builder object with new value for kind + */ + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); + return getSelf(); + } + + /** + * This function allows setting a value for administration + * + * @param administration desired value to be set + * @return Builder object with new value for administration + */ + public B administration(AdministrativeInformation administration) { + getBuildingInstance().setAdministration(administration); + return getSelf(); + } + + /** + * This function allows setting a value for id + * + * @param id desired value to be set + * @return Builder object with new value for id + */ + public B id(String id) { + getBuildingInstance().setId(id); + return getSelf(); + } + + /** + * This function allows setting a value for category + * + * @param category desired value to be set + * @return Builder object with new value for category + */ + public B category(String category) { + getBuildingInstance().setCategory(category); + return getSelf(); + } + + /** + * This function allows setting a value for idShort + * + * @param idShort desired value to be set + * @return Builder object with new value for idShort + */ + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayNames desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); + return getSelf(); + } + + /** + * This function allows adding a value to the List displayName + * + * @param displayName desired value to be added + * @return Builder object with new value for displayName + */ + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); + return getSelf(); + } + + /** + * This function allows setting a value for description + * + * @param descriptions desired value to be set + * @return Builder object with new value for description + */ + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); + return getSelf(); + } + + /** + * This function allows adding a value to the List description + * + * @param description desired value to be added + * @return Builder object with new value for description + */ + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); + return getSelf(); + } + + /** + * This function allows setting a value for extensions + * + * @param extensions desired value to be set + * @return Builder object with new value for extensions + */ + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); + return getSelf(); + } + + /** + * This function allows adding a value to the List extensions + * + * @param extensions desired value to be added + * @return Builder object with new value for extensions + */ + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); + return getSelf(); + } + + /** + * This function allows setting a value for embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be set + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(List embeddedDataSpecifications) { + getBuildingInstance().setEmbeddedDataSpecifications(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows adding a value to the List embeddedDataSpecifications + * + * @param embeddedDataSpecifications desired value to be added + * @return Builder object with new value for embeddedDataSpecifications + */ + public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecifications) { + getBuildingInstance().getEmbeddedDataSpecifications().add(embeddedDataSpecifications); + return getSelf(); + } + + /** + * This function allows setting a value for semanticId + * + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId + */ + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); + return getSelf(); + } + + /** + * This function allows setting a value for supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows adding a value to the List supplementalSemanticIds + * + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds + */ + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + return getSelf(); + } + + /** + * This function allows setting a value for qualifiers + * + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers + */ + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); + return getSelf(); + } + + /** + * This function allows adding a value to the List qualifiers + * + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers + */ + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); + return getSelf(); + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueListBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueListBuilder.java index 5050fe0a7..4aeba5a50 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueListBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueListBuilder.java @@ -15,12 +15,13 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.ValueList; -import org.eclipse.digitaltwin.aas4j.v3.model.ValueReferencePair; - import java.util.List; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; + + public abstract class ValueListBuilder> extends ExtendableBuilder { /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueReferencePairBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueReferencePairBuilder.java index 8dfb746d3..bbc1a5bad 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueReferencePairBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ValueReferencePairBuilder.java @@ -16,8 +16,9 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.ValueReferencePair; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.*; public abstract class ValueReferencePairBuilder> diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAdministrativeInformation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAdministrativeInformation.java index e13dbd853..b90f9e4ef 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAdministrativeInformation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAdministrativeInformation.java @@ -15,17 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.AdministrativeInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.EmbeddedDataSpecification; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.AdministrativeInformationBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.AdministrativeInformation @@ -53,6 +52,14 @@ public class DefaultAdministrativeInformation implements AdministrativeInformati public DefaultAdministrativeInformation() {} + public DefaultAdministrativeInformation(AdministrativeInformation x) { + this.creator = x.getCreator(); + this.revision = x.getRevision(); + this.templateId = x.getTemplateId(); + this.version = x.getVersion(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + } + @Override public int hashCode() { return Objects.hash(this.version, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElement.java index 7e8ed7c90..4b3c37789 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElement.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.AnnotatedRelationshipElementBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.AnnotatedRelationshipElement @@ -73,20 +74,35 @@ public class DefaultAnnotatedRelationshipElement implements AnnotatedRelationshi public DefaultAnnotatedRelationshipElement() {} + public DefaultAnnotatedRelationshipElement(AnnotatedRelationshipElement x) { + this.annotations = x.getAnnotations(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.first = x.getFirst(); + this.second = x.getSecond(); + } + @Override public int hashCode() { return Objects.hash(this.annotations, this.first, this.second, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -103,14 +119,14 @@ public boolean equals(Object obj) { Objects.equals(this.first, other.first) && Objects.equals(this.second, other.second) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -154,36 +170,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -234,6 +220,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultAnnotatedRelationshipElement (" + "annotations=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElementMetadata.java new file mode 100644 index 000000000..ae1f7192f --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElementMetadata.java @@ -0,0 +1,242 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.AnnotatedRelationshipElementMetadata + * + */ + +@IRI("aas:AnnotatedRelationshipElementMetadata") +public class DefaultAnnotatedRelationshipElementMetadata implements AnnotatedRelationshipElementMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultAnnotatedRelationshipElementMetadata() {} + + public DefaultAnnotatedRelationshipElementMetadata(AnnotatedRelationshipElementMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultAnnotatedRelationshipElementMetadata other = (DefaultAnnotatedRelationshipElementMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultAnnotatedRelationshipElementMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultAnnotatedRelationshipElementMetadata bean. + */ + public static class Builder extends AnnotatedRelationshipElementMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultAnnotatedRelationshipElementMetadata newBuildingInstance() { + return new DefaultAnnotatedRelationshipElementMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElementValue.java new file mode 100644 index 000000000..964dcc426 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAnnotatedRelationshipElementValue.java @@ -0,0 +1,131 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.AnnotatedRelationshipElementValue + * + */ + +@IRI("aas:AnnotatedRelationshipElementValue") +public class DefaultAnnotatedRelationshipElementValue implements AnnotatedRelationshipElementValue { + + @IRI("https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/annotation") + protected List annotation = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/first") + protected ReferenceValue first; + + @IRI("https://admin-shell.io/aas/3/0/AnnotatedRelationshipElementValue/second") + protected ReferenceValue second; + + public DefaultAnnotatedRelationshipElementValue() {} + + public DefaultAnnotatedRelationshipElementValue(AnnotatedRelationshipElementValue x) { + this.annotation = x.getAnnotation(); + this.first = x.getFirst(); + this.second = x.getSecond(); + } + + @Override + public int hashCode() { + return Objects.hash(this.first, + this.second, + this.annotation); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultAnnotatedRelationshipElementValue other = (DefaultAnnotatedRelationshipElementValue) obj; + return Objects.equals(this.first, other.first) && + Objects.equals(this.second, other.second) && + Objects.equals(this.annotation, other.annotation); + } + } + + @Override + public ReferenceValue getFirst() { + return first; + } + + @Override + public void setFirst(ReferenceValue first) { + this.first = first; + } + + @Override + public ReferenceValue getSecond() { + return second; + } + + @Override + public void setSecond(ReferenceValue second) { + this.second = second; + } + + @Override + public List getAnnotation() { + return annotation; + } + + @Override + public void setAnnotation(List annotations) { + this.annotation = annotations; + } + + public String toString() { + return String.format( + "DefaultAnnotatedRelationshipElementValue (" + "first=%s," + + "second=%s," + + "annotation=%s," + + ")", + this.first, this.second, this.annotation); + } + + /** + * This builder class can be used to construct a DefaultAnnotatedRelationshipElementValue bean. + */ + public static class Builder extends AnnotatedRelationshipElementValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultAnnotatedRelationshipElementValue newBuildingInstance() { + return new DefaultAnnotatedRelationshipElementValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShell.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShell.java index 1cc73cb62..03568b196 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShell.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShell.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.AssetAdministrationShellBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell * @@ -68,19 +69,33 @@ public class DefaultAssetAdministrationShell implements AssetAdministrationShell public DefaultAssetAdministrationShell() {} + public DefaultAssetAdministrationShell(AssetAdministrationShell x) { + this.assetInformation = x.getAssetInformation(); + this.derivedFrom = x.getDerivedFrom(); + this.submodels = x.getSubmodels(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.administration = x.getAdministration(); + this.id = x.getId(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.derivedFrom, this.assetInformation, this.submodels, - this.embeddedDataSpecifications, this.administration, this.id, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.embeddedDataSpecifications); } @Override @@ -96,14 +111,14 @@ public boolean equals(Object obj) { return Objects.equals(this.derivedFrom, other.derivedFrom) && Objects.equals(this.assetInformation, other.assetInformation) && Objects.equals(this.submodels, other.submodels) && - Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && Objects.equals(this.administration, other.administration) && Objects.equals(this.id, other.id) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications); } } @@ -137,16 +152,6 @@ public void setSubmodels(List submodels) { this.submodels = submodels; } - @Override - public List getEmbeddedDataSpecifications() { - return embeddedDataSpecifications; - } - - @Override - public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { - this.embeddedDataSpecifications = embeddedDataSpecifications; - } - @Override public AdministrativeInformation getAdministration() { return administration; @@ -217,6 +222,16 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + public String toString() { return String.format( "DefaultAssetAdministrationShell (" + "derivedFrom=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java index 634590eab..e5b6ad662 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java @@ -1,12 +1,12 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software distributed under the License * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express * or implied. See the License for the specific language governing permissions and limitations under @@ -15,59 +15,92 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.AssetAdministrationShellDescriptorBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShellDescriptor + * + */ + @IRI("aas:AssetAdministrationShellDescriptor") public class DefaultAssetAdministrationShellDescriptor implements AssetAdministrationShellDescriptor { - @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") - protected List endpoints = new ArrayList<>(); - - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration") + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/administration") protected AdministrativeInformation administration; - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description") - protected List description; + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetKind") + protected AssetKind assetKind; + + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/assetType") + protected String assetType; + + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/endpoints") + protected List endpoints = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/globalAssetId") + protected String globalAssetId; - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName") - protected List displayName; + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/id") + protected String id; - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort") + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/idShort") protected String idShort; - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/identification") - protected String identification; + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/specificAssetIds") + protected List specificAssetIds = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId") - protected Reference globalAssetId; + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellDescriptor/submodelDescriptors") + protected List submodelDescriptors = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds") - protected SpecificAssetId specificAssetId; + @IRI("https://admin-shell.io/aas/3/0/Descriptor/description") + protected List description = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor") - protected List submodelDescriptor; + @IRI("https://admin-shell.io/aas/3/0/Descriptor/displayName") + protected List displayName = new ArrayList<>(); + @IRI("https://admin-shell.io/aas/3/0/Descriptor/extensions") + protected List extensions = new ArrayList<>(); - public DefaultAssetAdministrationShellDescriptor() { + public DefaultAssetAdministrationShellDescriptor() {} + + public DefaultAssetAdministrationShellDescriptor(AssetAdministrationShellDescriptor x) { + this.administration = x.getAdministration(); + this.assetKind = x.getAssetKind(); + this.assetType = x.getAssetType(); + this.endpoints = x.getEndpoints(); + this.globalAssetId = x.getGlobalAssetId(); + this.id = x.getId(); + this.idShort = x.getIdShort(); + this.specificAssetIds = x.getSpecificAssetIds(); + this.submodelDescriptors = x.getSubmodelDescriptors(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.extensions = x.getExtensions(); } @Override public int hashCode() { return Objects.hash(this.administration, + this.assetKind, + this.assetType, + this.endpoints, + this.globalAssetId, + this.idShort, + this.id, + this.specificAssetIds, + this.submodelDescriptors, this.description, this.displayName, - this.idShort, - this.identification, - this.globalAssetId, - this.specificAssetId, - this.submodelDescriptor, - this.endpoints); + this.extensions); } @Override @@ -81,14 +114,17 @@ public boolean equals(Object obj) { } else { DefaultAssetAdministrationShellDescriptor other = (DefaultAssetAdministrationShellDescriptor) obj; return Objects.equals(this.administration, other.administration) && + Objects.equals(this.assetKind, other.assetKind) && + Objects.equals(this.assetType, other.assetType) && + Objects.equals(this.endpoints, other.endpoints) && + Objects.equals(this.globalAssetId, other.globalAssetId) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.id, other.id) && + Objects.equals(this.specificAssetIds, other.specificAssetIds) && + Objects.equals(this.submodelDescriptors, other.submodelDescriptors) && Objects.equals(this.description, other.description) && Objects.equals(this.displayName, other.displayName) && - Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.identification, other.identification) && - Objects.equals(this.globalAssetId, other.globalAssetId) && - Objects.equals(this.specificAssetId, other.specificAssetId) && - Objects.equals(this.submodelDescriptor, other.submodelDescriptor) && - Objects.equals(this.endpoints, other.endpoints); + Objects.equals(this.extensions, other.extensions); } } @@ -103,23 +139,43 @@ public void setAdministration(AdministrativeInformation administration) { } @Override - public List getDescription() { - return description; + public AssetKind getAssetKind() { + return assetKind; } @Override - public void setDescription(List description) { - this.description = description; + public void setAssetKind(AssetKind assetKind) { + this.assetKind = assetKind; } @Override - public List getDisplayName() { - return displayName; + public String getAssetType() { + return assetType; + } + + @Override + public void setAssetType(String assetType) { + this.assetType = assetType; } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public List getEndpoints() { + return endpoints; + } + + @Override + public void setEndpoints(List endpoints) { + this.endpoints = endpoints; + } + + @Override + public String getGlobalAssetId() { + return globalAssetId; + } + + @Override + public void setGlobalAssetId(String globalAssetId) { + this.globalAssetId = globalAssetId; } @Override @@ -133,54 +189,79 @@ public void setIdShort(String idShort) { } @Override - public String getIdentification() { - return identification; + public String getId() { + return id; } @Override - public void setIdentification(String identification) { - this.identification = identification; + public void setId(String id) { + this.id = id; } @Override - public Reference getGlobalAssetId() { - return globalAssetId; + public List getSpecificAssetIds() { + return specificAssetIds; } @Override - public void setGlobalAssetId(Reference globalAssetId) { - this.globalAssetId = globalAssetId; + public void setSpecificAssetIds(List specificAssetIds) { + this.specificAssetIds = specificAssetIds; } @Override - public SpecificAssetId getSpecificAssetIds() { - return specificAssetId; + public List getSubmodelDescriptors() { + return submodelDescriptors; } @Override - public void setSpecificAssetIds(SpecificAssetId specificAssetId) { - this.specificAssetId = specificAssetId; + public void setSubmodelDescriptors(List submodelDescriptors) { + this.submodelDescriptors = submodelDescriptors; } @Override - public List getSubmodelDescriptor() { - return submodelDescriptor; + public List getDescription() { + return description; } @Override - public void setSubmodelDescriptor(List submodelDescriptor) { - this.submodelDescriptor = submodelDescriptor; + public void setDescription(List descriptions) { + this.description = descriptions; } + @Override + public List getDisplayName() { + return displayName; + } @Override - public List getEndpoints() { - return endpoints; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public void setEndpoints(List endpoints) { - this.endpoints = endpoints; + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + public String toString() { + return String.format( + "DefaultAssetAdministrationShellDescriptor (" + "administration=%s," + + "assetKind=%s," + + "assetType=%s," + + "endpoints=%s," + + "globalAssetId=%s," + + "idShort=%s," + + "id=%s," + + "specificAssetIds=%s," + + "submodelDescriptors=%s," + + ")", + this.administration, this.assetKind, this.assetType, this.endpoints, this.globalAssetId, this.idShort, this.id, + this.specificAssetIds, this.submodelDescriptors); } /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellMetadata.java new file mode 100644 index 000000000..df48cd549 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellMetadata.java @@ -0,0 +1,225 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShellMetadata + * + */ + +@IRI("aas:AssetAdministrationShellMetadata") +public class DefaultAssetAdministrationShellMetadata implements AssetAdministrationShellMetadata { + + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShellMetadata/derivedFrom") + protected List derivedFrom = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Identifiable/administration") + protected AdministrativeInformation administration; + + @IRI("https://admin-shell.io/aas/3/0/Identifiable/id") + protected String id; + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + public DefaultAssetAdministrationShellMetadata() {} + + public DefaultAssetAdministrationShellMetadata(AssetAdministrationShellMetadata x) { + this.derivedFrom = x.getDerivedFrom(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.administration = x.getAdministration(); + this.id = x.getId(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + + @Override + public int hashCode() { + return Objects.hash(this.derivedFrom, + this.administration, + this.id, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.embeddedDataSpecifications); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultAssetAdministrationShellMetadata other = (DefaultAssetAdministrationShellMetadata) obj; + return Objects.equals(this.derivedFrom, other.derivedFrom) && + Objects.equals(this.administration, other.administration) && + Objects.equals(this.id, other.id) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications); + } + } + + @Override + public List getDerivedFrom() { + return derivedFrom; + } + + @Override + public void setDerivedFrom(List derivedFroms) { + this.derivedFrom = derivedFroms; + } + + @Override + public AdministrativeInformation getAdministration() { + return administration; + } + + @Override + public void setAdministration(AdministrativeInformation administration) { + this.administration = administration; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + public String toString() { + return String.format( + "DefaultAssetAdministrationShellMetadata (" + "derivedFrom=%s," + + ")", + this.derivedFrom); + } + + /** + * This builder class can be used to construct a DefaultAssetAdministrationShellMetadata bean. + */ + public static class Builder extends AssetAdministrationShellMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultAssetAdministrationShellMetadata newBuildingInstance() { + return new DefaultAssetAdministrationShellMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetInformation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetInformation.java index 0dbc4be34..6126b80e7 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetInformation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetInformation.java @@ -15,18 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; -import org.eclipse.digitaltwin.aas4j.v3.model.Resource; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.AssetInformationBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.AssetInformation * @@ -54,6 +52,14 @@ public class DefaultAssetInformation implements AssetInformation { public DefaultAssetInformation() {} + public DefaultAssetInformation(AssetInformation x) { + this.assetKind = x.getAssetKind(); + this.assetType = x.getAssetType(); + this.defaultThumbnail = x.getDefaultThumbnail(); + this.globalAssetId = x.getGlobalAssetId(); + this.specificAssetIds = x.getSpecificAssetIds(); + } + @Override public int hashCode() { return Objects.hash(this.assetKind, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElement.java index c83be01c2..366919da3 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElement.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.BasicEventElementBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.BasicEventElement * @@ -86,6 +87,26 @@ public class DefaultBasicEventElement implements BasicEventElement { public DefaultBasicEventElement() {} + public DefaultBasicEventElement(BasicEventElement x) { + this.direction = x.getDirection(); + this.lastUpdate = x.getLastUpdate(); + this.maxInterval = x.getMaxInterval(); + this.messageBroker = x.getMessageBroker(); + this.messageTopic = x.getMessageTopic(); + this.minInterval = x.getMinInterval(); + this.observed = x.getObserved(); + this.state = x.getState(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.observed, @@ -97,14 +118,14 @@ public int hashCode() { this.minInterval, this.maxInterval, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -126,14 +147,14 @@ public boolean equals(Object obj) { Objects.equals(this.minInterval, other.minInterval) && Objects.equals(this.maxInterval, other.maxInterval) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -227,36 +248,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -307,6 +298,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultBasicEventElement (" + "observed=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElementMetadata.java new file mode 100644 index 000000000..650554123 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElementMetadata.java @@ -0,0 +1,359 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.BasicEventElementMetadata + * + */ + +@IRI("aas:BasicEventElementMetadata") +public class DefaultBasicEventElementMetadata implements BasicEventElementMetadata { + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/direction") + protected List direction = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/lastUpdate") + protected List lastUpdate = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/maxInterval") + protected List maxInterval = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageBroker") + protected List messageBroker = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/messageTopic") + protected List messageTopic = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/minInterval") + protected List minInterval = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementMetadata/state") + protected List state = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultBasicEventElementMetadata() {} + + public DefaultBasicEventElementMetadata(BasicEventElementMetadata x) { + this.direction = x.getDirection(); + this.lastUpdate = x.getLastUpdate(); + this.maxInterval = x.getMaxInterval(); + this.messageBroker = x.getMessageBroker(); + this.messageTopic = x.getMessageTopic(); + this.minInterval = x.getMinInterval(); + this.state = x.getState(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.direction, + this.state, + this.messageBroker, + this.messageTopic, + this.lastUpdate, + this.minInterval, + this.maxInterval, + this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultBasicEventElementMetadata other = (DefaultBasicEventElementMetadata) obj; + return Objects.equals(this.direction, other.direction) && + Objects.equals(this.state, other.state) && + Objects.equals(this.messageBroker, other.messageBroker) && + Objects.equals(this.messageTopic, other.messageTopic) && + Objects.equals(this.lastUpdate, other.lastUpdate) && + Objects.equals(this.minInterval, other.minInterval) && + Objects.equals(this.maxInterval, other.maxInterval) && + Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public List getDirection() { + return direction; + } + + @Override + public void setDirection(List directions) { + this.direction = directions; + } + + @Override + public List getState() { + return state; + } + + @Override + public void setState(List states) { + this.state = states; + } + + @Override + public List getMessageBroker() { + return messageBroker; + } + + @Override + public void setMessageBroker(List messageBrokers) { + this.messageBroker = messageBrokers; + } + + @Override + public List getMessageTopic() { + return messageTopic; + } + + @Override + public void setMessageTopic(List messageTopics) { + this.messageTopic = messageTopics; + } + + @Override + public List getLastUpdate() { + return lastUpdate; + } + + @Override + public void setLastUpdate(List lastUpdates) { + this.lastUpdate = lastUpdates; + } + + @Override + public List getMinInterval() { + return minInterval; + } + + @Override + public void setMinInterval(List minIntervals) { + this.minInterval = minIntervals; + } + + @Override + public List getMaxInterval() { + return maxInterval; + } + + @Override + public void setMaxInterval(List maxIntervals) { + this.maxInterval = maxIntervals; + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultBasicEventElementMetadata (" + "direction=%s," + + "state=%s," + + "messageBroker=%s," + + "messageTopic=%s," + + "lastUpdate=%s," + + "minInterval=%s," + + "maxInterval=%s," + + ")", + this.direction, this.state, this.messageBroker, this.messageTopic, this.lastUpdate, this.minInterval, this.maxInterval); + } + + /** + * This builder class can be used to construct a DefaultBasicEventElementMetadata bean. + */ + public static class Builder extends BasicEventElementMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultBasicEventElementMetadata newBuildingInstance() { + return new DefaultBasicEventElementMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElementValue.java new file mode 100644 index 000000000..f513c62e5 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBasicEventElementValue.java @@ -0,0 +1,96 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.BasicEventElementValue + * + */ + +@IRI("aas:BasicEventElementValue") +public class DefaultBasicEventElementValue implements BasicEventElementValue { + + @IRI("https://admin-shell.io/aas/3/0/BasicEventElementValue/observed") + protected List observed = new ArrayList<>(); + + public DefaultBasicEventElementValue() {} + + public DefaultBasicEventElementValue(BasicEventElementValue x) { + this.observed = x.getObserved(); + } + + @Override + public int hashCode() { + return Objects.hash(this.observed); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultBasicEventElementValue other = (DefaultBasicEventElementValue) obj; + return Objects.equals(this.observed, other.observed); + } + } + + @Override + public List getObserved() { + return observed; + } + + @Override + public void setObserved(List observeds) { + this.observed = observeds; + } + + public String toString() { + return String.format( + "DefaultBasicEventElementValue (" + "observed=%s," + + ")", + this.observed); + } + + /** + * This builder class can be used to construct a DefaultBasicEventElementValue bean. + */ + public static class Builder extends BasicEventElementValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultBasicEventElementValue newBuildingInstance() { + return new DefaultBasicEventElementValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlob.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlob.java index f0e59a60d..63822dc30 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlob.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlob.java @@ -15,16 +15,17 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.BlobBuilder; - import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Blob * @@ -70,19 +71,33 @@ public class DefaultBlob implements Blob { public DefaultBlob() {} + public DefaultBlob(Blob x) { + this.contentType = x.getContentType(); + this.value = x.getValue(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(Arrays.hashCode(this.value), this.contentType, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -98,14 +113,14 @@ public boolean equals(Object obj) { return Arrays.equals(this.value, other.value) && Objects.equals(this.contentType, other.contentType) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -139,36 +154,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -219,6 +204,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultBlob (" + "value=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlobMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlobMetadata.java new file mode 100644 index 000000000..294be7279 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlobMetadata.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.BlobMetadata + * + */ + +@IRI("aas:BlobMetadata") +public class DefaultBlobMetadata implements BlobMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultBlobMetadata() {} + + public DefaultBlobMetadata(BlobMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultBlobMetadata other = (DefaultBlobMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultBlobMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultBlobMetadata bean. + */ + public static class Builder extends BlobMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultBlobMetadata newBuildingInstance() { + return new DefaultBlobMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlobValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlobValue.java new file mode 100644 index 000000000..3d220c308 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultBlobValue.java @@ -0,0 +1,111 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.BlobValue + * + */ + +@IRI("aas:BlobValue") +public class DefaultBlobValue implements BlobValue { + + @IRI("https://admin-shell.io/aas/3/0/BlobValue/mimeType") + protected String mimeType; + + @IRI("https://admin-shell.io/aas/3/0/BlobValue/value") + protected String value; + + public DefaultBlobValue() {} + + public DefaultBlobValue(BlobValue x) { + this.mimeType = x.getMimeType(); + this.value = x.getValue(); + } + + @Override + public int hashCode() { + return Objects.hash(this.mimeType, + this.value); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultBlobValue other = (DefaultBlobValue) obj; + return Objects.equals(this.mimeType, other.mimeType) && + Objects.equals(this.value, other.value); + } + } + + @Override + public String getMimeType() { + return mimeType; + } + + @Override + public void setMimeType(String mimeType) { + this.mimeType = mimeType; + } + + @Override + public String getValue() { + return value; + } + + @Override + public void setValue(String value) { + this.value = value; + } + + public String toString() { + return String.format( + "DefaultBlobValue (" + "mimeType=%s," + + "value=%s," + + ")", + this.mimeType, this.value); + } + + /** + * This builder class can be used to construct a DefaultBlobValue bean. + */ + public static class Builder extends BlobValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultBlobValue newBuildingInstance() { + return new DefaultBlobValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultCapability.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultCapability.java index 6ca35f6bf..0f3006313 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultCapability.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultCapability.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.CapabilityBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Capability * @@ -63,17 +64,29 @@ public class DefaultCapability implements Capability { public DefaultCapability() {} + public DefaultCapability(Capability x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -87,14 +100,14 @@ public boolean equals(Object obj) { } else { DefaultCapability other = (DefaultCapability) obj; return Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -108,36 +121,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -188,6 +171,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultCapability (" diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultCapabilityMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultCapabilityMetadata.java new file mode 100644 index 000000000..dfe77fb95 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultCapabilityMetadata.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.CapabilityMetadata + * + */ + +@IRI("aas:CapabilityMetadata") +public class DefaultCapabilityMetadata implements CapabilityMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultCapabilityMetadata() {} + + public DefaultCapabilityMetadata(CapabilityMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultCapabilityMetadata other = (DefaultCapabilityMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultCapabilityMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultCapabilityMetadata bean. + */ + public static class Builder extends CapabilityMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultCapabilityMetadata newBuildingInstance() { + return new DefaultCapabilityMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultConceptDescription.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultConceptDescription.java index 51949170b..14d41dbe6 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultConceptDescription.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultConceptDescription.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ConceptDescriptionBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription * @@ -63,17 +64,29 @@ public class DefaultConceptDescription implements ConceptDescription { public DefaultConceptDescription() {} + public DefaultConceptDescription(ConceptDescription x) { + this.isCaseOf = x.getIsCaseOf(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.administration = x.getAdministration(); + this.id = x.getId(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.isCaseOf, - this.embeddedDataSpecifications, this.administration, this.id, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.embeddedDataSpecifications); } @Override @@ -87,14 +100,14 @@ public boolean equals(Object obj) { } else { DefaultConceptDescription other = (DefaultConceptDescription) obj; return Objects.equals(this.isCaseOf, other.isCaseOf) && - Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && Objects.equals(this.administration, other.administration) && Objects.equals(this.id, other.id) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications); } } @@ -108,16 +121,6 @@ public void setIsCaseOf(List isCaseOfs) { this.isCaseOf = isCaseOfs; } - @Override - public List getEmbeddedDataSpecifications() { - return embeddedDataSpecifications; - } - - @Override - public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { - this.embeddedDataSpecifications = embeddedDataSpecifications; - } - @Override public AdministrativeInformation getAdministration() { return administration; @@ -188,6 +191,16 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + public String toString() { return String.format( "DefaultConceptDescription (" + "isCaseOf=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDataSpecificationIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDataSpecificationIec61360.java index b772cd0a6..42f57c645 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDataSpecificationIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDataSpecificationIec61360.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.DataSpecificationIec61360Builder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.DataSpecificationIec61360 @@ -73,6 +74,21 @@ public class DefaultDataSpecificationIec61360 implements DataSpecificationIec613 public DefaultDataSpecificationIec61360() {} + public DefaultDataSpecificationIec61360(DataSpecificationIec61360 x) { + this.dataType = x.getDataType(); + this.definition = x.getDefinition(); + this.levelType = x.getLevelType(); + this.preferredName = x.getPreferredName(); + this.shortName = x.getShortName(); + this.sourceOfDefinition = x.getSourceOfDefinition(); + this.symbol = x.getSymbol(); + this.unit = x.getUnit(); + this.unitId = x.getUnitId(); + this.value = x.getValue(); + this.valueFormat = x.getValueFormat(); + this.valueList = x.getValueList(); + } + @Override public int hashCode() { return Objects.hash(this.preferredName, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.java index c1a915ca5..4ae3f5454 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.java @@ -1,12 +1,12 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software distributed under the License * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express * or implied. See the License for the specific language governing permissions and limitations under @@ -15,27 +15,46 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.Descriptor; -import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.DescriptorBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Descriptor + * + */ + @IRI("aas:Descriptor") public class DefaultDescriptor implements Descriptor { - @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") - protected List endpoints = new ArrayList<>(); + @IRI("https://admin-shell.io/aas/3/0/Descriptor/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Descriptor/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Descriptor/extensions") + protected List extensions = new ArrayList<>(); - public DefaultDescriptor() { + public DefaultDescriptor() {} + + public DefaultDescriptor(Descriptor x) { + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.extensions = x.getExtensions(); } @Override public int hashCode() { - return Objects.hash(this.endpoints); + return Objects.hash(this.description, + this.displayName, + this.extensions); } @Override @@ -48,18 +67,49 @@ public boolean equals(Object obj) { return false; } else { DefaultDescriptor other = (DefaultDescriptor) obj; - return Objects.equals(this.endpoints, other.endpoints); + return Objects.equals(this.description, other.description) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.extensions, other.extensions); } } @Override - public List getEndpoints() { - return endpoints; + public List getDescription() { + return description; } @Override - public void setEndpoints(List endpoints) { - this.endpoints = endpoints; + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + public String toString() { + return String.format( + "DefaultDescriptor (" + "description=%s," + + "displayName=%s," + + "extensions=%s," + + ")", + this.description, this.displayName, this.extensions); } /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEmbeddedDataSpecification.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEmbeddedDataSpecification.java index 0235e810d..e279bbd7c 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEmbeddedDataSpecification.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEmbeddedDataSpecification.java @@ -15,15 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.DataSpecificationContent; -import org.eclipse.digitaltwin.aas4j.v3.model.EmbeddedDataSpecification; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.EmbeddedDataSpecificationBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.EmbeddedDataSpecification @@ -42,6 +41,11 @@ public class DefaultEmbeddedDataSpecification implements EmbeddedDataSpecificati public DefaultEmbeddedDataSpecification() {} + public DefaultEmbeddedDataSpecification(EmbeddedDataSpecification x) { + this.dataSpecification = x.getDataSpecification(); + this.dataSpecificationContent = x.getDataSpecificationContent(); + } + @Override public int hashCode() { return Objects.hash(this.dataSpecification, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java index 648e4859d..060c3a0e8 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java @@ -1,12 +1,12 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software distributed under the License * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express * or implied. See the License for the specific language governing permissions and limitations under @@ -15,28 +15,38 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; -import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.EndpointBuilder; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; -import java.util.Objects; + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Endpoint + * + */ @IRI("aas:Endpoint") public class DefaultEndpoint implements Endpoint { - @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/_interface") - protected String interfaceValue; + @IRI("https://admin-shell.io/aas/3/0/Endpoint/_interface") + protected String _interface; - @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation") + @IRI("https://admin-shell.io/aas/3/0/Endpoint/protocolInformation") protected ProtocolInformation protocolInformation; - public DefaultEndpoint() { + public DefaultEndpoint() {} + + public DefaultEndpoint(Endpoint x) { + this._interface = x.get_interface(); + this.protocolInformation = x.getProtocolInformation(); } @Override public int hashCode() { - return Objects.hash(this.interfaceValue, + return Objects.hash(this._interface, this.protocolInformation); } @@ -50,19 +60,19 @@ public boolean equals(Object obj) { return false; } else { DefaultEndpoint other = (DefaultEndpoint) obj; - return Objects.equals(this.interfaceValue, other.interfaceValue) && + return Objects.equals(this._interface, other._interface) && Objects.equals(this.protocolInformation, other.protocolInformation); } } @Override - public String getInterface() { - return interfaceValue; + public String get_interface() { + return _interface; } @Override - public void setInterface(String interfaceValue) { - this.interfaceValue = interfaceValue; + public void set_interface(String _interface) { + this._interface = _interface; } @Override @@ -75,6 +85,14 @@ public void setProtocolInformation(ProtocolInformation protocolInformation) { this.protocolInformation = protocolInformation; } + public String toString() { + return String.format( + "DefaultEndpoint (" + "_interface=%s," + + "protocolInformation=%s," + + ")", + this._interface, this.protocolInformation); + } + /** * This builder class can be used to construct a DefaultEndpoint bean. */ diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntity.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntity.java index 2b38425b8..c2bb3ae38 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntity.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntity.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.EntityBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Entity * @@ -74,6 +75,22 @@ public class DefaultEntity implements Entity { public DefaultEntity() {} + public DefaultEntity(Entity x) { + this.entityType = x.getEntityType(); + this.globalAssetId = x.getGlobalAssetId(); + this.specificAssetIds = x.getSpecificAssetIds(); + this.statements = x.getStatements(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.statements, @@ -81,14 +98,14 @@ public int hashCode() { this.globalAssetId, this.specificAssetIds, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -106,14 +123,14 @@ public boolean equals(Object obj) { Objects.equals(this.globalAssetId, other.globalAssetId) && Objects.equals(this.specificAssetIds, other.specificAssetIds) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -167,36 +184,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -247,6 +234,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultEntity (" + "statements=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntityMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntityMetadata.java new file mode 100644 index 000000000..cc3ee660e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntityMetadata.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.EntityMetadata + * + */ + +@IRI("aas:EntityMetadata") +public class DefaultEntityMetadata implements EntityMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultEntityMetadata() {} + + public DefaultEntityMetadata(EntityMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultEntityMetadata other = (DefaultEntityMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultEntityMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultEntityMetadata bean. + */ + public static class Builder extends EntityMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultEntityMetadata newBuildingInstance() { + return new DefaultEntityMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntityValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntityValue.java new file mode 100644 index 000000000..18b1e7539 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEntityValue.java @@ -0,0 +1,147 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.EntityValue + * + */ + +@IRI("aas:EntityValue") +public class DefaultEntityValue implements EntityValue { + + @IRI("https://admin-shell.io/aas/3/0/EntityValue/entityType") + protected EntityType entityType; + + @IRI("https://admin-shell.io/aas/3/0/EntityValue/globalAssetId") + protected ReferenceValue globalAssetId; + + @IRI("https://admin-shell.io/aas/3/0/EntityValue/specificAssetIds") + protected List specificAssetIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/EntityValue/statements") + protected List statements = new ArrayList<>(); + + public DefaultEntityValue() {} + + public DefaultEntityValue(EntityValue x) { + this.entityType = x.getEntityType(); + this.globalAssetId = x.getGlobalAssetId(); + this.specificAssetIds = x.getSpecificAssetIds(); + this.statements = x.getStatements(); + } + + @Override + public int hashCode() { + return Objects.hash(this.entityType, + this.globalAssetId, + this.specificAssetIds, + this.statements); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultEntityValue other = (DefaultEntityValue) obj; + return Objects.equals(this.entityType, other.entityType) && + Objects.equals(this.globalAssetId, other.globalAssetId) && + Objects.equals(this.specificAssetIds, other.specificAssetIds) && + Objects.equals(this.statements, other.statements); + } + } + + @Override + public EntityType getEntityType() { + return entityType; + } + + @Override + public void setEntityType(EntityType entityType) { + this.entityType = entityType; + } + + @Override + public ReferenceValue getGlobalAssetId() { + return globalAssetId; + } + + @Override + public void setGlobalAssetId(ReferenceValue globalAssetId) { + this.globalAssetId = globalAssetId; + } + + @Override + public List getSpecificAssetIds() { + return specificAssetIds; + } + + @Override + public void setSpecificAssetIds(List specificAssetIds) { + this.specificAssetIds = specificAssetIds; + } + + @Override + public List getStatements() { + return statements; + } + + @Override + public void setStatements(List statements) { + this.statements = statements; + } + + public String toString() { + return String.format( + "DefaultEntityValue (" + "entityType=%s," + + "globalAssetId=%s," + + "specificAssetIds=%s," + + "statements=%s," + + ")", + this.entityType, this.globalAssetId, this.specificAssetIds, this.statements); + } + + /** + * This builder class can be used to construct a DefaultEntityValue bean. + */ + public static class Builder extends EntityValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultEntityValue newBuildingInstance() { + return new DefaultEntityValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEnvironment.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEnvironment.java index 30d5f6377..27e72bdfd 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEnvironment.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEnvironment.java @@ -15,18 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; -import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.Environment; -import org.eclipse.digitaltwin.aas4j.v3.model.Submodel; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.EnvironmentBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Environment * @@ -47,6 +45,12 @@ public class DefaultEnvironment implements Environment { public DefaultEnvironment() {} + public DefaultEnvironment(Environment x) { + this.assetAdministrationShells = x.getAssetAdministrationShells(); + this.conceptDescriptions = x.getConceptDescriptions(); + this.submodels = x.getSubmodels(); + } + @Override public int hashCode() { return Objects.hash(this.assetAdministrationShells, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEventPayload.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEventPayload.java index 750f1c5ff..ada88d61c 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEventPayload.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEventPayload.java @@ -15,15 +15,15 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.EventPayload; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.EventPayloadBuilder; - import java.util.Arrays; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.EventPayload * @@ -59,6 +59,17 @@ public class DefaultEventPayload implements EventPayload { public DefaultEventPayload() {} + public DefaultEventPayload(EventPayload x) { + this.observableReference = x.getObservableReference(); + this.observableSemanticId = x.getObservableSemanticId(); + this.payload = x.getPayload(); + this.source = x.getSource(); + this.sourceSemanticId = x.getSourceSemanticId(); + this.subjectId = x.getSubjectId(); + this.timeStamp = x.getTimeStamp(); + this.topic = x.getTopic(); + } + @Override public int hashCode() { return Objects.hash(this.source, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultExtension.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultExtension.java index eb013ed1f..fd01dbfc2 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultExtension.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultExtension.java @@ -15,17 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; -import org.eclipse.digitaltwin.aas4j.v3.model.Extension; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ExtensionBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Extension * @@ -53,7 +52,18 @@ public class DefaultExtension implements Extension { @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); - public DefaultExtension() {} + public DefaultExtension() { + this.valueType = DataTypeDefXsd.STRING; + } + + public DefaultExtension(Extension x) { + this.name = x.getName(); + this.refersTo = x.getRefersTo(); + this.value = x.getValue(); + this.valueType = x.getValueType(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + } @Override public int hashCode() { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFile.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFile.java index 52f767e6e..678fde2fe 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFile.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFile.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.FileBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.File * @@ -68,19 +69,33 @@ public class DefaultFile implements File { public DefaultFile() {} + public DefaultFile(File x) { + this.contentType = x.getContentType(); + this.value = x.getValue(); + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.value, this.contentType, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -96,14 +111,14 @@ public boolean equals(Object obj) { return Objects.equals(this.value, other.value) && Objects.equals(this.contentType, other.contentType) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -137,36 +152,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -217,6 +202,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultFile (" + "value=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFileMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFileMetadata.java new file mode 100644 index 000000000..593a4acc7 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFileMetadata.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.FileMetadata + * + */ + +@IRI("aas:FileMetadata") +public class DefaultFileMetadata implements FileMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultFileMetadata() {} + + public DefaultFileMetadata(FileMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultFileMetadata other = (DefaultFileMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultFileMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultFileMetadata bean. + */ + public static class Builder extends FileMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultFileMetadata newBuildingInstance() { + return new DefaultFileMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFileValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFileValue.java new file mode 100644 index 000000000..cee3bfd30 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultFileValue.java @@ -0,0 +1,111 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.FileValue + * + */ + +@IRI("aas:FileValue") +public class DefaultFileValue implements FileValue { + + @IRI("https://admin-shell.io/aas/3/0/FileValue/contentType") + protected String contentType; + + @IRI("https://admin-shell.io/aas/3/0/FileValue/value") + protected String value; + + public DefaultFileValue() {} + + public DefaultFileValue(FileValue x) { + this.contentType = x.getContentType(); + this.value = x.getValue(); + } + + @Override + public int hashCode() { + return Objects.hash(this.contentType, + this.value); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultFileValue other = (DefaultFileValue) obj; + return Objects.equals(this.contentType, other.contentType) && + Objects.equals(this.value, other.value); + } + } + + @Override + public String getContentType() { + return contentType; + } + + @Override + public void setContentType(String contentType) { + this.contentType = contentType; + } + + @Override + public String getValue() { + return value; + } + + @Override + public void setValue(String value) { + this.value = value; + } + + public String toString() { + return String.format( + "DefaultFileValue (" + "contentType=%s," + + "value=%s," + + ")", + this.contentType, this.value); + } + + /** + * This builder class can be used to construct a DefaultFileValue bean. + */ + public static class Builder extends FileValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultFileValue newBuildingInstance() { + return new DefaultFileValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultKey.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultKey.java index 45d6d6f7e..ce3564955 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultKey.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultKey.java @@ -15,14 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.Key; -import org.eclipse.digitaltwin.aas4j.v3.model.KeyTypes; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.KeyBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Key * @@ -40,6 +40,11 @@ public class DefaultKey implements Key { public DefaultKey() {} + public DefaultKey(Key x) { + this.type = x.getType(); + this.value = x.getValue(); + } + @Override public int hashCode() { return Objects.hash(this.type, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringDefinitionTypeIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringDefinitionTypeIec61360.java index 4c8a473b9..df540bb93 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringDefinitionTypeIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringDefinitionTypeIec61360.java @@ -15,13 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringDefinitionTypeIec61360; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.LangStringDefinitionTypeIec61360Builder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.LangStringDefinitionTypeIec61360 @@ -40,6 +41,11 @@ public class DefaultLangStringDefinitionTypeIec61360 implements LangStringDefini public DefaultLangStringDefinitionTypeIec61360() {} + public DefaultLangStringDefinitionTypeIec61360(LangStringDefinitionTypeIec61360 x) { + this.language = x.getLanguage(); + this.text = x.getText(); + } + @Override public int hashCode() { return Objects.hash(this.language, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringNameType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringNameType.java index cf01867c5..f9230ad7e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringNameType.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringNameType.java @@ -15,13 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringNameType; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.LangStringNameTypeBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.LangStringNameType * @@ -39,6 +40,11 @@ public class DefaultLangStringNameType implements LangStringNameType { public DefaultLangStringNameType() {} + public DefaultLangStringNameType(LangStringNameType x) { + this.language = x.getLanguage(); + this.text = x.getText(); + } + @Override public int hashCode() { return Objects.hash(this.language, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringPreferredNameTypeIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringPreferredNameTypeIec61360.java index 40be9c6fc..00e4ea4ce 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringPreferredNameTypeIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringPreferredNameTypeIec61360.java @@ -15,13 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringPreferredNameTypeIec61360; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.LangStringPreferredNameTypeIec61360Builder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.LangStringPreferredNameTypeIec61360 @@ -40,6 +41,11 @@ public class DefaultLangStringPreferredNameTypeIec61360 implements LangStringPre public DefaultLangStringPreferredNameTypeIec61360() {} + public DefaultLangStringPreferredNameTypeIec61360(LangStringPreferredNameTypeIec61360 x) { + this.language = x.getLanguage(); + this.text = x.getText(); + } + @Override public int hashCode() { return Objects.hash(this.language, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringShortNameTypeIec61360.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringShortNameTypeIec61360.java index f33fc73ee..326f7d300 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringShortNameTypeIec61360.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringShortNameTypeIec61360.java @@ -15,13 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringShortNameTypeIec61360; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.LangStringShortNameTypeIec61360Builder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.LangStringShortNameTypeIec61360 @@ -40,6 +41,11 @@ public class DefaultLangStringShortNameTypeIec61360 implements LangStringShortNa public DefaultLangStringShortNameTypeIec61360() {} + public DefaultLangStringShortNameTypeIec61360(LangStringShortNameTypeIec61360 x) { + this.language = x.getLanguage(); + this.text = x.getText(); + } + @Override public int hashCode() { return Objects.hash(this.language, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringTextType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringTextType.java index 196784d6e..12524954e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringTextType.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLangStringTextType.java @@ -15,13 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringTextType; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.LangStringTextTypeBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.LangStringTextType * @@ -39,6 +40,11 @@ public class DefaultLangStringTextType implements LangStringTextType { public DefaultLangStringTextType() {} + public DefaultLangStringTextType(LangStringTextType x) { + this.language = x.getLanguage(); + this.text = x.getText(); + } + @Override public int hashCode() { return Objects.hash(this.language, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLevelType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLevelType.java index 5cf2b4ecd..987fcd731 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLevelType.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultLevelType.java @@ -15,13 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.LevelType; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.LevelTypeBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.LevelType * @@ -46,6 +47,13 @@ public class DefaultLevelType implements LevelType { public DefaultLevelType() {} + public DefaultLevelType(LevelType x) { + this.max = x.getMax(); + this.min = x.getMin(); + this.nom = x.getNom(); + this.typ = x.getTyp(); + } + @Override public int hashCode() { return Objects.hash(this.min, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMessage.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMessage.java new file mode 100644 index 000000000..d455c9c1c --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMessage.java @@ -0,0 +1,145 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Message + * + */ + +@IRI("aas:Message") +public class DefaultMessage implements Message { + + @IRI("https://admin-shell.io/aas/3/0/Message/code") + protected String code; + + @IRI("https://admin-shell.io/aas/3/0/Message/messageType") + protected MessageType messageType; + + @IRI("https://admin-shell.io/aas/3/0/Message/text") + protected String text; + + @IRI("https://admin-shell.io/aas/3/0/Message/timestamp") + protected String timestamp; + + public DefaultMessage() {} + + public DefaultMessage(Message x) { + this.code = x.getCode(); + this.messageType = x.getMessageType(); + this.text = x.getText(); + this.timestamp = x.getTimestamp(); + } + + @Override + public int hashCode() { + return Objects.hash(this.code, + this.messageType, + this.text, + this.timestamp); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultMessage other = (DefaultMessage) obj; + return Objects.equals(this.code, other.code) && + Objects.equals(this.messageType, other.messageType) && + Objects.equals(this.text, other.text) && + Objects.equals(this.timestamp, other.timestamp); + } + } + + @Override + public String getCode() { + return code; + } + + @Override + public void setCode(String code) { + this.code = code; + } + + @Override + public MessageType getMessageType() { + return messageType; + } + + @Override + public void setMessageType(MessageType messageType) { + this.messageType = messageType; + } + + @Override + public String getText() { + return text; + } + + @Override + public void setText(String text) { + this.text = text; + } + + @Override + public String getTimestamp() { + return timestamp; + } + + @Override + public void setTimestamp(String timestamp) { + this.timestamp = timestamp; + } + + public String toString() { + return String.format( + "DefaultMessage (" + "code=%s," + + "messageType=%s," + + "text=%s," + + "timestamp=%s," + + ")", + this.code, this.messageType, this.text, this.timestamp); + } + + /** + * This builder class can be used to construct a DefaultMessage bean. + */ + public static class Builder extends MessageBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultMessage newBuildingInstance() { + return new DefaultMessage(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguageProperty.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguageProperty.java index 16705fbb2..015eed191 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguageProperty.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguageProperty.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.MultiLanguagePropertyBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.MultiLanguageProperty * @@ -68,19 +69,33 @@ public class DefaultMultiLanguageProperty implements MultiLanguageProperty { public DefaultMultiLanguageProperty() {} + public DefaultMultiLanguageProperty(MultiLanguageProperty x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.value = x.getValue(); + this.valueId = x.getValueId(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.value, this.valueId, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -96,14 +111,14 @@ public boolean equals(Object obj) { return Objects.equals(this.value, other.value) && Objects.equals(this.valueId, other.valueId) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -137,36 +152,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -217,6 +202,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultMultiLanguageProperty (" + "value=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguagePropertyMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguagePropertyMetadata.java new file mode 100644 index 000000000..beaad42ce --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguagePropertyMetadata.java @@ -0,0 +1,242 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.MultiLanguagePropertyMetadata + * + */ + +@IRI("aas:MultiLanguagePropertyMetadata") +public class DefaultMultiLanguagePropertyMetadata implements MultiLanguagePropertyMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultMultiLanguagePropertyMetadata() {} + + public DefaultMultiLanguagePropertyMetadata(MultiLanguagePropertyMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultMultiLanguagePropertyMetadata other = (DefaultMultiLanguagePropertyMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultMultiLanguagePropertyMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultMultiLanguagePropertyMetadata bean. + */ + public static class Builder extends MultiLanguagePropertyMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultMultiLanguagePropertyMetadata newBuildingInstance() { + return new DefaultMultiLanguagePropertyMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguagePropertyValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguagePropertyValue.java new file mode 100644 index 000000000..76f517b3d --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultMultiLanguagePropertyValue.java @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.MultiLanguagePropertyValue + * + */ + +@IRI("aas:MultiLanguagePropertyValue") +public class DefaultMultiLanguagePropertyValue implements MultiLanguagePropertyValue { + + public DefaultMultiLanguagePropertyValue() {} + + public DefaultMultiLanguagePropertyValue(MultiLanguagePropertyValue x) { + + } + + @Override + public int hashCode() { + return Objects.hash(super.hashCode()); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } + return true; + } + + public String toString() { + return String.format( + "DefaultMultiLanguagePropertyValue (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultMultiLanguagePropertyValue bean. + */ + public static class Builder extends MultiLanguagePropertyValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultMultiLanguagePropertyValue newBuildingInstance() { + return new DefaultMultiLanguagePropertyValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultNumberValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultNumberValue.java new file mode 100644 index 000000000..7eb20d097 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultNumberValue.java @@ -0,0 +1,80 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.NumberValue + * + */ + +@IRI("aas:NumberValue") +public class DefaultNumberValue implements NumberValue { + + public DefaultNumberValue() {} + + public DefaultNumberValue(NumberValue x) { + + } + + @Override + public int hashCode() { + return Objects.hash(super.hashCode()); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } + return true; + } + + public String toString() { + return String.format( + "DefaultNumberValue (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultNumberValue bean. + */ + public static class Builder extends NumberValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultNumberValue newBuildingInstance() { + return new DefaultNumberValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperation.java index eb713de68..cddee6979 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperation.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.OperationBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Operation * @@ -71,20 +72,35 @@ public class DefaultOperation implements Operation { public DefaultOperation() {} + public DefaultOperation(Operation x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.inoutputVariables = x.getInoutputVariables(); + this.inputVariables = x.getInputVariables(); + this.outputVariables = x.getOutputVariables(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.inputVariables, this.outputVariables, this.inoutputVariables, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -101,14 +117,14 @@ public boolean equals(Object obj) { Objects.equals(this.outputVariables, other.outputVariables) && Objects.equals(this.inoutputVariables, other.inoutputVariables) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -152,36 +168,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -232,6 +218,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultOperation (" + "inputVariables=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationHandle.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationHandle.java new file mode 100644 index 000000000..228ff5052 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationHandle.java @@ -0,0 +1,111 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.OperationHandle + * + */ + +@IRI("aas:OperationHandle") +public class DefaultOperationHandle implements OperationHandle { + + @IRI("https://admin-shell.io/aas/3/0/OperationHandle/handleId") + protected String handleId; + + @IRI("https://admin-shell.io/aas/3/0/OperationHandle/requestId") + protected String requestId; + + public DefaultOperationHandle() {} + + public DefaultOperationHandle(OperationHandle x) { + this.handleId = x.getHandleId(); + this.requestId = x.getRequestId(); + } + + @Override + public int hashCode() { + return Objects.hash(this.handleId, + this.requestId); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultOperationHandle other = (DefaultOperationHandle) obj; + return Objects.equals(this.handleId, other.handleId) && + Objects.equals(this.requestId, other.requestId); + } + } + + @Override + public String getHandleId() { + return handleId; + } + + @Override + public void setHandleId(String handleId) { + this.handleId = handleId; + } + + @Override + public String getRequestId() { + return requestId; + } + + @Override + public void setRequestId(String requestId) { + this.requestId = requestId; + } + + public String toString() { + return String.format( + "DefaultOperationHandle (" + "handleId=%s," + + "requestId=%s," + + ")", + this.handleId, this.requestId); + } + + /** + * This builder class can be used to construct a DefaultOperationHandle bean. + */ + public static class Builder extends OperationHandleBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultOperationHandle newBuildingInstance() { + return new DefaultOperationHandle(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationMetadata.java new file mode 100644 index 000000000..a059e226e --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationMetadata.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.OperationMetadata + * + */ + +@IRI("aas:OperationMetadata") +public class DefaultOperationMetadata implements OperationMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultOperationMetadata() {} + + public DefaultOperationMetadata(OperationMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultOperationMetadata other = (DefaultOperationMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultOperationMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultOperationMetadata bean. + */ + public static class Builder extends OperationMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultOperationMetadata newBuildingInstance() { + return new DefaultOperationMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationRequest.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationRequest.java new file mode 100644 index 000000000..b147b94a4 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationRequest.java @@ -0,0 +1,146 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.math.BigInteger; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.OperationRequest + * + */ + +@IRI("aas:OperationRequest") +public class DefaultOperationRequest implements OperationRequest { + + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/inoutputArguments") + protected OperationVariable inoutputArguments; + + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/inputArguments") + protected OperationVariable inputArguments; + + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/requestId") + protected String requestId; + + @IRI("https://admin-shell.io/aas/3/0/OperationRequest/timeout") + protected BigInteger timeout; + + public DefaultOperationRequest() {} + + public DefaultOperationRequest(OperationRequest x) { + this.inoutputArguments = x.getInoutputArguments(); + this.inputArguments = x.getInputArguments(); + this.requestId = x.getRequestId(); + this.timeout = x.getTimeout(); + } + + @Override + public int hashCode() { + return Objects.hash(this.inoutputArguments, + this.inputArguments, + this.requestId, + this.timeout); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultOperationRequest other = (DefaultOperationRequest) obj; + return Objects.equals(this.inoutputArguments, other.inoutputArguments) && + Objects.equals(this.inputArguments, other.inputArguments) && + Objects.equals(this.requestId, other.requestId) && + Objects.equals(this.timeout, other.timeout); + } + } + + @Override + public OperationVariable getInoutputArguments() { + return inoutputArguments; + } + + @Override + public void setInoutputArguments(OperationVariable inoutputArguments) { + this.inoutputArguments = inoutputArguments; + } + + @Override + public OperationVariable getInputArguments() { + return inputArguments; + } + + @Override + public void setInputArguments(OperationVariable inputArguments) { + this.inputArguments = inputArguments; + } + + @Override + public String getRequestId() { + return requestId; + } + + @Override + public void setRequestId(String requestId) { + this.requestId = requestId; + } + + @Override + public BigInteger getTimeout() { + return timeout; + } + + @Override + public void setTimeout(BigInteger timeout) { + this.timeout = timeout; + } + + public String toString() { + return String.format( + "DefaultOperationRequest (" + "inoutputArguments=%s," + + "inputArguments=%s," + + "requestId=%s," + + "timeout=%s," + + ")", + this.inoutputArguments, this.inputArguments, this.requestId, this.timeout); + } + + /** + * This builder class can be used to construct a DefaultOperationRequest bean. + */ + public static class Builder extends OperationRequestBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultOperationRequest newBuildingInstance() { + return new DefaultOperationRequest(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationRequestValueOnly.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationRequestValueOnly.java new file mode 100644 index 000000000..a46ce9cf0 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationRequestValueOnly.java @@ -0,0 +1,147 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.math.BigInteger; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.OperationRequestValueOnly + * + */ + +@IRI("aas:OperationRequestValueOnly") +public class DefaultOperationRequestValueOnly implements OperationRequestValueOnly { + + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inoutputArguments") + protected String inoutputArguments; + + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/inputArguments") + protected String inputArguments; + + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/requestId") + protected String requestId; + + @IRI("https://admin-shell.io/aas/3/0/OperationRequestValueOnly/timeout") + protected BigInteger timeout; + + public DefaultOperationRequestValueOnly() {} + + public DefaultOperationRequestValueOnly(OperationRequestValueOnly x) { + this.inoutputArguments = x.getInoutputArguments(); + this.inputArguments = x.getInputArguments(); + this.requestId = x.getRequestId(); + this.timeout = x.getTimeout(); + } + + @Override + public int hashCode() { + return Objects.hash(this.inoutputArguments, + this.inputArguments, + this.requestId, + this.timeout); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultOperationRequestValueOnly other = (DefaultOperationRequestValueOnly) obj; + return Objects.equals(this.inoutputArguments, other.inoutputArguments) && + Objects.equals(this.inputArguments, other.inputArguments) && + Objects.equals(this.requestId, other.requestId) && + Objects.equals(this.timeout, other.timeout); + } + } + + @Override + public String getInoutputArguments() { + return inoutputArguments; + } + + @Override + public void setInoutputArguments(String inoutputArguments) { + this.inoutputArguments = inoutputArguments; + } + + @Override + public String getInputArguments() { + return inputArguments; + } + + @Override + public void setInputArguments(String inputArguments) { + this.inputArguments = inputArguments; + } + + @Override + public String getRequestId() { + return requestId; + } + + @Override + public void setRequestId(String requestId) { + this.requestId = requestId; + } + + @Override + public BigInteger getTimeout() { + return timeout; + } + + @Override + public void setTimeout(BigInteger timeout) { + this.timeout = timeout; + } + + public String toString() { + return String.format( + "DefaultOperationRequestValueOnly (" + "inoutputArguments=%s," + + "inputArguments=%s," + + "requestId=%s," + + "timeout=%s," + + ")", + this.inoutputArguments, this.inputArguments, this.requestId, this.timeout); + } + + /** + * This builder class can be used to construct a DefaultOperationRequestValueOnly bean. + */ + public static class Builder extends OperationRequestValueOnlyBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultOperationRequestValueOnly newBuildingInstance() { + return new DefaultOperationRequestValueOnly(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationResult.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationResult.java new file mode 100644 index 000000000..c364deba9 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationResult.java @@ -0,0 +1,162 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.OperationResult + * + */ + +@IRI("aas:OperationResult") +public class DefaultOperationResult implements OperationResult { + + @IRI("https://admin-shell.io/aas/3/0/OperationResult/executionResult") + protected Result executionResult; + + @IRI("https://admin-shell.io/aas/3/0/OperationResult/executionState") + protected ExecutionState executionState; + + @IRI("https://admin-shell.io/aas/3/0/OperationResult/inoutputArguments") + protected OperationVariable inoutputArguments; + + @IRI("https://admin-shell.io/aas/3/0/OperationResult/outputArguments") + protected OperationVariable outputArguments; + + @IRI("https://admin-shell.io/aas/3/0/OperationResult/requestId") + protected String requestId; + + public DefaultOperationResult() {} + + public DefaultOperationResult(OperationResult x) { + this.executionResult = x.getExecutionResult(); + this.executionState = x.getExecutionState(); + this.inoutputArguments = x.getInoutputArguments(); + this.outputArguments = x.getOutputArguments(); + this.requestId = x.getRequestId(); + } + + @Override + public int hashCode() { + return Objects.hash(this.executionResult, + this.executionState, + this.inoutputArguments, + this.outputArguments, + this.requestId); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultOperationResult other = (DefaultOperationResult) obj; + return Objects.equals(this.executionResult, other.executionResult) && + Objects.equals(this.executionState, other.executionState) && + Objects.equals(this.inoutputArguments, other.inoutputArguments) && + Objects.equals(this.outputArguments, other.outputArguments) && + Objects.equals(this.requestId, other.requestId); + } + } + + @Override + public Result getExecutionResult() { + return executionResult; + } + + @Override + public void setExecutionResult(Result executionResult) { + this.executionResult = executionResult; + } + + @Override + public ExecutionState getExecutionState() { + return executionState; + } + + @Override + public void setExecutionState(ExecutionState executionState) { + this.executionState = executionState; + } + + @Override + public OperationVariable getInoutputArguments() { + return inoutputArguments; + } + + @Override + public void setInoutputArguments(OperationVariable inoutputArguments) { + this.inoutputArguments = inoutputArguments; + } + + @Override + public OperationVariable getOutputArguments() { + return outputArguments; + } + + @Override + public void setOutputArguments(OperationVariable outputArguments) { + this.outputArguments = outputArguments; + } + + @Override + public String getRequestId() { + return requestId; + } + + @Override + public void setRequestId(String requestId) { + this.requestId = requestId; + } + + public String toString() { + return String.format( + "DefaultOperationResult (" + "executionResult=%s," + + "executionState=%s," + + "inoutputArguments=%s," + + "outputArguments=%s," + + "requestId=%s," + + ")", + this.executionResult, this.executionState, this.inoutputArguments, this.outputArguments, this.requestId); + } + + /** + * This builder class can be used to construct a DefaultOperationResult bean. + */ + public static class Builder extends OperationResultBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultOperationResult newBuildingInstance() { + return new DefaultOperationResult(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationResultValueOnly.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationResultValueOnly.java new file mode 100644 index 000000000..f499cc462 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationResultValueOnly.java @@ -0,0 +1,164 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.OperationResultValueOnly + * + */ + +@IRI("aas:OperationResultValueOnly") +public class DefaultOperationResultValueOnly implements OperationResultValueOnly { + + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionResult") + protected List executionResult = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/executionState") + protected List executionState = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/inoutputArguments") + protected List inoutputArguments = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/outputArguments") + protected List outputArguments = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/OperationResultValueOnly/requestId") + protected List requestId = new ArrayList<>(); + + public DefaultOperationResultValueOnly() {} + + public DefaultOperationResultValueOnly(OperationResultValueOnly x) { + this.executionResult = x.getExecutionResult(); + this.executionState = x.getExecutionState(); + this.inoutputArguments = x.getInoutputArguments(); + this.outputArguments = x.getOutputArguments(); + this.requestId = x.getRequestId(); + } + + @Override + public int hashCode() { + return Objects.hash(this.executionResult, + this.executionState, + this.inoutputArguments, + this.outputArguments, + this.requestId); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultOperationResultValueOnly other = (DefaultOperationResultValueOnly) obj; + return Objects.equals(this.executionResult, other.executionResult) && + Objects.equals(this.executionState, other.executionState) && + Objects.equals(this.inoutputArguments, other.inoutputArguments) && + Objects.equals(this.outputArguments, other.outputArguments) && + Objects.equals(this.requestId, other.requestId); + } + } + + @Override + public List getExecutionResult() { + return executionResult; + } + + @Override + public void setExecutionResult(List executionResults) { + this.executionResult = executionResults; + } + + @Override + public List getExecutionState() { + return executionState; + } + + @Override + public void setExecutionState(List executionStates) { + this.executionState = executionStates; + } + + @Override + public List getInoutputArguments() { + return inoutputArguments; + } + + @Override + public void setInoutputArguments(List inoutputArguments) { + this.inoutputArguments = inoutputArguments; + } + + @Override + public List getOutputArguments() { + return outputArguments; + } + + @Override + public void setOutputArguments(List outputArguments) { + this.outputArguments = outputArguments; + } + + @Override + public List getRequestId() { + return requestId; + } + + @Override + public void setRequestId(List requestIds) { + this.requestId = requestIds; + } + + public String toString() { + return String.format( + "DefaultOperationResultValueOnly (" + "executionResult=%s," + + "executionState=%s," + + "inoutputArguments=%s," + + "outputArguments=%s," + + "requestId=%s," + + ")", + this.executionResult, this.executionState, this.inoutputArguments, this.outputArguments, this.requestId); + } + + /** + * This builder class can be used to construct a DefaultOperationResultValueOnly bean. + */ + public static class Builder extends OperationResultValueOnlyBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultOperationResultValueOnly newBuildingInstance() { + return new DefaultOperationResultValueOnly(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationVariable.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationVariable.java index 17f42b008..eeb59a52d 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationVariable.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultOperationVariable.java @@ -15,14 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.OperationVariable; -import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.OperationVariableBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.OperationVariable * @@ -38,6 +38,10 @@ public class DefaultOperationVariable implements OperationVariable { public DefaultOperationVariable() {} + public DefaultOperationVariable(OperationVariable x) { + this.value = x.getValue(); + } + @Override public int hashCode() { return Objects.hash(this.value); diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultPackageDescription.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultPackageDescription.java new file mode 100644 index 000000000..0012b78d1 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultPackageDescription.java @@ -0,0 +1,113 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.PackageDescription + * + */ + +@IRI("aas:PackageDescription") +public class DefaultPackageDescription implements PackageDescription { + + @IRI("https://admin-shell.io/aas/3/0/PackageDescription/items") + protected List items = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/PackageDescription/packageId") + protected String packageId; + + public DefaultPackageDescription() {} + + public DefaultPackageDescription(PackageDescription x) { + this.items = x.getItems(); + this.packageId = x.getPackageId(); + } + + @Override + public int hashCode() { + return Objects.hash(this.items, + this.packageId); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultPackageDescription other = (DefaultPackageDescription) obj; + return Objects.equals(this.items, other.items) && + Objects.equals(this.packageId, other.packageId); + } + } + + @Override + public List getItems() { + return items; + } + + @Override + public void setItems(List items) { + this.items = items; + } + + @Override + public String getPackageId() { + return packageId; + } + + @Override + public void setPackageId(String packageId) { + this.packageId = packageId; + } + + public String toString() { + return String.format( + "DefaultPackageDescription (" + "items=%s," + + "packageId=%s," + + ")", + this.items, this.packageId); + } + + /** + * This builder class can be used to construct a DefaultPackageDescription bean. + */ + public static class Builder extends PackageDescriptionBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultPackageDescription newBuildingInstance() { + return new DefaultPackageDescription(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProperty.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProperty.java index 7917d7d94..acca03333 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProperty.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProperty.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.PropertyBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Property * @@ -71,20 +72,35 @@ public class DefaultProperty implements Property { public DefaultProperty() {} + public DefaultProperty(Property x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.value = x.getValue(); + this.valueId = x.getValueId(); + this.valueType = x.getValueType(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.valueType, this.value, this.valueId, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -101,14 +117,14 @@ public boolean equals(Object obj) { Objects.equals(this.value, other.value) && Objects.equals(this.valueId, other.valueId) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -152,36 +168,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -232,6 +218,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultProperty (" + "valueType=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultPropertyMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultPropertyMetadata.java new file mode 100644 index 000000000..41bbdb0a2 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultPropertyMetadata.java @@ -0,0 +1,256 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.PropertyMetadata + * + */ + +@IRI("aas:PropertyMetadata") +public class DefaultPropertyMetadata implements PropertyMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/PropertyMetadata/valueType") + protected DataTypeDefXsd valueType; + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultPropertyMetadata() {} + + public DefaultPropertyMetadata(PropertyMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.valueType = x.getValueType(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.valueType, + this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultPropertyMetadata other = (DefaultPropertyMetadata) obj; + return Objects.equals(this.valueType, other.valueType) && + Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public DataTypeDefXsd getValueType() { + return valueType; + } + + @Override + public void setValueType(DataTypeDefXsd valueType) { + this.valueType = valueType; + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultPropertyMetadata (" + "valueType=%s," + + ")", + this.valueType); + } + + /** + * This builder class can be used to construct a DefaultPropertyMetadata bean. + */ + public static class Builder extends PropertyMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultPropertyMetadata newBuildingInstance() { + return new DefaultPropertyMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java index 4f2d99fb2..df1b5a03b 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java @@ -1,12 +1,12 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software distributed under the License * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express * or implied. See the License for the specific language governing permissions and limitations under @@ -15,34 +15,49 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ProtocolInformationBuilder; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; -import java.util.Objects; + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation + * + */ @IRI("aas:ProtocolInformation") public class DefaultProtocolInformation implements ProtocolInformation { - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/endpointAddress") protected String endpointAddress; - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocol") protected String endpointProtocol; - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/endpointProtocolVersion") protected String endpointProtocolVersion; - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocol") protected String subprotocol; - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBody") protected String subprotocolBody; - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding") + @IRI("https://admin-shell.io/aas/3/0/ProtocolInformation/subprotocolBodyEncoding") protected String subprotocolBodyEncoding; - public DefaultProtocolInformation() { + public DefaultProtocolInformation() {} + + public DefaultProtocolInformation(ProtocolInformation x) { + this.endpointAddress = x.getEndpointAddress(); + this.endpointProtocol = x.getEndpointProtocol(); + this.endpointProtocolVersion = x.getEndpointProtocolVersion(); + this.subprotocol = x.getSubprotocol(); + this.subprotocolBody = x.getSubprotocolBody(); + this.subprotocolBodyEncoding = x.getSubprotocolBodyEncoding(); } @Override @@ -134,6 +149,19 @@ public void setSubprotocolBodyEncoding(String subprotocolBodyEncoding) { this.subprotocolBodyEncoding = subprotocolBodyEncoding; } + public String toString() { + return String.format( + "DefaultProtocolInformation (" + "endpointAddress=%s," + + "endpointProtocol=%s," + + "endpointProtocolVersion=%s," + + "subprotocol=%s," + + "subprotocolBody=%s," + + "subprotocolBodyEncoding=%s," + + ")", + this.endpointAddress, this.endpointProtocol, this.endpointProtocolVersion, this.subprotocol, this.subprotocolBody, + this.subprotocolBodyEncoding); + } + /** * This builder class can be used to construct a DefaultProtocolInformation bean. */ diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultQualifier.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultQualifier.java index 4a3447a43..4ef4f2d37 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultQualifier.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultQualifier.java @@ -15,18 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; -import org.eclipse.digitaltwin.aas4j.v3.model.Qualifier; -import org.eclipse.digitaltwin.aas4j.v3.model.QualifierKind; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.QualifierBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Qualifier * @@ -58,7 +56,19 @@ public class DefaultQualifier implements Qualifier { @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueType") protected DataTypeDefXsd valueType; - public DefaultQualifier() {} + public DefaultQualifier() { + this.kind = QualifierKind.CONCEPT_QUALIFIER; + } + + public DefaultQualifier(Qualifier x) { + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.kind = x.getKind(); + this.type = x.getType(); + this.value = x.getValue(); + this.valueId = x.getValueId(); + this.valueType = x.getValueType(); + } @Override public int hashCode() { diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRange.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRange.java index 475339717..525b31942 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRange.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRange.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.RangeBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Range * @@ -71,20 +72,35 @@ public class DefaultRange implements Range { public DefaultRange() {} + public DefaultRange(Range x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.max = x.getMax(); + this.min = x.getMin(); + this.valueType = x.getValueType(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + } + @Override public int hashCode() { return Objects.hash(this.valueType, this.min, this.max, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -101,14 +117,14 @@ public boolean equals(Object obj) { Objects.equals(this.min, other.min) && Objects.equals(this.max, other.max) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -152,36 +168,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -232,6 +218,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultRange (" + "valueType=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRangeMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRangeMetadata.java new file mode 100644 index 000000000..48fc44a56 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRangeMetadata.java @@ -0,0 +1,256 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.RangeMetadata + * + */ + +@IRI("aas:RangeMetadata") +public class DefaultRangeMetadata implements RangeMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/RangeMetadata/valueType") + protected DataTypeDefXsd valueType; + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultRangeMetadata() {} + + public DefaultRangeMetadata(RangeMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.valueType = x.getValueType(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.valueType, + this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultRangeMetadata other = (DefaultRangeMetadata) obj; + return Objects.equals(this.valueType, other.valueType) && + Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public DataTypeDefXsd getValueType() { + return valueType; + } + + @Override + public void setValueType(DataTypeDefXsd valueType) { + this.valueType = valueType; + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultRangeMetadata (" + "valueType=%s," + + ")", + this.valueType); + } + + /** + * This builder class can be used to construct a DefaultRangeMetadata bean. + */ + public static class Builder extends RangeMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultRangeMetadata newBuildingInstance() { + return new DefaultRangeMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRangeValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRangeValue.java new file mode 100644 index 000000000..505a4e65c --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRangeValue.java @@ -0,0 +1,112 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.math.BigInteger; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.RangeValue + * + */ + +@IRI("aas:RangeValue") +public class DefaultRangeValue implements RangeValue { + + @IRI("https://admin-shell.io/aas/3/0/RangeValue/max") + protected BigInteger max; + + @IRI("https://admin-shell.io/aas/3/0/RangeValue/min") + protected BigInteger min; + + public DefaultRangeValue() {} + + public DefaultRangeValue(RangeValue x) { + this.max = x.getMax(); + this.min = x.getMin(); + } + + @Override + public int hashCode() { + return Objects.hash(this.max, + this.min); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultRangeValue other = (DefaultRangeValue) obj; + return Objects.equals(this.max, other.max) && + Objects.equals(this.min, other.min); + } + } + + @Override + public BigInteger getMax() { + return max; + } + + @Override + public void setMax(BigInteger max) { + this.max = max; + } + + @Override + public BigInteger getMin() { + return min; + } + + @Override + public void setMin(BigInteger min) { + this.min = min; + } + + public String toString() { + return String.format( + "DefaultRangeValue (" + "max=%s," + + "min=%s," + + ")", + this.max, this.min); + } + + /** + * This builder class can be used to construct a DefaultRangeValue bean. + */ + public static class Builder extends RangeValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultRangeValue newBuildingInstance() { + return new DefaultRangeValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReference.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReference.java index ceed8d70d..ad3389db0 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReference.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReference.java @@ -15,17 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.Key; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.ReferenceTypes; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ReferenceBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Reference * @@ -46,6 +45,12 @@ public class DefaultReference implements Reference { public DefaultReference() {} + public DefaultReference(Reference x) { + this.keys = x.getKeys(); + this.referredSemanticId = x.getReferredSemanticId(); + this.type = x.getType(); + } + @Override public int hashCode() { return Objects.hash(this.type, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElement.java index da64e65ec..8c3a4537c 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElement.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ReferenceElementBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ReferenceElement * @@ -66,18 +67,31 @@ public class DefaultReferenceElement implements ReferenceElement { public DefaultReferenceElement() {} + public DefaultReferenceElement(ReferenceElement x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.value = x.getValue(); + } + @Override public int hashCode() { return Objects.hash(this.value, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -92,14 +106,14 @@ public boolean equals(Object obj) { DefaultReferenceElement other = (DefaultReferenceElement) obj; return Objects.equals(this.value, other.value) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -123,36 +137,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -203,6 +187,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultReferenceElement (" + "value=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElementMetadata.java new file mode 100644 index 000000000..9d1c6e25f --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElementMetadata.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ReferenceElementMetadata + * + */ + +@IRI("aas:ReferenceElementMetadata") +public class DefaultReferenceElementMetadata implements ReferenceElementMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultReferenceElementMetadata() {} + + public DefaultReferenceElementMetadata(ReferenceElementMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultReferenceElementMetadata other = (DefaultReferenceElementMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultReferenceElementMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultReferenceElementMetadata bean. + */ + public static class Builder extends ReferenceElementMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultReferenceElementMetadata newBuildingInstance() { + return new DefaultReferenceElementMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElementValue.java new file mode 100644 index 000000000..9fcc9dad0 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceElementValue.java @@ -0,0 +1,97 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ReferenceElementValue + * + */ + +@IRI("aas:ReferenceElementValue") +public class DefaultReferenceElementValue implements ReferenceElementValue { + + @IRI("https://admin-shell.io/aas/3/0/ReferenceValue/outputArguments") + protected List outputArguments = new ArrayList<>(); + + public DefaultReferenceElementValue() {} + + public DefaultReferenceElementValue(ReferenceElementValue x) { + this.outputArguments = x.getOutputArguments(); + } + + @Override + public int hashCode() { + return Objects.hash(this.outputArguments); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultReferenceElementValue other = (DefaultReferenceElementValue) obj; + return Objects.equals(this.outputArguments, other.outputArguments); + } + } + + @Override + public List getOutputArguments() { + return outputArguments; + } + + @Override + public void setOutputArguments(List outputArguments) { + this.outputArguments = outputArguments; + } + + public String toString() { + return String.format( + "DefaultReferenceElementValue (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultReferenceElementValue bean. + */ + public static class Builder extends ReferenceElementValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultReferenceElementValue newBuildingInstance() { + return new DefaultReferenceElementValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceValue.java new file mode 100644 index 000000000..6ff25d247 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultReferenceValue.java @@ -0,0 +1,96 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ReferenceValue + * + */ + +@IRI("aas:ReferenceValue") +public class DefaultReferenceValue implements ReferenceValue { + + @IRI("https://admin-shell.io/aas/3/0/ReferenceValue/outputArguments") + protected List outputArguments = new ArrayList<>(); + + public DefaultReferenceValue() {} + + public DefaultReferenceValue(ReferenceValue x) { + this.outputArguments = x.getOutputArguments(); + } + + @Override + public int hashCode() { + return Objects.hash(this.outputArguments); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultReferenceValue other = (DefaultReferenceValue) obj; + return Objects.equals(this.outputArguments, other.outputArguments); + } + } + + @Override + public List getOutputArguments() { + return outputArguments; + } + + @Override + public void setOutputArguments(List outputArguments) { + this.outputArguments = outputArguments; + } + + public String toString() { + return String.format( + "DefaultReferenceValue (" + "outputArguments=%s," + + ")", + this.outputArguments); + } + + /** + * This builder class can be used to construct a DefaultReferenceValue bean. + */ + public static class Builder extends ReferenceValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultReferenceValue newBuildingInstance() { + return new DefaultReferenceValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElement.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElement.java index d151659c5..0a28e723b 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElement.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElement.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.RelationshipElementBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.RelationshipElement * @@ -69,19 +70,33 @@ public class DefaultRelationshipElement implements RelationshipElement { public DefaultRelationshipElement() {} + public DefaultRelationshipElement(RelationshipElement x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.first = x.getFirst(); + this.second = x.getSecond(); + } + @Override public int hashCode() { return Objects.hash(this.first, this.second, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -97,14 +112,14 @@ public boolean equals(Object obj) { return Objects.equals(this.first, other.first) && Objects.equals(this.second, other.second) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -138,36 +153,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -218,6 +203,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultRelationshipElement (" + "first=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElementMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElementMetadata.java new file mode 100644 index 000000000..e473039b5 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElementMetadata.java @@ -0,0 +1,242 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.RelationshipElementMetadata + * + */ + +@IRI("aas:RelationshipElementMetadata") +public class DefaultRelationshipElementMetadata implements RelationshipElementMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultRelationshipElementMetadata() {} + + public DefaultRelationshipElementMetadata(RelationshipElementMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultRelationshipElementMetadata other = (DefaultRelationshipElementMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultRelationshipElementMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultRelationshipElementMetadata bean. + */ + public static class Builder extends RelationshipElementMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultRelationshipElementMetadata newBuildingInstance() { + return new DefaultRelationshipElementMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElementValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElementValue.java new file mode 100644 index 000000000..e8a71cb2d --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultRelationshipElementValue.java @@ -0,0 +1,111 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.RelationshipElementValue + * + */ + +@IRI("aas:RelationshipElementValue") +public class DefaultRelationshipElementValue implements RelationshipElementValue { + + @IRI("https://admin-shell.io/aas/3/0/RelationshipElementValue/first") + protected ReferenceValue first; + + @IRI("https://admin-shell.io/aas/3/0/RelationshipElementValue/second") + protected ReferenceValue second; + + public DefaultRelationshipElementValue() {} + + public DefaultRelationshipElementValue(RelationshipElementValue x) { + this.first = x.getFirst(); + this.second = x.getSecond(); + } + + @Override + public int hashCode() { + return Objects.hash(this.first, + this.second); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultRelationshipElementValue other = (DefaultRelationshipElementValue) obj; + return Objects.equals(this.first, other.first) && + Objects.equals(this.second, other.second); + } + } + + @Override + public ReferenceValue getFirst() { + return first; + } + + @Override + public void setFirst(ReferenceValue first) { + this.first = first; + } + + @Override + public ReferenceValue getSecond() { + return second; + } + + @Override + public void setSecond(ReferenceValue second) { + this.second = second; + } + + public String toString() { + return String.format( + "DefaultRelationshipElementValue (" + "first=%s," + + "second=%s," + + ")", + this.first, this.second); + } + + /** + * This builder class can be used to construct a DefaultRelationshipElementValue bean. + */ + public static class Builder extends RelationshipElementValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultRelationshipElementValue newBuildingInstance() { + return new DefaultRelationshipElementValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultResource.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultResource.java index 068c2ad83..6b3b72075 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultResource.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultResource.java @@ -15,13 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.Resource; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ResourceBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Resource * @@ -40,6 +41,11 @@ public class DefaultResource implements Resource { public DefaultResource() {} + public DefaultResource(Resource x) { + this.contentType = x.getContentType(); + this.path = x.getPath(); + } + @Override public int hashCode() { return Objects.hash(this.path, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultResult.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultResult.java new file mode 100644 index 000000000..1aa9e40ef --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultResult.java @@ -0,0 +1,113 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Result + * + */ + +@IRI("aas:Result") +public class DefaultResult implements Result { + + @IRI("https://admin-shell.io/aas/3/0/Result/messages") + protected List messages = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Result/success") + protected boolean success; + + public DefaultResult() {} + + public DefaultResult(Result x) { + this.messages = x.getMessages(); + this.success = x.getSuccess(); + } + + @Override + public int hashCode() { + return Objects.hash(this.messages, + this.success); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultResult other = (DefaultResult) obj; + return Objects.equals(this.messages, other.messages) && + Objects.equals(this.success, other.success); + } + } + + @Override + public List getMessages() { + return messages; + } + + @Override + public void setMessages(List messages) { + this.messages = messages; + } + + @Override + public boolean getSuccess() { + return success; + } + + @Override + public void setSuccess(boolean success) { + this.success = success; + } + + public String toString() { + return String.format( + "DefaultResult (" + "messages=%s," + + "success=%s," + + ")", + this.messages, this.success); + } + + /** + * This builder class can be used to construct a DefaultResult bean. + */ + public static class Builder extends ResultBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultResult newBuildingInstance() { + return new DefaultResult(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSpecificAssetId.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSpecificAssetId.java index 53122fe0c..6971280f8 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSpecificAssetId.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSpecificAssetId.java @@ -15,16 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SpecificAssetIdBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId * @@ -51,6 +51,14 @@ public class DefaultSpecificAssetId implements SpecificAssetId { public DefaultSpecificAssetId() {} + public DefaultSpecificAssetId(SpecificAssetId x) { + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.externalSubjectId = x.getExternalSubjectId(); + this.name = x.getName(); + this.value = x.getValue(); + } + @Override public int hashCode() { return Objects.hash(this.name, diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultStringValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultStringValue.java new file mode 100644 index 000000000..723626602 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultStringValue.java @@ -0,0 +1,80 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.StringValue + * + */ + +@IRI("aas:StringValue") +public class DefaultStringValue implements StringValue { + + public DefaultStringValue() {} + + public DefaultStringValue(StringValue x) { + + } + + @Override + public int hashCode() { + return Objects.hash(super.hashCode()); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } + return true; + } + + public String toString() { + return String.format( + "DefaultStringValue (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultStringValue bean. + */ + public static class Builder extends StringValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultStringValue newBuildingInstance() { + return new DefaultStringValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodel.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodel.java index b5697a48f..7a3f16df9 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodel.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodel.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.Submodel * @@ -72,15 +73,29 @@ public class DefaultSubmodel implements Submodel { @IRI("https://admin-shell.io/aas/3/0/Submodel/submodelElements") protected List submodelElements = new ArrayList<>(); - public DefaultSubmodel() {} + public DefaultSubmodel() { + this.kind = ModellingKind.INSTANCE; + } + + public DefaultSubmodel(Submodel x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.kind = x.getKind(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.administration = x.getAdministration(); + this.id = x.getId(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.submodelElements = x.getSubmodelElements(); + } @Override public int hashCode() { return Objects.hash(this.submodelElements, - this.embeddedDataSpecifications, - this.kind, - this.semanticId, - this.supplementalSemanticIds, this.administration, this.id, this.category, @@ -88,7 +103,11 @@ public int hashCode() { this.displayName, this.description, this.extensions, - this.qualifiers); + this.embeddedDataSpecifications, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers, + this.kind); } @Override @@ -102,10 +121,6 @@ public boolean equals(Object obj) { } else { DefaultSubmodel other = (DefaultSubmodel) obj; return Objects.equals(this.submodelElements, other.submodelElements) && - Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.kind, other.kind) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && Objects.equals(this.administration, other.administration) && Objects.equals(this.id, other.id) && Objects.equals(this.category, other.category) && @@ -113,7 +128,11 @@ public boolean equals(Object obj) { Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && + Objects.equals(this.kind, other.kind); } } @@ -127,46 +146,6 @@ public void setSubmodelElements(List submodelElements) { this.submodelElements = submodelElements; } - @Override - public List getEmbeddedDataSpecifications() { - return embeddedDataSpecifications; - } - - @Override - public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { - this.embeddedDataSpecifications = embeddedDataSpecifications; - } - - @Override - public ModellingKind getKind() { - return kind; - } - - @Override - public void setKind(ModellingKind kind) { - this.kind = kind; - } - - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - @Override public AdministrativeInformation getAdministration() { return administration; @@ -237,6 +216,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + @Override public List getQualifiers() { return qualifiers; @@ -247,6 +256,16 @@ public void setQualifiers(List qualifiers) { this.qualifiers = qualifiers; } + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + public String toString() { return String.format( "DefaultSubmodel (" + "submodelElements=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java index 0c40ea39d..cda3b8b08 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java @@ -1,12 +1,12 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software distributed under the License * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express * or implied. See the License for the specific language governing permissions and limitations under @@ -19,51 +19,72 @@ import java.util.List; import java.util.Objects; -import org.eclipse.digitaltwin.aas4j.v3.model.AdministrativeInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringTextType; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringNameType; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelDescriptor; + +import org.eclipse.digitaltwin.aas4j.v3.model.*; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelDescriptorBuilder; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SubmodelDescriptor + * + */ @IRI("aas:SubmodelDescriptor") public class DefaultSubmodelDescriptor implements SubmodelDescriptor { - @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") - protected List endpoints = new ArrayList<>(); + @IRI("https://admin-shell.io/aas/3/0/Descriptor/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Descriptor/displayName") + protected List displayName = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration") + @IRI("https://admin-shell.io/aas/3/0/Descriptor/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/administration") protected AdministrativeInformation administration; - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description") - protected List description; + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/endpoints") + protected List endpoints = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName") - protected List displayName; + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/id") + protected String id; - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort") + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/idShort") protected String idShort; - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/identification") - protected String identification; - - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId") + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/semanticId") protected Reference semanticId; - public DefaultSubmodelDescriptor() { + @IRI("https://admin-shell.io/aas/3/0/SubmodelDescriptor/supplementalSemanticId") + protected List supplementalSemanticId = new ArrayList<>(); + + public DefaultSubmodelDescriptor() {} + + public DefaultSubmodelDescriptor(SubmodelDescriptor x) { + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.extensions = x.getExtensions(); + this.administration = x.getAdministration(); + this.endpoints = x.getEndpoints(); + this.id = x.getId(); + this.idShort = x.getIdShort(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticId = x.getSupplementalSemanticId(); } @Override public int hashCode() { return Objects.hash(this.administration, - this.description, - this.displayName, + this.endpoints, this.idShort, - this.identification, + this.id, this.semanticId, - this.endpoints); + this.supplementalSemanticId, + this.description, + this.displayName, + this.extensions); } @Override @@ -77,12 +98,14 @@ public boolean equals(Object obj) { } else { DefaultSubmodelDescriptor other = (DefaultSubmodelDescriptor) obj; return Objects.equals(this.administration, other.administration) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.endpoints, other.endpoints) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.identification, other.identification) && + Objects.equals(this.id, other.id) && Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.endpoints, other.endpoints); + Objects.equals(this.supplementalSemanticId, other.supplementalSemanticId) && + Objects.equals(this.description, other.description) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.extensions, other.extensions); } } @@ -97,23 +120,13 @@ public void setAdministration(AdministrativeInformation administration) { } @Override - public List getDescription() { - return description; - } - - @Override - public void setDescription(List description) { - this.description = description; - } - - @Override - public List getDisplayName() { - return displayName; + public List getEndpoints() { + return endpoints; } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setEndpoints(List endpoints) { + this.endpoints = endpoints; } @Override @@ -127,13 +140,13 @@ public void setIdShort(String idShort) { } @Override - public String getIdentification() { - return identification; + public String getId() { + return id; } @Override - public void setIdentification(String identification) { - this.identification = identification; + public void setId(String id) { + this.id = id; } @Override @@ -147,13 +160,55 @@ public void setSemanticId(Reference semanticId) { } @Override - public List getEndpoints() { - return endpoints; + public List getSupplementalSemanticId() { + return supplementalSemanticId; } @Override - public void setEndpoints(List endpoints) { - this.endpoints = endpoints; + public void setSupplementalSemanticId(List supplementalSemanticIds) { + this.supplementalSemanticId = supplementalSemanticIds; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + public String toString() { + return String.format( + "DefaultSubmodelDescriptor (" + "administration=%s," + + "endpoints=%s," + + "idShort=%s," + + "id=%s," + + "semanticId=%s," + + "supplementalSemanticId=%s," + + ")", + this.administration, this.endpoints, this.idShort, this.id, this.semanticId, this.supplementalSemanticId); } /** diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementAttributes.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementAttributes.java new file mode 100644 index 000000000..ab02c4942 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementAttributes.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementAttributes + * + */ + +@IRI("aas:SubmodelElementAttributes") +public class DefaultSubmodelElementAttributes implements SubmodelElementAttributes { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultSubmodelElementAttributes() {} + + public DefaultSubmodelElementAttributes(SubmodelElementAttributes x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultSubmodelElementAttributes other = (DefaultSubmodelElementAttributes) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultSubmodelElementAttributes (" + "kind=%s," + + ")", + this.kind); + } + + /** + * This builder class can be used to construct a DefaultSubmodelElementAttributes bean. + */ + public static class Builder extends SubmodelElementAttributesBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultSubmodelElementAttributes newBuildingInstance() { + return new DefaultSubmodelElementAttributes(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementCollection.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementCollection.java index a81775b3b..0704959be 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementCollection.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementCollection.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelElementCollectionBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package * org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementCollection @@ -67,18 +68,31 @@ public class DefaultSubmodelElementCollection implements SubmodelElementCollecti public DefaultSubmodelElementCollection() {} + public DefaultSubmodelElementCollection(SubmodelElementCollection x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.value = x.getValue(); + } + @Override public int hashCode() { return Objects.hash(this.value, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -93,14 +107,14 @@ public boolean equals(Object obj) { DefaultSubmodelElementCollection other = (DefaultSubmodelElementCollection) obj; return Objects.equals(this.value, other.value) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -124,36 +138,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -204,6 +188,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultSubmodelElementCollection (" + "value=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementCollectionMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementCollectionMetadata.java new file mode 100644 index 000000000..6a7410f34 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementCollectionMetadata.java @@ -0,0 +1,242 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementCollectionMetadata + * + */ + +@IRI("aas:SubmodelElementCollectionMetadata") +public class DefaultSubmodelElementCollectionMetadata implements SubmodelElementCollectionMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + public DefaultSubmodelElementCollectionMetadata() {} + + public DefaultSubmodelElementCollectionMetadata(SubmodelElementCollectionMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultSubmodelElementCollectionMetadata other = (DefaultSubmodelElementCollectionMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultSubmodelElementCollectionMetadata (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultSubmodelElementCollectionMetadata bean. + */ + public static class Builder extends SubmodelElementCollectionMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultSubmodelElementCollectionMetadata newBuildingInstance() { + return new DefaultSubmodelElementCollectionMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementList.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementList.java index 221b3fd75..6e366cd1f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementList.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementList.java @@ -15,15 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.*; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelElementListBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementList * @@ -75,7 +76,26 @@ public class DefaultSubmodelElementList implements SubmodelElementList { @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement") protected DataTypeDefXsd valueTypeListElement; - public DefaultSubmodelElementList() {} + public DefaultSubmodelElementList() { + this.orderRelevant = Boolean.TRUE; + } + + public DefaultSubmodelElementList(SubmodelElementList x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.orderRelevant = x.getOrderRelevant(); + this.semanticIdListElement = x.getSemanticIdListElement(); + this.typeValueListElement = x.getTypeValueListElement(); + this.value = x.getValue(); + this.valueTypeListElement = x.getValueTypeListElement(); + } @Override public int hashCode() { @@ -85,14 +105,14 @@ public int hashCode() { this.valueTypeListElement, this.value, this.embeddedDataSpecifications, - this.semanticId, - this.supplementalSemanticIds, - this.qualifiers, this.category, this.idShort, this.displayName, this.description, - this.extensions); + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); } @Override @@ -111,14 +131,14 @@ public boolean equals(Object obj) { Objects.equals(this.valueTypeListElement, other.valueTypeListElement) && Objects.equals(this.value, other.value) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && - Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && Objects.equals(this.idShort, other.idShort) && Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && - Objects.equals(this.extensions, other.extensions); + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -182,36 +202,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; - } - - @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; - } - - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; - } - @Override public String getCategory() { return category; @@ -262,6 +252,36 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + public String toString() { return String.format( "DefaultSubmodelElementList (" + "orderRelevant=%s," diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementListMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementListMetadata.java new file mode 100644 index 000000000..d3d4a7989 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementListMetadata.java @@ -0,0 +1,308 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package + * org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementListMetadata + * + */ + +@IRI("aas:SubmodelElementListMetadata") +public class DefaultSubmodelElementListMetadata implements SubmodelElementListMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementAttributes/kind") + protected ModellingKind kind; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/orderRelevant") + protected boolean orderRelevant; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/semanticIdListElement") + protected Reference semanticIdListElement; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/typeValueListElement") + protected ModelType typeValueListElement; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementListMetadata/valueTypeListElement") + protected DataTypeDefXsd valueTypeListElement; + + public DefaultSubmodelElementListMetadata() {} + + public DefaultSubmodelElementListMetadata(SubmodelElementListMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + this.orderRelevant = x.getOrderRelevant(); + this.semanticIdListElement = x.getSemanticIdListElement(); + this.typeValueListElement = x.getTypeValueListElement(); + this.valueTypeListElement = x.getValueTypeListElement(); + } + + @Override + public int hashCode() { + return Objects.hash(this.orderRelevant, + this.semanticIdListElement, + this.typeValueListElement, + this.valueTypeListElement, + this.kind, + this.embeddedDataSpecifications, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultSubmodelElementListMetadata other = (DefaultSubmodelElementListMetadata) obj; + return Objects.equals(this.orderRelevant, other.orderRelevant) && + Objects.equals(this.semanticIdListElement, other.semanticIdListElement) && + Objects.equals(this.typeValueListElement, other.typeValueListElement) && + Objects.equals(this.valueTypeListElement, other.valueTypeListElement) && + Objects.equals(this.kind, other.kind) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public boolean getOrderRelevant() { + return orderRelevant; + } + + @Override + public void setOrderRelevant(boolean orderRelevant) { + this.orderRelevant = orderRelevant; + } + + @Override + public Reference getSemanticIdListElement() { + return semanticIdListElement; + } + + @Override + public void setSemanticIdListElement(Reference semanticIdListElement) { + this.semanticIdListElement = semanticIdListElement; + } + + @Override + public ModelType getTypeValueListElement() { + return typeValueListElement; + } + + @Override + public void setTypeValueListElement(ModelType typeValueListElement) { + this.typeValueListElement = typeValueListElement; + } + + @Override + public DataTypeDefXsd getValueTypeListElement() { + return valueTypeListElement; + } + + @Override + public void setValueTypeListElement(DataTypeDefXsd valueTypeListElement) { + this.valueTypeListElement = valueTypeListElement; + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultSubmodelElementListMetadata (" + "orderRelevant=%s," + + "semanticIdListElement=%s," + + "typeValueListElement=%s," + + "valueTypeListElement=%s," + + ")", + this.orderRelevant, this.semanticIdListElement, this.typeValueListElement, this.valueTypeListElement); + } + + /** + * This builder class can be used to construct a DefaultSubmodelElementListMetadata bean. + */ + public static class Builder extends SubmodelElementListMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultSubmodelElementListMetadata newBuildingInstance() { + return new DefaultSubmodelElementListMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementListValue.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementListValue.java new file mode 100644 index 000000000..0094104b5 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelElementListValue.java @@ -0,0 +1,80 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementListValue + * + */ + +@IRI("aas:SubmodelElementListValue") +public class DefaultSubmodelElementListValue implements SubmodelElementListValue { + + public DefaultSubmodelElementListValue() {} + + public DefaultSubmodelElementListValue(SubmodelElementListValue x) { + + } + + @Override + public int hashCode() { + return Objects.hash(super.hashCode()); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } + return true; + } + + public String toString() { + return String.format( + "DefaultSubmodelElementListValue (" + + ")" + + ); + } + + /** + * This builder class can be used to construct a DefaultSubmodelElementListValue bean. + */ + public static class Builder extends SubmodelElementListValueBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultSubmodelElementListValue newBuildingInstance() { + return new DefaultSubmodelElementListValue(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelMetadata.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelMetadata.java new file mode 100644 index 000000000..87b328ab7 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelMetadata.java @@ -0,0 +1,272 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023, SAP SE or an SAP affiliate company + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except + * in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ + +package org.eclipse.digitaltwin.aas4j.v3.model.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; + + +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + +/** + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SubmodelMetadata + * + */ + +@IRI("aas:SubmodelMetadata") +public class DefaultSubmodelMetadata implements SubmodelMetadata { + + @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") + protected List embeddedDataSpecifications = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasExtensions/extensions") + protected List extensions = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + protected Reference semanticId; + + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") + protected List supplementalSemanticIds = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Identifiable/administration") + protected AdministrativeInformation administration; + + @IRI("https://admin-shell.io/aas/3/0/Identifiable/id") + protected String id; + + @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") + protected List qualifiers = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/category") + protected String category; + + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + protected List description = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/displayName") + protected List displayName = new ArrayList<>(); + + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/SubmodelMetadata/kind") + protected ModellingKind kind; + + public DefaultSubmodelMetadata() {} + + public DefaultSubmodelMetadata(SubmodelMetadata x) { + this.embeddedDataSpecifications = x.getEmbeddedDataSpecifications(); + this.extensions = x.getExtensions(); + this.semanticId = x.getSemanticId(); + this.supplementalSemanticIds = x.getSupplementalSemanticIds(); + this.administration = x.getAdministration(); + this.id = x.getId(); + this.qualifiers = x.getQualifiers(); + this.category = x.getCategory(); + this.description = x.getDescription(); + this.displayName = x.getDisplayName(); + this.idShort = x.getIdShort(); + this.kind = x.getKind(); + } + + @Override + public int hashCode() { + return Objects.hash(this.kind, + this.administration, + this.id, + this.category, + this.idShort, + this.displayName, + this.description, + this.extensions, + this.embeddedDataSpecifications, + this.semanticId, + this.supplementalSemanticIds, + this.qualifiers); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } else if (obj == null) { + return false; + } else if (this.getClass() != obj.getClass()) { + return false; + } else { + DefaultSubmodelMetadata other = (DefaultSubmodelMetadata) obj; + return Objects.equals(this.kind, other.kind) && + Objects.equals(this.administration, other.administration) && + Objects.equals(this.id, other.id) && + Objects.equals(this.category, other.category) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers); + } + } + + @Override + public ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + + @Override + public AdministrativeInformation getAdministration() { + return administration; + } + + @Override + public void setAdministration(AdministrativeInformation administration) { + this.administration = administration; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public String getCategory() { + return category; + } + + @Override + public void setCategory(String category) { + this.category = category; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayNames) { + this.displayName = displayNames; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List descriptions) { + this.description = descriptions; + } + + @Override + public List getExtensions() { + return extensions; + } + + @Override + public void setExtensions(List extensions) { + this.extensions = extensions; + } + + @Override + public List getEmbeddedDataSpecifications() { + return embeddedDataSpecifications; + } + + @Override + public void setEmbeddedDataSpecifications(List embeddedDataSpecifications) { + this.embeddedDataSpecifications = embeddedDataSpecifications; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; + } + + @Override + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; + } + + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; + } + + public String toString() { + return String.format( + "DefaultSubmodelMetadata (" + "kind=%s," + + ")", + this.kind); + } + + /** + * This builder class can be used to construct a DefaultSubmodelMetadata bean. + */ + public static class Builder extends SubmodelMetadataBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultSubmodelMetadata newBuildingInstance() { + return new DefaultSubmodelMetadata(); + } + } +} diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueList.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueList.java index 95df776d9..b955fec98 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueList.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueList.java @@ -15,16 +15,16 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.ValueList; -import org.eclipse.digitaltwin.aas4j.v3.model.ValueReferencePair; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ValueListBuilder; - import java.util.ArrayList; import java.util.List; import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ValueList * @@ -39,6 +39,10 @@ public class DefaultValueList implements ValueList { public DefaultValueList() {} + public DefaultValueList(ValueList x) { + this.valueReferencePairs = x.getValueReferencePairs(); + } + @Override public int hashCode() { return Objects.hash(this.valueReferencePairs); diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueReferencePair.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueReferencePair.java index 752281744..a41506105 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueReferencePair.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultValueReferencePair.java @@ -15,14 +15,14 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.Reference; -import org.eclipse.digitaltwin.aas4j.v3.model.ValueReferencePair; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ValueReferencePairBuilder; - import java.util.Objects; +import org.eclipse.digitaltwin.aas4j.v3.model.*; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.*; + + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.ValueReferencePair * @@ -41,6 +41,11 @@ public class DefaultValueReferencePair implements ValueReferencePair { public DefaultValueReferencePair() {} + public DefaultValueReferencePair(ValueReferencePair x) { + this.value = x.getValue(); + this.valueId = x.getValueId(); + } + @Override public int hashCode() { return Objects.hash(this.value,