From 75f6000380b0e008a1be8a235f333e905783d5ee Mon Sep 17 00:00:00 2001 From: Sebastian Bader Date: Mon, 28 Aug 2023 18:22:55 +0200 Subject: [PATCH 01/18] cherry pick the assetinformation serialiser --- .../v3/dataformat/json/JsonDeserializer.java | 21 +++- .../v3/dataformat/json/JsonSerializer.java | 19 +++ .../dataformat/json/ObjectMapperFactory.java | 113 ++++++++++++++++++ .../dataformat/json/JsonDeserializerTest.java | 18 +++ .../dataformat/json/JsonSerializerTest.java | 83 ++++++++++++- pom.xml | 2 +- 6 files changed, 251 insertions(+), 5 deletions(-) create mode 100644 dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java index 6b35c1454..03fdc9ca9 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java @@ -1,5 +1,6 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2022 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. @@ -26,6 +27,7 @@ import java.util.List; import java.util.stream.Collectors; +import com.fasterxml.jackson.databind.module.SimpleModule; import org.eclipse.digitaltwin.aas4j.v3.dataformat.DeserializationException; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.deserialization.EnumDeserializer; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.util.ReflectionHelper; @@ -38,8 +40,12 @@ import com.fasterxml.jackson.databind.DeserializationFeature; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.json.JsonMapper; +//import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.module.SimpleAbstractTypeResolver; -import com.fasterxml.jackson.databind.module.SimpleModule; + +import static org.eclipse.digitaltwin.aas4j.v3.dataformat.json.ObjectMapperFactory.createMapper; +//import static org.eclipse.digitaltwin.aas4j.v3.dataformat.json.ObjectMapperFactory.createTypeResolver; + /** * Class for deserializing/parsing AAS JSON documents. @@ -47,6 +53,7 @@ public class JsonDeserializer { protected JsonMapper mapper; +// protected ObjectMapper mapper; protected SimpleAbstractTypeResolver typeResolver; private static final Charset DEFAULT_CHARSET = StandardCharsets.UTF_8; @@ -54,6 +61,8 @@ public class JsonDeserializer { public JsonDeserializer() { initTypeResolver(); buildMapper(); +// typeResolver = createTypeResolver(); +// mapper = createMapper(typeResolver); } protected void buildMapper() { @@ -183,7 +192,7 @@ public Environment read(java.io.File file) throws FileNotFoundException, Deseria */ public void useImplementation(Class aasInterface, Class implementation) { typeResolver.addMapping(aasInterface, implementation); - buildMapper(); + mapper = createMapper(typeResolver); } /** @@ -374,4 +383,12 @@ public List readReferables(File src, Class outputCla public List readReferables(File src, Charset charset, Class outputClass) throws DeserializationException, FileNotFoundException { return readReferables(new FileInputStream(src), charset, outputClass); } + + public T read(String json, Class clazz) throws DeserializationException { + try { + return mapper.readValue(json, clazz); + } catch (JsonProcessingException ex) { + throw new DeserializationException("Error by deserializing the json string:\n" + json, ex); + } + } } diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java index 750d83c8e..84bb9b21a 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java @@ -1,5 +1,6 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2022 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. @@ -41,11 +42,18 @@ import java.io.OutputStreamWriter; import java.util.Objects; +//import com.fasterxml.jackson.core.JsonProcessingException; +//import com.fasterxml.jackson.databind.ObjectMapper; +//import com.fasterxml.jackson.databind.ObjectWriter; +// +//import java.util.List; + /** * Class for serializing an instance of AssetAdministrationShellEnvironment or Referables to JSON. */ public class JsonSerializer { +// protected final ObjectMapper mapper; protected JsonMapper mapper; private static final Charset DEFAULT_CHARSET = StandardCharsets.UTF_8; @@ -214,4 +222,15 @@ public JsonNode toNode(Collection referables) { } return mapper.valueToTree(referables); } + + public String write(Object aas_element) throws SerializationException { + try { + // the new schema (version 3.0.RC02) defines modelType as a string, therefore the ModelTypeProcessor is not needed anymore + //return mapper.writeValueAsString(ModelTypeProcessor.postprocess(this.mapper.readTree(json))); + return mapper.writeValueAsString(aas_element); + } catch (JsonProcessingException ex) { + throw new SerializationException("Error serializing an aas-element", ex); + } + } + } diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java new file mode 100644 index 000000000..4e80cdca9 --- /dev/null +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java @@ -0,0 +1,113 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2022 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.dataformat.json; + +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.databind.DeserializationFeature; +import com.fasterxml.jackson.databind.ObjectMapper; +import com.fasterxml.jackson.databind.SerializationFeature; +import com.fasterxml.jackson.databind.json.JsonMapper; +import com.fasterxml.jackson.databind.module.SimpleAbstractTypeResolver; +import com.fasterxml.jackson.databind.module.SimpleModule; +//import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.ReflectionHelper; +import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.deserialization.EnumDeserializer; +import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.serialization.EnumSerializer; + +/** + * This class contains the initialization code used by the JsonSerializer and JsonDeserializer. It also contains a + * factory method, that is very useful to be used in SpringBoot environment, to automate the serialization. Here is a + * sample code: + *
+ * {@code @Configuration}
+ * public class JacksonConfig {
+ *     {@code @Bean}
+ *     {@code @Primary}
+ *     public ObjectMapper objectMapper() {
+ *         return ObjectMapperFactory.createMapper();
+ *     }
+ *  
+ * Having such JacksonConfig class in your SpringBoot web application, the framework will always use the created mapper + * for serialization and deserialization, and you don't need to carry about it anymore. + */ +public class ObjectMapperFactory { + private ObjectMapperFactory() {} + + /** + * The factory method to create the object mapper for serialization/deserialization of AAS objects. + * @return the configured object mapper. According to the Jackson documentation the ObjectMapper class is + * thread-safe. + * + * The returned object mapper can be used directly for AAS serialization/deserialization, or you can use the utility + * JsonSerializer and JsonDeserializer wrapper classes. + */ + public static ObjectMapper createMapper() { + return createMapper(null); + } + + /** + * A package-private method used by JsonDeserializer wrapper class. It is needed only to support its + * useImplementation method, which require modification of the type resolver. + * @param typeResolver The type resolver used for deserialization. + * @return the configured object mapper. According to the Jackson documentation the ObjectMapper class is + * thread-safe. + */ + static JsonMapper createMapper(SimpleAbstractTypeResolver typeResolver) { + JsonMapper mapper = JsonMapper.builder() + .enable(SerializationFeature.INDENT_OUTPUT) + .enable(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY) + .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES) + .serializationInclusion(JsonInclude.Include.NON_NULL) + .serializationInclusion(JsonInclude.Include.NON_EMPTY) +// .annotationIntrospector(new ReflectionAnnotationIntrospector()) + .addModule(buildEnumModule()) + .addModule(buildTypeResolverModule(typeResolver)) + .build(); +// ReflectionHelper.JSON_MIXINS.entrySet().forEach(x -> mapper.addMixIn(x.getKey(), x.getValue())); + return mapper; + } + + /** + * A package-private method, to create a type resolver, which is used for serialization/deserialization of AAS + * object. + * @return the type resolver. + */ + static SimpleAbstractTypeResolver createTypeResolver() { + SimpleAbstractTypeResolver typeResolver = new SimpleAbstractTypeResolver(); +// ReflectionHelper.DEFAULT_IMPLEMENTATIONS +// .stream() +// .forEach(x -> typeResolver.addMapping(x.getInterfaceType(), x.getImplementationType())); + return typeResolver; + } + + private static SimpleModule buildTypeResolverModule(SimpleAbstractTypeResolver typeResolver) { + final SimpleModule module = new SimpleModule(); + if(typeResolver == null) { + typeResolver = createTypeResolver(); + } + module.setAbstractTypes(typeResolver); + return module; + } + + private static SimpleModule buildEnumModule() { + SimpleModule module = new SimpleModule(); +// ReflectionHelper.ENUMS.forEach(x -> { +// module.addDeserializer(x, new EnumDeserializer<>(x)); +// module.addSerializer(x, new EnumSerializer()); +// }); + return module; + } +} diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java index 6fe6d1140..1cc0b22b8 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java @@ -1,5 +1,6 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2022 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. @@ -19,6 +20,7 @@ import com.fasterxml.jackson.databind.ObjectMapper; import static org.junit.Assert.assertEquals; +import com.fasterxml.jackson.databind.ObjectMapper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.AASSimple; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.CustomProperty; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.CustomSubmodel; @@ -46,6 +48,14 @@ public void testSimpleExample() throws Exception { Assert.assertEquals(expected, actual); } + @Test + public void testSimpleExampleDirectly() throws Exception { + ObjectMapper mapper = ObjectMapperFactory.createMapper(); + Environment expected = Examples.EXAMPLE_SIMPLE.getModel(); + Environment actual = mapper.readValue(Examples.EXAMPLE_SIMPLE.fileContentStream(), Environment.class); + Assert.assertEquals(expected, actual); + } + @Test public void testFullExample() throws Exception { Environment expected = Examples.EXAMPLE_FULL.getModel(); @@ -61,6 +71,14 @@ public void testFullExampleFromNode() throws Exception { Assert.assertEquals(expected, actual); } + @Test + public void testFullExampleDirectly() throws Exception { + ObjectMapper mapper = ObjectMapperFactory.createMapper(); + Environment expected = Examples.EXAMPLE_FULL.getModel(); + Environment actual = mapper.readValue(Examples.EXAMPLE_FULL.fileContentStream(), Environment.class); + Assert.assertEquals(expected, actual); + } + @Test public void testCustomImplementationClass() throws Exception { String json = new JsonSerializer().write(AASSimple.createEnvironment()); diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java index 7b51487f1..8a07eb1ea 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java @@ -1,5 +1,6 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2022 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. @@ -16,6 +17,7 @@ package org.eclipse.digitaltwin.aas4j.v3.dataformat.json; import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertTrue; import java.io.File; @@ -24,12 +26,17 @@ import java.util.List; import java.util.Set; +import com.fasterxml.jackson.databind.ObjectMapper; +import org.eclipse.digitaltwin.aas4j.v3.dataformat.DeserializationException; import org.eclipse.digitaltwin.aas4j.v3.dataformat.SerializationException; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.AASSimple; import org.eclipse.digitaltwin.aas4j.v3.dataformat.json.util.ExampleData; import org.eclipse.digitaltwin.aas4j.v3.dataformat.json.util.Examples; +import org.eclipse.digitaltwin.aas4j.v3.model.AssetInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Referable; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAssetInformation; import org.json.JSONException; import org.junit.Rule; import org.junit.Test; @@ -51,12 +58,19 @@ public class JsonSerializerTest { public TemporaryFolder tempFolder = new TemporaryFolder(); @Test - public void testSerializeNull() throws JsonProcessingException, IOException, SerializationException { + public void testSerializeNull() throws SerializationException { assertEquals("null", new JsonSerializer().write((Environment) null)); } @Test - public void testWriteToFile() throws JsonProcessingException, IOException, SerializationException { + public void testDirectSerializeNull() throws JsonProcessingException { + ObjectMapper mapper = ObjectMapperFactory.createMapper(); + String json = mapper.writeValueAsString((Environment)null); + assertEquals("null", json); + } + + @Test + public void testWriteToFile() throws IOException, SerializationException { File file = tempFolder.newFile("output.json"); new JsonSerializer().write(file, AASSimple.createEnvironment()); assertTrue(file.exists()); @@ -67,11 +81,20 @@ public void testSerializeEmpty() throws JsonProcessingException, IOException, Se validateAndCompare(Examples.ENVIRONMENT_EMPTY); } + @Test + public void testSerializeDirectEmpty() throws IOException, JSONException { + validateAndCompareDirectly(Examples.ENVIRONMENT_EMPTY); + } + @Test public void testSerializeSimpleExample() throws SerializationException, JSONException, IOException { validateAndCompare(Examples.EXAMPLE_SIMPLE); } + public void testSerializeDirectlySimpleExample() throws SerializationException, JSONException, IOException { + validateAndCompareDirectly(Examples.EXAMPLE_SIMPLE); + } + @Test public void testSerializeFullExample() throws SerializationException, JSONException, IOException { validateAndCompare(Examples.EXAMPLE_FULL); @@ -92,6 +115,53 @@ public void testSerializeEmptyReferableList() throws SerializationException { assertEquals("[]", serialized); } +// @Test +// public void testSerializeEmptyReferableList() throws SerializationException, JSONException { +// List emptyList = Collections.emptyList(); +// String serialized = new JsonSerializer().write(emptyList); +// JSONAssert.assertEquals("[]", serialized, JSONCompareMode.NON_EXTENSIBLE); +// } + + @Test + public void testSerializeDirectlyFullExample() throws SerializationException, JSONException, IOException { + validateAndCompareDirectly(Examples.EXAMPLE_FULL); + } + + @Test + public void testSerializeAssetInfo() throws SerializationException, DeserializationException { + AssetInformation assetInfo = new DefaultAssetInformation.Builder() + .assetKind(AssetKind.INSTANCE) + .assetType("asset-type") + .globalAssetID("global-asset-id").build(); + String jsonString = new JsonSerializer().write(assetInfo); + assertNotNull(jsonString); + AssetInformation assetInfo2 = new JsonDeserializer().read(jsonString, AssetInformation.class); + assertNotNull(assetInfo2); + assertEquals(assetInfo, assetInfo2); + } + + @Test + public void testDirectlySerializeAssetInfo() throws JsonProcessingException { + AssetInformation assetInfo = new DefaultAssetInformation.Builder() + .assetKind(AssetKind.INSTANCE) + .assetType("asset-type") + .globalAssetID("global-asset-id").build(); + ObjectMapper mapper = ObjectMapperFactory.createMapper(); + String jsonString = mapper.writeValueAsString(assetInfo); + assertNotNull(jsonString); + AssetInformation assetInfo2 = mapper.readValue(jsonString, AssetInformation.class); + assertNotNull(assetInfo2); + assertEquals(assetInfo, assetInfo2); + } + + @Test + public void testDirectlySerializeEmptyReferableList() throws JsonProcessingException, JSONException { + List emptyList = Collections.emptyList(); + ObjectMapper mapper = ObjectMapperFactory.createMapper(); + String serialized = mapper.writeValueAsString(emptyList); + JSONAssert.assertEquals("[]", serialized, JSONCompareMode.NON_EXTENSIBLE); + } + private void validateAndCompare(ExampleData exampleData) throws IOException, SerializationException, JSONException { String expected = exampleData.fileContent(); String actual = new JsonSerializer().write(exampleData.getModel()); @@ -106,4 +176,13 @@ private void validateAndCompare(String expected, String actual) throws IOExcepti JSONAssert.assertEquals(actual, expected, JSONCompareMode.NON_EXTENSIBLE); } + private void validateAndCompareDirectly(ExampleData exampleData) throws IOException, JSONException { + String expected = exampleData.fileContent(); + ObjectMapper mapper = ObjectMapperFactory.createMapper(); + String actual = mapper.writeValueAsString(exampleData.getModel()); + Set errors = new JsonSchemaValidator().validateSchema(actual); + assertTrue(errors.isEmpty()); + JSONAssert.assertEquals(expected, actual, JSONCompareMode.NON_EXTENSIBLE); + JSONAssert.assertEquals(actual, expected, JSONCompareMode.NON_EXTENSIBLE); + } } diff --git a/pom.xml b/pom.xml index f94cb34f8..31b994143 100644 --- a/pom.xml +++ b/pom.xml @@ -42,7 +42,7 @@ 0 -SNAPSHOT ${revision.major}.${revision.minor}.${revision.patch}${revision.suffix} - 1.0.0-SNAPSHOT + 1.0.1-SNAPSHOT UTF-8 UTF-8 From fba7d7f1127a5f280e1eb23e3f51b47b93a9f5da Mon Sep 17 00:00:00 2001 From: Sebastian Bader Date: Mon, 28 Aug 2023 18:23:19 +0200 Subject: [PATCH 02/18] fix: correct wrong model version --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 31b994143..f94cb34f8 100644 --- a/pom.xml +++ b/pom.xml @@ -42,7 +42,7 @@ 0 -SNAPSHOT ${revision.major}.${revision.minor}.${revision.patch}${revision.suffix} - 1.0.1-SNAPSHOT + 1.0.0-SNAPSHOT UTF-8 UTF-8 From 13a3327f38f9e9d7c050cec3567a47a44ef91d31 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Tue, 29 Aug 2023 10:27:55 +0200 Subject: [PATCH 03/18] Update the model --- .../aas4j/v3/model/AASSubmodelElements.java | 39 ++-- .../aas4j/v3/model/AbstractLangString.java | 3 +- .../v3/model/AdministrativeInformation.java | 55 ++--- .../model/AnnotatedRelationshipElement.java | 1 + .../v3/model/AssetAdministrationShell.java | 37 +-- .../AssetAdministrationShellDescriptor.java | 186 +++++++++++++++ .../aas4j/v3/model/AssetInformation.java | 81 +++---- .../digitaltwin/aas4j/v3/model/AssetKind.java | 1 + .../aas4j/v3/model/BasicEventElement.java | 119 +++++----- .../digitaltwin/aas4j/v3/model/Blob.java | 37 +-- .../aas4j/v3/model/Capability.java | 1 + .../aas4j/v3/model/ConceptDescription.java | 5 +- .../aas4j/v3/model/DataElement.java | 1 + .../v3/model/DataSpecificationContent.java | 1 + .../v3/model/DataSpecificationIec61360.java | 193 ++++++++-------- .../aas4j/v3/model/DataTypeDefXSD.java | 65 +++--- .../aas4j/v3/model/DataTypeIec61360.java | 41 ++-- .../aas4j/v3/model/Descriptor.java | 49 ++++ .../digitaltwin/aas4j/v3/model/Direction.java | 1 + .../v3/model/EmbeddedDataSpecification.java | 1 + .../digitaltwin/aas4j/v3/model/Endpoint.java | 61 +++++ .../digitaltwin/aas4j/v3/model/Entity.java | 63 ++--- .../aas4j/v3/model/EntityType.java | 1 + .../aas4j/v3/model/Environment.java | 37 +-- .../aas4j/v3/model/EventElement.java | 1 + .../aas4j/v3/model/EventPayload.java | 131 +++++------ .../digitaltwin/aas4j/v3/model/Extension.java | 37 +-- .../digitaltwin/aas4j/v3/model/File.java | 37 +-- .../aas4j/v3/model/HasDataSpecification.java | 3 +- .../aas4j/v3/model/HasExtensions.java | 1 + .../digitaltwin/aas4j/v3/model/HasKind.java | 1 + .../aas4j/v3/model/HasSemantics.java | 17 +- .../aas4j/v3/model/Identifiable.java | 1 + .../digitaltwin/aas4j/v3/model/Key.java | 1 + .../digitaltwin/aas4j/v3/model/KeyTypes.java | 1 + .../aas4j/v3/model/LangString.java | 93 ++++++++ .../LangStringDefinitionTypeIec61360.java | 1 + .../aas4j/v3/model/LangStringNameType.java | 1 + .../LangStringPreferredNameTypeIec61360.java | 1 + .../LangStringShortNameTypeIec61360.java | 1 + .../aas4j/v3/model/LangStringTextType.java | 1 + .../digitaltwin/aas4j/v3/model/LevelType.java | 39 ++-- .../aas4j/v3/model/ModellingKind.java | 1 + .../aas4j/v3/model/MultiLanguageProperty.java | 19 +- .../digitaltwin/aas4j/v3/model/Operation.java | 39 ++-- .../aas4j/v3/model/OperationVariable.java | 1 + .../digitaltwin/aas4j/v3/model/Property.java | 53 ++--- .../aas4j/v3/model/ProtocolInformation.java | 135 +++++++++++ .../aas4j/v3/model/Qualifiable.java | 1 + .../digitaltwin/aas4j/v3/model/Qualifier.java | 53 ++--- .../aas4j/v3/model/QualifierKind.java | 3 +- .../digitaltwin/aas4j/v3/model/Range.java | 37 +-- .../digitaltwin/aas4j/v3/model/Referable.java | 49 ++-- .../digitaltwin/aas4j/v3/model/Reference.java | 55 ++--- .../aas4j/v3/model/ReferenceElement.java | 1 + .../aas4j/v3/model/ReferenceTypes.java | 1 + .../aas4j/v3/model/RelationshipElement.java | 1 + .../digitaltwin/aas4j/v3/model/Resource.java | 37 +-- .../aas4j/v3/model/SpecificAssetID.java | 57 ++--- .../aas4j/v3/model/StateOfEvent.java | 1 + .../digitaltwin/aas4j/v3/model/Submodel.java | 3 +- .../aas4j/v3/model/SubmodelDescriptor.java | 133 +++++++++++ .../aas4j/v3/model/SubmodelElement.java | 7 +- .../v3/model/SubmodelElementCollection.java | 11 +- .../aas4j/v3/model/SubmodelElementList.java | 57 ++--- .../digitaltwin/aas4j/v3/model/ValueList.java | 1 + .../aas4j/v3/model/ValueReferencePair.java | 19 +- .../aas4j/v3/model/annotations/IRI.java | 1 + .../v3/model/annotations/KnownSubtypes.java | 1 + .../v3/model/builder/AbstractBuilder.java | 1 + .../AdministrativeInformationBuilder.java | 31 +-- .../AnnotatedRelationshipElementBuilder.java | 101 ++++---- .../AssetAdministrationShellBuilder.java | 69 +++--- ...tAdministrationShellDescriptorBuilder.java | 145 ++++++++++++ .../builder/AssetInformationBuilder.java | 53 ++--- .../builder/BasicEventElementBuilder.java | 163 ++++++------- .../aas4j/v3/model/builder/BlobBuilder.java | 121 +++++----- .../aas4j/v3/model/builder/Builder.java | 1 + .../v3/model/builder/CapabilityBuilder.java | 101 ++++---- .../builder/ConceptDescriptionBuilder.java | 55 ++--- .../DataSpecificationIec61360Builder.java | 131 +++++------ .../v3/model/builder/DescriptorBuilder.java | 46 ++++ .../EmbeddedDataSpecificationBuilder.java | 1 + .../v3/model/builder/EndpointBuilder.java | 46 ++++ .../aas4j/v3/model/builder/EntityBuilder.java | 159 ++++++------- .../v3/model/builder/EnvironmentBuilder.java | 41 ++-- .../v3/model/builder/EventPayloadBuilder.java | 71 +++--- .../v3/model/builder/ExtendableBuilder.java | 1 + .../v3/model/builder/ExtensionBuilder.java | 53 ++--- .../aas4j/v3/model/builder/FileBuilder.java | 121 +++++----- .../aas4j/v3/model/builder/KeyBuilder.java | 1 + ...ngStringDefinitionTypeIec61360Builder.java | 1 + .../builder/LangStringNameTypeBuilder.java | 1 + ...tringPreferredNameTypeIec61360Builder.java | 1 + ...angStringShortNameTypeIec61360Builder.java | 1 + .../builder/LangStringTextTypeBuilder.java | 1 + .../v3/model/builder/LevelTypeBuilder.java | 23 +- .../builder/MultiLanguagePropertyBuilder.java | 117 +++++----- .../v3/model/builder/OperationBuilder.java | 145 ++++++------ .../builder/OperationVariableBuilder.java | 1 + .../v3/model/builder/PropertyBuilder.java | 131 +++++------ .../builder/ProtocolInformationBuilder.java | 88 +++++++ .../v3/model/builder/QualifierBuilder.java | 43 ++-- .../aas4j/v3/model/builder/RangeBuilder.java | 121 +++++----- .../v3/model/builder/ReferenceBuilder.java | 41 ++-- .../builder/ReferenceElementBuilder.java | 101 ++++---- .../builder/RelationshipElementBuilder.java | 101 ++++---- .../v3/model/builder/ResourceBuilder.java | 21 +- .../model/builder/SpecificAssetIDBuilder.java | 41 ++-- .../v3/model/builder/SubmodelBuilder.java | 131 +++++------ .../builder/SubmodelDescriptorBuilder.java | 117 ++++++++++ .../SubmodelElementCollectionBuilder.java | 110 ++++----- .../builder/SubmodelElementListBuilder.java | 141 ++++++------ .../v3/model/builder/ValueListBuilder.java | 1 + .../builder/ValueReferencePairBuilder.java | 11 +- .../DefaultAdministrativeInformation.java | 55 +++-- .../DefaultAnnotatedRelationshipElement.java | 80 ++++--- .../impl/DefaultAssetAdministrationShell.java | 80 +++---- ...ultAssetAdministrationShellDescriptor.java | 216 ++++++++++++++++++ .../model/impl/DefaultAssetInformation.java | 68 +++--- .../model/impl/DefaultBasicEventElement.java | 164 +++++++------ .../aas4j/v3/model/impl/DefaultBlob.java | 105 +++++---- .../v3/model/impl/DefaultCapability.java | 79 ++++--- .../model/impl/DefaultConceptDescription.java | 44 ++-- .../DefaultDataSpecificationIec61360.java | 172 +++++++------- .../v3/model/impl/DefaultDescriptor.java | 80 +++++++ .../DefaultEmbeddedDataSpecification.java | 13 +- .../aas4j/v3/model/impl/DefaultEndpoint.java | 93 ++++++++ .../aas4j/v3/model/impl/DefaultEntity.java | 133 ++++++----- .../v3/model/impl/DefaultEnvironment.java | 38 +-- .../v3/model/impl/DefaultEventPayload.java | 116 +++++----- .../aas4j/v3/model/impl/DefaultExtension.java | 59 +++-- .../aas4j/v3/model/impl/DefaultFile.java | 105 +++++---- .../aas4j/v3/model/impl/DefaultKey.java | 13 +- ...faultLangStringDefinitionTypeIec61360.java | 17 +- .../model/impl/DefaultLangStringNameType.java | 13 +- ...ltLangStringPreferredNameTypeIec61360.java | 17 +- ...efaultLangStringShortNameTypeIec61360.java | 17 +- .../model/impl/DefaultLangStringTextType.java | 13 +- .../aas4j/v3/model/impl/DefaultLevelType.java | 47 ++-- .../impl/DefaultMultiLanguageProperty.java | 101 ++++---- .../aas4j/v3/model/impl/DefaultOperation.java | 110 ++++----- .../model/impl/DefaultOperationVariable.java | 8 + .../aas4j/v3/model/impl/DefaultProperty.java | 124 +++++----- .../impl/DefaultProtocolInformation.java | 152 ++++++++++++ .../aas4j/v3/model/impl/DefaultQualifier.java | 72 +++--- .../aas4j/v3/model/impl/DefaultRange.java | 108 +++++---- .../aas4j/v3/model/impl/DefaultReference.java | 54 +++-- .../model/impl/DefaultReferenceElement.java | 80 ++++--- .../impl/DefaultRelationshipElement.java | 81 ++++--- .../aas4j/v3/model/impl/DefaultResource.java | 37 +-- .../v3/model/impl/DefaultSpecificAssetID.java | 86 +++---- .../aas4j/v3/model/impl/DefaultSubmodel.java | 116 +++++----- .../model/impl/DefaultSubmodelDescriptor.java | 174 ++++++++++++++ .../DefaultSubmodelElementCollection.java | 89 ++++---- .../impl/DefaultSubmodelElementList.java | 128 ++++++----- .../aas4j/v3/model/impl/DefaultValueList.java | 8 + .../model/impl/DefaultValueReferencePair.java | 29 ++- 158 files changed, 5423 insertions(+), 3197 deletions(-) create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangString.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java create mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java 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 23009d63b..311f54a79 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,92 +23,92 @@ /** * Enumeration of all possible elements of a 'SubmodelElementList'. */ -@IRI("aas:AASSubmodelElements") -public enum AASSubmodelElements { +@IRI("aas:AasSubmodelElements") +public enum AasSubmodelElements { /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/AnnotatedRelationshipElement") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/AnnotatedRelationshipElement") ANNOTATED_RELATIONSHIP_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/BasicEventElement") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/BasicEventElement") BASIC_EVENT_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Blob") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Blob") BLOB, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Capability") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Capability") CAPABILITY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/DataElement") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/DataElement") DATA_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Entity") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Entity") ENTITY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/EventElement") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/EventElement") EVENT_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/File") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/File") FILE, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/MultiLanguageProperty") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/MultiLanguageProperty") MULTI_LANGUAGE_PROPERTY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Operation") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Operation") OPERATION, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Property") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Property") PROPERTY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Range") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Range") RANGE, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/ReferenceElement") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/ReferenceElement") REFERENCE_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/RelationshipElement") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/RelationshipElement") RELATIONSHIP_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/SubmodelElement") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/SubmodelElement") SUBMODEL_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/SubmodelElementCollection") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/SubmodelElementCollection") SUBMODEL_ELEMENT_COLLECTION, /** */ - @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/SubmodelElementList") + @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/SubmodelElementList") SUBMODEL_ELEMENT_LIST; } 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 c50f75ab4..7689f9526 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 @@ -1,5 +1,6 @@ /* * 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 @@ -24,9 +25,9 @@ * Strings with language tags */ @KnownSubtypes({ - @KnownSubtypes.Type(value = LangStringDefinitionTypeIec61360.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) }) 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 e5c3ff60f..25e8457fd 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 @@ -1,5 +1,6 @@ /* * 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 @@ -29,23 +30,23 @@ public interface AdministrativeInformation extends HasDataSpecification { /** - * The subject ID of the subject responsible for making the element. + * Version of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version * - * @return Returns the Reference for the property creator. + * @return Returns the String for the property version. */ - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/creator") - Reference getCreator(); + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/version") + String getVersion(); /** - * The subject ID of the subject responsible for making the element. + * Version of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version * - * @param creator desired value for the property creator. + * @param version desired value for the property version. */ - void setCreator(Reference creator); + void setVersion(String version); /** * Revision of the element. @@ -67,41 +68,41 @@ public interface AdministrativeInformation extends HasDataSpecification { void setRevision(String revision); /** - * Identifier of the template that guided the creation of the element. + * The subject ID of the subject responsible for making the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator * - * @return Returns the String for the property templateID. + * @return Returns the Reference for the property creator. */ - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID") - String getTemplateID(); + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/creator") + Reference getCreator(); /** - * Identifier of the template that guided the creation of the element. + * The subject ID of the subject responsible for making the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator * - * @param templateID desired value for the property templateID. + * @param creator desired value for the property creator. */ - void setTemplateID(String templateID); + void setCreator(Reference creator); /** - * Version of the element. + * Identifier of the template that guided the creation of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId * - * @return Returns the String for the property version. + * @return Returns the String for the property templateId. */ - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/version") - String getVersion(); + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId") + String getTemplateId(); /** - * Version of the element. + * Identifier of the template that guided the creation of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId * - * @param version desired value for the property version. + * @param templateId desired value for the property templateId. */ - void setVersion(String version); + void setTemplateId(String templateId); } 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 841ea2032..987cc7a15 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 @@ -1,5 +1,6 @@ /* * 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 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 238314362..2b51a7a67 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 @@ -1,5 +1,6 @@ /* * 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 @@ -30,42 +31,42 @@ public interface AssetAdministrationShell extends HasDataSpecification, Identifiable { /** - * Meta-information about the asset the AAS is representing. + * The reference to the AAS the AAS was derived from. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom * - * @return Returns the AssetInformation for the property assetInformation. + * @return Returns the Reference for the property derivedFrom. */ - @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation") - AssetInformation getAssetInformation(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom") + Reference getDerivedFrom(); /** - * Meta-information about the asset the AAS is representing. + * The reference to the AAS the AAS was derived from. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom * - * @param assetInformation desired value for the property assetInformation. + * @param derivedFrom desired value for the property derivedFrom. */ - void setAssetInformation(AssetInformation assetInformation); + void setDerivedFrom(Reference derivedFrom); /** - * The reference to the AAS the AAS was derived from. + * Meta-information about the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation * - * @return Returns the Reference for the property derivedFrom. + * @return Returns the AssetInformation for the property assetInformation. */ - @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom") - Reference getDerivedFrom(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation") + AssetInformation getAssetInformation(); /** - * The reference to the AAS the AAS was derived from. + * Meta-information about the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation * - * @param derivedFrom desired value for the property derivedFrom. + * @param assetInformation desired value for the property assetInformation. */ - void setDerivedFrom(Reference derivedFrom); + void setAssetInformation(AssetInformation assetInformation); /** * References to submodels of the AAS. 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 new file mode 100644 index 000000000..bca665c23 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java @@ -0,0 +1,186 @@ +/* + * Copyright (c) 2023 SAP SE + * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. + * + * 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.impl.DefaultAssetAdministrationShellDescriptor; + +import java.util.List; + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultAssetAdministrationShellDescriptor.class) +}) +public interface AssetAdministrationShellDescriptor extends Descriptor { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration + * + * @return Returns the AdministrativeInformation for the property administration. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration") + AdministrativeInformation getAdministration(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration + * + * @param administration desired value for the property administration. + */ + void setAdministration(AdministrativeInformation administration); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description + * + * @return Returns the LangStringSet for the property description. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description") + List getDescription(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description + * + * @param description desired value for the property description. + */ + void setDescription(List description); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName + * + * @return Returns the LangStringSet for the property displayName. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName") + List getDisplayName(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName + * + * @param displayName desired value for the property displayName. + */ + void setDisplayName(List displayName); + + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId + * + * @return Returns the String for the property idShort. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId") + Reference getGlobalAssetId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId + * + * @param globalAssetId desired value for the property globalAssetId. + */ + void setGlobalAssetId(Reference globalAssetId); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort + * + * @return Returns the String for the property idShort. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort") + String getIdShort(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort + * + * @param idShort desired value for the property idShort. + */ + void setIdShort(String idShort); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id + * + * @return Returns the String for the property identification. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id") + String getId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id + * + * @param id desired value for the property identification. + */ + void setId(String id); + + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind + * + * @return Returns the AssetKind for the property assetKind. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind") + AssetKind getAssetKind(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind + * + * @param assetKind desired value for the property assetKind. + */ + void setAssetKind(AssetKind assetKind); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetId + * + * @return Returns the String for the property specificAssetId. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds") + SpecificAssetId getSpecificAssetIds(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds + * + * @param specificAssetIds desired value for the property specificAssetIds. + */ + void setSpecificAssetIds(SpecificAssetId specificAssetIds); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor + * + * @return Returns the String for the property submodelDescriptor. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor") + List getSubmodelDescriptor(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor + * + * @param submodelDescriptor desired value for the property submodelDescriptor. + */ + void setSubmodelDescriptor(List submodelDescriptor); + +} 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 517cb9db6..61ce8f421 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 @@ -1,5 +1,6 @@ /* * 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 @@ -50,83 +51,83 @@ public interface AssetInformation { void setAssetKind(AssetKind assetKind); /** - * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset - * under consideration as identified by 'globalAssetID'. + * Global identifier of the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType + * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId * - * @return Returns the String for the property assetType. + * @return Returns the String for the property globalAssetId. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/assetType") - String getAssetType(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId") + String getGlobalAssetId(); /** - * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset - * under consideration as identified by 'globalAssetID'. + * Global identifier of the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType + * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId * - * @param assetType desired value for the property assetType. + * @param globalAssetId desired value for the property globalAssetId. */ - void setAssetType(String assetType); + void setGlobalAssetId(String globalAssetId); /** - * Thumbnail of the asset represented by the Asset Administration Shell. + * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial + * number etc. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail + * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds * - * @return Returns the Resource for the property defaultThumbnail. + * @return Returns the List of SpecificAssetIds for the property specificAssetIds. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail") - Resource getDefaultThumbnail(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds") + List getSpecificAssetIds(); /** - * Thumbnail of the asset represented by the Asset Administration Shell. + * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial + * number etc. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail + * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds * - * @param defaultThumbnail desired value for the property defaultThumbnail. + * @param specificAssetIds desired value for the property specificAssetIds. */ - void setDefaultThumbnail(Resource defaultThumbnail); + void setSpecificAssetIds(List specificAssetIds); /** - * Global identifier of the asset the AAS is representing. + * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset + * under consideration as identified by 'globalAssetId'. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID + * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType * - * @return Returns the String for the property globalAssetID. + * @return Returns the String for the property assetType. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID") - String getGlobalAssetID(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/assetType") + String getAssetType(); /** - * Global identifier of the asset the AAS is representing. + * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset + * under consideration as identified by 'globalAssetId'. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID + * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType * - * @param globalAssetID desired value for the property globalAssetID. + * @param assetType desired value for the property assetType. */ - void setGlobalAssetID(String globalAssetID); + void setAssetType(String assetType); /** - * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial - * number etc. + * Thumbnail of the asset represented by the Asset Administration Shell. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds + * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail * - * @return Returns the List of SpecificAssetIDs for the property specificAssetIds. + * @return Returns the Resource for the property defaultThumbnail. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds") - List getSpecificAssetIds(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail") + Resource getDefaultThumbnail(); /** - * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial - * number etc. + * Thumbnail of the asset represented by the Asset Administration Shell. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds + * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail * - * @param specificAssetIds desired value for the property specificAssetIds. + * @param defaultThumbnail desired value for the property defaultThumbnail. */ - void setSpecificAssetIds(List specificAssetIds); + void setDefaultThumbnail(Resource defaultThumbnail); } 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 70ea05c93..80401d406 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 @@ -1,5 +1,6 @@ /* * 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 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 2364f88f2..b4544ceef 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 @@ -1,5 +1,6 @@ /* * 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 @@ -28,6 +29,27 @@ }) public interface BasicEventElement extends EventElement { + /** + * Reference to the 'Referable', which defines the scope of the event. Can be + * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed + * + * @return Returns the Reference for the property observed. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/observed") + Reference getObserved(); + + /** + * Reference to the 'Referable', which defines the scope of the event. Can be + * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed + * + * @param observed desired value for the property observed. + */ + void setObserved(Reference observed); + /** * Direction of event. * @@ -48,42 +70,44 @@ public interface BasicEventElement extends EventElement { void setDirection(Direction direction); /** - * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). + * State of event. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state * - * @return Returns the String for the property lastUpdate. + * @return Returns the StateOfEvent for the property state. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate") - String getLastUpdate(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/state") + StateOfEvent getState(); /** - * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). + * State of event. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state * - * @param lastUpdate desired value for the property lastUpdate. + * @param state desired value for the property state. */ - void setLastUpdate(String lastUpdate); + void setState(StateOfEvent state); /** - * For input direction: not applicable. + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic * - * @return Returns the String for the property maxInterval. + * @return Returns the String for the property messageTopic. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval") - String getMaxInterval(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic") + String getMessageTopic(); /** - * For input direction: not applicable. + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic * - * @param maxInterval desired value for the property maxInterval. + * @param messageTopic desired value for the property messageTopic. */ - void setMaxInterval(String maxInterval); + void setMessageTopic(String messageTopic); /** * Information, which outer message infrastructure shall handle messages for the 'EventElement'. @@ -109,25 +133,23 @@ public interface BasicEventElement extends EventElement { void setMessageBroker(Reference messageBroker); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate * - * @return Returns the String for the property messageTopic. + * @return Returns the String for the property lastUpdate. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic") - String getMessageTopic(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate") + String getLastUpdate(); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate * - * @param messageTopic desired value for the property messageTopic. + * @param lastUpdate desired value for the property lastUpdate. */ - void setMessageTopic(String messageTopic); + void setLastUpdate(String lastUpdate); /** * For input direction, reports on the maximum frequency, the software entity behind the respective @@ -151,43 +173,22 @@ public interface BasicEventElement extends EventElement { void setMinInterval(String minInterval); /** - * Reference to the 'Referable', which defines the scope of the event. Can be - * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. - * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed - * - * @return Returns the Reference for the property observed. - */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/observed") - Reference getObserved(); - - /** - * Reference to the 'Referable', which defines the scope of the event. Can be - * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. - * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed - * - * @param observed desired value for the property observed. - */ - void setObserved(Reference observed); - - /** - * State of event. + * For input direction: not applicable. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval * - * @return Returns the StateOfEvent for the property state. + * @return Returns the String for the property maxInterval. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/state") - StateOfEvent getState(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval") + String getMaxInterval(); /** - * State of event. + * For input direction: not applicable. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval * - * @param state desired value for the property state. + * @param maxInterval desired value for the property maxInterval. */ - void setState(StateOfEvent state); + void setMaxInterval(String maxInterval); } 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 8ea957078..1edb58bed 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 @@ -1,5 +1,6 @@ /* * 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 @@ -30,41 +31,41 @@ public interface Blob extends DataElement { /** - * Content type of the content of the 'Blob'. + * The value of the 'Blob' instance of a blob data element. * - * More information under https://admin-shell.io/aas/3/0/Blob/contentType + * More information under https://admin-shell.io/aas/3/0/Blob/value * - * @return Returns the String for the property contentType. + * @return Returns the byte[] for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/Blob/contentType") - String getContentType(); + @IRI("https://admin-shell.io/aas/3/0/Blob/value") + byte[] getValue(); /** - * Content type of the content of the 'Blob'. + * The value of the 'Blob' instance of a blob data element. * - * More information under https://admin-shell.io/aas/3/0/Blob/contentType + * More information under https://admin-shell.io/aas/3/0/Blob/value * - * @param contentType desired value for the property contentType. + * @param value desired value for the property value. */ - void setContentType(String contentType); + void setValue(byte[] value); /** - * The value of the 'Blob' instance of a blob data element. + * Content type of the content of the 'Blob'. * - * More information under https://admin-shell.io/aas/3/0/Blob/value + * More information under https://admin-shell.io/aas/3/0/Blob/contentType * - * @return Returns the byte[] for the property value. + * @return Returns the String for the property contentType. */ - @IRI("https://admin-shell.io/aas/3/0/Blob/value") - byte[] getValue(); + @IRI("https://admin-shell.io/aas/3/0/Blob/contentType") + String getContentType(); /** - * The value of the 'Blob' instance of a blob data element. + * Content type of the content of the 'Blob'. * - * More information under https://admin-shell.io/aas/3/0/Blob/value + * More information under https://admin-shell.io/aas/3/0/Blob/contentType * - * @param value desired value for the property value. + * @param contentType desired value for the property contentType. */ - void setValue(byte[] value); + void setContentType(String contentType); } 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 26cb02ec6..0dc242c2f 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 @@ -1,5 +1,6 @@ /* * 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 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 a18fe9266..724d31fed 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 @@ -1,5 +1,6 @@ /* * 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 @@ -45,8 +46,8 @@ public interface ConceptDescription extends HasDataSpecification, Identifiable { * * More information under https://admin-shell.io/aas/3/0/ConceptDescription/isCaseOf * - * @param isCaseOf desired value for the property isCaseOf. + * @param isCaseOfs desired value for the property isCaseOf. */ - void setIsCaseOf(List isCaseOf); + void setIsCaseOf(List isCaseOfs); } 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 3c848efab..628d658af 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 @@ -1,5 +1,6 @@ /* * 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 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 c6ba9d955..e2933c187 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 @@ -1,5 +1,6 @@ /* * 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 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 c0b5a1b18..182a70102 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 @@ -1,5 +1,6 @@ /* * 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 @@ -31,99 +32,80 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { /** - * Data Type - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType - * - * @return Returns the DataTypeIec61360 for the property dataType. - */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/dataType") - DataTypeIec61360 getDataType(); - - /** - * Data Type - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType - * - * @param dataType desired value for the property dataType. - */ - void setDataType(DataTypeIec61360 dataType); - - /** - * Definition in different languages + * Preferred name * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName * - * @return Returns the List of LangStringDefinitionTypeIEC61360s for the property definition. + * @return Returns the List of LangStringPreferredNameTypeIec61360s for the property preferredName. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/definition") - List getDefinition(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName") + List getPreferredName(); /** - * Definition in different languages + * Preferred name * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName * - * @param definition desired value for the property definition. + * @param preferredNames desired value for the property preferredName. */ - void setDefinition(List definition); + void setPreferredName(List preferredNames); /** - * Set of levels. + * Short name * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName * - * @return Returns the LevelType for the property levelType. + * @return Returns the List of LangStringShortNameTypeIec61360s for the property shortName. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType") - LevelType getLevelType(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName") + List getShortName(); /** - * Set of levels. + * Short name * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName * - * @param levelType desired value for the property levelType. + * @param shortNames desired value for the property shortName. */ - void setLevelType(LevelType levelType); + void setShortName(List shortNames); /** - * Preferred name + * Unit * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit * - * @return Returns the List of LangStringPreferredNameTypeIEC61360s for the property preferredName. + * @return Returns the String for the property unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/preferredName") - List getPreferredName(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit") + String getUnit(); /** - * Preferred name + * Unit * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit * - * @param preferredName desired value for the property preferredName. + * @param unit desired value for the property unit. */ - void setPreferredName(List preferredName); + void setUnit(String unit); /** - * Short name + * Unique unit id * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId * - * @return Returns the List of LangStringShortNameTypeIEC61360s for the property shortName. + * @return Returns the Reference for the property unitId. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/shortName") - List getShortName(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId") + Reference getUnitId(); /** - * Short name + * Unique unit id * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId * - * @param shortName desired value for the property shortName. + * @param unitId desired value for the property unitId. */ - void setShortName(List shortName); + void setUnitId(Reference unitId); /** * Source of definition @@ -133,7 +115,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the String for the property sourceOfDefinition. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/sourceOfDefinition") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/sourceOfDefinition") String getSourceOfDefinition(); /** @@ -153,7 +135,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the String for the property symbol. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/symbol") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/symbol") String getSymbol(); /** @@ -166,61 +148,42 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { void setSymbol(String symbol); /** - * Unit - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit - * - * @return Returns the String for the property unit. - */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unit") - String getUnit(); - - /** - * Unit - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit - * - * @param unit desired value for the property unit. - */ - void setUnit(String unit); - - /** - * Unique unit id + * Data Type * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitID + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType * - * @return Returns the Reference for the property unitID. + * @return Returns the DataTypeIec61360 for the property dataType. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unitID") - Reference getUnitID(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType") + DataTypeIec61360 getDataType(); /** - * Unique unit id + * Data Type * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitID + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType * - * @param unitID desired value for the property unitID. + * @param dataType desired value for the property dataType. */ - void setUnitID(Reference unitID); + void setDataType(DataTypeIec61360 dataType); /** - * Value + * Definition in different languages * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition * - * @return Returns the String for the property value. + * @return Returns the List of LangStringDefinitionTypeIec61360s for the property definition. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/value") - String getValue(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition") + List getDefinition(); /** - * Value + * Definition in different languages * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition * - * @param value desired value for the property value. + * @param definitions desired value for the property definition. */ - void setValue(String value); + void setDefinition(List definitions); /** * Value Format @@ -229,7 +192,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the String for the property valueFormat. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueFormat") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueFormat") String getValueFormat(); /** @@ -248,7 +211,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the ValueList for the property valueList. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueList") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueList") ValueList getValueList(); /** @@ -260,4 +223,42 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { */ void setValueList(ValueList valueList); + /** + * Value + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value + * + * @return Returns the String for the property value. + */ + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value") + String getValue(); + + /** + * Value + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value + * + * @param value desired value for the property value. + */ + void setValue(String value); + + /** + * Set of levels. + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType + * + * @return Returns the LevelType for the property levelType. + */ + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType") + LevelType getLevelType(); + + /** + * Set of levels. + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType + * + * @param levelType desired value for the property levelType. + */ + void setLevelType(LevelType levelType); + } 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 7452b2596..cb41effbd 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,157 +23,157 @@ /** * Enumeration listing all XSD anySimpleTypes */ -@IRI("aas:DataTypeDefXSD") -public enum DataTypeDefXSD { +@IRI("aas:DataTypeDefXsd") +public enum DataTypeDefXsd { /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/AnyUri") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/AnyUri") ANY_URI, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Base64Binary") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Base64Binary") BASE64BINARY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Boolean") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Boolean") BOOLEAN, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Byte") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Byte") BYTE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Date") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Date") DATE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/DateTime") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/DateTime") DATE_TIME, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Decimal") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Decimal") DECIMAL, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Double") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Double") DOUBLE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Duration") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Duration") DURATION, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Float") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Float") FLOAT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GDay") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GDay") GDAY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GMonth") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GMonth") GMONTH, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GMonthDay") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GMonthDay") GMONTH_DAY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GYear") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GYear") GYEAR, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GYearMonth") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GYearMonth") GYEAR_MONTH, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/HexBinary") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/HexBinary") HEX_BINARY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Int") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Int") INT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Integer") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Integer") INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Long") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Long") LONG, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/NegativeInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/NegativeInteger") NEGATIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/NonNegativeInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/NonNegativeInteger") NON_NEGATIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/NonPositiveInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/NonPositiveInteger") NON_POSITIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/PositiveInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/PositiveInteger") POSITIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Short") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Short") SHORT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/String") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/String") STRING, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Time") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Time") TIME, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedByte") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedByte") UNSIGNED_BYTE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedInt") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedInt") UNSIGNED_INT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedLong") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedLong") UNSIGNED_LONG, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedShort") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedShort") UNSIGNED_SHORT; } 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 a77873cda..d0ddfa144 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 @@ -1,5 +1,6 @@ /* * 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 @@ -21,129 +22,129 @@ /** */ -@IRI("aas:DataTypeIEC61360") +@IRI("aas:DataTypeIec61360") public enum DataTypeIec61360 { /** * values containing the content of a file. Values may be binaries. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Blob") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Blob") BLOB, /** * values representing truth of logic or Boolean algebra (TRUE, FALSE) */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Boolean") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Boolean") BOOLEAN, /** * values containing a calendar date, conformant to ISO 8601:2004 Format yyyy-mm-dd Example from IEC * 61360-1:2017: "1999-05-31" is the [DATE] representation of: "31 May 1999". */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Date") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Date") DATE, /** * values containing an address to a file. The values are of type URI and can represent an absolute * or relative path. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/File") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/File") FILE, /** * Values containing string with any sequence of characters, using the syntax of HTML5 (see W3C * Recommendation 28:2014) */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Html") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Html") HTML, /** * values containing values of type INTEGER but are no currencies or measures */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/IntegerCount") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/IntegerCount") INTEGER_COUNT, /** * values containing values of type INTEGER that are currencies */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/IntegerCurrency") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/IntegerCurrency") INTEGER_CURRENCY, /** * values containing values that are measure of type INTEGER. In addition such a value comes with a * physical unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/IntegerMeasure") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/IntegerMeasure") INTEGER_MEASURE, /** * values conforming to ISO/IEC 11179 series global identifier sequences */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Irdi") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Irdi") IRDI, /** * values containing values of type STRING conformant to Rfc 3987 */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Iri") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Iri") IRI, /** * values containing values of type rational */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Rational") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Rational") RATIONAL, /** * values containing values of type rational. In addition such a value comes with a physical unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RationalMeasure") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RationalMeasure") RATIONAL_MEASURE, /** * values containing numbers that can be written as a terminating or non-terminating decimal; a * rational or irrational number but are no currencies or measures */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RealCount") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RealCount") REAL_COUNT, /** * values containing values of type REAL that are currencies */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RealCurrency") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RealCurrency") REAL_CURRENCY, /** * values containing values that are measures of type REAL. In addition such a value comes with a * physical unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RealMeasure") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RealMeasure") REAL_MEASURE, /** * values consisting of sequence of characters but cannot be translated into other languages */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/String") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/String") STRING, /** * values containing string but shall be represented as different string in different languages */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/StringTranslatable") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/StringTranslatable") STRING_TRANSLATABLE, /** * values containing a time, conformant to ISO 8601:2004 but restricted to what is allowed in the * corresponding type in xml. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Time") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Time") TIME, /** * values containing a time, conformant to ISO 8601:2004 but restricted to what is allowed in the * corresponding type in xml. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Timestamp") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Timestamp") TIMESTAMP; } 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 new file mode 100644 index 000000000..a06e883fc --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.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. All rights reserved. + * + * 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.impl.DefaultDescriptor; + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultDescriptor.class), + @KnownSubtypes.Type(value = SubmodelDescriptor.class) +}) +public interface Descriptor { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints + * + * @return Returns the List of Endpoints for the property endpoints. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") + List getEndpoints(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints + * + * @param endpoints desired value for the property endpoints. + */ + void setEndpoints(List endpoints); + +} 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 9a556a503..dcc154a6c 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 @@ -1,5 +1,6 @@ /* * 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 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 5be85af48..48c3a2ccb 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 @@ -1,5 +1,6 @@ /* * 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 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 new file mode 100644 index 000000000..fa8b8fee6 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java @@ -0,0 +1,61 @@ +/* + * 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. + * + * 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.impl.DefaultEndpoint; + +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultEndpoint.class) +}) +public interface Endpoint { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/interface + * + * @return Returns the String for the property interface. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/interface") + String getInterface(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/interface + * + * @param interfaceValue desired value for the property interface. + */ + void setInterface(String interfaceValue); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation + * + * @return Returns the ProtocolInformation for the property protocolInformation. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation") + ProtocolInformation getProtocolInformation(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation + * + * @param protocolInformation desired value for the property protocolInformation. + */ + void setProtocolInformation(ProtocolInformation 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 17c09503a..c29c453e2 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 @@ -1,5 +1,6 @@ /* * 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 @@ -29,6 +30,27 @@ }) public interface Entity extends SubmodelElement { + /** + * Describes statements applicable to the entity by a set of submodel elements, typically with a + * qualified value. + * + * More information under https://admin-shell.io/aas/3/0/Entity/statements + * + * @return Returns the List of SubmodelElements for the property statements. + */ + @IRI("https://admin-shell.io/aas/3/0/Entity/statements") + List getStatements(); + + /** + * Describes statements applicable to the entity by a set of submodel elements, typically with a + * qualified value. + * + * More information under https://admin-shell.io/aas/3/0/Entity/statements + * + * @param statements desired value for the property statements. + */ + void setStatements(List statements); + /** * Describes whether the entity is a co-managed entity or a self-managed entity. * @@ -51,21 +73,21 @@ public interface Entity extends SubmodelElement { /** * Global identifier of the asset the entity is representing. * - * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetID + * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetId * - * @return Returns the String for the property globalAssetID. + * @return Returns the String for the property globalAssetId. */ - @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetID") - String getGlobalAssetID(); + @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetId") + String getGlobalAssetId(); /** * Global identifier of the asset the entity is representing. * - * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetID + * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetId * - * @param globalAssetID desired value for the property globalAssetID. + * @param globalAssetId desired value for the property globalAssetId. */ - void setGlobalAssetID(String globalAssetID); + void setGlobalAssetId(String globalAssetId); /** * Reference to a specific asset ID representing a supplementary identifier of the asset represented @@ -73,10 +95,10 @@ public interface Entity extends SubmodelElement { * * More information under https://admin-shell.io/aas/3/0/Entity/specificAssetIds * - * @return Returns the List of SpecificAssetIDs for the property specificAssetIds. + * @return Returns the List of SpecificAssetIds for the property specificAssetIds. */ @IRI("https://admin-shell.io/aas/3/0/Entity/specificAssetIds") - List getSpecificAssetIds(); + List getSpecificAssetIds(); /** * Reference to a specific asset ID representing a supplementary identifier of the asset represented @@ -86,27 +108,6 @@ public interface Entity extends SubmodelElement { * * @param specificAssetIds desired value for the property specificAssetIds. */ - void setSpecificAssetIds(List specificAssetIds); - - /** - * Describes statements applicable to the entity by a set of submodel elements, typically with a - * qualified value. - * - * More information under https://admin-shell.io/aas/3/0/Entity/statements - * - * @return Returns the List of SubmodelElements for the property statements. - */ - @IRI("https://admin-shell.io/aas/3/0/Entity/statements") - List getStatements(); - - /** - * Describes statements applicable to the entity by a set of submodel elements, typically with a - * qualified value. - * - * More information under https://admin-shell.io/aas/3/0/Entity/statements - * - * @param statements desired value for the property statements. - */ - void setStatements(List statements); + void setSpecificAssetIds(List specificAssetIds); } 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 5fec4fe06..233102815 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 @@ -1,5 +1,6 @@ /* * 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 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 5485872b9..e41524972 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 @@ -1,5 +1,6 @@ /* * 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 @@ -49,41 +50,41 @@ public interface Environment { void setAssetAdministrationShells(List assetAdministrationShells); /** - * Concept description + * Submodel * - * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions + * More information under https://admin-shell.io/aas/3/0/Environment/submodels * - * @return Returns the List of ConceptDescriptions for the property conceptDescriptions. + * @return Returns the List of Submodels for the property submodels. */ - @IRI("https://admin-shell.io/aas/3/0/Environment/conceptDescriptions") - List getConceptDescriptions(); + @IRI("https://admin-shell.io/aas/3/0/Environment/submodels") + List getSubmodels(); /** - * Concept description + * Submodel * - * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions + * More information under https://admin-shell.io/aas/3/0/Environment/submodels * - * @param conceptDescriptions desired value for the property conceptDescriptions. + * @param submodels desired value for the property submodels. */ - void setConceptDescriptions(List conceptDescriptions); + void setSubmodels(List submodels); /** - * Submodel + * Concept description * - * More information under https://admin-shell.io/aas/3/0/Environment/submodels + * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions * - * @return Returns the List of Submodels for the property submodels. + * @return Returns the List of ConceptDescriptions for the property conceptDescriptions. */ - @IRI("https://admin-shell.io/aas/3/0/Environment/submodels") - List getSubmodels(); + @IRI("https://admin-shell.io/aas/3/0/Environment/conceptDescriptions") + List getConceptDescriptions(); /** - * Submodel + * Concept description * - * More information under https://admin-shell.io/aas/3/0/Environment/submodels + * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions * - * @param submodels desired value for the property submodels. + * @param conceptDescriptions desired value for the property conceptDescriptions. */ - void setSubmodels(List submodels); + void setConceptDescriptions(List conceptDescriptions); } 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 02818c712..a134a0289 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 @@ -1,5 +1,6 @@ /* * 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 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 f971df611..42720b37c 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 @@ -1,5 +1,6 @@ /* * 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 @@ -29,120 +30,122 @@ public interface EventPayload { /** - * Reference to the referable, which defines the scope of the event. + * Reference to the source event element, including identification of 'AssetAdministrationShell', + * 'Submodel', 'SubmodelElement''s. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference + * More information under https://admin-shell.io/aas/3/0/EventPayload/source * - * @return Returns the Reference for the property observableReference. + * @return Returns the Reference for the property source. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableReference") - Reference getObservableReference(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/source") + Reference getSource(); /** - * Reference to the referable, which defines the scope of the event. + * Reference to the source event element, including identification of 'AssetAdministrationShell', + * 'Submodel', 'SubmodelElement''s. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference + * More information under https://admin-shell.io/aas/3/0/EventPayload/source * - * @param observableReference desired value for the property observableReference. + * @param source desired value for the property source. */ - void setObservableReference(Reference observableReference); + void setSource(Reference source); /** - * 'semanticID' of the referable which defines the scope of the event, if available. + * 'semanticId' of the source event element, if available * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID + * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId * - * @return Returns the Reference for the property observableSemanticID. + * @return Returns the Reference for the property sourceSemanticId. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID") - Reference getObservableSemanticID(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId") + Reference getSourceSemanticId(); /** - * 'semanticID' of the referable which defines the scope of the event, if available. + * 'semanticId' of the source event element, if available * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID + * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId * - * @param observableSemanticID desired value for the property observableSemanticID. + * @param sourceSemanticId desired value for the property sourceSemanticId. */ - void setObservableSemanticID(Reference observableSemanticID); + void setSourceSemanticId(Reference sourceSemanticId); /** - * Event specific payload. + * Reference to the referable, which defines the scope of the event. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/payload + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference * - * @return Returns the byte[] for the property payload. + * @return Returns the Reference for the property observableReference. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/payload") - byte[] getPayload(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableReference") + Reference getObservableReference(); /** - * Event specific payload. + * Reference to the referable, which defines the scope of the event. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/payload + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference * - * @param payload desired value for the property payload. + * @param observableReference desired value for the property observableReference. */ - void setPayload(byte[] payload); + void setObservableReference(Reference observableReference); /** - * Reference to the source event element, including identification of 'AssetAdministrationShell', - * 'Submodel', 'SubmodelElement''s. + * 'semanticId' of the referable which defines the scope of the event, if available. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/source + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId * - * @return Returns the Reference for the property source. + * @return Returns the Reference for the property observableSemanticId. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/source") - Reference getSource(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId") + Reference getObservableSemanticId(); /** - * Reference to the source event element, including identification of 'AssetAdministrationShell', - * 'Submodel', 'SubmodelElement''s. + * 'semanticId' of the referable which defines the scope of the event, if available. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/source + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId * - * @param source desired value for the property source. + * @param observableSemanticId desired value for the property observableSemanticId. */ - void setSource(Reference source); + void setObservableSemanticId(Reference observableSemanticId); /** - * 'semanticID' of the source event element, if available + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID + * More information under https://admin-shell.io/aas/3/0/EventPayload/topic * - * @return Returns the Reference for the property sourceSemanticID. + * @return Returns the String for the property topic. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID") - Reference getSourceSemanticID(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/topic") + String getTopic(); /** - * 'semanticID' of the source event element, if available + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID + * More information under https://admin-shell.io/aas/3/0/EventPayload/topic * - * @param sourceSemanticID desired value for the property sourceSemanticID. + * @param topic desired value for the property topic. */ - void setSourceSemanticID(Reference sourceSemanticID); + void setTopic(String topic); /** * Subject, who/which initiated the creation. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectID + * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectId * - * @return Returns the Reference for the property subjectID. + * @return Returns the Reference for the property subjectId. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectID") - Reference getSubjectID(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectId") + Reference getSubjectId(); /** * Subject, who/which initiated the creation. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectID + * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectId * - * @param subjectID desired value for the property subjectID. + * @param subjectId desired value for the property subjectId. */ - void setSubjectID(Reference subjectID); + void setSubjectId(Reference subjectId); /** * Timestamp in UTC, when this event was triggered. @@ -164,24 +167,22 @@ public interface EventPayload { void setTimeStamp(String timeStamp); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * Event specific payload. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/topic + * More information under https://admin-shell.io/aas/3/0/EventPayload/payload * - * @return Returns the String for the property topic. + * @return Returns the byte[] for the property payload. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/topic") - String getTopic(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/payload") + byte[] getPayload(); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * Event specific payload. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/topic + * More information under https://admin-shell.io/aas/3/0/EventPayload/payload * - * @param topic desired value for the property topic. + * @param payload desired value for the property payload. */ - void setTopic(String topic); + void setPayload(byte[] payload); } 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 9638fe412..c3c5f2659 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 @@ -1,5 +1,6 @@ /* * 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 @@ -49,23 +50,23 @@ public interface Extension extends HasSemantics { void setName(String name); /** - * Reference to an element the extension refers to. + * Type of the value of the extension. * - * More information under https://admin-shell.io/aas/3/0/Extension/refersTo + * More information under https://admin-shell.io/aas/3/0/Extension/valueType * - * @return Returns the List of References for the property refersTo. + * @return Returns the DataTypeDefXsd for the property valueType. */ - @IRI("https://admin-shell.io/aas/3/0/Extension/refersTo") - List getRefersTo(); + @IRI("https://admin-shell.io/aas/3/0/Extension/valueType") + DataTypeDefXsd getValueType(); /** - * Reference to an element the extension refers to. + * Type of the value of the extension. * - * More information under https://admin-shell.io/aas/3/0/Extension/refersTo + * More information under https://admin-shell.io/aas/3/0/Extension/valueType * - * @param refersTo desired value for the property refersTo. + * @param valueType desired value for the property valueType. */ - void setRefersTo(List refersTo); + void setValueType(DataTypeDefXsd valueType); /** * Value of the extension @@ -87,22 +88,22 @@ public interface Extension extends HasSemantics { void setValue(String value); /** - * Type of the value of the extension. + * Reference to an element the extension refers to. * - * More information under https://admin-shell.io/aas/3/0/Extension/valueType + * More information under https://admin-shell.io/aas/3/0/Extension/refersTo * - * @return Returns the DataTypeDefXSD for the property valueType. + * @return Returns the List of References for the property refersTo. */ - @IRI("https://admin-shell.io/aas/3/0/Extension/valueType") - DataTypeDefXSD getValueType(); + @IRI("https://admin-shell.io/aas/3/0/Extension/refersTo") + List getRefersTo(); /** - * Type of the value of the extension. + * Reference to an element the extension refers to. * - * More information under https://admin-shell.io/aas/3/0/Extension/valueType + * More information under https://admin-shell.io/aas/3/0/Extension/refersTo * - * @param valueType desired value for the property valueType. + * @param refersTos desired value for the property refersTo. */ - void setValueType(DataTypeDefXSD valueType); + void setRefersTo(List refersTos); } 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 6bf0dfc6c..ed40d2d1e 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 @@ -1,5 +1,6 @@ /* * 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 @@ -29,41 +30,41 @@ public interface File extends DataElement { /** - * Content type of the content of the file. + * Path and name of the referenced file (with file extension). * - * More information under https://admin-shell.io/aas/3/0/File/contentType + * More information under https://admin-shell.io/aas/3/0/File/value * - * @return Returns the String for the property contentType. + * @return Returns the String for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/File/contentType") - String getContentType(); + @IRI("https://admin-shell.io/aas/3/0/File/value") + String getValue(); /** - * Content type of the content of the file. + * Path and name of the referenced file (with file extension). * - * More information under https://admin-shell.io/aas/3/0/File/contentType + * More information under https://admin-shell.io/aas/3/0/File/value * - * @param contentType desired value for the property contentType. + * @param value desired value for the property value. */ - void setContentType(String contentType); + void setValue(String value); /** - * Path and name of the referenced file (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/File/value + * More information under https://admin-shell.io/aas/3/0/File/contentType * - * @return Returns the String for the property value. + * @return Returns the String for the property contentType. */ - @IRI("https://admin-shell.io/aas/3/0/File/value") - String getValue(); + @IRI("https://admin-shell.io/aas/3/0/File/contentType") + String getContentType(); /** - * Path and name of the referenced file (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/File/value + * More information under https://admin-shell.io/aas/3/0/File/contentType * - * @param value desired value for the property value. + * @param contentType desired value for the property contentType. */ - void setValue(String value); + void setContentType(String contentType); } 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 c266eda1c..5887c38e5 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 @@ -1,5 +1,6 @@ /* * 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 @@ -26,8 +27,8 @@ @KnownSubtypes({ @KnownSubtypes.Type(value = AdministrativeInformation.class), @KnownSubtypes.Type(value = AssetAdministrationShell.class), - @KnownSubtypes.Type(value = SubmodelElement.class), @KnownSubtypes.Type(value = ConceptDescription.class), + @KnownSubtypes.Type(value = SubmodelElement.class), @KnownSubtypes.Type(value = Submodel.class) }) public interface HasDataSpecification { 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 4da4a2342..761b5baca 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 @@ -1,5 +1,6 @@ /* * 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 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 420fed252..452c60ee1 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 @@ -1,5 +1,6 @@ /* * 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 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 a5933022c..41f9b9978 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 @@ -1,5 +1,6 @@ /* * 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 @@ -24,7 +25,7 @@ * Element that can have a semantic definition plus some supplemental semantic definitions. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = SpecificAssetID.class), + @KnownSubtypes.Type(value = SpecificAssetId.class), @KnownSubtypes.Type(value = SubmodelElement.class), @KnownSubtypes.Type(value = Submodel.class), @KnownSubtypes.Type(value = Extension.class), @@ -36,22 +37,22 @@ public interface HasSemantics { * Identifier of the semantic definition of the element. It is called semantic ID of the element or * also main semantic ID of the element. * - * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticID + * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticId * - * @return Returns the Reference for the property semanticID. + * @return Returns the Reference for the property semanticId. */ - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticID") - Reference getSemanticID(); + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") + Reference getSemanticId(); /** * Identifier of the semantic definition of the element. It is called semantic ID of the element or * also main semantic ID of the element. * - * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticID + * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticId * - * @param semanticID desired value for the property semanticID. + * @param semanticId desired value for the property semanticId. */ - void setSemanticID(Reference semanticID); + void setSemanticId(Reference semanticId); /** * Identifier of a supplemental semantic definition of the element. It is called supplemental 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 325a3d6d8..6cf22f3bf 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 @@ -1,5 +1,6 @@ /* * 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 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 e58033a6a..f91b08a96 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 @@ -1,5 +1,6 @@ /* * 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 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 c08fef3b8..84d18f137 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 @@ -1,5 +1,6 @@ /* * 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 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..0bd4f3547 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangString.java @@ -0,0 +1,93 @@ +/* + * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. + * Copyright (c) 2023 SAP SE + * + * 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 java.io.Serializable; +import java.util.Objects; + + +@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 a2153c56c..fb49700bd 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 @@ -1,5 +1,6 @@ /* * 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 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 510fa9ff7..1fe4604ef 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 @@ -1,5 +1,6 @@ /* * 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 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 970690271..e03afda72 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 @@ -1,5 +1,6 @@ /* * 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 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 dfa79c706..98fcdaf14 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 @@ -1,5 +1,6 @@ /* * 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 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 dc960b950..2ff44c065 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 @@ -1,5 +1,6 @@ /* * 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 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 36ca14e5b..4f3931d96 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 @@ -1,5 +1,6 @@ /* * 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 @@ -29,25 +30,6 @@ }) public interface LevelType { - /** - * Maximum of the value - * - * More information under https://admin-shell.io/aas/3/0/LevelType/max - * - * @return Returns the boolean for the property max. - */ - @IRI("https://admin-shell.io/aas/3/0/LevelType/max") - boolean getMax(); - - /** - * Maximum of the value - * - * More information under https://admin-shell.io/aas/3/0/LevelType/max - * - * @param max desired value for the property max. - */ - void setMax(boolean max); - /** * Minimum of the value * @@ -105,4 +87,23 @@ public interface LevelType { */ void setTyp(boolean typ); + /** + * Maximum of the value + * + * More information under https://admin-shell.io/aas/3/0/LevelType/max + * + * @return Returns the boolean for the property max. + */ + @IRI("https://admin-shell.io/aas/3/0/LevelType/max") + boolean getMax(); + + /** + * Maximum of the value + * + * More information under https://admin-shell.io/aas/3/0/LevelType/max + * + * @param max desired value for the property max. + */ + void setMax(boolean max); + } 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 070e48af7..aba02a581 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 @@ -1,5 +1,6 @@ /* * 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 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 e2ca85aa4..5058811c4 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 @@ -1,5 +1,6 @@ /* * 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 @@ -44,27 +45,27 @@ public interface MultiLanguageProperty extends DataElement { * * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/value * - * @param value desired value for the property value. + * @param values desired value for the property value. */ - void setValue(List value); + void setValue(List values); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID + * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId * - * @return Returns the Reference for the property valueID. + * @return Returns the Reference for the property valueId. */ - @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID") - Reference getValueID(); + @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId") + Reference getValueId(); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID + * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId * - * @param valueID desired value for the property valueID. + * @param valueId desired value for the property valueId. */ - void setValueID(Reference valueID); + void setValueId(Reference valueId); } 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 18bb33559..093835165 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 @@ -1,5 +1,6 @@ /* * 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 @@ -29,25 +30,6 @@ }) public interface Operation extends SubmodelElement { - /** - * Parameter that is input and output of the operation. - * - * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables - * - * @return Returns the List of OperationVariables for the property inoutputVariables. - */ - @IRI("https://admin-shell.io/aas/3/0/Operation/inoutputVariables") - List getInoutputVariables(); - - /** - * Parameter that is input and output of the operation. - * - * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables - * - * @param inoutputVariables desired value for the property inoutputVariables. - */ - void setInoutputVariables(List inoutputVariables); - /** * Input parameter of the operation. * @@ -86,4 +68,23 @@ public interface Operation extends SubmodelElement { */ void setOutputVariables(List outputVariables); + /** + * Parameter that is input and output of the operation. + * + * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables + * + * @return Returns the List of OperationVariables for the property inoutputVariables. + */ + @IRI("https://admin-shell.io/aas/3/0/Operation/inoutputVariables") + List getInoutputVariables(); + + /** + * Parameter that is input and output of the operation. + * + * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables + * + * @param inoutputVariables desired value for the property inoutputVariables. + */ + void setInoutputVariables(List inoutputVariables); + } 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 7b5cf13d6..c61563481 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 @@ -1,5 +1,6 @@ /* * 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 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 13a195fb3..72fc83156 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 @@ -1,5 +1,6 @@ /* * 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 @@ -28,6 +29,25 @@ }) public interface Property extends DataElement { + /** + * Data type of the value + * + * More information under https://admin-shell.io/aas/3/0/Property/valueType + * + * @return Returns the DataTypeDefXsd for the property valueType. + */ + @IRI("https://admin-shell.io/aas/3/0/Property/valueType") + DataTypeDefXsd getValueType(); + + /** + * Data type of the value + * + * More information under https://admin-shell.io/aas/3/0/Property/valueType + * + * @param valueType desired value for the property valueType. + */ + void setValueType(DataTypeDefXsd valueType); + /** * The value of the property instance. * @@ -50,39 +70,20 @@ public interface Property extends DataElement { /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Property/valueID + * More information under https://admin-shell.io/aas/3/0/Property/valueId * - * @return Returns the Reference for the property valueID. + * @return Returns the Reference for the property valueId. */ - @IRI("https://admin-shell.io/aas/3/0/Property/valueID") - Reference getValueID(); + @IRI("https://admin-shell.io/aas/3/0/Property/valueId") + Reference getValueId(); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Property/valueID + * More information under https://admin-shell.io/aas/3/0/Property/valueId * - * @param valueID desired value for the property valueID. - */ - void setValueID(Reference valueID); - - /** - * Data type of the value - * - * More information under https://admin-shell.io/aas/3/0/Property/valueType - * - * @return Returns the DataTypeDefXSD for the property valueType. - */ - @IRI("https://admin-shell.io/aas/3/0/Property/valueType") - DataTypeDefXSD getValueType(); - - /** - * Data type of the value - * - * More information under https://admin-shell.io/aas/3/0/Property/valueType - * - * @param valueType desired value for the property valueType. + * @param valueId desired value for the property valueId. */ - void setValueType(DataTypeDefXSD valueType); + void setValueId(Reference valueId); } 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 new file mode 100644 index 000000000..8b4527f69 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java @@ -0,0 +1,135 @@ +/* + * 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. + * + * 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.impl.DefaultProtocolInformation; + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultProtocolInformation.class) +}) +public interface ProtocolInformation { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress + * + * @return Returns the String for the property endpointAddress. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress") + String getEndpointAddress(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress + * + * @param endpointAddress desired value for the property endpointAddress. + */ + void setEndpointAddress(String endpointAddress); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol + * + * @return Returns the String for the property endpointProtocol. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol") + String getEndpointProtocol(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol + * + * @param endpointProtocol desired value for the property endpointProtocol. + */ + void setEndpointProtocol(String endpointProtocol); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion + * + * @return Returns the String for the property endpointProtocolVersion. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion") + String getEndpointProtocolVersion(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion + * + * @param endpointProtocolVersion desired value for the property endpointProtocolVersion. + */ + void setEndpointProtocolVersion(String endpointProtocolVersion); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol + * + * @return Returns the String for the property subprotocol. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol") + String getSubprotocol(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol + * + * @param subprotocol desired value for the property subprotocol. + */ + void setSubprotocol(String subprotocol); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody + * + * @return Returns the String for the property subprotocolBody. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody") + String getSubprotocolBody(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody + * + * @param subprotocolBody desired value for the property subprotocolBody. + */ + void setSubprotocolBody(String subprotocolBody); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding + * + * @return Returns the String for the property subprotocolBodyEncoding. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding") + String getSubprotocolBodyEncoding(); + + /** + * + * More information under + * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding + * + * @param subprotocolBodyEncoding desired value for the property subprotocolBodyEncoding. + */ + void setSubprotocolBodyEncoding(String 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 c7dcf966d..d8f0e2e84 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 @@ -1,5 +1,6 @@ /* * 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 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 d78e990a8..fd3876c9d 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 @@ -1,5 +1,6 @@ /* * 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 @@ -67,6 +68,25 @@ public interface Qualifier extends HasSemantics { */ void setType(String type); + /** + * Data type of the qualifier value. + * + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType + * + * @return Returns the DataTypeDefXsd for the property valueType. + */ + @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueType") + DataTypeDefXsd getValueType(); + + /** + * Data type of the qualifier value. + * + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType + * + * @param valueType desired value for the property valueType. + */ + void setValueType(DataTypeDefXsd valueType); + /** * The qualifier value is the value of the qualifier. * @@ -89,39 +109,20 @@ public interface Qualifier extends HasSemantics { /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueID + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueId * - * @return Returns the Reference for the property valueID. + * @return Returns the Reference for the property valueId. */ - @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueID") - Reference getValueID(); + @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueId") + Reference getValueId(); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueID + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueId * - * @param valueID desired value for the property valueID. - */ - void setValueID(Reference valueID); - - /** - * Data type of the qualifier value. - * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType - * - * @return Returns the DataTypeDefXSD for the property valueType. - */ - @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueType") - DataTypeDefXSD getValueType(); - - /** - * Data type of the qualifier value. - * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType - * - * @param valueType desired value for the property valueType. + * @param valueId desired value for the property valueId. */ - void setValueType(DataTypeDefXSD valueType); + void setValueId(Reference valueId); } 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 776c50f89..3f34d3abd 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 @@ -1,5 +1,6 @@ /* * 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 @@ -26,7 +27,7 @@ public enum QualifierKind { /** - * qualifies the semantic definition the element is referring to ('semanticID') + * qualifies the semantic definition the element is referring to ('semanticId') */ @IRI("https://admin-shell.io/aas/3/0/QualifierKind/ConceptQualifier") CONCEPT_QUALIFIER, 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 c9d70b9eb..9c9c60f51 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 @@ -1,5 +1,6 @@ /* * 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 @@ -29,23 +30,23 @@ public interface Range extends DataElement { /** - * The maximum value of the range. + * Data type of the min und max * - * More information under https://admin-shell.io/aas/3/0/Range/max + * More information under https://admin-shell.io/aas/3/0/Range/valueType * - * @return Returns the String for the property max. + * @return Returns the DataTypeDefXsd for the property valueType. */ - @IRI("https://admin-shell.io/aas/3/0/Range/max") - String getMax(); + @IRI("https://admin-shell.io/aas/3/0/Range/valueType") + DataTypeDefXsd getValueType(); /** - * The maximum value of the range. + * Data type of the min und max * - * More information under https://admin-shell.io/aas/3/0/Range/max + * More information under https://admin-shell.io/aas/3/0/Range/valueType * - * @param max desired value for the property max. + * @param valueType desired value for the property valueType. */ - void setMax(String max); + void setValueType(DataTypeDefXsd valueType); /** * The minimum value of the range. @@ -67,22 +68,22 @@ public interface Range extends DataElement { void setMin(String min); /** - * Data type of the min und max + * The maximum value of the range. * - * More information under https://admin-shell.io/aas/3/0/Range/valueType + * More information under https://admin-shell.io/aas/3/0/Range/max * - * @return Returns the DataTypeDefXSD for the property valueType. + * @return Returns the String for the property max. */ - @IRI("https://admin-shell.io/aas/3/0/Range/valueType") - DataTypeDefXSD getValueType(); + @IRI("https://admin-shell.io/aas/3/0/Range/max") + String getMax(); /** - * Data type of the min und max + * The maximum value of the range. * - * More information under https://admin-shell.io/aas/3/0/Range/valueType + * More information under https://admin-shell.io/aas/3/0/Range/max * - * @param valueType desired value for the property valueType. + * @param max desired value for the property max. */ - void setValueType(DataTypeDefXSD valueType); + void setMax(String max); } 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 b8a84a829..71c5e6ad8 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 @@ -1,5 +1,6 @@ /* * 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 @@ -24,8 +25,8 @@ * An element that is referable by its 'idShort'. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = Identifiable.class), - @KnownSubtypes.Type(value = SubmodelElement.class) + @KnownSubtypes.Type(value = SubmodelElement.class), + @KnownSubtypes.Type(value = Identifiable.class) }) public interface Referable extends HasExtensions { @@ -51,23 +52,25 @@ public interface Referable extends HasExtensions { void setCategory(String category); /** - * Description or comments on the element. + * In case of identifiables this attribute is a short name of the element. In case of referable this + * ID is an identifying string of the element within its name space. * - * More information under https://admin-shell.io/aas/3/0/Referable/description + * More information under https://admin-shell.io/aas/3/0/Referable/idShort * - * @return Returns the List of LangStringTextTypes for the property description. + * @return Returns the String for the property idShort. */ - @IRI("https://admin-shell.io/aas/3/0/Referable/description") - List getDescription(); + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + String getIdShort(); /** - * Description or comments on the element. + * In case of identifiables this attribute is a short name of the element. In case of referable this + * ID is an identifying string of the element within its name space. * - * More information under https://admin-shell.io/aas/3/0/Referable/description + * More information under https://admin-shell.io/aas/3/0/Referable/idShort * - * @param description desired value for the property description. + * @param idShort desired value for the property idShort. */ - void setDescription(List description); + void setIdShort(String idShort); /** * Display name. Can be provided in several languages. @@ -84,29 +87,27 @@ public interface Referable extends HasExtensions { * * More information under https://admin-shell.io/aas/3/0/Referable/displayName * - * @param displayName desired value for the property displayName. + * @param displayNames desired value for the property displayName. */ - void setDisplayName(List displayName); + void setDisplayName(List displayNames); /** - * In case of identifiables this attribute is a short name of the element. In case of referable this - * ID is an identifying string of the element within its name space. + * Description or comments on the element. * - * More information under https://admin-shell.io/aas/3/0/Referable/idShort + * More information under https://admin-shell.io/aas/3/0/Referable/description * - * @return Returns the String for the property idShort. + * @return Returns the List of LangStringTextTypes for the property description. */ - @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") - String getIdShort(); + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + List getDescription(); /** - * In case of identifiables this attribute is a short name of the element. In case of referable this - * ID is an identifying string of the element within its name space. + * Description or comments on the element. * - * More information under https://admin-shell.io/aas/3/0/Referable/idShort + * More information under https://admin-shell.io/aas/3/0/Referable/description * - * @param idShort desired value for the property idShort. + * @param descriptions desired value for the property description. */ - void setIdShort(String idShort); + void setDescription(List descriptions); } 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 e338f7e63..ee6ceffda 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 @@ -1,5 +1,6 @@ /* * 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 @@ -30,60 +31,60 @@ public interface Reference { /** - * Unique references in their name space. + * Type of the reference. * - * More information under https://admin-shell.io/aas/3/0/Reference/keys + * More information under https://admin-shell.io/aas/3/0/Reference/type * - * @return Returns the List of Keys for the property keys. + * @return Returns the ReferenceTypes for the property type. */ - @IRI("https://admin-shell.io/aas/3/0/Reference/keys") - List getKeys(); + @IRI("https://admin-shell.io/aas/3/0/Reference/type") + ReferenceTypes getType(); /** - * Unique references in their name space. + * Type of the reference. * - * More information under https://admin-shell.io/aas/3/0/Reference/keys + * More information under https://admin-shell.io/aas/3/0/Reference/type * - * @param keys desired value for the property keys. + * @param type desired value for the property type. */ - void setKeys(List keys); + void setType(ReferenceTypes type); /** - * 'semanticID' of the referenced model element ('type' = 'ModelReference'). + * 'semanticId' of the referenced model element ('type' = 'ModelReference'). * - * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticID + * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticId * - * @return Returns the Reference for the property referredSemanticID. + * @return Returns the Reference for the property referredSemanticId. */ - @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticID") - Reference getReferredSemanticID(); + @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticId") + Reference getReferredSemanticId(); /** - * 'semanticID' of the referenced model element ('type' = 'ModelReference'). + * 'semanticId' of the referenced model element ('type' = 'ModelReference'). * - * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticID + * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticId * - * @param referredSemanticID desired value for the property referredSemanticID. + * @param referredSemanticId desired value for the property referredSemanticId. */ - void setReferredSemanticID(Reference referredSemanticID); + void setReferredSemanticId(Reference referredSemanticId); /** - * Type of the reference. + * Unique references in their name space. * - * More information under https://admin-shell.io/aas/3/0/Reference/type + * More information under https://admin-shell.io/aas/3/0/Reference/keys * - * @return Returns the ReferenceTypes for the property type. + * @return Returns the List of Keys for the property keys. */ - @IRI("https://admin-shell.io/aas/3/0/Reference/type") - ReferenceTypes getType(); + @IRI("https://admin-shell.io/aas/3/0/Reference/keys") + List getKeys(); /** - * Type of the reference. + * Unique references in their name space. * - * More information under https://admin-shell.io/aas/3/0/Reference/type + * More information under https://admin-shell.io/aas/3/0/Reference/keys * - * @param type desired value for the property type. + * @param keys desired value for the property keys. */ - void setType(ReferenceTypes type); + void setKeys(List keys); } 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 f94d3b5f9..40a6de3a5 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 @@ -1,5 +1,6 @@ /* * 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 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 6182c32e0..99ded8f49 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 @@ -1,5 +1,6 @@ /* * 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 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 ab0b90430..986c78aa2 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 @@ -1,5 +1,6 @@ /* * 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 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 78e144ece..4534c1408 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 @@ -1,5 +1,6 @@ /* * 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 @@ -30,41 +31,41 @@ public interface Resource { /** - * Content type of the content of the file. + * Path and name of the resource (with file extension). * - * More information under https://admin-shell.io/aas/3/0/Resource/contentType + * More information under https://admin-shell.io/aas/3/0/Resource/path * - * @return Returns the String for the property contentType. + * @return Returns the String for the property path. */ - @IRI("https://admin-shell.io/aas/3/0/Resource/contentType") - String getContentType(); + @IRI("https://admin-shell.io/aas/3/0/Resource/path") + String getPath(); /** - * Content type of the content of the file. + * Path and name of the resource (with file extension). * - * More information under https://admin-shell.io/aas/3/0/Resource/contentType + * More information under https://admin-shell.io/aas/3/0/Resource/path * - * @param contentType desired value for the property contentType. + * @param path desired value for the property path. */ - void setContentType(String contentType); + void setPath(String path); /** - * Path and name of the resource (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/Resource/path + * More information under https://admin-shell.io/aas/3/0/Resource/contentType * - * @return Returns the String for the property path. + * @return Returns the String for the property contentType. */ - @IRI("https://admin-shell.io/aas/3/0/Resource/path") - String getPath(); + @IRI("https://admin-shell.io/aas/3/0/Resource/contentType") + String getContentType(); /** - * Path and name of the resource (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/Resource/path + * More information under https://admin-shell.io/aas/3/0/Resource/contentType * - * @param path desired value for the property path. + * @param contentType desired value for the property contentType. */ - void setPath(String path); + void setContentType(String contentType); } 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 fd90bddd3..c868e3e2b 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 @@ -1,5 +1,6 @@ /* * 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 @@ -17,50 +18,31 @@ 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.impl.DefaultSpecificAssetId; /** * A specific asset ID describes a generic supplementary identifying attribute of the asset. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = DefaultSpecificAssetID.class) + @KnownSubtypes.Type(value = DefaultSpecificAssetId.class) }) -public interface SpecificAssetID extends HasSemantics { - - /** - * The (external) subject the key belongs to or has meaning to. - * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/externalSubjectID - * - * @return Returns the Reference for the property externalSubjectID. - */ - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/externalSubjectID") - Reference getExternalSubjectID(); - - /** - * The (external) subject the key belongs to or has meaning to. - * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/externalSubjectID - * - * @param externalSubjectID desired value for the property externalSubjectID. - */ - void setExternalSubjectID(Reference externalSubjectID); +public interface SpecificAssetId extends HasSemantics { /** * Name of the identifier * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/name + * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/name * * @return Returns the String for the property name. */ - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/name") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/name") String getName(); /** * Name of the identifier * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/name + * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/name * * @param name desired value for the property name. */ @@ -69,20 +51,39 @@ public interface SpecificAssetID extends HasSemantics { /** * The value of the specific asset identifier with the corresponding name. * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/value + * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/value * * @return Returns the String for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/value") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/value") String getValue(); /** * The value of the specific asset identifier with the corresponding name. * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/value + * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/value * * @param value desired value for the property value. */ void setValue(String value); + /** + * The (external) subject the key belongs to or has meaning to. + * + * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/externalSubjectId + * + * @return Returns the Reference for the property externalSubjectId. + */ + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/externalSubjectId") + Reference getExternalSubjectId(); + + /** + * The (external) subject the key belongs to or has meaning to. + * + * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/externalSubjectId + * + * @param externalSubjectId desired value for the property externalSubjectId. + */ + void setExternalSubjectId(Reference externalSubjectId); + } 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 67ec72fe8..c71416c94 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 @@ -1,5 +1,6 @@ /* * 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 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 132c85b2d..4e8fd3266 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 @@ -1,5 +1,6 @@ /* * 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 @@ -27,7 +28,7 @@ @KnownSubtypes({ @KnownSubtypes.Type(value = DefaultSubmodel.class) }) -public interface Submodel extends HasDataSpecification, Identifiable, HasSemantics, HasKind, Qualifiable { +public interface Submodel extends HasDataSpecification, HasKind, HasSemantics, Identifiable, Qualifiable { /** * 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 new file mode 100644 index 000000000..d6ecec4c5 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java @@ -0,0 +1,133 @@ +/* + * 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. + * + * 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.impl.DefaultSubmodelDescriptor; + +import java.util.List; + +/** +*/ +@KnownSubtypes({ + @KnownSubtypes.Type(value = DefaultSubmodelDescriptor.class) +}) +public interface SubmodelDescriptor extends Descriptor { + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration + * + * @return Returns the AdministrativeInformation for the property administration. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration") + AdministrativeInformation getAdministration(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration + * + * @param administration desired value for the property administration. + */ + void setAdministration(AdministrativeInformation administration); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description + * + * @return Returns the LangStringSet for the property description. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description") + List getDescription(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description + * + * @param description desired value for the property description. + */ + void setDescription(List description); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName + * + * @return Returns the LangStringSet for the property displayName. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName") + List getDisplayName(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName + * + * @param displayName desired value for the property displayName. + */ + void setDisplayName(List displayName); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort + * + * @return Returns the String for the property idShort. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort") + String getIdShort(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort + * + * @param idShort desired value for the property idShort. + */ + void setIdShort(String idShort); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id + * + * @return Returns the String for the property id. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id") + String getId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id + * + * @param id desired value for the property id. + */ + void setId(String id); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId + * + * @return Returns the Reference for the property semanticId. + */ + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId") + Reference getSemanticId(); + + /** + * + * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId + * + * @param semanticId desired value for the property semanticId. + */ + void setSemanticId(Reference semanticId); + +} 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 8e9f1af77..5c19158d9 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 @@ -1,5 +1,6 @@ /* * 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 @@ -23,15 +24,15 @@ * A submodel element is an element suitable for the description and differentiation of assets. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = RelationshipElement.class), @KnownSubtypes.Type(value = DataElement.class), - @KnownSubtypes.Type(value = EventElement.class), @KnownSubtypes.Type(value = Capability.class), @KnownSubtypes.Type(value = Entity.class), + @KnownSubtypes.Type(value = EventElement.class), @KnownSubtypes.Type(value = Operation.class), + @KnownSubtypes.Type(value = RelationshipElement.class), @KnownSubtypes.Type(value = SubmodelElementCollection.class), @KnownSubtypes.Type(value = SubmodelElementList.class) }) -public interface SubmodelElement extends HasDataSpecification, HasSemantics, Referable, Qualifiable { +public interface SubmodelElement extends HasDataSpecification, HasSemantics, Qualifiable, Referable { } 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 ccfffd58b..2080567bd 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 @@ -1,5 +1,6 @@ /* * 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 @@ -18,7 +19,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementCollection; -import java.util.Collection; +import java.util.List; /** @@ -35,18 +36,18 @@ public interface SubmodelElementCollection extends SubmodelElement { * * More information under https://admin-shell.io/aas/3/0/SubmodelElementCollection/value * - * @return Returns the Collection of SubmodelElements for the property value. + * @return Returns the List of SubmodelElements for the property value. */ @IRI("https://admin-shell.io/aas/3/0/SubmodelElementCollection/value") - Collection getValue(); + List getValue(); /** * Submodel element contained in the collection. * * More information under https://admin-shell.io/aas/3/0/SubmodelElementCollection/value * - * @param value desired value for the property value. + * @param values desired value for the property value. */ - void setValue(Collection value); + void setValue(List values); } 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 f83b4eb55..7e94212b4 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 @@ -1,5 +1,6 @@ /* * 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 @@ -53,31 +54,31 @@ public interface SubmodelElementList extends SubmodelElement { /** * Semantic ID the submodel elements contained in the list match to. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement * - * @return Returns the Reference for the property semanticIDListElement. + * @return Returns the Reference for the property semanticIdListElement. */ - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement") - Reference getSemanticIDListElement(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement") + Reference getSemanticIdListElement(); /** * Semantic ID the submodel elements contained in the list match to. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement * - * @param semanticIDListElement desired value for the property semanticIDListElement. + * @param semanticIdListElement desired value for the property semanticIdListElement. */ - void setSemanticIDListElement(Reference semanticIDListElement); + void setSemanticIdListElement(Reference semanticIdListElement); /** * The submodel element type of the submodel elements contained in the list. * * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/typeValueListElement * - * @return Returns the AASSubmodelElements for the property typeValueListElement. + * @return Returns the AasSubmodelElements for the property typeValueListElement. */ @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/typeValueListElement") - AASSubmodelElements getTypeValueListElement(); + AasSubmodelElements getTypeValueListElement(); /** * The submodel element type of the submodel elements contained in the list. @@ -86,44 +87,44 @@ public interface SubmodelElementList extends SubmodelElement { * * @param typeValueListElement desired value for the property typeValueListElement. */ - void setTypeValueListElement(AASSubmodelElements typeValueListElement); + void setTypeValueListElement(AasSubmodelElements typeValueListElement); /** - * Submodel element contained in the list. + * The value type of the submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement * - * @return Returns the List of SubmodelElements for the property value. + * @return Returns the DataTypeDefXsd for the property valueTypeListElement. */ - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/value") - List getValue(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement") + DataTypeDefXsd getValueTypeListElement(); /** - * Submodel element contained in the list. + * The value type of the submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement * - * @param value desired value for the property value. + * @param valueTypeListElement desired value for the property valueTypeListElement. */ - void setValue(List value); + void setValueTypeListElement(DataTypeDefXsd valueTypeListElement); /** - * The value type of the submodel element contained in the list. + * Submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value * - * @return Returns the DataTypeDefXSD for the property valueTypeListElement. + * @return Returns the List of SubmodelElements for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement") - DataTypeDefXSD getValueTypeListElement(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/value") + List getValue(); /** - * The value type of the submodel element contained in the list. + * Submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value * - * @param valueTypeListElement desired value for the property valueTypeListElement. + * @param values desired value for the property value. */ - void setValueTypeListElement(DataTypeDefXSD valueTypeListElement); + void setValue(List values); } 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 3fa7f75ce..9313bc322 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 @@ -1,5 +1,6 @@ /* * 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 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 8b432070b..53d12d3bf 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 @@ -1,5 +1,6 @@ /* * 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 @@ -30,7 +31,7 @@ public interface ValueReferencePair { /** - * The value of the referenced concept definition of the value in 'valueID'. + * The value of the referenced concept definition of the value in 'valueId'. * * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/value * @@ -40,7 +41,7 @@ public interface ValueReferencePair { String getValue(); /** - * The value of the referenced concept definition of the value in 'valueID'. + * The value of the referenced concept definition of the value in 'valueId'. * * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/value * @@ -51,20 +52,20 @@ public interface ValueReferencePair { /** * Global unique id of the value. * - * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueID + * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueId * - * @return Returns the Reference for the property valueID. + * @return Returns the Reference for the property valueId. */ - @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueID") - Reference getValueID(); + @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueId") + Reference getValueId(); /** * Global unique id of the value. * - * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueID + * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueId * - * @param valueID desired value for the property valueID. + * @param valueId desired value for the property valueId. */ - void setValueID(Reference valueID); + void setValueId(Reference valueId); } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java index a16de81f0..075f2353a 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java @@ -1,5 +1,6 @@ /* * 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 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 14a7ca309..1c13de81d 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 @@ -1,5 +1,6 @@ /* * 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 diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java index 283f216a7..2090757dc 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java @@ -1,5 +1,6 @@ /* * 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 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 25ccb9399..f75faf333 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 @@ -1,5 +1,6 @@ /* * 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 @@ -25,13 +26,13 @@ public abstract class AdministrativeInformationBuilder { /** - * This function allows setting a value for creator + * This function allows setting a value for version * - * @param creator desired value to be set - * @return Builder object with new value for creator + * @param version desired value to be set + * @return Builder object with new value for version */ - public B creator(Reference creator) { - getBuildingInstance().setCreator(creator); + public B version(String version) { + getBuildingInstance().setVersion(version); return getSelf(); } @@ -47,24 +48,24 @@ public B revision(String revision) { } /** - * This function allows setting a value for templateID + * This function allows setting a value for creator * - * @param templateID desired value to be set - * @return Builder object with new value for templateID + * @param creator desired value to be set + * @return Builder object with new value for creator */ - public B templateID(String templateID) { - getBuildingInstance().setTemplateID(templateID); + public B creator(Reference creator) { + getBuildingInstance().setCreator(creator); return getSelf(); } /** - * This function allows setting a value for version + * This function allows setting a value for templateId * - * @param version desired value to be set - * @return Builder object with new value for version + * @param templateId desired value to be set + * @return Builder object with new value for templateId */ - public B version(String version) { - getBuildingInstance().setVersion(version); + public B templateId(String templateId) { + getBuildingInstance().setTemplateId(templateId); return getSelf(); } 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 663bd819f..f26548cc2 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 @@ -1,5 +1,6 @@ /* * 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 @@ -89,13 +90,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -122,46 +123,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -177,13 +189,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -208,26 +231,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/AssetAdministrationShellBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellBuilder.java index 45b103666..51e9059c1 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 @@ -1,5 +1,6 @@ /* * 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 @@ -23,24 +24,24 @@ public abstract class AssetAdministrationShellBuilder { /** - * This function allows setting a value for assetInformation + * This function allows setting a value for derivedFrom * - * @param assetInformation desired value to be set - * @return Builder object with new value for assetInformation + * @param derivedFrom desired value to be set + * @return Builder object with new value for derivedFrom */ - public B assetInformation(AssetInformation assetInformation) { - getBuildingInstance().setAssetInformation(assetInformation); + public B derivedFrom(Reference derivedFrom) { + getBuildingInstance().setDerivedFrom(derivedFrom); return getSelf(); } /** - * This function allows setting a value for derivedFrom + * This function allows setting a value for assetInformation * - * @param derivedFrom desired value to be set - * @return Builder object with new value for derivedFrom + * @param assetInformation desired value to be set + * @return Builder object with new value for assetInformation */ - public B derivedFrom(Reference derivedFrom) { - getBuildingInstance().setDerivedFrom(derivedFrom); + public B assetInformation(AssetInformation assetInformation) { + getBuildingInstance().setAssetInformation(assetInformation); return getSelf(); } @@ -122,35 +123,24 @@ public B category(String category) { } /** - * This function allows setting a value for description - * - * @param description desired value to be set - * @return Builder object with new value for description - */ - public B description(List description) { - getBuildingInstance().setDescription(description); - return getSelf(); - } - - /** - * This function allows adding a value to the List description + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } /** * This function allows setting a value for displayName * - * @param displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -166,13 +156,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } 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 new file mode 100644 index 000000000..e0b711277 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.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. All rights reserved. + * + * 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 java.util.List; + +public abstract class AssetAdministrationShellDescriptorBuilder> + extends ExtendableBuilder { + + /** + * 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 description + * + * @param description desired value to be set + * @return Builder object with new value for description + */ + public B description(List description) { + getBuildingInstance().setDescription(description); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayName desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); + 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 id property + * + * @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 assetKind property + * + * @param assetKind desired value to be set + * @return Builder object with new value for assetId + */ + public B assetKind(AssetKind assetKind) { + getBuildingInstance().setAssetKind(assetKind); + return getSelf(); + } + + /** + * This function allows setting a value for specificAssetId + * + * @param specificAssetId desired value to be set + * @return Builder object with new value for specificAssetId + */ + public B specificAssetId(SpecificAssetId specificAssetId) { + getBuildingInstance().setSpecificAssetIds(specificAssetId); + 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(Reference globalAssetId) { + getBuildingInstance().setGlobalAssetId(globalAssetId); + 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 + */ + public B submodelDescriptor(List submodelDescriptor) { + getBuildingInstance().setSubmodelDescriptor(submodelDescriptor); + 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 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(); + } +} 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 cb3798301..974bbcae2 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 @@ -1,5 +1,6 @@ /* * 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 @@ -17,7 +18,7 @@ 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.SpecificAssetId; import java.util.List; @@ -37,57 +38,57 @@ public B assetKind(AssetKind assetKind) { } /** - * This function allows setting a value for assetType + * This function allows setting a value for globalAssetId * - * @param assetType desired value to be set - * @return Builder object with new value for assetType + * @param globalAssetId desired value to be set + * @return Builder object with new value for globalAssetId */ - public B assetType(String assetType) { - getBuildingInstance().setAssetType(assetType); + public B globalAssetId(String globalAssetId) { + getBuildingInstance().setGlobalAssetId(globalAssetId); return getSelf(); } /** - * This function allows setting a value for defaultThumbnail + * This function allows setting a value for specificAssetIds * - * @param defaultThumbnail desired value to be set - * @return Builder object with new value for defaultThumbnail + * @param specificAssetIds desired value to be set + * @return Builder object with new value for specificAssetIds */ - public B defaultThumbnail(Resource defaultThumbnail) { - getBuildingInstance().setDefaultThumbnail(defaultThumbnail); + public B specificAssetIds(List specificAssetIds) { + getBuildingInstance().setSpecificAssetIds(specificAssetIds); return getSelf(); } /** - * This function allows setting a value for globalAssetID + * This function allows adding a value to the List specificAssetIds * - * @param globalAssetID desired value to be set - * @return Builder object with new value for globalAssetID + * @param specificAssetIds desired value to be added + * @return Builder object with new value for specificAssetIds */ - public B globalAssetID(String globalAssetID) { - getBuildingInstance().setGlobalAssetID(globalAssetID); + public B specificAssetIds(SpecificAssetId specificAssetIds) { + getBuildingInstance().getSpecificAssetIds().add(specificAssetIds); return getSelf(); } /** - * This function allows setting a value for specificAssetIds + * This function allows setting a value for assetType * - * @param specificAssetIds desired value to be set - * @return Builder object with new value for specificAssetIds + * @param assetType desired value to be set + * @return Builder object with new value for assetType */ - public B specificAssetIds(List specificAssetIds) { - getBuildingInstance().setSpecificAssetIds(specificAssetIds); + public B assetType(String assetType) { + getBuildingInstance().setAssetType(assetType); return getSelf(); } /** - * This function allows adding a value to the List specificAssetIds + * This function allows setting a value for defaultThumbnail * - * @param specificAssetIds desired value to be added - * @return Builder object with new value for specificAssetIds + * @param defaultThumbnail desired value to be set + * @return Builder object with new value for defaultThumbnail */ - public B specificAssetIds(SpecificAssetID specificAssetIds) { - getBuildingInstance().getSpecificAssetIds().add(specificAssetIds); + public B defaultThumbnail(Resource defaultThumbnail) { + getBuildingInstance().setDefaultThumbnail(defaultThumbnail); return getSelf(); } } 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 01edbf0a3..718767d8b 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,6 +23,17 @@ public abstract class BasicEventElementBuilder> extends ExtendableBuilder { + /** + * This function allows setting a value for observed + * + * @param observed desired value to be set + * @return Builder object with new value for observed + */ + public B observed(Reference observed) { + getBuildingInstance().setObserved(observed); + return getSelf(); + } + /** * This function allows setting a value for direction * @@ -34,24 +46,24 @@ public B direction(Direction direction) { } /** - * This function allows setting a value for lastUpdate + * This function allows setting a value for state * - * @param lastUpdate desired value to be set - * @return Builder object with new value for lastUpdate + * @param state desired value to be set + * @return Builder object with new value for state */ - public B lastUpdate(String lastUpdate) { - getBuildingInstance().setLastUpdate(lastUpdate); + public B state(StateOfEvent state) { + getBuildingInstance().setState(state); return getSelf(); } /** - * This function allows setting a value for maxInterval + * This function allows setting a value for messageTopic * - * @param maxInterval desired value to be set - * @return Builder object with new value for maxInterval + * @param messageTopic desired value to be set + * @return Builder object with new value for messageTopic */ - public B maxInterval(String maxInterval) { - getBuildingInstance().setMaxInterval(maxInterval); + public B messageTopic(String messageTopic) { + getBuildingInstance().setMessageTopic(messageTopic); return getSelf(); } @@ -67,13 +79,13 @@ public B messageBroker(Reference messageBroker) { } /** - * This function allows setting a value for messageTopic + * This function allows setting a value for lastUpdate * - * @param messageTopic desired value to be set - * @return Builder object with new value for messageTopic + * @param lastUpdate desired value to be set + * @return Builder object with new value for lastUpdate */ - public B messageTopic(String messageTopic) { - getBuildingInstance().setMessageTopic(messageTopic); + public B lastUpdate(String lastUpdate) { + getBuildingInstance().setLastUpdate(lastUpdate); return getSelf(); } @@ -89,24 +101,13 @@ public B minInterval(String minInterval) { } /** - * This function allows setting a value for observed - * - * @param observed desired value to be set - * @return Builder object with new value for observed - */ - public B observed(Reference observed) { - getBuildingInstance().setObserved(observed); - return getSelf(); - } - - /** - * This function allows setting a value for state + * This function allows setting a value for maxInterval * - * @param state desired value to be set - * @return Builder object with new value for state + * @param maxInterval desired value to be set + * @return Builder object with new value for maxInterval */ - public B state(StateOfEvent state) { - getBuildingInstance().setState(state); + public B maxInterval(String maxInterval) { + getBuildingInstance().setMaxInterval(maxInterval); return getSelf(); } @@ -133,13 +134,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -166,46 +167,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -221,13 +233,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -252,26 +275,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/BlobBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobBuilder.java index 43f20de00..6fe946097 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,24 +23,24 @@ public abstract class BlobBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for contentType + * This function allows setting a value for value * - * @param contentType desired value to be set - * @return Builder object with new value for contentType + * @param value desired value to be set + * @return Builder object with new value for value */ - public B contentType(String contentType) { - getBuildingInstance().setContentType(contentType); + public B value(byte[] value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows setting a value for value + * This function allows setting a value for contentType * - * @param value desired value to be set - * @return Builder object with new value for value + * @param contentType desired value to be set + * @return Builder object with new value for contentType */ - public B value(byte[] value) { - getBuildingInstance().setValue(value); + public B contentType(String contentType) { + getBuildingInstance().setContentType(contentType); return getSelf(); } @@ -66,13 +67,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -99,46 +100,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -154,13 +166,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -185,26 +208,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/Builder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/Builder.java index 7e27dad1f..cdc11013e 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/Builder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/Builder.java @@ -1,5 +1,6 @@ /* * 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 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 f62d73756..2264c9c68 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 @@ -1,5 +1,6 @@ /* * 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 @@ -44,13 +45,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -77,46 +78,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -132,13 +144,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -163,26 +186,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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 65e871bb3..85c3f259b 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 @@ -1,5 +1,6 @@ /* * 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 @@ -25,11 +26,11 @@ public abstract class ConceptDescriptionBuilder isCaseOf) { - getBuildingInstance().setIsCaseOf(isCaseOf); + public B isCaseOf(List isCaseOfs) { + getBuildingInstance().setIsCaseOf(isCaseOfs); return getSelf(); } @@ -100,35 +101,24 @@ public B category(String category) { } /** - * This function allows setting a value for description - * - * @param description desired value to be set - * @return Builder object with new value for description - */ - public B description(List description) { - getBuildingInstance().setDescription(description); - return getSelf(); - } - - /** - * This function allows adding a value to the List description + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } /** * This function allows setting a value for displayName * - * @param displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -144,13 +134,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } 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 d02d832fe..41ce802e4 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,58 +23,14 @@ public abstract class DataSpecificationIec61360Builder> extends ExtendableBuilder { - /** - * This function allows setting a value for dataType - * - * @param dataType desired value to be set - * @return Builder object with new value for dataType - */ - public B dataType(DataTypeIec61360 dataType) { - getBuildingInstance().setDataType(dataType); - return getSelf(); - } - - /** - * This function allows setting a value for definition - * - * @param definition desired value to be set - * @return Builder object with new value for definition - */ - public B definition(List definition) { - getBuildingInstance().setDefinition(definition); - return getSelf(); - } - - /** - * This function allows adding a value to the List definition - * - * @param definition desired value to be added - * @return Builder object with new value for definition - */ - public B definition(LangStringDefinitionTypeIec61360 definition) { - getBuildingInstance().getDefinition().add(definition); - return getSelf(); - } - - /** - * This function allows setting a value for levelType - * - * @param levelType desired value to be set - * @return Builder object with new value for levelType - */ - public B levelType(LevelType levelType) { - getBuildingInstance().setLevelType(levelType); - return getSelf(); - } - /** * This function allows setting a value for preferredName * - * @param preferredName desired value to be set + * @param preferredNames desired value to be set * @return Builder object with new value for preferredName */ - public B preferredName(List preferredName) { - getBuildingInstance().setPreferredName(preferredName); + public B preferredName(List preferredNames) { + getBuildingInstance().setPreferredName(preferredNames); return getSelf(); } @@ -91,11 +48,11 @@ public B preferredName(LangStringPreferredNameTypeIec61360 preferredName) { /** * This function allows setting a value for shortName * - * @param shortName desired value to be set + * @param shortNames desired value to be set * @return Builder object with new value for shortName */ - public B shortName(List shortName) { - getBuildingInstance().setShortName(shortName); + public B shortName(List shortNames) { + getBuildingInstance().setShortName(shortNames); return getSelf(); } @@ -110,6 +67,28 @@ public B shortName(LangStringShortNameTypeIec61360 shortName) { return getSelf(); } + /** + * This function allows setting a value for unit + * + * @param unit desired value to be set + * @return Builder object with new value for unit + */ + public B unit(String unit) { + getBuildingInstance().setUnit(unit); + return getSelf(); + } + + /** + * This function allows setting a value for unitId + * + * @param unitId desired value to be set + * @return Builder object with new value for unitId + */ + public B unitId(Reference unitId) { + getBuildingInstance().setUnitId(unitId); + return getSelf(); + } + /** * This function allows setting a value for sourceOfDefinition * @@ -133,35 +112,35 @@ public B symbol(String symbol) { } /** - * This function allows setting a value for unit + * This function allows setting a value for dataType * - * @param unit desired value to be set - * @return Builder object with new value for unit + * @param dataType desired value to be set + * @return Builder object with new value for dataType */ - public B unit(String unit) { - getBuildingInstance().setUnit(unit); + public B dataType(DataTypeIec61360 dataType) { + getBuildingInstance().setDataType(dataType); return getSelf(); } /** - * This function allows setting a value for unitID + * This function allows setting a value for definition * - * @param unitID desired value to be set - * @return Builder object with new value for unitID + * @param definitions desired value to be set + * @return Builder object with new value for definition */ - public B unitID(Reference unitID) { - getBuildingInstance().setUnitID(unitID); + public B definition(List definitions) { + getBuildingInstance().setDefinition(definitions); return getSelf(); } /** - * This function allows setting a value for value + * This function allows adding a value to the List definition * - * @param value desired value to be set - * @return Builder object with new value for value + * @param definition desired value to be added + * @return Builder object with new value for definition */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B definition(LangStringDefinitionTypeIec61360 definition) { + getBuildingInstance().getDefinition().add(definition); return getSelf(); } @@ -187,4 +166,26 @@ public B valueList(ValueList valueList) { 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(); + } + + /** + * This function allows setting a value for levelType + * + * @param levelType desired value to be set + * @return Builder object with new value for levelType + */ + public B levelType(LevelType levelType) { + getBuildingInstance().setLevelType(levelType); + return getSelf(); + } + } 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 new file mode 100644 index 000000000..85175e975 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java @@ -0,0 +1,46 @@ +/* + * 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. + * + * 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.Descriptor; +import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; + +public abstract class DescriptorBuilder> extends ExtendableBuilder { + + /** + * 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 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(); + } +} 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 f88b3561e..f92f45fe4 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 @@ -1,5 +1,6 @@ /* * 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 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 new file mode 100644 index 000000000..22c99fe99 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java @@ -0,0 +1,46 @@ +/* + * 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. + * + * 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.Endpoint; +import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; + +public abstract class EndpointBuilder> extends ExtendableBuilder { + + /** + * This function allows setting a value for interface + * + * @param interfaceValue desired value to be set + * @return Builder object with new value for interface + */ + public B withInterface(String interfaceValue) { + getBuildingInstance().setInterface(interfaceValue); + return getSelf(); + } + + /** + * This function allows setting a value for protocolInformation + * + * @param protocolInformation desired value to be set + * @return Builder object with new value for protocolInformation + */ + public B protocolInformation(ProtocolInformation protocolInformation) { + getBuildingInstance().setProtocolInformation(protocolInformation); + 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 92e516e17..fda9f062c 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 @@ -1,5 +1,6 @@ /* * 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 @@ -21,6 +22,28 @@ public abstract class EntityBuilder> extends ExtendableBuilder { + /** + * 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(SubmodelElement statements) { + getBuildingInstance().getStatements().add(statements); + return getSelf(); + } + /** * This function allows setting a value for entityType * @@ -33,13 +56,13 @@ public B entityType(EntityType entityType) { } /** - * This function allows setting a value for globalAssetID + * This function allows setting a value for globalAssetId * - * @param globalAssetID desired value to be set - * @return Builder object with new 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); + public B globalAssetId(String globalAssetId) { + getBuildingInstance().setGlobalAssetId(globalAssetId); return getSelf(); } @@ -49,7 +72,7 @@ public B globalAssetID(String globalAssetID) { * @param specificAssetIds desired value to be set * @return Builder object with new value for specificAssetIds */ - public B specificAssetIds(List specificAssetIds) { + public B specificAssetIds(List specificAssetIds) { getBuildingInstance().setSpecificAssetIds(specificAssetIds); return getSelf(); } @@ -60,33 +83,11 @@ public B specificAssetIds(List specificAssetIds) { * @param specificAssetIds desired value to be added * @return Builder object with new value for specificAssetIds */ - public B specificAssetIds(SpecificAssetID specificAssetIds) { + public B specificAssetIds(SpecificAssetId 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(SubmodelElement statements) { - getBuildingInstance().getStatements().add(statements); - return getSelf(); - } - /** * This function allows setting a value for embeddedDataSpecifications * @@ -110,13 +111,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -143,46 +144,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @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 + * + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } /** * This function allows setting a value for displayName * - * @param displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -198,13 +210,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -229,26 +252,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/EnvironmentBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EnvironmentBuilder.java index d33b72b90..60288ffc2 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 @@ -1,5 +1,6 @@ /* * 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 @@ -47,46 +48,46 @@ public B assetAdministrationShells(AssetAdministrationShell assetAdministrationS } /** - * This function allows setting a value for conceptDescriptions + * This function allows setting a value for submodels * - * @param conceptDescriptions desired value to be set - * @return Builder object with new value for conceptDescriptions + * @param submodels desired value to be set + * @return Builder object with new value for submodels */ - public B conceptDescriptions(List conceptDescriptions) { - getBuildingInstance().setConceptDescriptions(conceptDescriptions); + public B submodels(List submodels) { + getBuildingInstance().setSubmodels(submodels); return getSelf(); } /** - * This function allows adding a value to the List conceptDescriptions + * This function allows adding a value to the List submodels * - * @param conceptDescriptions desired value to be added - * @return Builder object with new value for conceptDescriptions + * @param submodels desired value to be added + * @return Builder object with new value for submodels */ - public B conceptDescriptions(ConceptDescription conceptDescriptions) { - getBuildingInstance().getConceptDescriptions().add(conceptDescriptions); + public B submodels(Submodel submodels) { + getBuildingInstance().getSubmodels().add(submodels); return getSelf(); } /** - * This function allows setting a value for submodels + * This function allows setting a value for conceptDescriptions * - * @param submodels desired value to be set - * @return Builder object with new value for submodels + * @param conceptDescriptions desired value to be set + * @return Builder object with new value for conceptDescriptions */ - public B submodels(List submodels) { - getBuildingInstance().setSubmodels(submodels); + public B conceptDescriptions(List conceptDescriptions) { + getBuildingInstance().setConceptDescriptions(conceptDescriptions); return getSelf(); } /** - * This function allows adding a value to the List submodels + * This function allows adding a value to the List conceptDescriptions * - * @param submodels desired value to be added - * @return Builder object with new value for submodels + * @param conceptDescriptions desired value to be added + * @return Builder object with new value for conceptDescriptions */ - public B submodels(Submodel submodels) { - getBuildingInstance().getSubmodels().add(submodels); + public B conceptDescriptions(ConceptDescription conceptDescriptions) { + getBuildingInstance().getConceptDescriptions().add(conceptDescriptions); return getSelf(); } } 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 d00833379..b3e691032 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,68 +23,68 @@ public abstract class EventPayloadBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for observableReference + * This function allows setting a value for source * - * @param observableReference desired value to be set - * @return Builder object with new value for observableReference + * @param source desired value to be set + * @return Builder object with new value for source */ - public B observableReference(Reference observableReference) { - getBuildingInstance().setObservableReference(observableReference); + public B source(Reference source) { + getBuildingInstance().setSource(source); return getSelf(); } /** - * This function allows setting a value for observableSemanticID + * This function allows setting a value for sourceSemanticId * - * @param observableSemanticID desired value to be set - * @return Builder object with new value for observableSemanticID + * @param sourceSemanticId desired value to be set + * @return Builder object with new value for sourceSemanticId */ - public B observableSemanticID(Reference observableSemanticID) { - getBuildingInstance().setObservableSemanticID(observableSemanticID); + public B sourceSemanticId(Reference sourceSemanticId) { + getBuildingInstance().setSourceSemanticId(sourceSemanticId); return getSelf(); } /** - * This function allows setting a value for payload + * This function allows setting a value for observableReference * - * @param payload desired value to be set - * @return Builder object with new value for payload + * @param observableReference desired value to be set + * @return Builder object with new value for observableReference */ - public B payload(byte[] payload) { - getBuildingInstance().setPayload(payload); + public B observableReference(Reference observableReference) { + getBuildingInstance().setObservableReference(observableReference); return getSelf(); } /** - * This function allows setting a value for source + * This function allows setting a value for observableSemanticId * - * @param source desired value to be set - * @return Builder object with new value for source + * @param observableSemanticId desired value to be set + * @return Builder object with new value for observableSemanticId */ - public B source(Reference source) { - getBuildingInstance().setSource(source); + public B observableSemanticId(Reference observableSemanticId) { + getBuildingInstance().setObservableSemanticId(observableSemanticId); return getSelf(); } /** - * This function allows setting a value for sourceSemanticID + * This function allows setting a value for topic * - * @param sourceSemanticID desired value to be set - * @return Builder object with new value for sourceSemanticID + * @param topic desired value to be set + * @return Builder object with new value for topic */ - public B sourceSemanticID(Reference sourceSemanticID) { - getBuildingInstance().setSourceSemanticID(sourceSemanticID); + public B topic(String topic) { + getBuildingInstance().setTopic(topic); return getSelf(); } /** - * This function allows setting a value for subjectID + * This function allows setting a value for subjectId * - * @param subjectID desired value to be set - * @return Builder object with new value for subjectID + * @param subjectId desired value to be set + * @return Builder object with new value for subjectId */ - public B subjectID(Reference subjectID) { - getBuildingInstance().setSubjectID(subjectID); + public B subjectId(Reference subjectId) { + getBuildingInstance().setSubjectId(subjectId); return getSelf(); } @@ -99,13 +100,13 @@ public B timeStamp(String timeStamp) { } /** - * This function allows setting a value for topic + * This function allows setting a value for payload * - * @param topic desired value to be set - * @return Builder object with new value for topic + * @param payload desired value to be set + * @return Builder object with new value for payload */ - public B topic(String topic) { - getBuildingInstance().setTopic(topic); + public B payload(byte[] payload) { + getBuildingInstance().setPayload(payload); return getSelf(); } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java index 57cf35007..f11f39f72 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java @@ -1,5 +1,6 @@ /* * 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 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 bff2490ca..d6dc6f4b4 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,7 +15,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.Extension; import org.eclipse.digitaltwin.aas4j.v3.model.Reference; @@ -35,57 +36,57 @@ public B name(String name) { } /** - * This function allows setting a value for refersTo + * This function allows setting a value for valueType * - * @param refersTo desired value to be set - * @return Builder object with new value for refersTo + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B refersTo(List refersTo) { - getBuildingInstance().setRefersTo(refersTo); + public B valueType(DataTypeDefXsd valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } /** - * This function allows adding a value to the List refersTo + * This function allows setting a value for value * - * @param refersTo desired value to be added - * @return Builder object with new value for refersTo + * @param value desired value to be set + * @return Builder object with new value for value */ - public B refersTo(Reference refersTo) { - getBuildingInstance().getRefersTo().add(refersTo); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows setting a value for value + * This function allows setting a value for refersTo * - * @param value desired value to be set - * @return Builder object with new value for value + * @param refersTos desired value to be set + * @return Builder object with new value for refersTo */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B refersTo(List refersTos) { + getBuildingInstance().setRefersTo(refersTos); return getSelf(); } /** - * This function allows setting a value for valueType + * This function allows adding a value to the List refersTo * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param refersTo desired value to be added + * @return Builder object with new value for refersTo */ - public B valueType(DataTypeDefXSD valueType) { - getBuildingInstance().setValueType(valueType); + public B refersTo(Reference refersTo) { + getBuildingInstance().getRefersTo().add(refersTo); return getSelf(); } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } 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 347317d65..4bca2a16f 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,24 +23,24 @@ public abstract class FileBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for contentType + * This function allows setting a value for value * - * @param contentType desired value to be set - * @return Builder object with new value for contentType + * @param value desired value to be set + * @return Builder object with new value for value */ - public B contentType(String contentType) { - getBuildingInstance().setContentType(contentType); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows setting a value for value + * This function allows setting a value for contentType * - * @param value desired value to be set - * @return Builder object with new value for value + * @param contentType desired value to be set + * @return Builder object with new value for contentType */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B contentType(String contentType) { + getBuildingInstance().setContentType(contentType); return getSelf(); } @@ -66,13 +67,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -99,46 +100,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -154,13 +166,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -185,26 +208,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/KeyBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/KeyBuilder.java index f04e9a96c..131e0ee5d 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 @@ -1,5 +1,6 @@ /* * 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 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 29b8d3f92..b6d43e28e 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 @@ -1,5 +1,6 @@ /* * 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 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 8b541147d..2df57ae9c 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 @@ -1,5 +1,6 @@ /* * 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 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 dedd6c541..685de3530 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 @@ -1,5 +1,6 @@ /* * 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 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 697ef25fc..2b37bb3d5 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 @@ -1,5 +1,6 @@ /* * 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 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 b84b045d8..55e927566 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 @@ -1,5 +1,6 @@ /* * 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 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 48246a400..47bc13d6c 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 @@ -1,5 +1,6 @@ /* * 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 @@ -20,17 +21,6 @@ public abstract class LevelTypeBuilder> 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(boolean max) { - getBuildingInstance().setMax(max); - return getSelf(); - } - /** * This function allows setting a value for min * @@ -63,4 +53,15 @@ public B typ(boolean typ) { getBuildingInstance().setTyp(typ); return getSelf(); } + + /** + * 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(boolean max) { + getBuildingInstance().setMax(max); + 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 ac14d8c29..706314092 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 @@ -1,5 +1,6 @@ /* * 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 @@ -25,11 +26,11 @@ public abstract class MultiLanguagePropertyBuilder value) { - getBuildingInstance().setValue(value); + public B value(List values) { + getBuildingInstance().setValue(values); return getSelf(); } @@ -45,13 +46,13 @@ public B value(LangStringTextType value) { } /** - * This function allows setting a value for valueID + * This function allows setting a value for valueId * - * @param valueID desired value to be set - * @return Builder object with new value for valueID + * @param valueId desired value to be set + * @return Builder object with new value for valueId */ - public B valueID(Reference valueID) { - getBuildingInstance().setValueID(valueID); + public B valueId(Reference valueId) { + getBuildingInstance().setValueId(valueId); return getSelf(); } @@ -78,13 +79,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -111,46 +112,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -166,13 +178,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -197,26 +220,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/OperationBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationBuilder.java index 767c3bd8e..8c8b23f59 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 @@ -1,5 +1,6 @@ /* * 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 @@ -21,28 +22,6 @@ public abstract class OperationBuilder> extends ExtendableBuilder { - /** - * This function allows setting a value for inoutputVariables - * - * @param inoutputVariables desired value to be set - * @return Builder object with new value for inoutputVariables - */ - public B inoutputVariables(List inoutputVariables) { - getBuildingInstance().setInoutputVariables(inoutputVariables); - return getSelf(); - } - - /** - * This function allows adding a value to the List inoutputVariables - * - * @param inoutputVariables desired value to be added - * @return Builder object with new value for inoutputVariables - */ - public B inoutputVariables(OperationVariable inoutputVariables) { - getBuildingInstance().getInoutputVariables().add(inoutputVariables); - return getSelf(); - } - /** * This function allows setting a value for inputVariables * @@ -87,6 +66,28 @@ public B outputVariables(OperationVariable outputVariables) { return getSelf(); } + /** + * This function allows setting a value for inoutputVariables + * + * @param inoutputVariables desired value to be set + * @return Builder object with new value for inoutputVariables + */ + public B inoutputVariables(List inoutputVariables) { + getBuildingInstance().setInoutputVariables(inoutputVariables); + return getSelf(); + } + + /** + * This function allows adding a value to the List inoutputVariables + * + * @param inoutputVariables desired value to be added + * @return Builder object with new value for inoutputVariables + */ + public B inoutputVariables(OperationVariable inoutputVariables) { + getBuildingInstance().getInoutputVariables().add(inoutputVariables); + return getSelf(); + } + /** * This function allows setting a value for embeddedDataSpecifications * @@ -110,13 +111,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -143,46 +144,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @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 + * + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } /** * This function allows setting a value for displayName * - * @param displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -198,13 +210,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -229,26 +252,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/OperationVariableBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationVariableBuilder.java index 790ee3960..cddb89a47 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 @@ -1,5 +1,6 @@ /* * 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 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 234ebf561..9ceee2daa 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,35 +23,35 @@ public abstract class PropertyBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for value + * This function allows setting a value for valueType * - * @param value desired value to be set - * @return Builder object with new value for value + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B valueType(DataTypeDefXsd valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } /** - * This function allows setting a value for valueID + * This function allows setting a value for value * - * @param valueID desired value to be set - * @return Builder object with new value for valueID + * @param value desired value to be set + * @return Builder object with new value for value */ - public B valueID(Reference valueID) { - getBuildingInstance().setValueID(valueID); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows setting a value for valueType + * This function allows setting a value for valueId * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param valueId desired value to be set + * @return Builder object with new value for valueId */ - public B valueType(DataTypeDefXSD valueType) { - getBuildingInstance().setValueType(valueType); + public B valueId(Reference valueId) { + getBuildingInstance().setValueId(valueId); return getSelf(); } @@ -77,13 +78,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -110,46 +111,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -165,13 +177,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -196,26 +219,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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 new file mode 100644 index 000000000..e158128d3 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java @@ -0,0 +1,88 @@ +/* + * 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. + * + * 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.ProtocolInformation; + +public abstract class ProtocolInformationBuilder> + extends ExtendableBuilder { + + /** + * This function allows setting a value for endpointAddress + * + * @param endpointAddress desired value to be set + * @return Builder object with new value for endpointAddress + */ + public B endpointAddress(String endpointAddress) { + getBuildingInstance().setEndpointAddress(endpointAddress); + return getSelf(); + } + + /** + * This function allows setting a value for endpointProtocol + * + * @param endpointProtocol desired value to be set + * @return Builder object with new value for endpointProtocol + */ + public B endpointProtocol(String endpointProtocol) { + getBuildingInstance().setEndpointProtocol(endpointProtocol); + return getSelf(); + } + + /** + * This function allows setting a value for endpointProtocolVersion + * + * @param endpointProtocolVersion desired value to be set + * @return Builder object with new value for endpointProtocolVersion + */ + public B endpointProtocolVersion(String endpointProtocolVersion) { + getBuildingInstance().setEndpointProtocolVersion(endpointProtocolVersion); + return getSelf(); + } + + /** + * This function allows setting a value for subprotocol + * + * @param subprotocol desired value to be set + * @return Builder object with new value for subprotocol + */ + public B subprotocol(String subprotocol) { + getBuildingInstance().setSubprotocol(subprotocol); + return getSelf(); + } + + /** + * This function allows setting a value for subprotocolBody + * + * @param subprotocolBody desired value to be set + * @return Builder object with new value for subprotocolBody + */ + public B subprotocolBody(String subprotocolBody) { + getBuildingInstance().setSubprotocolBody(subprotocolBody); + return getSelf(); + } + + /** + * This function allows setting a value for subprotocolBodyEncoding + * + * @param subprotocolBodyEncoding desired value to be set + * @return Builder object with new value for subprotocolBodyEncoding + */ + public B subprotocolBodyEncoding(String subprotocolBodyEncoding) { + getBuildingInstance().setSubprotocolBodyEncoding(subprotocolBodyEncoding); + return getSelf(); + } +} 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 ed8646d44..24427c217 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,7 +15,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +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; @@ -47,46 +48,46 @@ public B type(String type) { } /** - * This function allows setting a value for value + * This function allows setting a value for valueType * - * @param value desired value to be set - * @return Builder object with new value for value + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B valueType(DataTypeDefXsd valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } /** - * This function allows setting a value for valueID + * This function allows setting a value for value * - * @param valueID desired value to be set - * @return Builder object with new value for valueID + * @param value desired value to be set + * @return Builder object with new value for value */ - public B valueID(Reference valueID) { - getBuildingInstance().setValueID(valueID); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows setting a value for valueType + * This function allows setting a value for valueId * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param valueId desired value to be set + * @return Builder object with new value for valueId */ - public B valueType(DataTypeDefXSD valueType) { - getBuildingInstance().setValueType(valueType); + public B valueId(Reference valueId) { + getBuildingInstance().setValueId(valueId); return getSelf(); } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } 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 f265d1700..e9bae46c4 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 @@ -1,5 +1,6 @@ /* * 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 @@ -22,13 +23,13 @@ public abstract class RangeBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for max + * This function allows setting a value for valueType * - * @param max desired value to be set - * @return Builder object with new value for max + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B max(String max) { - getBuildingInstance().setMax(max); + public B valueType(DataTypeDefXsd valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } @@ -44,13 +45,13 @@ public B min(String min) { } /** - * This function allows setting a value for valueType + * This function allows setting a value for max * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param max desired value to be set + * @return Builder object with new value for max */ - public B valueType(DataTypeDefXSD valueType) { - getBuildingInstance().setValueType(valueType); + public B max(String max) { + getBuildingInstance().setMax(max); return getSelf(); } @@ -77,13 +78,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -110,46 +111,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -165,13 +177,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -196,26 +219,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/ReferenceBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceBuilder.java index 734afc5dc..afec436d6 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 @@ -1,5 +1,6 @@ /* * 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 @@ -24,46 +25,46 @@ public abstract class ReferenceBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for keys + * This function allows setting a value for type * - * @param keys desired value to be set - * @return Builder object with new value for keys + * @param type desired value to be set + * @return Builder object with new value for type */ - public B keys(List keys) { - getBuildingInstance().setKeys(keys); + public B type(ReferenceTypes type) { + getBuildingInstance().setType(type); return getSelf(); } /** - * This function allows adding a value to the List keys + * This function allows setting a value for referredSemanticId * - * @param keys desired value to be added - * @return Builder object with new value for keys + * @param referredSemanticId desired value to be set + * @return Builder object with new value for referredSemanticId */ - public B keys(Key keys) { - getBuildingInstance().getKeys().add(keys); + public B referredSemanticId(Reference referredSemanticId) { + getBuildingInstance().setReferredSemanticId(referredSemanticId); return getSelf(); } /** - * This function allows setting a value for referredSemanticID + * This function allows setting a value for keys * - * @param referredSemanticID desired value to be set - * @return Builder object with new value for referredSemanticID + * @param keys desired value to be set + * @return Builder object with new value for keys */ - public B referredSemanticID(Reference referredSemanticID) { - getBuildingInstance().setReferredSemanticID(referredSemanticID); + public B keys(List keys) { + getBuildingInstance().setKeys(keys); return getSelf(); } /** - * This function allows setting a value for type + * This function allows adding a value to the List keys * - * @param type desired value to be set - * @return Builder object with new value for type + * @param keys desired value to be added + * @return Builder object with new value for keys */ - public B type(ReferenceTypes type) { - getBuildingInstance().setType(type); + public B keys(Key keys) { + getBuildingInstance().getKeys().add(keys); return getSelf(); } } 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 35af6b641..a34e8526f 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 @@ -1,5 +1,6 @@ /* * 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 @@ -56,13 +57,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -89,46 +90,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -144,13 +156,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -175,26 +198,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/RelationshipElementBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementBuilder.java index 40079a339..1d6208913 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 @@ -1,5 +1,6 @@ /* * 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 @@ -67,13 +68,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -100,46 +101,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -155,13 +167,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -186,26 +209,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/ResourceBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResourceBuilder.java index 94a8f727e..9fd9b7d69 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 @@ -1,5 +1,6 @@ /* * 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 @@ -21,24 +22,24 @@ public abstract class ResourceBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for contentType + * This function allows setting a value for path * - * @param contentType desired value to be set - * @return Builder object with new value for contentType + * @param path desired value to be set + * @return Builder object with new value for path */ - public B contentType(String contentType) { - getBuildingInstance().setContentType(contentType); + public B path(String path) { + getBuildingInstance().setPath(path); return getSelf(); } /** - * This function allows setting a value for path + * This function allows setting a value for contentType * - * @param path desired value to be set - * @return Builder object with new value for path + * @param contentType desired value to be set + * @return Builder object with new value for contentType */ - public B path(String path) { - getBuildingInstance().setPath(path); + public B contentType(String contentType) { + getBuildingInstance().setContentType(contentType); 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 4db2e0991..df6998dae 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 @@ -1,5 +1,10 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. +<<<<<<< HEAD + * Copyright (c) 2023 SAP SE +======= + * Copyright (c) 2023, SAP SE or an SAP affiliate company +>>>>>>> 32df45a2ecc2825513496d22d7e5423aa8744bba * * 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,25 +20,14 @@ 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 org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; import java.util.List; -public abstract class SpecificAssetIDBuilder> +public abstract class SpecificAssetIdBuilder> extends ExtendableBuilder { - /** - * This function allows setting a value for externalSubjectID - * - * @param externalSubjectID desired value to be set - * @return Builder object with new value for externalSubjectID - */ - public B externalSubjectID(Reference externalSubjectID) { - getBuildingInstance().setExternalSubjectID(externalSubjectID); - return getSelf(); - } - /** * This function allows setting a value for name * @@ -57,13 +51,24 @@ public B value(String value) { } /** - * This function allows setting a value for semanticID + * This function allows setting a value for externalSubjectId + * + * @param externalSubjectId desired value to be set + * @return Builder object with new value for externalSubjectId + */ + public B externalSubjectId(Reference externalSubjectId) { + getBuildingInstance().setExternalSubjectId(externalSubjectId); + 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 + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId */ - public B semanticID(Reference semanticID) { - getBuildingInstance().setSemanticID(semanticID); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } 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 583367d60..9b5b784b5 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 @@ -1,5 +1,6 @@ /* * 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 @@ -66,79 +67,79 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for administration + * This function allows setting a value for kind * - * @param administration desired value to be set - * @return Builder object with new value for administration + * @param kind desired value to be set + * @return Builder object with new value for kind */ - public B administration(AdministrativeInformation administration) { - getBuildingInstance().setAdministration(administration); + public B kind(ModellingKind kind) { + getBuildingInstance().setKind(kind); return getSelf(); } /** - * This function allows setting a value for id + * This function allows setting a value for semanticId * - * @param id desired value to be set - * @return Builder object with new value for id + * @param semanticId desired value to be set + * @return Builder object with new value for semanticId */ - public B id(String id) { - getBuildingInstance().setId(id); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for supplementalSemanticIds * - * @param category desired value to be set - * @return Builder object with new value for category + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List supplementalSemanticIds * - * @param description desired value to be set - * @return Builder object with new value for description + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for administration * - * @param description desired value to be added - * @return Builder object with new value for description + * @param administration desired value to be set + * @return Builder object with new value for administration */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B administration(AdministrativeInformation administration) { + getBuildingInstance().setAdministration(administration); return getSelf(); } /** - * This function allows setting a value for displayName + * This function allows setting a value for id * - * @param displayName desired value to be set - * @return Builder object with new value for displayName + * @param id desired value to be set + * @return Builder object with new value for id */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B id(String id) { + getBuildingInstance().setId(id); return getSelf(); } /** - * This function allows adding a value to the List displayName + * This function allows setting a value for category * - * @param displayName desired value to be added - * @return Builder object with new value for displayName + * @param category desired value to be set + * @return Builder object with new value for category */ - public B displayName(LangStringNameType displayName) { - getBuildingInstance().getDisplayName().add(displayName); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } @@ -154,68 +155,68 @@ public B idShort(String idShort) { } /** - * This function allows setting a value for extensions + * This function allows setting a value for displayName * - * @param extensions desired value to be set - * @return Builder object with new value for extensions + * @param displayNames desired value to be set + * @return Builder object with new value for displayName */ - public B extensions(List extensions) { - getBuildingInstance().setExtensions(extensions); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } /** - * This function allows adding a value to the List extensions + * This function allows adding a value to the List displayName * - * @param extensions desired value to be added - * @return Builder object with new value for extensions + * @param displayName desired value to be added + * @return Builder object with new value for displayName */ - public B extensions(Extension extensions) { - getBuildingInstance().getExtensions().add(extensions); + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); return getSelf(); } /** - * This function allows setting a value for semanticID + * This function allows setting a value for description * - * @param semanticID desired value to be set - * @return Builder object with new value for semanticID + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B semanticID(Reference semanticID) { - getBuildingInstance().setSemanticID(semanticID); + public B description(List descriptions) { + getBuildingInstance().setDescription(descriptions); return getSelf(); } /** - * This function allows setting a value for supplementalSemanticIds + * This function allows adding a value to the List description * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds + * @param description desired value to be added + * @return Builder object with new value for description */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); return getSelf(); } /** - * This function allows adding a value to the List supplementalSemanticIds + * This function allows setting a value for extensions * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds + * @param extensions desired value to be set + * @return Builder object with new value for extensions */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); return getSelf(); } /** - * This function allows setting a value for kind + * This function allows adding a value to the List extensions * - * @param kind desired value to be set - * @return Builder object with new value for kind + * @param extensions desired value to be added + * @return Builder object with new value for extensions */ - public B kind(ModellingKind kind) { - getBuildingInstance().setKind(kind); + 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/SubmodelDescriptorBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java new file mode 100644 index 000000000..ae034da25 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java @@ -0,0 +1,117 @@ +/* + * 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. + * + * 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.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; + +public abstract class SubmodelDescriptorBuilder> + extends ExtendableBuilder { + + /** + * 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 description + * + * @param description desired value to be set + * @return Builder object with new value for description + */ + public B description(List description) { + getBuildingInstance().setDescription(description); + return getSelf(); + } + + /** + * This function allows setting a value for displayName + * + * @param displayName desired value to be set + * @return Builder object with new value for displayName + */ + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); + 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 identification + * + * @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 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 endpoints + * + * @param endpoints desired value to be set + * @return Builder object with new value for endpoints + */ + 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(); + } +} 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 44b318ea5..ec1010f09 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 @@ -1,5 +1,6 @@ /* * 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 @@ -16,7 +17,6 @@ import org.eclipse.digitaltwin.aas4j.v3.model.*; -import java.util.Collection; import java.util.List; @@ -25,12 +25,12 @@ public abstract class SubmodelElementCollectionBuilder value) { - getBuildingInstance().setValue(value); + public B value(List values) { + getBuildingInstance().setValue(values); return getSelf(); } @@ -68,13 +68,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -101,46 +101,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -156,13 +167,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -187,26 +209,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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 c81241e0a..f52ed9b36 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 @@ -1,5 +1,6 @@ /* * 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 @@ -34,13 +35,13 @@ public B orderRelevant(boolean orderRelevant) { } /** - * This function allows setting a value for semanticIDListElement + * This function allows setting a value for semanticIdListElement * - * @param semanticIDListElement desired value to be set - * @return Builder object with new 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); + public B semanticIdListElement(Reference semanticIdListElement) { + getBuildingInstance().setSemanticIdListElement(semanticIdListElement); return getSelf(); } @@ -50,41 +51,41 @@ public B semanticIDListElement(Reference semanticIDListElement) { * @param typeValueListElement desired value to be set * @return Builder object with new value for typeValueListElement */ - public B typeValueListElement(AASSubmodelElements typeValueListElement) { + public B typeValueListElement(AasSubmodelElements typeValueListElement) { getBuildingInstance().setTypeValueListElement(typeValueListElement); return getSelf(); } /** - * This function allows setting a value for value + * This function allows setting a value for valueTypeListElement * - * @param value desired value to be set - * @return Builder object with new value for value + * @param valueTypeListElement desired value to be set + * @return Builder object with new value for valueTypeListElement */ - public B value(List value) { - getBuildingInstance().setValue(value); + public B valueTypeListElement(DataTypeDefXsd valueTypeListElement) { + getBuildingInstance().setValueTypeListElement(valueTypeListElement); return getSelf(); } /** - * This function allows adding a value to the List value + * This function allows setting a value for value * - * @param value desired value to be added + * @param values desired value to be set * @return Builder object with new value for value */ - public B value(SubmodelElement value) { - getBuildingInstance().getValue().add(value); + public B value(List values) { + getBuildingInstance().setValue(values); return getSelf(); } /** - * This function allows setting a value for valueTypeListElement + * This function allows adding a value to the List value * - * @param valueTypeListElement desired value to be set - * @return Builder object with new value for valueTypeListElement + * @param value desired value to be added + * @return Builder object with new value for value */ - public B valueTypeListElement(DataTypeDefXSD valueTypeListElement) { - getBuildingInstance().setValueTypeListElement(valueTypeListElement); + public B value(SubmodelElement value) { + getBuildingInstance().getValue().add(value); return getSelf(); } @@ -111,13 +112,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticID + * This function allows setting a value for semanticId * - * @param semanticID desired value to be set - * @return Builder object with new 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); + public B semanticId(Reference semanticId) { + getBuildingInstance().setSemanticId(semanticId); return getSelf(); } @@ -144,46 +145,57 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * This function allows setting a value for category + * This function allows setting a value for qualifiers * - * @param category desired value to be set - * @return Builder object with new value for category + * @param qualifiers desired value to be set + * @return Builder object with new value for qualifiers */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B qualifiers(List qualifiers) { + getBuildingInstance().setQualifiers(qualifiers); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List qualifiers * - * @param description desired value to be set - * @return Builder object with new value for description + * @param qualifiers desired value to be added + * @return Builder object with new value for qualifiers */ - public B description(List description) { - getBuildingInstance().setDescription(description); + public B qualifiers(Qualifier qualifiers) { + getBuildingInstance().getQualifiers().add(qualifiers); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for category * - * @param description desired value to be added - * @return Builder object with new value for description + * @param category desired value to be set + * @return Builder object with new value for category */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + 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 displayName desired value to be set + * @param displayNames desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); + public B displayName(List displayNames) { + getBuildingInstance().setDisplayName(displayNames); return getSelf(); } @@ -199,13 +211,24 @@ public B displayName(LangStringNameType displayName) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param descriptions desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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(); } @@ -230,26 +253,4 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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 3cc977501..5050fe0a7 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 @@ -1,5 +1,6 @@ /* * 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 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 a3589053e..8dfb746d3 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 @@ -1,5 +1,6 @@ /* * 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 @@ -34,13 +35,13 @@ public B value(String value) { } /** - * This function allows setting a value for valueID + * This function allows setting a value for valueId * - * @param valueID desired value to be set - * @return Builder object with new value for valueID + * @param valueId desired value to be set + * @return Builder object with new value for valueId */ - public B valueID(Reference valueID) { - getBuildingInstance().setValueID(valueID); + public B valueId(Reference valueId) { + getBuildingInstance().setValueId(valueId); return getSelf(); } } 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 236a00239..e13dbd853 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 @@ -1,5 +1,6 @@ /* * 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 @@ -41,8 +42,8 @@ public class DefaultAdministrativeInformation implements AdministrativeInformati @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/revision") protected String revision; - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID") - protected String templateID; + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId") + protected String templateId; @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/version") protected String version; @@ -50,16 +51,14 @@ public class DefaultAdministrativeInformation implements AdministrativeInformati @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") protected List embeddedDataSpecifications = new ArrayList<>(); - public DefaultAdministrativeInformation() { - - } + public DefaultAdministrativeInformation() {} @Override public int hashCode() { - return Objects.hash(this.creator, + return Objects.hash(this.version, this.revision, - this.templateID, - this.version, + this.creator, + this.templateId, this.embeddedDataSpecifications); } @@ -73,22 +72,22 @@ public boolean equals(Object obj) { return false; } else { DefaultAdministrativeInformation other = (DefaultAdministrativeInformation) obj; - return Objects.equals(this.creator, other.creator) && + return Objects.equals(this.version, other.version) && Objects.equals(this.revision, other.revision) && - Objects.equals(this.templateID, other.templateID) && - Objects.equals(this.version, other.version) && + Objects.equals(this.creator, other.creator) && + Objects.equals(this.templateId, other.templateId) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications); } } @Override - public Reference getCreator() { - return creator; + public String getVersion() { + return version; } @Override - public void setCreator(Reference creator) { - this.creator = creator; + public void setVersion(String version) { + this.version = version; } @Override @@ -102,23 +101,23 @@ public void setRevision(String revision) { } @Override - public String getTemplateID() { - return templateID; + public Reference getCreator() { + return creator; } @Override - public void setTemplateID(String templateID) { - this.templateID = templateID; + public void setCreator(Reference creator) { + this.creator = creator; } @Override - public String getVersion() { - return version; + public String getTemplateId() { + return templateId; } @Override - public void setVersion(String version) { - this.version = version; + public void setTemplateId(String templateId) { + this.templateId = templateId; } @Override @@ -131,6 +130,16 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } + public String toString() { + return String.format( + "DefaultAdministrativeInformation (" + "version=%s," + + "revision=%s," + + "creator=%s," + + "templateId=%s," + + ")", + this.version, this.revision, this.creator, this.templateId); + } + /** * This builder class can be used to construct a DefaultAdministrativeInformation bean. */ 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 722d4ab26..7e8ed7c90 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 @@ -1,5 +1,6 @@ /* * 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 @@ -43,8 +44,8 @@ public class DefaultAnnotatedRelationshipElement implements AnnotatedRelationshi @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -70,9 +71,7 @@ public class DefaultAnnotatedRelationshipElement implements AnnotatedRelationshi @IRI("https://admin-shell.io/aas/3/0/RelationshipElement/second") protected Reference second; - public DefaultAnnotatedRelationshipElement() { - - } + public DefaultAnnotatedRelationshipElement() {} @Override public int hashCode() { @@ -80,14 +79,14 @@ public int hashCode() { this.first, this.second, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -104,14 +103,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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @@ -156,13 +155,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -175,6 +174,16 @@ 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; @@ -186,13 +195,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -201,18 +210,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -225,14 +234,11 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultAnnotatedRelationshipElement (" + "annotations=%s," + + ")", + this.annotations); } /** 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 f9d5a7d03..1cc73cb62 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,21 +15,14 @@ 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.AdministrativeInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; -import org.eclipse.digitaltwin.aas4j.v3.model.AssetInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.EmbeddedDataSpecification; -import org.eclipse.digitaltwin.aas4j.v3.model.Extension; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringNameType; -import org.eclipse.digitaltwin.aas4j.v3.model.LangStringTextType; -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.AssetAdministrationShellBuilder; - /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell @@ -72,21 +66,20 @@ public class DefaultAssetAdministrationShell implements AssetAdministrationShell @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultAssetAdministrationShell() { - } + public DefaultAssetAdministrationShell() {} @Override public int hashCode() { - return Objects.hash(this.assetInformation, - this.derivedFrom, + return Objects.hash(this.derivedFrom, + this.assetInformation, this.submodels, this.embeddedDataSpecifications, this.administration, this.id, this.category, - this.description, - this.displayName, this.idShort, + this.displayName, + this.description, this.extensions); } @@ -100,38 +93,38 @@ public boolean equals(Object obj) { return false; } else { DefaultAssetAdministrationShell other = (DefaultAssetAdministrationShell) obj; - return Objects.equals(this.assetInformation, other.assetInformation) && - Objects.equals(this.derivedFrom, other.derivedFrom) && + 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.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && Objects.equals(this.extensions, other.extensions); } } @Override - public AssetInformation getAssetInformation() { - return assetInformation; + public Reference getDerivedFrom() { + return derivedFrom; } @Override - public void setAssetInformation(AssetInformation assetInformation) { - this.assetInformation = assetInformation; + public void setDerivedFrom(Reference derivedFrom) { + this.derivedFrom = derivedFrom; } @Override - public Reference getDerivedFrom() { - return derivedFrom; + public AssetInformation getAssetInformation() { + return assetInformation; } @Override - public void setDerivedFrom(Reference derivedFrom) { - this.derivedFrom = derivedFrom; + public void setAssetInformation(AssetInformation assetInformation) { + this.assetInformation = assetInformation; } @Override @@ -185,13 +178,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -200,18 +193,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -224,6 +217,15 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + public String toString() { + return String.format( + "DefaultAssetAdministrationShell (" + "derivedFrom=%s," + + "assetInformation=%s," + + "submodels=%s," + + ")", + this.derivedFrom, this.assetInformation, this.submodels); + } + /** * This builder class can be used to construct a DefaultAssetAdministrationShell bean. */ 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 new file mode 100644 index 000000000..dba5ce9e2 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java @@ -0,0 +1,216 @@ +/* + * 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. + * + * 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 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; + +@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") + 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/RC02/AssetAdministrationShellDescriptor/displayName") + protected List displayName; + + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/id") + protected String id; + + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind") + protected AssetKind assetKind; + + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId") + protected Reference globalAssetId; + + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds") + protected SpecificAssetId specificAssetId; + + @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor") + protected List submodelDescriptor; + + + public DefaultAssetAdministrationShellDescriptor() { + } + + @Override + public int hashCode() { + return Objects.hash(this.administration, + this.description, + this.displayName, + this.idShort, + this.id, + this.globalAssetId, + this.specificAssetId, + this.submodelDescriptor, + this.endpoints); + } + + @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 { + DefaultAssetAdministrationShellDescriptor other = (DefaultAssetAdministrationShellDescriptor) obj; + return Objects.equals(this.administration, other.administration) && + Objects.equals(this.description, other.description) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.id, other.id) && + Objects.equals(this.assetKind, other.assetKind) && + Objects.equals(this.globalAssetId, other.globalAssetId) && + Objects.equals(this.specificAssetId, other.specificAssetId) && + Objects.equals(this.submodelDescriptor, other.submodelDescriptor) && + Objects.equals(this.endpoints, other.endpoints); + } + } + + @Override + public AdministrativeInformation getAdministration() { + return administration; + } + + @Override + public void setAdministration(AdministrativeInformation administration) { + this.administration = administration; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List description) { + this.description = description; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayName) { + this.displayName = displayName; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + + @Override + public AssetKind getAssetKind() { + return assetKind; + } + + @Override + public void setAssetKind(AssetKind assetKind) { + this.assetKind = assetKind; + } + + @Override + public Reference getGlobalAssetId() { + return globalAssetId; + } + + @Override + public void setGlobalAssetId(Reference globalAssetId) { + this.globalAssetId = globalAssetId; + } + + @Override + public SpecificAssetId getSpecificAssetIds() { + return specificAssetId; + } + + @Override + public void setSpecificAssetIds(SpecificAssetId specificAssetId) { + this.specificAssetId = specificAssetId; + } + + @Override + public List getSubmodelDescriptor() { + return submodelDescriptor; + } + + @Override + public void setSubmodelDescriptor(List submodelDescriptor) { + this.submodelDescriptor = submodelDescriptor; + } + + + @Override + public List getEndpoints() { + return endpoints; + } + + @Override + public void setEndpoints(List endpoints) { + this.endpoints = endpoints; + } + + /** + * This builder class can be used to construct a DefaultAssetAdministrationShellDescriptor bean. + */ + public static class Builder extends AssetAdministrationShellDescriptorBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultAssetAdministrationShellDescriptor newBuildingInstance() { + return new DefaultAssetAdministrationShellDescriptor(); + } + } +} 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 ade88005b..0dbc4be34 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 @@ -1,5 +1,6 @@ /* * 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 @@ -17,7 +18,7 @@ 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.SpecificAssetId; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.builder.AssetInformationBuilder; @@ -45,23 +46,21 @@ public class DefaultAssetInformation implements AssetInformation { @IRI("https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail") protected Resource defaultThumbnail; - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID") - protected String globalAssetID; + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId") + protected String globalAssetId; @IRI("https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds") - protected List specificAssetIds = new ArrayList<>(); + protected List specificAssetIds = new ArrayList<>(); - public DefaultAssetInformation() { - - } + public DefaultAssetInformation() {} @Override public int hashCode() { return Objects.hash(this.assetKind, + this.globalAssetId, + this.specificAssetIds, this.assetType, - this.defaultThumbnail, - this.globalAssetID, - this.specificAssetIds); + this.defaultThumbnail); } @Override @@ -75,10 +74,10 @@ public boolean equals(Object obj) { } else { DefaultAssetInformation other = (DefaultAssetInformation) obj; return Objects.equals(this.assetKind, other.assetKind) && + Objects.equals(this.globalAssetId, other.globalAssetId) && + Objects.equals(this.specificAssetIds, other.specificAssetIds) && Objects.equals(this.assetType, other.assetType) && - Objects.equals(this.defaultThumbnail, other.defaultThumbnail) && - Objects.equals(this.globalAssetID, other.globalAssetID) && - Objects.equals(this.specificAssetIds, other.specificAssetIds); + Objects.equals(this.defaultThumbnail, other.defaultThumbnail); } } @@ -93,43 +92,54 @@ public void setAssetKind(AssetKind assetKind) { } @Override - public String getAssetType() { - return assetType; + public String getGlobalAssetId() { + return globalAssetId; } @Override - public void setAssetType(String assetType) { - this.assetType = assetType; + public void setGlobalAssetId(String globalAssetId) { + this.globalAssetId = globalAssetId; } @Override - public Resource getDefaultThumbnail() { - return defaultThumbnail; + public List getSpecificAssetIds() { + return specificAssetIds; } @Override - public void setDefaultThumbnail(Resource defaultThumbnail) { - this.defaultThumbnail = defaultThumbnail; + public void setSpecificAssetIds(List specificAssetIds) { + this.specificAssetIds = specificAssetIds; } @Override - public String getGlobalAssetID() { - return globalAssetID; + public String getAssetType() { + return assetType; } @Override - public void setGlobalAssetID(String globalAssetID) { - this.globalAssetID = globalAssetID; + public void setAssetType(String assetType) { + this.assetType = assetType; } @Override - public List getSpecificAssetIds() { - return specificAssetIds; + public Resource getDefaultThumbnail() { + return defaultThumbnail; } @Override - public void setSpecificAssetIds(List specificAssetIds) { - this.specificAssetIds = specificAssetIds; + public void setDefaultThumbnail(Resource defaultThumbnail) { + this.defaultThumbnail = defaultThumbnail; + } + + public String toString() { + return String.format( + "DefaultAssetInformation (" + "assetKind=%s," + + "globalAssetId=%s," + + "specificAssetIds=%s," + + "assetType=%s," + + "defaultThumbnail=%s," + + ")", + this.assetKind, this.globalAssetId, this.specificAssetIds, this.assetType, this.defaultThumbnail); } /** 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 035a2c7b0..c83be01c2 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 @@ -1,5 +1,6 @@ /* * 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 @@ -62,8 +63,8 @@ public class DefaultBasicEventElement implements BasicEventElement { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -83,29 +84,27 @@ public class DefaultBasicEventElement implements BasicEventElement { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultBasicEventElement() { - - } + public DefaultBasicEventElement() {} @Override public int hashCode() { - return Objects.hash(this.direction, - this.lastUpdate, - this.maxInterval, - this.messageBroker, + return Objects.hash(this.observed, + this.direction, + this.state, this.messageTopic, + this.messageBroker, + this.lastUpdate, this.minInterval, - this.observed, - this.state, + this.maxInterval, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -118,26 +117,36 @@ public boolean equals(Object obj) { return false; } else { DefaultBasicEventElement other = (DefaultBasicEventElement) obj; - return Objects.equals(this.direction, other.direction) && - Objects.equals(this.lastUpdate, other.lastUpdate) && - Objects.equals(this.maxInterval, other.maxInterval) && - Objects.equals(this.messageBroker, other.messageBroker) && + return Objects.equals(this.observed, other.observed) && + Objects.equals(this.direction, other.direction) && + Objects.equals(this.state, other.state) && Objects.equals(this.messageTopic, other.messageTopic) && + Objects.equals(this.messageBroker, other.messageBroker) && + Objects.equals(this.lastUpdate, other.lastUpdate) && Objects.equals(this.minInterval, other.minInterval) && - Objects.equals(this.observed, other.observed) && - Objects.equals(this.state, other.state) && + Objects.equals(this.maxInterval, other.maxInterval) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticID, other.semanticID) && + 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.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } + @Override + public Reference getObserved() { + return observed; + } + + @Override + public void setObserved(Reference observed) { + this.observed = observed; + } + @Override public Direction getDirection() { return direction; @@ -149,23 +158,23 @@ public void setDirection(Direction direction) { } @Override - public String getLastUpdate() { - return lastUpdate; + public StateOfEvent getState() { + return state; } @Override - public void setLastUpdate(String lastUpdate) { - this.lastUpdate = lastUpdate; + public void setState(StateOfEvent state) { + this.state = state; } @Override - public String getMaxInterval() { - return maxInterval; + public String getMessageTopic() { + return messageTopic; } @Override - public void setMaxInterval(String maxInterval) { - this.maxInterval = maxInterval; + public void setMessageTopic(String messageTopic) { + this.messageTopic = messageTopic; } @Override @@ -179,13 +188,13 @@ public void setMessageBroker(Reference messageBroker) { } @Override - public String getMessageTopic() { - return messageTopic; + public String getLastUpdate() { + return lastUpdate; } @Override - public void setMessageTopic(String messageTopic) { - this.messageTopic = messageTopic; + public void setLastUpdate(String lastUpdate) { + this.lastUpdate = lastUpdate; } @Override @@ -199,23 +208,13 @@ public void setMinInterval(String minInterval) { } @Override - public Reference getObserved() { - return observed; - } - - @Override - public void setObserved(Reference observed) { - this.observed = observed; - } - - @Override - public StateOfEvent getState() { - return state; + public String getMaxInterval() { + return maxInterval; } @Override - public void setState(StateOfEvent state) { - this.state = state; + public void setMaxInterval(String maxInterval) { + this.maxInterval = maxInterval; } @Override @@ -229,13 +228,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -248,6 +247,16 @@ 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; @@ -259,13 +268,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -274,18 +283,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -298,14 +307,19 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultBasicEventElement (" + "observed=%s," + + "direction=%s," + + "state=%s," + + "messageTopic=%s," + + "messageBroker=%s," + + "lastUpdate=%s," + + "minInterval=%s," + + "maxInterval=%s," + + ")", + this.observed, this.direction, this.state, this.messageTopic, this.messageBroker, this.lastUpdate, this.minInterval, + this.maxInterval); } /** 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 bcb565022..f0e59a60d 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 @@ -1,5 +1,6 @@ /* * 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 @@ -46,8 +47,8 @@ public class DefaultBlob implements Blob { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -67,23 +68,21 @@ public class DefaultBlob implements Blob { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultBlob() { - - } + public DefaultBlob() {} @Override public int hashCode() { - return Objects.hash(this.contentType, - Arrays.hashCode(this.value), + return Objects.hash(Arrays.hashCode(this.value), + this.contentType, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -96,38 +95,38 @@ public boolean equals(Object obj) { return false; } else { DefaultBlob other = (DefaultBlob) obj; - return Objects.equals(this.contentType, other.contentType) && - Arrays.equals(this.value, other.value) && + 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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @Override - public String getContentType() { - return contentType; + public byte[] getValue() { + return value; } @Override - public void setContentType(String contentType) { - this.contentType = contentType; + public void setValue(byte[] value) { + this.value = value; } @Override - public byte[] getValue() { - return value; + public String getContentType() { + return contentType; } @Override - public void setValue(byte[] value) { - this.value = value; + public void setContentType(String contentType) { + this.contentType = contentType; } @Override @@ -141,13 +140,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -160,6 +159,16 @@ 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; @@ -171,13 +180,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -186,18 +195,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -210,14 +219,12 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultBlob (" + "value=%s," + + "contentType=%s," + + ")", + this.value, this.contentType); } /** 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 77c89e298..6ca35f6bf 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 @@ -1,5 +1,6 @@ /* * 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 @@ -39,8 +40,8 @@ public class DefaultCapability implements Capability { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -60,21 +61,19 @@ public class DefaultCapability implements Capability { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultCapability() { - - } + public DefaultCapability() {} @Override public int hashCode() { return Objects.hash(this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -88,14 +87,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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @@ -110,13 +109,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -129,6 +128,16 @@ 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; @@ -140,13 +149,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -155,18 +164,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -179,14 +188,12 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } + public String toString() { + return String.format( + "DefaultCapability (" + + ")" - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + ); } /** 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 558778b24..51949170b 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 @@ -1,5 +1,6 @@ /* * 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 @@ -60,9 +61,7 @@ public class DefaultConceptDescription implements ConceptDescription { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultConceptDescription() { - - } + public DefaultConceptDescription() {} @Override public int hashCode() { @@ -71,9 +70,9 @@ public int hashCode() { this.administration, this.id, this.category, - this.description, - this.displayName, this.idShort, + this.displayName, + this.description, this.extensions); } @@ -92,9 +91,9 @@ public boolean equals(Object obj) { Objects.equals(this.administration, other.administration) && Objects.equals(this.id, other.id) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && Objects.equals(this.extensions, other.extensions); } } @@ -105,8 +104,8 @@ public List getIsCaseOf() { } @Override - public void setIsCaseOf(List isCaseOf) { - this.isCaseOf = isCaseOf; + public void setIsCaseOf(List isCaseOfs) { + this.isCaseOf = isCaseOfs; } @Override @@ -150,13 +149,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -165,18 +164,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -189,6 +188,13 @@ public void setExtensions(List extensions) { this.extensions = extensions; } + public String toString() { + return String.format( + "DefaultConceptDescription (" + "isCaseOf=%s," + + ")", + this.isCaseOf); + } + /** * This builder class can be used to construct a DefaultConceptDescription bean. */ 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 168d88f21..b772cd0a6 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 @@ -1,5 +1,6 @@ /* * 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 @@ -31,63 +32,61 @@ * lists conformant to IEC 61360. */ -@IRI("aas:DataSpecificationIEC61360") +@IRI("aas:DataSpecificationIec61360") public class DefaultDataSpecificationIec61360 implements DataSpecificationIec61360 { - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/dataType") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType") protected DataTypeIec61360 dataType; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/definition") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition") protected List definition = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType") protected LevelType levelType; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/preferredName") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName") protected List preferredName = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/shortName") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName") protected List shortName = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/sourceOfDefinition") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/sourceOfDefinition") protected String sourceOfDefinition; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/symbol") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/symbol") protected String symbol; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unit") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit") protected String unit; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unitID") - protected Reference unitID; + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId") + protected Reference unitId; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/value") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueFormat") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueFormat") protected String valueFormat; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueList") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueList") protected ValueList valueList; - public DefaultDataSpecificationIec61360() { - - } + public DefaultDataSpecificationIec61360() {} @Override public int hashCode() { - return Objects.hash(this.dataType, - this.definition, - this.levelType, - this.preferredName, + return Objects.hash(this.preferredName, this.shortName, + this.unit, + this.unitId, this.sourceOfDefinition, this.symbol, - this.unit, - this.unitID, - this.value, + this.dataType, + this.definition, this.valueFormat, - this.valueList); + this.valueList, + this.value, + this.levelType); } @Override @@ -100,69 +99,59 @@ public boolean equals(Object obj) { return false; } else { DefaultDataSpecificationIec61360 other = (DefaultDataSpecificationIec61360) obj; - return Objects.equals(this.dataType, other.dataType) && - Objects.equals(this.definition, other.definition) && - Objects.equals(this.levelType, other.levelType) && - Objects.equals(this.preferredName, other.preferredName) && + return Objects.equals(this.preferredName, other.preferredName) && Objects.equals(this.shortName, other.shortName) && + Objects.equals(this.unit, other.unit) && + Objects.equals(this.unitId, other.unitId) && Objects.equals(this.sourceOfDefinition, other.sourceOfDefinition) && Objects.equals(this.symbol, other.symbol) && - Objects.equals(this.unit, other.unit) && - Objects.equals(this.unitID, other.unitID) && - Objects.equals(this.value, other.value) && + Objects.equals(this.dataType, other.dataType) && + Objects.equals(this.definition, other.definition) && Objects.equals(this.valueFormat, other.valueFormat) && - Objects.equals(this.valueList, other.valueList); + Objects.equals(this.valueList, other.valueList) && + Objects.equals(this.value, other.value) && + Objects.equals(this.levelType, other.levelType); } } @Override - public DataTypeIec61360 getDataType() { - return dataType; - } - - @Override - public void setDataType(DataTypeIec61360 dataType) { - this.dataType = dataType; - } - - @Override - public List getDefinition() { - return definition; + public List getPreferredName() { + return preferredName; } @Override - public void setDefinition(List definition) { - this.definition = definition; + public void setPreferredName(List preferredNames) { + this.preferredName = preferredNames; } @Override - public LevelType getLevelType() { - return levelType; + public List getShortName() { + return shortName; } @Override - public void setLevelType(LevelType levelType) { - this.levelType = levelType; + public void setShortName(List shortNames) { + this.shortName = shortNames; } @Override - public List getPreferredName() { - return preferredName; + public String getUnit() { + return unit; } @Override - public void setPreferredName(List preferredName) { - this.preferredName = preferredName; + public void setUnit(String unit) { + this.unit = unit; } @Override - public List getShortName() { - return shortName; + public Reference getUnitId() { + return unitId; } @Override - public void setShortName(List shortName) { - this.shortName = shortName; + public void setUnitId(Reference unitId) { + this.unitId = unitId; } @Override @@ -186,33 +175,23 @@ public void setSymbol(String symbol) { } @Override - public String getUnit() { - return unit; - } - - @Override - public void setUnit(String unit) { - this.unit = unit; - } - - @Override - public Reference getUnitID() { - return unitID; + public DataTypeIec61360 getDataType() { + return dataType; } @Override - public void setUnitID(Reference unitID) { - this.unitID = unitID; + public void setDataType(DataTypeIec61360 dataType) { + this.dataType = dataType; } @Override - public String getValue() { - return value; + public List getDefinition() { + return definition; } @Override - public void setValue(String value) { - this.value = value; + public void setDefinition(List definitions) { + this.definition = definitions; } @Override @@ -235,6 +214,45 @@ public void setValueList(ValueList valueList) { this.valueList = valueList; } + @Override + public String getValue() { + return value; + } + + @Override + public void setValue(String value) { + this.value = value; + } + + @Override + public LevelType getLevelType() { + return levelType; + } + + @Override + public void setLevelType(LevelType levelType) { + this.levelType = levelType; + } + + public String toString() { + return String.format( + "DefaultDataSpecificationIec61360 (" + "preferredName=%s," + + "shortName=%s," + + "unit=%s," + + "unitId=%s," + + "sourceOfDefinition=%s," + + "symbol=%s," + + "dataType=%s," + + "definition=%s," + + "valueFormat=%s," + + "valueList=%s," + + "value=%s," + + "levelType=%s," + + ")", + this.preferredName, this.shortName, this.unit, this.unitId, this.sourceOfDefinition, this.symbol, this.dataType, + this.definition, this.valueFormat, this.valueList, this.value, this.levelType); + } + /** * This builder class can be used to construct a DefaultDataSpecificationIec61360 bean. */ 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 new file mode 100644 index 000000000..c1a915ca5 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.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. All rights reserved. + * + * 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 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; + +@IRI("aas:Descriptor") +public class DefaultDescriptor implements Descriptor { + + @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") + protected List endpoints = new ArrayList<>(); + + public DefaultDescriptor() { + } + + @Override + public int hashCode() { + return Objects.hash(this.endpoints); + } + + @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 { + DefaultDescriptor other = (DefaultDescriptor) obj; + return Objects.equals(this.endpoints, other.endpoints); + } + } + + @Override + public List getEndpoints() { + return endpoints; + } + + @Override + public void setEndpoints(List endpoints) { + this.endpoints = endpoints; + } + + /** + * This builder class can be used to construct a DefaultDescriptor bean. + */ + public static class Builder extends DescriptorBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultDescriptor newBuildingInstance() { + return new DefaultDescriptor(); + } + } +} 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 4d3135579..0235e810d 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 @@ -1,5 +1,6 @@ /* * 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 @@ -39,9 +40,7 @@ public class DefaultEmbeddedDataSpecification implements EmbeddedDataSpecificati @IRI("https://admin-shell.io/aas/3/0/EmbeddedDataSpecification/dataSpecificationContent") protected DataSpecificationContent dataSpecificationContent; - public DefaultEmbeddedDataSpecification() { - - } + public DefaultEmbeddedDataSpecification() {} @Override public int hashCode() { @@ -84,6 +83,14 @@ public void setDataSpecificationContent(DataSpecificationContent dataSpecificati this.dataSpecificationContent = dataSpecificationContent; } + public String toString() { + return String.format( + "DefaultEmbeddedDataSpecification (" + "dataSpecification=%s," + + "dataSpecificationContent=%s," + + ")", + this.dataSpecification, this.dataSpecificationContent); + } + /** * This builder class can be used to construct a DefaultEmbeddedDataSpecification bean. */ 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 new file mode 100644 index 000000000..648e4859d --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java @@ -0,0 +1,93 @@ +/* + * 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. + * + * 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 org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; +import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.EndpointBuilder; + +import java.util.Objects; + +@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/RC02/Endpoint/protocolInformation") + protected ProtocolInformation protocolInformation; + + public DefaultEndpoint() { + } + + @Override + public int hashCode() { + return Objects.hash(this.interfaceValue, + this.protocolInformation); + } + + @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 { + DefaultEndpoint other = (DefaultEndpoint) obj; + return Objects.equals(this.interfaceValue, other.interfaceValue) && + Objects.equals(this.protocolInformation, other.protocolInformation); + } + } + + @Override + public String getInterface() { + return interfaceValue; + } + + @Override + public void setInterface(String interfaceValue) { + this.interfaceValue = interfaceValue; + } + + @Override + public ProtocolInformation getProtocolInformation() { + return protocolInformation; + } + + @Override + public void setProtocolInformation(ProtocolInformation protocolInformation) { + this.protocolInformation = protocolInformation; + } + + /** + * This builder class can be used to construct a DefaultEndpoint bean. + */ + public static class Builder extends EndpointBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultEndpoint newBuildingInstance() { + return new DefaultEndpoint(); + } + } +} 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 e3a75f9a8..2b38425b8 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 @@ -1,5 +1,6 @@ /* * 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 @@ -35,11 +36,11 @@ public class DefaultEntity implements Entity { @IRI("https://admin-shell.io/aas/3/0/Entity/entityType") protected EntityType entityType; - @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetID") - protected String globalAssetID; + @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetId") + protected String globalAssetId; @IRI("https://admin-shell.io/aas/3/0/Entity/specificAssetIds") - protected List specificAssetIds = new ArrayList<>(); + protected List specificAssetIds = new ArrayList<>(); @IRI("https://admin-shell.io/aas/3/0/Entity/statements") protected List statements = new ArrayList<>(); @@ -50,8 +51,8 @@ public class DefaultEntity implements Entity { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -71,25 +72,23 @@ public class DefaultEntity implements Entity { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultEntity() { - - } + public DefaultEntity() {} @Override public int hashCode() { - return Objects.hash(this.entityType, - this.globalAssetID, + return Objects.hash(this.statements, + this.entityType, + this.globalAssetId, this.specificAssetIds, - this.statements, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -102,60 +101,60 @@ public boolean equals(Object obj) { return false; } else { DefaultEntity other = (DefaultEntity) obj; - return Objects.equals(this.entityType, other.entityType) && - Objects.equals(this.globalAssetID, other.globalAssetID) && + return Objects.equals(this.statements, other.statements) && + Objects.equals(this.entityType, other.entityType) && + Objects.equals(this.globalAssetId, other.globalAssetId) && Objects.equals(this.specificAssetIds, other.specificAssetIds) && - Objects.equals(this.statements, other.statements) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticID, other.semanticID) && + 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.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @Override - public EntityType getEntityType() { - return entityType; + public List getStatements() { + return statements; } @Override - public void setEntityType(EntityType entityType) { - this.entityType = entityType; + public void setStatements(List statements) { + this.statements = statements; } @Override - public String getGlobalAssetID() { - return globalAssetID; + public EntityType getEntityType() { + return entityType; } @Override - public void setGlobalAssetID(String globalAssetID) { - this.globalAssetID = globalAssetID; + public void setEntityType(EntityType entityType) { + this.entityType = entityType; } @Override - public List getSpecificAssetIds() { - return specificAssetIds; + public String getGlobalAssetId() { + return globalAssetId; } @Override - public void setSpecificAssetIds(List specificAssetIds) { - this.specificAssetIds = specificAssetIds; + public void setGlobalAssetId(String globalAssetId) { + this.globalAssetId = globalAssetId; } @Override - public List getStatements() { - return statements; + public List getSpecificAssetIds() { + return specificAssetIds; } @Override - public void setStatements(List statements) { - this.statements = statements; + public void setSpecificAssetIds(List specificAssetIds) { + this.specificAssetIds = specificAssetIds; } @Override @@ -169,13 +168,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -188,6 +187,16 @@ 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; @@ -199,13 +208,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -214,18 +223,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -238,14 +247,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultEntity (" + "statements=%s," + + "entityType=%s," + + "globalAssetId=%s," + + "specificAssetIds=%s," + + ")", + this.statements, this.entityType, this.globalAssetId, this.specificAssetIds); } /** 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 ae4b92b96..30d5f6377 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 @@ -1,5 +1,6 @@ /* * 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 @@ -44,15 +45,13 @@ public class DefaultEnvironment implements Environment { @IRI("https://admin-shell.io/aas/3/0/Environment/submodels") protected List submodels = new ArrayList<>(); - public DefaultEnvironment() { - - } + public DefaultEnvironment() {} @Override public int hashCode() { return Objects.hash(this.assetAdministrationShells, - this.conceptDescriptions, - this.submodels); + this.submodels, + this.conceptDescriptions); } @Override @@ -66,8 +65,8 @@ public boolean equals(Object obj) { } else { DefaultEnvironment other = (DefaultEnvironment) obj; return Objects.equals(this.assetAdministrationShells, other.assetAdministrationShells) && - Objects.equals(this.conceptDescriptions, other.conceptDescriptions) && - Objects.equals(this.submodels, other.submodels); + Objects.equals(this.submodels, other.submodels) && + Objects.equals(this.conceptDescriptions, other.conceptDescriptions); } } @@ -82,23 +81,32 @@ public void setAssetAdministrationShells(List assetAdm } @Override - public List getConceptDescriptions() { - return conceptDescriptions; + public List getSubmodels() { + return submodels; } @Override - public void setConceptDescriptions(List conceptDescriptions) { - this.conceptDescriptions = conceptDescriptions; + public void setSubmodels(List submodels) { + this.submodels = submodels; } @Override - public List getSubmodels() { - return submodels; + public List getConceptDescriptions() { + return conceptDescriptions; } @Override - public void setSubmodels(List submodels) { - this.submodels = submodels; + public void setConceptDescriptions(List conceptDescriptions) { + this.conceptDescriptions = conceptDescriptions; + } + + public String toString() { + return String.format( + "DefaultEnvironment (" + "assetAdministrationShells=%s," + + "submodels=%s," + + "conceptDescriptions=%s," + + ")", + this.assetAdministrationShells, this.submodels, this.conceptDescriptions); } /** 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 b775a8922..750f1c5ff 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 @@ -1,5 +1,6 @@ /* * 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 @@ -35,8 +36,8 @@ public class DefaultEventPayload implements EventPayload { @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableReference") protected Reference observableReference; - @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID") - protected Reference observableSemanticID; + @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId") + protected Reference observableSemanticId; @IRI("https://admin-shell.io/aas/3/0/EventPayload/payload") protected byte[] payload; @@ -44,11 +45,11 @@ public class DefaultEventPayload implements EventPayload { @IRI("https://admin-shell.io/aas/3/0/EventPayload/source") protected Reference source; - @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID") - protected Reference sourceSemanticID; + @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId") + protected Reference sourceSemanticId; - @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectID") - protected Reference subjectID; + @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectId") + protected Reference subjectId; @IRI("https://admin-shell.io/aas/3/0/EventPayload/timeStamp") protected String timeStamp; @@ -56,20 +57,18 @@ public class DefaultEventPayload implements EventPayload { @IRI("https://admin-shell.io/aas/3/0/EventPayload/topic") protected String topic; - public DefaultEventPayload() { - - } + public DefaultEventPayload() {} @Override public int hashCode() { - return Objects.hash(this.observableReference, - this.observableSemanticID, - Arrays.hashCode(this.payload), - this.source, - this.sourceSemanticID, - this.subjectID, + return Objects.hash(this.source, + this.sourceSemanticId, + this.observableReference, + this.observableSemanticId, + this.topic, + this.subjectId, this.timeStamp, - this.topic); + Arrays.hashCode(this.payload)); } @Override @@ -82,75 +81,75 @@ public boolean equals(Object obj) { return false; } else { DefaultEventPayload other = (DefaultEventPayload) obj; - return Objects.equals(this.observableReference, other.observableReference) && - Objects.equals(this.observableSemanticID, other.observableSemanticID) && - Arrays.equals(this.payload, other.payload) && - Objects.equals(this.source, other.source) && - Objects.equals(this.sourceSemanticID, other.sourceSemanticID) && - Objects.equals(this.subjectID, other.subjectID) && + return Objects.equals(this.source, other.source) && + Objects.equals(this.sourceSemanticId, other.sourceSemanticId) && + Objects.equals(this.observableReference, other.observableReference) && + Objects.equals(this.observableSemanticId, other.observableSemanticId) && + Objects.equals(this.topic, other.topic) && + Objects.equals(this.subjectId, other.subjectId) && Objects.equals(this.timeStamp, other.timeStamp) && - Objects.equals(this.topic, other.topic); + Arrays.equals(this.payload, other.payload); } } @Override - public Reference getObservableReference() { - return observableReference; + public Reference getSource() { + return source; } @Override - public void setObservableReference(Reference observableReference) { - this.observableReference = observableReference; + public void setSource(Reference source) { + this.source = source; } @Override - public Reference getObservableSemanticID() { - return observableSemanticID; + public Reference getSourceSemanticId() { + return sourceSemanticId; } @Override - public void setObservableSemanticID(Reference observableSemanticID) { - this.observableSemanticID = observableSemanticID; + public void setSourceSemanticId(Reference sourceSemanticId) { + this.sourceSemanticId = sourceSemanticId; } @Override - public byte[] getPayload() { - return payload; + public Reference getObservableReference() { + return observableReference; } @Override - public void setPayload(byte[] payload) { - this.payload = payload; + public void setObservableReference(Reference observableReference) { + this.observableReference = observableReference; } @Override - public Reference getSource() { - return source; + public Reference getObservableSemanticId() { + return observableSemanticId; } @Override - public void setSource(Reference source) { - this.source = source; + public void setObservableSemanticId(Reference observableSemanticId) { + this.observableSemanticId = observableSemanticId; } @Override - public Reference getSourceSemanticID() { - return sourceSemanticID; + public String getTopic() { + return topic; } @Override - public void setSourceSemanticID(Reference sourceSemanticID) { - this.sourceSemanticID = sourceSemanticID; + public void setTopic(String topic) { + this.topic = topic; } @Override - public Reference getSubjectID() { - return subjectID; + public Reference getSubjectId() { + return subjectId; } @Override - public void setSubjectID(Reference subjectID) { - this.subjectID = subjectID; + public void setSubjectId(Reference subjectId) { + this.subjectId = subjectId; } @Override @@ -164,13 +163,28 @@ public void setTimeStamp(String timeStamp) { } @Override - public String getTopic() { - return topic; + public byte[] getPayload() { + return payload; } @Override - public void setTopic(String topic) { - this.topic = topic; + public void setPayload(byte[] payload) { + this.payload = payload; + } + + public String toString() { + return String.format( + "DefaultEventPayload (" + "source=%s," + + "sourceSemanticId=%s," + + "observableReference=%s," + + "observableSemanticId=%s," + + "topic=%s," + + "subjectId=%s," + + "timeStamp=%s," + + "payload=%s," + + ")", + this.source, this.sourceSemanticId, this.observableReference, this.observableSemanticId, this.topic, this.subjectId, + this.timeStamp, this.payload); } /** 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 7f0212ad5..eb013ed1f 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,7 +15,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +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; @@ -44,25 +45,23 @@ public class DefaultExtension implements Extension { protected String value; @IRI("https://admin-shell.io/aas/3/0/Extension/valueType") - protected DataTypeDefXSD valueType; + protected DataTypeDefXsd valueType; - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticID") - protected Reference semanticID; + @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<>(); - public DefaultExtension() { - - } + public DefaultExtension() {} @Override public int hashCode() { return Objects.hash(this.name, - this.refersTo, - this.value, this.valueType, - this.semanticID, + this.value, + this.refersTo, + this.semanticId, this.supplementalSemanticIds); } @@ -77,10 +76,10 @@ public boolean equals(Object obj) { } else { DefaultExtension other = (DefaultExtension) obj; return Objects.equals(this.name, other.name) && - Objects.equals(this.refersTo, other.refersTo) && - Objects.equals(this.value, other.value) && Objects.equals(this.valueType, other.valueType) && - Objects.equals(this.semanticID, other.semanticID) && + Objects.equals(this.value, other.value) && + Objects.equals(this.refersTo, other.refersTo) && + Objects.equals(this.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds); } } @@ -96,13 +95,13 @@ public void setName(String name) { } @Override - public List getRefersTo() { - return refersTo; + public DataTypeDefXsd getValueType() { + return valueType; } @Override - public void setRefersTo(List refersTo) { - this.refersTo = refersTo; + public void setValueType(DataTypeDefXsd valueType) { + this.valueType = valueType; } @Override @@ -116,23 +115,23 @@ public void setValue(String value) { } @Override - public DataTypeDefXSD getValueType() { - return valueType; + public List getRefersTo() { + return refersTo; } @Override - public void setValueType(DataTypeDefXSD valueType) { - this.valueType = valueType; + public void setRefersTo(List refersTos) { + this.refersTo = refersTos; } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -145,6 +144,16 @@ public void setSupplementalSemanticIds(List supplementalSemanticIds) this.supplementalSemanticIds = supplementalSemanticIds; } + public String toString() { + return String.format( + "DefaultExtension (" + "name=%s," + + "valueType=%s," + + "value=%s," + + "refersTo=%s," + + ")", + this.name, this.valueType, this.value, this.refersTo); + } + /** * This builder class can be used to construct a DefaultExtension bean. */ 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 146fed567..52f767e6e 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 @@ -1,5 +1,6 @@ /* * 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 @@ -44,8 +45,8 @@ public class DefaultFile implements File { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -65,23 +66,21 @@ public class DefaultFile implements File { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultFile() { - - } + public DefaultFile() {} @Override public int hashCode() { - return Objects.hash(this.contentType, - this.value, + return Objects.hash(this.value, + this.contentType, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -94,38 +93,38 @@ public boolean equals(Object obj) { return false; } else { DefaultFile other = (DefaultFile) obj; - return Objects.equals(this.contentType, other.contentType) && - Objects.equals(this.value, other.value) && + 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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @Override - public String getContentType() { - return contentType; + public String getValue() { + return value; } @Override - public void setContentType(String contentType) { - this.contentType = contentType; + public void setValue(String value) { + this.value = value; } @Override - public String getValue() { - return value; + public String getContentType() { + return contentType; } @Override - public void setValue(String value) { - this.value = value; + public void setContentType(String contentType) { + this.contentType = contentType; } @Override @@ -139,13 +138,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -158,6 +157,16 @@ 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; @@ -169,13 +178,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -184,18 +193,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -208,14 +217,12 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultFile (" + "value=%s," + + "contentType=%s," + + ")", + this.value, this.contentType); } /** 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 d098f2840..45d6d6f7e 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 @@ -1,5 +1,6 @@ /* * 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 @@ -37,9 +38,7 @@ public class DefaultKey implements Key { @IRI("https://admin-shell.io/aas/3/0/Key/value") protected String value; - public DefaultKey() { - - } + public DefaultKey() {} @Override public int hashCode() { @@ -82,6 +81,14 @@ public void setValue(String value) { this.value = value; } + public String toString() { + return String.format( + "DefaultKey (" + "type=%s," + + "value=%s," + + ")", + this.type, this.value); + } + /** * This builder class can be used to construct a DefaultKey bean. */ 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 ed0a94c2f..4c8a473b9 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,11 +15,11 @@ 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.LangStringDefinitionTypeIec61360; /** @@ -28,7 +29,7 @@ * String with length 1023 maximum and minimum 1 characters and with language tags */ -@IRI("aas:LangStringDefinitionTypeIEC61360") +@IRI("aas:LangStringDefinitionTypeIec61360") public class DefaultLangStringDefinitionTypeIec61360 implements LangStringDefinitionTypeIec61360 { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/language") @@ -37,9 +38,7 @@ public class DefaultLangStringDefinitionTypeIec61360 implements LangStringDefini @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringDefinitionTypeIec61360() { - - } + public DefaultLangStringDefinitionTypeIec61360() {} @Override public int hashCode() { @@ -82,6 +81,14 @@ public void setText(String text) { this.text = text; } + public String toString() { + return String.format( + "DefaultLangStringDefinitionTypeIec61360 (" + + ")" + + ); + } + /** * This builder class can be used to construct a DefaultLangStringDefinitionTypeIec61360 bean. */ 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 1d165b23d..cf01867c5 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 @@ -1,5 +1,6 @@ /* * 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 @@ -36,9 +37,7 @@ public class DefaultLangStringNameType implements LangStringNameType { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringNameType() { - - } + public DefaultLangStringNameType() {} @Override public int hashCode() { @@ -81,6 +80,14 @@ public void setText(String text) { this.text = text; } + public String toString() { + return String.format( + "DefaultLangStringNameType (" + + ")" + + ); + } + /** * This builder class can be used to construct a DefaultLangStringNameType bean. */ 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 6e60307a3..40be9c6fc 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,11 +15,11 @@ 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.LangStringPreferredNameTypeIec61360; /** @@ -28,7 +29,7 @@ * String with length 255 maximum and minimum 1 characters and with language tags */ -@IRI("aas:LangStringPreferredNameTypeIEC61360") +@IRI("aas:LangStringPreferredNameTypeIec61360") public class DefaultLangStringPreferredNameTypeIec61360 implements LangStringPreferredNameTypeIec61360 { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/language") @@ -37,9 +38,7 @@ public class DefaultLangStringPreferredNameTypeIec61360 implements LangStringPre @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringPreferredNameTypeIec61360() { - - } + public DefaultLangStringPreferredNameTypeIec61360() {} @Override public int hashCode() { @@ -82,6 +81,14 @@ public void setText(String text) { this.text = text; } + public String toString() { + return String.format( + "DefaultLangStringPreferredNameTypeIec61360 (" + + ")" + + ); + } + /** * This builder class can be used to construct a DefaultLangStringPreferredNameTypeIec61360 bean. */ 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 adf213af1..f33fc73ee 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,11 +15,11 @@ 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.LangStringShortNameTypeIec61360; /** @@ -28,7 +29,7 @@ * String with length 18 maximum and minimum 1 characters and with language tags */ -@IRI("aas:LangStringShortNameTypeIEC61360") +@IRI("aas:LangStringShortNameTypeIec61360") public class DefaultLangStringShortNameTypeIec61360 implements LangStringShortNameTypeIec61360 { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/language") @@ -37,9 +38,7 @@ public class DefaultLangStringShortNameTypeIec61360 implements LangStringShortNa @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringShortNameTypeIec61360() { - - } + public DefaultLangStringShortNameTypeIec61360() {} @Override public int hashCode() { @@ -82,6 +81,14 @@ public void setText(String text) { this.text = text; } + public String toString() { + return String.format( + "DefaultLangStringShortNameTypeIec61360 (" + + ")" + + ); + } + /** * This builder class can be used to construct a DefaultLangStringShortNameTypeIec61360 bean. */ 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 90c243c77..196784d6e 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 @@ -1,5 +1,6 @@ /* * 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 @@ -36,9 +37,7 @@ public class DefaultLangStringTextType implements LangStringTextType { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringTextType() { - - } + public DefaultLangStringTextType() {} @Override public int hashCode() { @@ -81,6 +80,14 @@ public void setText(String text) { this.text = text; } + public String toString() { + return String.format( + "DefaultLangStringTextType (" + + ")" + + ); + } + /** * This builder class can be used to construct a DefaultLangStringTextType bean. */ 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 5251649b3..5cf2b4ecd 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 @@ -1,5 +1,6 @@ /* * 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 @@ -43,16 +44,14 @@ public class DefaultLevelType implements LevelType { @IRI("https://admin-shell.io/aas/3/0/LevelType/typ") protected boolean typ; - public DefaultLevelType() { - - } + public DefaultLevelType() {} @Override public int hashCode() { - return Objects.hash(this.max, - this.min, + return Objects.hash(this.min, this.nom, - this.typ); + this.typ, + this.max); } @Override @@ -65,23 +64,13 @@ public boolean equals(Object obj) { return false; } else { DefaultLevelType other = (DefaultLevelType) obj; - return Objects.equals(this.max, other.max) && - Objects.equals(this.min, other.min) && + return Objects.equals(this.min, other.min) && Objects.equals(this.nom, other.nom) && - Objects.equals(this.typ, other.typ); + Objects.equals(this.typ, other.typ) && + Objects.equals(this.max, other.max); } } - @Override - public boolean getMax() { - return max; - } - - @Override - public void setMax(boolean max) { - this.max = max; - } - @Override public boolean getMin() { return min; @@ -112,6 +101,26 @@ public void setTyp(boolean typ) { this.typ = typ; } + @Override + public boolean getMax() { + return max; + } + + @Override + public void setMax(boolean max) { + this.max = max; + } + + public String toString() { + return String.format( + "DefaultLevelType (" + "min=%s," + + "nom=%s," + + "typ=%s," + + "max=%s," + + ")", + this.min, this.nom, this.typ, this.max); + } + /** * This builder class can be used to construct a DefaultLevelType bean. */ 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 56f9cb8f7..16705fbb2 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 @@ -1,5 +1,6 @@ /* * 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 @@ -38,8 +39,8 @@ public class DefaultMultiLanguageProperty implements MultiLanguageProperty { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -47,8 +48,8 @@ public class DefaultMultiLanguageProperty implements MultiLanguageProperty { @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/value") protected List value = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID") - protected Reference valueID; + @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId") + protected Reference valueId; @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") protected List qualifiers = new ArrayList<>(); @@ -65,23 +66,21 @@ public class DefaultMultiLanguageProperty implements MultiLanguageProperty { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultMultiLanguageProperty() { - - } + public DefaultMultiLanguageProperty() {} @Override public int hashCode() { return Objects.hash(this.value, - this.valueID, + this.valueId, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -95,16 +94,16 @@ public boolean equals(Object obj) { } else { DefaultMultiLanguageProperty other = (DefaultMultiLanguageProperty) obj; return Objects.equals(this.value, other.value) && - Objects.equals(this.valueID, other.valueID) && + Objects.equals(this.valueId, other.valueId) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticID, other.semanticID) && + 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.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @@ -114,18 +113,18 @@ public List getValue() { } @Override - public void setValue(List value) { - this.value = value; + public void setValue(List values) { + this.value = values; } @Override - public Reference getValueID() { - return valueID; + public Reference getValueId() { + return valueId; } @Override - public void setValueID(Reference valueID) { - this.valueID = valueID; + public void setValueId(Reference valueId) { + this.valueId = valueId; } @Override @@ -139,13 +138,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -158,6 +157,16 @@ 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; @@ -169,13 +178,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -184,18 +193,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -208,14 +217,12 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultMultiLanguageProperty (" + "value=%s," + + "valueId=%s," + + ")", + this.value, this.valueId); } /** 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 51f9b021d..eb713de68 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 @@ -1,5 +1,6 @@ /* * 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 @@ -38,8 +39,8 @@ public class DefaultOperation implements Operation { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -68,24 +69,22 @@ public class DefaultOperation implements Operation { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultOperation() { - - } + public DefaultOperation() {} @Override public int hashCode() { - return Objects.hash(this.inoutputVariables, - this.inputVariables, + return Objects.hash(this.inputVariables, this.outputVariables, + this.inoutputVariables, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -98,31 +97,21 @@ public boolean equals(Object obj) { return false; } else { DefaultOperation other = (DefaultOperation) obj; - return Objects.equals(this.inoutputVariables, other.inoutputVariables) && - Objects.equals(this.inputVariables, other.inputVariables) && + return Objects.equals(this.inputVariables, other.inputVariables) && 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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } - @Override - public List getInoutputVariables() { - return inoutputVariables; - } - - @Override - public void setInoutputVariables(List inoutputVariables) { - this.inoutputVariables = inoutputVariables; - } - @Override public List getInputVariables() { return inputVariables; @@ -143,6 +132,16 @@ public void setOutputVariables(List outputVariables) { this.outputVariables = outputVariables; } + @Override + public List getInoutputVariables() { + return inoutputVariables; + } + + @Override + public void setInoutputVariables(List inoutputVariables) { + this.inoutputVariables = inoutputVariables; + } + @Override public List getEmbeddedDataSpecifications() { return embeddedDataSpecifications; @@ -154,13 +153,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -173,6 +172,16 @@ 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; @@ -184,13 +193,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -199,18 +208,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -223,14 +232,13 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultOperation (" + "inputVariables=%s," + + "outputVariables=%s," + + "inoutputVariables=%s," + + ")", + this.inputVariables, this.outputVariables, this.inoutputVariables); } /** 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 6ba755f0a..17f42b008 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 @@ -1,5 +1,6 @@ /* * 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 @@ -66,6 +67,13 @@ public void setValue(SubmodelElement value) { this.value = value; } + public String toString() { + return String.format( + "DefaultOperationVariable (" + "value=%s," + + ")", + this.value); + } + /** * This builder class can be used to construct a DefaultOperationVariable bean. */ 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 738f5723f..7917d7d94 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 @@ -1,5 +1,6 @@ /* * 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 @@ -38,8 +39,8 @@ public class DefaultProperty implements Property { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -47,11 +48,11 @@ public class DefaultProperty implements Property { @IRI("https://admin-shell.io/aas/3/0/Property/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/Property/valueID") - protected Reference valueID; + @IRI("https://admin-shell.io/aas/3/0/Property/valueId") + protected Reference valueId; @IRI("https://admin-shell.io/aas/3/0/Property/valueType") - protected DataTypeDefXSD valueType; + protected DataTypeDefXsd valueType; @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") protected List qualifiers = new ArrayList<>(); @@ -68,24 +69,22 @@ public class DefaultProperty implements Property { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultProperty() { - - } + public DefaultProperty() {} @Override public int hashCode() { - return Objects.hash(this.value, - this.valueID, - this.valueType, + return Objects.hash(this.valueType, + this.value, + this.valueId, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -98,49 +97,49 @@ public boolean equals(Object obj) { return false; } else { DefaultProperty other = (DefaultProperty) obj; - return Objects.equals(this.value, other.value) && - Objects.equals(this.valueID, other.valueID) && - Objects.equals(this.valueType, other.valueType) && + return Objects.equals(this.valueType, other.valueType) && + 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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @Override - public String getValue() { - return value; + public DataTypeDefXsd getValueType() { + return valueType; } @Override - public void setValue(String value) { - this.value = value; + public void setValueType(DataTypeDefXsd valueType) { + this.valueType = valueType; } @Override - public Reference getValueID() { - return valueID; + public String getValue() { + return value; } @Override - public void setValueID(Reference valueID) { - this.valueID = valueID; + public void setValue(String value) { + this.value = value; } @Override - public DataTypeDefXSD getValueType() { - return valueType; + public Reference getValueId() { + return valueId; } @Override - public void setValueType(DataTypeDefXSD valueType) { - this.valueType = valueType; + public void setValueId(Reference valueId) { + this.valueId = valueId; } @Override @@ -154,13 +153,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -173,6 +172,16 @@ 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; @@ -184,13 +193,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -199,18 +208,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -223,14 +232,13 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultProperty (" + "valueType=%s," + + "value=%s," + + "valueId=%s," + + ")", + this.valueType, this.value, this.valueId); } /** 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 new file mode 100644 index 000000000..4f2d99fb2 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java @@ -0,0 +1,152 @@ +/* + * 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. + * + * 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 org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.ProtocolInformationBuilder; + +import java.util.Objects; + +@IRI("aas:ProtocolInformation") +public class DefaultProtocolInformation implements ProtocolInformation { + + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress") + protected String endpointAddress; + + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol") + protected String endpointProtocol; + + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion") + protected String endpointProtocolVersion; + + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol") + protected String subprotocol; + + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody") + protected String subprotocolBody; + + @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding") + protected String subprotocolBodyEncoding; + + public DefaultProtocolInformation() { + } + + @Override + public int hashCode() { + return Objects.hash(this.endpointAddress, + this.endpointProtocol, + this.endpointProtocolVersion, + this.subprotocol, + this.subprotocolBody, + this.subprotocolBodyEncoding); + } + + @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 { + DefaultProtocolInformation other = (DefaultProtocolInformation) obj; + return Objects.equals(this.endpointAddress, other.endpointAddress) && + Objects.equals(this.endpointProtocol, other.endpointProtocol) && + Objects.equals(this.endpointProtocolVersion, other.endpointProtocolVersion) && + Objects.equals(this.subprotocol, other.subprotocol) && + Objects.equals(this.subprotocolBody, other.subprotocolBody) && + Objects.equals(this.subprotocolBodyEncoding, other.subprotocolBodyEncoding); + } + } + + @Override + public String getEndpointAddress() { + return endpointAddress; + } + + @Override + public void setEndpointAddress(String endpointAddress) { + this.endpointAddress = endpointAddress; + } + + @Override + public String getEndpointProtocol() { + return endpointProtocol; + } + + @Override + public void setEndpointProtocol(String endpointProtocol) { + this.endpointProtocol = endpointProtocol; + } + + @Override + public String getEndpointProtocolVersion() { + return endpointProtocolVersion; + } + + @Override + public void setEndpointProtocolVersion(String endpointProtocolVersion) { + this.endpointProtocolVersion = endpointProtocolVersion; + } + + @Override + public String getSubprotocol() { + return subprotocol; + } + + @Override + public void setSubprotocol(String subprotocol) { + this.subprotocol = subprotocol; + } + + @Override + public String getSubprotocolBody() { + return subprotocolBody; + } + + @Override + public void setSubprotocolBody(String subprotocolBody) { + this.subprotocolBody = subprotocolBody; + } + + @Override + public String getSubprotocolBodyEncoding() { + return subprotocolBodyEncoding; + } + + @Override + public void setSubprotocolBodyEncoding(String subprotocolBodyEncoding) { + this.subprotocolBodyEncoding = subprotocolBodyEncoding; + } + + /** + * This builder class can be used to construct a DefaultProtocolInformation bean. + */ + public static class Builder extends ProtocolInformationBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultProtocolInformation newBuildingInstance() { + return new DefaultProtocolInformation(); + } + } +} 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 fc1d46bb3..4a3447a43 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 @@ -1,5 +1,6 @@ /* * 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 @@ -14,7 +15,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +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; @@ -36,8 +37,8 @@ @IRI("aas:Qualifier") public class DefaultQualifier implements Qualifier { - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticID") - protected Reference semanticID; + @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<>(); @@ -51,24 +52,22 @@ public class DefaultQualifier implements Qualifier { @IRI("https://admin-shell.io/aas/3/0/Qualifier/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueID") - protected Reference valueID; + @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueId") + protected Reference valueId; @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueType") - protected DataTypeDefXSD valueType; + protected DataTypeDefXsd valueType; - public DefaultQualifier() { - - } + public DefaultQualifier() {} @Override public int hashCode() { return Objects.hash(this.kind, this.type, - this.value, - this.valueID, this.valueType, - this.semanticID, + this.value, + this.valueId, + this.semanticId, this.supplementalSemanticIds); } @@ -84,10 +83,10 @@ public boolean equals(Object obj) { DefaultQualifier other = (DefaultQualifier) obj; return Objects.equals(this.kind, other.kind) && Objects.equals(this.type, other.type) && - Objects.equals(this.value, other.value) && - Objects.equals(this.valueID, other.valueID) && Objects.equals(this.valueType, other.valueType) && - Objects.equals(this.semanticID, other.semanticID) && + Objects.equals(this.value, other.value) && + Objects.equals(this.valueId, other.valueId) && + Objects.equals(this.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds); } } @@ -113,43 +112,43 @@ public void setType(String type) { } @Override - public String getValue() { - return value; + public DataTypeDefXsd getValueType() { + return valueType; } @Override - public void setValue(String value) { - this.value = value; + public void setValueType(DataTypeDefXsd valueType) { + this.valueType = valueType; } @Override - public Reference getValueID() { - return valueID; + public String getValue() { + return value; } @Override - public void setValueID(Reference valueID) { - this.valueID = valueID; + public void setValue(String value) { + this.value = value; } @Override - public DataTypeDefXSD getValueType() { - return valueType; + public Reference getValueId() { + return valueId; } @Override - public void setValueType(DataTypeDefXSD valueType) { - this.valueType = valueType; + public void setValueId(Reference valueId) { + this.valueId = valueId; } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -162,6 +161,17 @@ public void setSupplementalSemanticIds(List supplementalSemanticIds) this.supplementalSemanticIds = supplementalSemanticIds; } + public String toString() { + return String.format( + "DefaultQualifier (" + "kind=%s," + + "type=%s," + + "valueType=%s," + + "value=%s," + + "valueId=%s," + + ")", + this.kind, this.type, this.valueType, this.value, this.valueId); + } + /** * This builder class can be used to construct a DefaultQualifier bean. */ 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 18710604c..475339717 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 @@ -1,5 +1,6 @@ /* * 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 @@ -38,8 +39,8 @@ public class DefaultRange implements Range { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -54,7 +55,7 @@ public class DefaultRange implements Range { protected String min; @IRI("https://admin-shell.io/aas/3/0/Range/valueType") - protected DataTypeDefXSD valueType; + protected DataTypeDefXsd valueType; @IRI("https://admin-shell.io/aas/3/0/Referable/category") protected String category; @@ -68,24 +69,22 @@ public class DefaultRange implements Range { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultRange() { - - } + public DefaultRange() {} @Override public int hashCode() { - return Objects.hash(this.max, + return Objects.hash(this.valueType, this.min, - this.valueType, + this.max, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -98,29 +97,29 @@ public boolean equals(Object obj) { return false; } else { DefaultRange other = (DefaultRange) obj; - return Objects.equals(this.max, other.max) && + return Objects.equals(this.valueType, other.valueType) && Objects.equals(this.min, other.min) && - Objects.equals(this.valueType, other.valueType) && + Objects.equals(this.max, other.max) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticID, other.semanticID) && + 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.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @Override - public String getMax() { - return max; + public DataTypeDefXsd getValueType() { + return valueType; } @Override - public void setMax(String max) { - this.max = max; + public void setValueType(DataTypeDefXsd valueType) { + this.valueType = valueType; } @Override @@ -134,13 +133,13 @@ public void setMin(String min) { } @Override - public DataTypeDefXSD getValueType() { - return valueType; + public String getMax() { + return max; } @Override - public void setValueType(DataTypeDefXSD valueType) { - this.valueType = valueType; + public void setMax(String max) { + this.max = max; } @Override @@ -154,13 +153,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -173,6 +172,16 @@ 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; @@ -184,13 +193,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -199,18 +208,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -223,14 +232,13 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultRange (" + "valueType=%s," + + "min=%s," + + "max=%s," + + ")", + this.valueType, this.min, this.max); } /** 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 3817f9236..ceed8d70d 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 @@ -1,5 +1,6 @@ /* * 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 @@ -37,21 +38,19 @@ public class DefaultReference implements Reference { @IRI("https://admin-shell.io/aas/3/0/Reference/keys") protected List keys = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticID") - protected Reference referredSemanticID; + @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticId") + protected Reference referredSemanticId; @IRI("https://admin-shell.io/aas/3/0/Reference/type") protected ReferenceTypes type; - public DefaultReference() { - - } + public DefaultReference() {} @Override public int hashCode() { - return Objects.hash(this.keys, - this.referredSemanticID, - this.type); + return Objects.hash(this.type, + this.referredSemanticId, + this.keys); } @Override @@ -64,40 +63,49 @@ public boolean equals(Object obj) { return false; } else { DefaultReference other = (DefaultReference) obj; - return Objects.equals(this.keys, other.keys) && - Objects.equals(this.referredSemanticID, other.referredSemanticID) && - Objects.equals(this.type, other.type); + return Objects.equals(this.type, other.type) && + Objects.equals(this.referredSemanticId, other.referredSemanticId) && + Objects.equals(this.keys, other.keys); } } @Override - public List getKeys() { - return keys; + public ReferenceTypes getType() { + return type; } @Override - public void setKeys(List keys) { - this.keys = keys; + public void setType(ReferenceTypes type) { + this.type = type; } @Override - public Reference getReferredSemanticID() { - return referredSemanticID; + public Reference getReferredSemanticId() { + return referredSemanticId; } @Override - public void setReferredSemanticID(Reference referredSemanticID) { - this.referredSemanticID = referredSemanticID; + public void setReferredSemanticId(Reference referredSemanticId) { + this.referredSemanticId = referredSemanticId; } @Override - public ReferenceTypes getType() { - return type; + public List getKeys() { + return keys; } @Override - public void setType(ReferenceTypes type) { - this.type = type; + public void setKeys(List keys) { + this.keys = keys; + } + + public String toString() { + return String.format( + "DefaultReference (" + "type=%s," + + "referredSemanticId=%s," + + "keys=%s," + + ")", + this.type, this.referredSemanticId, this.keys); } /** 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 3b36d2062..da64e65ec 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 @@ -1,5 +1,6 @@ /* * 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 @@ -39,8 +40,8 @@ public class DefaultReferenceElement implements ReferenceElement { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -63,22 +64,20 @@ public class DefaultReferenceElement implements ReferenceElement { @IRI("https://admin-shell.io/aas/3/0/ReferenceElement/value") protected Reference value; - public DefaultReferenceElement() { - - } + public DefaultReferenceElement() {} @Override public int hashCode() { return Objects.hash(this.value, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -93,14 +92,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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @@ -125,13 +124,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -144,6 +143,16 @@ 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; @@ -155,13 +164,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -170,18 +179,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -194,14 +203,11 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultReferenceElement (" + "value=%s," + + ")", + this.value); } /** 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 99bd400e0..d151659c5 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 @@ -1,5 +1,6 @@ /* * 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 @@ -39,8 +40,8 @@ public class DefaultRelationshipElement implements RelationshipElement { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -66,23 +67,21 @@ public class DefaultRelationshipElement implements RelationshipElement { @IRI("https://admin-shell.io/aas/3/0/RelationshipElement/second") protected Reference second; - public DefaultRelationshipElement() { - - } + public DefaultRelationshipElement() {} @Override public int hashCode() { return Objects.hash(this.first, this.second, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -98,14 +97,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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @@ -140,13 +139,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -159,6 +158,16 @@ 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; @@ -170,13 +179,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -185,18 +194,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -209,14 +218,12 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultRelationshipElement (" + "first=%s," + + "second=%s," + + ")", + this.first, this.second); } /** 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 44b40cb2b..068c2ad83 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 @@ -1,5 +1,6 @@ /* * 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 @@ -37,14 +38,12 @@ public class DefaultResource implements Resource { @IRI("https://admin-shell.io/aas/3/0/Resource/path") protected String path; - public DefaultResource() { - - } + public DefaultResource() {} @Override public int hashCode() { - return Objects.hash(this.contentType, - this.path); + return Objects.hash(this.path, + this.contentType); } @Override @@ -57,29 +56,37 @@ public boolean equals(Object obj) { return false; } else { DefaultResource other = (DefaultResource) obj; - return Objects.equals(this.contentType, other.contentType) && - Objects.equals(this.path, other.path); + return Objects.equals(this.path, other.path) && + Objects.equals(this.contentType, other.contentType); } } @Override - public String getContentType() { - return contentType; + public String getPath() { + return path; } @Override - public void setContentType(String contentType) { - this.contentType = contentType; + public void setPath(String path) { + this.path = path; } @Override - public String getPath() { - return path; + public String getContentType() { + return contentType; } @Override - public void setPath(String path) { - this.path = path; + public void setContentType(String contentType) { + this.contentType = contentType; + } + + public String toString() { + return String.format( + "DefaultResource (" + "path=%s," + + "contentType=%s," + + ")", + this.path, this.contentType); } /** 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 5c35ffb9e..53122fe0c 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 @@ -1,5 +1,6 @@ /* * 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,9 +16,9 @@ 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.SpecificAssetId; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SpecificAssetIDBuilder; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.SpecificAssetIdBuilder; import java.util.ArrayList; import java.util.List; @@ -25,39 +26,37 @@ /** - * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetID + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId * * A specific asset ID describes a generic supplementary identifying attribute of the asset. */ -@IRI("aas:SpecificAssetID") -public class DefaultSpecificAssetID implements SpecificAssetID { +@IRI("aas:SpecificAssetId") +public class DefaultSpecificAssetId implements SpecificAssetId { - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticID") - protected Reference semanticID; + @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/SpecificAssetID/externalSubjectID") - protected Reference externalSubjectID; + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/externalSubjectId") + protected Reference externalSubjectId; - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/name") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/name") protected String name; - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/value") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/value") protected String value; - public DefaultSpecificAssetID() { - - } + public DefaultSpecificAssetId() {} @Override public int hashCode() { - return Objects.hash(this.externalSubjectID, - this.name, + return Objects.hash(this.name, this.value, - this.semanticID, + this.externalSubjectId, + this.semanticId, this.supplementalSemanticIds); } @@ -70,25 +69,15 @@ public boolean equals(Object obj) { } else if (this.getClass() != obj.getClass()) { return false; } else { - DefaultSpecificAssetID other = (DefaultSpecificAssetID) obj; - return Objects.equals(this.externalSubjectID, other.externalSubjectID) && - Objects.equals(this.name, other.name) && + DefaultSpecificAssetId other = (DefaultSpecificAssetId) obj; + return Objects.equals(this.name, other.name) && Objects.equals(this.value, other.value) && - Objects.equals(this.semanticID, other.semanticID) && + Objects.equals(this.externalSubjectId, other.externalSubjectId) && + Objects.equals(this.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds); } } - @Override - public Reference getExternalSubjectID() { - return externalSubjectID; - } - - @Override - public void setExternalSubjectID(Reference externalSubjectID) { - this.externalSubjectID = externalSubjectID; - } - @Override public String getName() { return name; @@ -110,13 +99,23 @@ public void setValue(String value) { } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getExternalSubjectId() { + return externalSubjectId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setExternalSubjectId(Reference externalSubjectId) { + this.externalSubjectId = externalSubjectId; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -129,10 +128,19 @@ public void setSupplementalSemanticIds(List supplementalSemanticIds) this.supplementalSemanticIds = supplementalSemanticIds; } + public String toString() { + return String.format( + "DefaultSpecificAssetId (" + "name=%s," + + "value=%s," + + "externalSubjectId=%s," + + ")", + this.name, this.value, this.externalSubjectId); + } + /** - * This builder class can be used to construct a DefaultSpecificAssetID bean. + * This builder class can be used to construct a DefaultSpecificAssetId bean. */ - public static class Builder extends SpecificAssetIDBuilder { + public static class Builder extends SpecificAssetIdBuilder { @Override protected Builder getSelf() { @@ -140,8 +148,8 @@ protected Builder getSelf() { } @Override - protected DefaultSpecificAssetID newBuildingInstance() { - return new DefaultSpecificAssetID(); + protected DefaultSpecificAssetId newBuildingInstance() { + return new DefaultSpecificAssetId(); } } } 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 17f582dc9..b5697a48f 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 @@ -1,5 +1,6 @@ /* * 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 @@ -41,8 +42,8 @@ public class DefaultSubmodel implements Submodel { @IRI("https://admin-shell.io/aas/3/0/HasKind/kind") protected ModellingKind kind; - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticID") - protected Reference semanticID; + @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<>(); @@ -71,24 +72,22 @@ public class DefaultSubmodel implements Submodel { @IRI("https://admin-shell.io/aas/3/0/Submodel/submodelElements") protected List submodelElements = new ArrayList<>(); - public DefaultSubmodel() { - - } + public DefaultSubmodel() {} @Override public int hashCode() { return Objects.hash(this.submodelElements, this.embeddedDataSpecifications, + this.kind, + this.semanticId, + this.supplementalSemanticIds, this.administration, this.id, this.category, - this.description, - this.displayName, this.idShort, + this.displayName, + this.description, this.extensions, - this.semanticID, - this.supplementalSemanticIds, - this.kind, this.qualifiers); } @@ -104,16 +103,16 @@ public boolean equals(Object obj) { 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) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && 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.kind, other.kind) && Objects.equals(this.qualifiers, other.qualifiers); } } @@ -139,103 +138,103 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public AdministrativeInformation getAdministration() { - return administration; + public ModellingKind getKind() { + return kind; } @Override - public void setAdministration(AdministrativeInformation administration) { - this.administration = administration; + public void setKind(ModellingKind kind) { + this.kind = kind; } @Override - public String getId() { - return id; + public Reference getSemanticId() { + return semanticId; } @Override - public void setId(String id) { - this.id = id; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override - public String getCategory() { - return category; + public List getSupplementalSemanticIds() { + return supplementalSemanticIds; } @Override - public void setCategory(String category) { - this.category = category; + public void setSupplementalSemanticIds(List supplementalSemanticIds) { + this.supplementalSemanticIds = supplementalSemanticIds; } @Override - public List getDescription() { - return description; + public AdministrativeInformation getAdministration() { + return administration; } @Override - public void setDescription(List description) { - this.description = description; + public void setAdministration(AdministrativeInformation administration) { + this.administration = administration; } @Override - public List getDisplayName() { - return displayName; + public String getId() { + return id; } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setId(String id) { + this.id = id; } @Override - public String getIdShort() { - return idShort; + public String getCategory() { + return category; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setCategory(String category) { + this.category = category; } @Override - public List getExtensions() { - return extensions; + public String getIdShort() { + return idShort; } @Override - public void setExtensions(List extensions) { - this.extensions = extensions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override - public Reference getSemanticID() { - return semanticID; + public List getDisplayName() { + return displayName; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public List getSupplementalSemanticIds() { - return supplementalSemanticIds; + public List getDescription() { + return description; } @Override - public void setSupplementalSemanticIds(List supplementalSemanticIds) { - this.supplementalSemanticIds = supplementalSemanticIds; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override - public ModellingKind getKind() { - return kind; + public List getExtensions() { + return extensions; } @Override - public void setKind(ModellingKind kind) { - this.kind = kind; + public void setExtensions(List extensions) { + this.extensions = extensions; } @Override @@ -248,6 +247,13 @@ public void setQualifiers(List qualifiers) { this.qualifiers = qualifiers; } + public String toString() { + return String.format( + "DefaultSubmodel (" + "submodelElements=%s," + + ")", + this.submodelElements); + } + /** * This builder class can be used to construct a DefaultSubmodel bean. */ 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 new file mode 100644 index 000000000..8d4025c93 --- /dev/null +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java @@ -0,0 +1,174 @@ +/* + * 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. + * + * 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.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.annotations.IRI; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelDescriptorBuilder; + +@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/RC02/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/RC02/SubmodelDescriptor/displayName") + protected List displayName; + + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort") + protected String idShort; + + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/ide") + protected String id; + + @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId") + protected Reference semanticId; + + public DefaultSubmodelDescriptor() { + } + + @Override + public int hashCode() { + return Objects.hash(this.administration, + this.description, + this.displayName, + this.idShort, + this.id, + this.semanticId, + this.endpoints); + } + + @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 { + 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.idShort, other.idShort) && + Objects.equals(this.id, other.id) && + Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.endpoints, other.endpoints); + } + } + + @Override + public AdministrativeInformation getAdministration() { + return administration; + } + + @Override + public void setAdministration(AdministrativeInformation administration) { + this.administration = administration; + } + + @Override + public List getDescription() { + return description; + } + + @Override + public void setDescription(List description) { + this.description = description; + } + + @Override + public List getDisplayName() { + return displayName; + } + + @Override + public void setDisplayName(List displayName) { + this.displayName = displayName; + } + + @Override + public String getIdShort() { + return idShort; + } + + @Override + public void setIdShort(String idShort) { + this.idShort = idShort; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public Reference getSemanticId() { + return semanticId; + } + + @Override + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; + } + + @Override + public List getEndpoints() { + return endpoints; + } + + @Override + public void setEndpoints(List endpoints) { + this.endpoints = endpoints; + } + + /** + * This builder class can be used to construct a DefaultSubmodelDescriptor bean. + */ + public static class Builder extends SubmodelDescriptorBuilder { + + @Override + protected Builder getSelf() { + return this; + } + + @Override + protected DefaultSubmodelDescriptor newBuildingInstance() { + return new DefaultSubmodelDescriptor(); + } + } +} 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 2cb74847c..a81775b3b 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 @@ -1,5 +1,6 @@ /* * 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 @@ -19,7 +20,6 @@ import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelElementCollectionBuilder; import java.util.ArrayList; -import java.util.Collection; import java.util.List; import java.util.Objects; @@ -41,8 +41,8 @@ public class DefaultSubmodelElementCollection implements SubmodelElementCollecti @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -63,24 +63,22 @@ public class DefaultSubmodelElementCollection implements SubmodelElementCollecti protected String idShort; @IRI("https://admin-shell.io/aas/3/0/SubmodelElementCollection/value") - protected Collection value = new ArrayList<>(); + protected List value = new ArrayList<>(); - public DefaultSubmodelElementCollection() { - - } + public DefaultSubmodelElementCollection() {} @Override public int hashCode() { return Objects.hash(this.value, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -95,25 +93,25 @@ 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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @Override - public Collection getValue() { + public List getValue() { return value; } @Override - public void setValue(Collection value) { - this.value = value; + public void setValue(List values) { + this.value = values; } @Override @@ -127,13 +125,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -146,6 +144,16 @@ 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; @@ -157,13 +165,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -172,18 +180,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -196,14 +204,11 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultSubmodelElementCollection (" + "value=%s," + + ")", + this.value); } /** 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 745f21e17..221b3fd75 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 @@ -1,5 +1,6 @@ /* * 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 @@ -38,8 +39,8 @@ public class DefaultSubmodelElementList implements SubmodelElementList { @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/semanticId") + protected Reference semanticId; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -62,38 +63,36 @@ public class DefaultSubmodelElementList implements SubmodelElementList { @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/orderRelevant") protected boolean orderRelevant; - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement") - protected Reference semanticIDListElement; + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement") + protected Reference semanticIdListElement; @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/typeValueListElement") - protected AASSubmodelElements typeValueListElement; + protected AasSubmodelElements typeValueListElement; @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/value") protected List value = new ArrayList<>(); @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement") - protected DataTypeDefXSD valueTypeListElement; + protected DataTypeDefXsd valueTypeListElement; - public DefaultSubmodelElementList() { - - } + public DefaultSubmodelElementList() {} @Override public int hashCode() { return Objects.hash(this.orderRelevant, - this.semanticIDListElement, + this.semanticIdListElement, this.typeValueListElement, - this.value, this.valueTypeListElement, + this.value, this.embeddedDataSpecifications, - this.semanticID, + this.semanticId, this.supplementalSemanticIds, + this.qualifiers, this.category, - this.description, - this.displayName, this.idShort, - this.extensions, - this.qualifiers); + this.displayName, + this.description, + this.extensions); } @Override @@ -107,19 +106,19 @@ public boolean equals(Object obj) { } else { DefaultSubmodelElementList other = (DefaultSubmodelElementList) obj; return Objects.equals(this.orderRelevant, other.orderRelevant) && - Objects.equals(this.semanticIDListElement, other.semanticIDListElement) && + Objects.equals(this.semanticIdListElement, other.semanticIdListElement) && Objects.equals(this.typeValueListElement, other.typeValueListElement) && - Objects.equals(this.value, other.value) && 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.semanticId, other.semanticId) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.qualifiers, other.qualifiers) && Objects.equals(this.category, other.category) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.extensions, other.extensions) && - Objects.equals(this.qualifiers, other.qualifiers); + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.description, other.description) && + Objects.equals(this.extensions, other.extensions); } } @@ -134,43 +133,43 @@ public void setOrderRelevant(boolean orderRelevant) { } @Override - public Reference getSemanticIDListElement() { - return semanticIDListElement; + public Reference getSemanticIdListElement() { + return semanticIdListElement; } @Override - public void setSemanticIDListElement(Reference semanticIDListElement) { - this.semanticIDListElement = semanticIDListElement; + public void setSemanticIdListElement(Reference semanticIdListElement) { + this.semanticIdListElement = semanticIdListElement; } @Override - public AASSubmodelElements getTypeValueListElement() { + public AasSubmodelElements getTypeValueListElement() { return typeValueListElement; } @Override - public void setTypeValueListElement(AASSubmodelElements typeValueListElement) { + public void setTypeValueListElement(AasSubmodelElements typeValueListElement) { this.typeValueListElement = typeValueListElement; } @Override - public List getValue() { - return value; + public DataTypeDefXsd getValueTypeListElement() { + return valueTypeListElement; } @Override - public void setValue(List value) { - this.value = value; + public void setValueTypeListElement(DataTypeDefXsd valueTypeListElement) { + this.valueTypeListElement = valueTypeListElement; } @Override - public DataTypeDefXSD getValueTypeListElement() { - return valueTypeListElement; + public List getValue() { + return value; } @Override - public void setValueTypeListElement(DataTypeDefXSD valueTypeListElement) { - this.valueTypeListElement = valueTypeListElement; + public void setValue(List values) { + this.value = values; } @Override @@ -184,13 +183,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticID() { - return semanticID; + public Reference getSemanticId() { + return semanticId; } @Override - public void setSemanticID(Reference semanticID) { - this.semanticID = semanticID; + public void setSemanticId(Reference semanticId) { + this.semanticId = semanticId; } @Override @@ -203,6 +202,16 @@ 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; @@ -214,13 +223,13 @@ public void setCategory(String category) { } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List description) { - this.description = description; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -229,18 +238,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; + public void setDisplayName(List displayNames) { + this.displayName = displayNames; } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List descriptions) { + this.description = descriptions; } @Override @@ -253,14 +262,15 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - @Override - public List getQualifiers() { - return qualifiers; - } - - @Override - public void setQualifiers(List qualifiers) { - this.qualifiers = qualifiers; + public String toString() { + return String.format( + "DefaultSubmodelElementList (" + "orderRelevant=%s," + + "semanticIdListElement=%s," + + "typeValueListElement=%s," + + "valueTypeListElement=%s," + + "value=%s," + + ")", + this.orderRelevant, this.semanticIdListElement, this.typeValueListElement, this.valueTypeListElement, this.value); } /** 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 a4c7d4236..95df776d9 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 @@ -1,5 +1,6 @@ /* * 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 @@ -67,6 +68,13 @@ public void setValueReferencePairs(List valueReferencePairs) this.valueReferencePairs = valueReferencePairs; } + public String toString() { + return String.format( + "DefaultValueList (" + "valueReferencePairs=%s," + + ")", + this.valueReferencePairs); + } + /** * This builder class can be used to construct a DefaultValueList bean. */ 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 fbffa2f47..752281744 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 @@ -1,5 +1,6 @@ /* * 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 @@ -35,17 +36,15 @@ public class DefaultValueReferencePair implements ValueReferencePair { @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueID") - protected Reference valueID; + @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueId") + protected Reference valueId; - public DefaultValueReferencePair() { - - } + public DefaultValueReferencePair() {} @Override public int hashCode() { return Objects.hash(this.value, - this.valueID); + this.valueId); } @Override @@ -59,7 +58,7 @@ public boolean equals(Object obj) { } else { DefaultValueReferencePair other = (DefaultValueReferencePair) obj; return Objects.equals(this.value, other.value) && - Objects.equals(this.valueID, other.valueID); + Objects.equals(this.valueId, other.valueId); } } @@ -74,13 +73,21 @@ public void setValue(String value) { } @Override - public Reference getValueID() { - return valueID; + public Reference getValueId() { + return valueId; } @Override - public void setValueID(Reference valueID) { - this.valueID = valueID; + public void setValueId(Reference valueId) { + this.valueId = valueId; + } + + public String toString() { + return String.format( + "DefaultValueReferencePair (" + "value=%s," + + "valueId=%s," + + ")", + this.value, this.valueId); } /** From 5304b47c9f85163efaba612bf7e3250081e48e37 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Tue, 29 Aug 2023 15:47:07 +0200 Subject: [PATCH 04/18] Fix the compilation errors --- ...ssetAdministrationShellElementVisitor.java | 8 +- ...ministrationShellElementWalkerVisitor.java | 13 +- .../core/serialization/EnumSerializer.java | 9 +- .../aas4j/v3/dataformat/core/AASFull.java | 236 +++++++++--------- .../aas4j/v3/dataformat/core/AASSimple.java | 36 +-- .../v3/dataformat/core/CustomProperty.java | 14 +- .../aas4j/v3/dataformat/core/Examples.java | 10 +- .../json/mixins/SubmodelElementListMixin.java | 12 +- .../dataformat/json/JsonSerializerTest.java | 4 +- .../v3/dataformat/json/util/Examples.java | 8 +- .../ValueReferencePairNodeDeserializer.java | 2 +- .../xml/mixins/AssetInformationMixin.java | 6 +- .../dataformat/xml/mixins/QualifierMixin.java | 4 +- .../dataformat/xml/mixins/ResourceMixin.java | 4 +- ...IDMixin.java => SpecificAssetIdMixin.java} | 4 +- .../xml/mixins/SubmodelElementListMixin.java | 12 +- .../v3/dataformat/xml/XmlSerializerTest.java | 6 +- 17 files changed, 194 insertions(+), 194 deletions(-) rename dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/{SpecificAssetIDMixin.java => SpecificAssetIdMixin.java} (94%) diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java index f9b13eceb..1d6e63b4d 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java @@ -53,7 +53,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.ReferenceElement; import org.eclipse.digitaltwin.aas4j.v3.model.RelationshipElement; import org.eclipse.digitaltwin.aas4j.v3.model.Resource; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetID; +import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; import org.eclipse.digitaltwin.aas4j.v3.model.Submodel; import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementCollection; @@ -132,8 +132,8 @@ public default void visit(HasSemantics hasSemantics) { Class type = hasSemantics.getClass(); if (Extension.class.isAssignableFrom(type)) { visit((Extension) hasSemantics); - } else if (SpecificAssetID.class.isAssignableFrom(type)) { - visit((SpecificAssetID) hasSemantics); + } else if (SpecificAssetId.class.isAssignableFrom(type)) { + visit((SpecificAssetId) hasSemantics); } else if (Submodel.class.isAssignableFrom(type)) { visit((Submodel) hasSemantics); } else if (SubmodelElement.class.isAssignableFrom(type)) { @@ -245,7 +245,7 @@ public default void visit(Extension extension) { public default void visit(File file) { } - public default void visit(SpecificAssetID identifierKeyValuePair) { + public default void visit(SpecificAssetId identifierKeyValuePair) { } public default void visit(Key key) { diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java index d16f45849..e58231115 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java @@ -98,7 +98,7 @@ public default void visit(HasSemantics hasSemantics) { if (hasSemantics == null) { return; } - visit(hasSemantics.getSemanticID()); + visit(hasSemantics.getSemanticId()); hasSemantics.getSupplementalSemanticIds().forEach(x->visit(x)); AssetAdministrationShellElementVisitor.super.visit(hasSemantics); } @@ -113,11 +113,11 @@ public default void visit(Identifiable identifiable) { } @Override - public default void visit(SpecificAssetID specificAssetId) { + public default void visit(SpecificAssetId specificAssetId) { if (specificAssetId == null) { return; } - visit(specificAssetId.getExternalSubjectID()); + visit(specificAssetId.getExternalSubjectId()); AssetAdministrationShellElementVisitor.super.visit(specificAssetId); } @@ -127,7 +127,7 @@ public default void visit(MultiLanguageProperty multiLanguageProperty) { return; } multiLanguageProperty.getValue().forEach(x -> visit(x)); - visit(multiLanguageProperty.getValueID()); + visit(multiLanguageProperty.getValueId()); AssetAdministrationShellElementVisitor.super.visit(multiLanguageProperty); } @@ -145,7 +145,7 @@ public default void visit(Property property) { if (property == null) { return; } - visit(property.getValueID()); + visit(property.getValueId()); AssetAdministrationShellElementVisitor.super.visit(property); } @@ -163,7 +163,7 @@ public default void visit(Qualifier qualifier) { if (qualifier == null) { return; } - visit(qualifier.getValueID()); + visit(qualifier.getValueId()); AssetAdministrationShellElementVisitor.super.visit(qualifier); } @@ -295,5 +295,4 @@ public default void visit(Operation operation) { operation.getOutputVariables().forEach(x -> visit(x.getValue())); AssetAdministrationShellElementVisitor.super.visit(operation); } - } diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java index dadf9bc6c..147bfadf3 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java @@ -1,5 +1,6 @@ /* * 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. @@ -18,7 +19,7 @@ import java.io.IOException; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.util.ReflectionHelper; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeIec61360; import org.eclipse.digitaltwin.aas4j.v3.model.Direction; import org.eclipse.digitaltwin.aas4j.v3.model.StateOfEvent; @@ -37,11 +38,11 @@ public class EnumSerializer extends JsonSerializer { @Override public void serialize(Enum value, JsonGenerator gen, SerializerProvider provider) throws IOException { - if (value instanceof DataTypeDefXSD) { + if (value instanceof DataTypeDefXsd) { // only for the DataTypeDefXsd notation - if (value.equals(DataTypeDefXSD.ANY_URI)) { + if (value.equals(DataTypeDefXsd.ANY_URI)) { gen.writeString("xs:anyURI"); - } else if (value.equals(DataTypeDefXSD.NON_NEGATIVE_INTEGER)) { + } else if (value.equals(DataTypeDefXsd.NON_NEGATIVE_INTEGER)) { gen.writeString("xs:nonNegativeInteger"); } else if(isTimeRelatedValue(value)) { handleTimeRelatedValue(gen, value); diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java index 4844d4e3c..4833a5850 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java @@ -18,11 +18,11 @@ import java.util.Arrays; import java.util.Base64; -import org.eclipse.digitaltwin.aas4j.v3.model.AASSubmodelElements; +import org.eclipse.digitaltwin.aas4j.v3.model.AasSubmodelElements; import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeIec61360; import org.eclipse.digitaltwin.aas4j.v3.model.Direction; import org.eclipse.digitaltwin.aas4j.v3.model.EntityType; @@ -106,7 +106,7 @@ public static AssetAdministrationShell createAAS1() { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetID("https://acplt.org/Test_Asset") + .globalAssetId("https://acplt.org/Test_Asset") .build()) .submodels(new DefaultReference.Builder() .keys(new DefaultKey.Builder() @@ -138,7 +138,7 @@ public static AssetAdministrationShell createAAS2() { .id("https://acplt.org/Test_AssetAdministrationShell_Mandatory") .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetID("https://acplt.org/Test_Asset_Mandatory") + .globalAssetId("https://acplt.org/Test_Asset_Mandatory") .build()) .submodels(new DefaultReference.Builder() .keys(new DefaultKey.Builder() @@ -163,7 +163,7 @@ public static AssetAdministrationShell createAAS3() { .id("https://acplt.org/Test_AssetAdministrationShell2_Mandatory") .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetID("https://acplt.org/Test_Asset_Mandatory") + .globalAssetId("https://acplt.org/Test_Asset_Mandatory") .build()) .build(); } @@ -182,7 +182,7 @@ public static AssetAdministrationShell createAAS4() { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetID("https://acplt.org/Test_Asset_Missing") + .globalAssetId("https://acplt.org/Test_Asset_Missing") .build()) .submodels(new DefaultReference.Builder() .keys(new DefaultKey.Builder() @@ -207,7 +207,7 @@ public static Submodel createSubmodel1() { .revision("9") .build()) .kind(ModellingKind.INSTANCE) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.SUBMODEL) .value("http://acplt.org/SubmodelTemplates/AssetIdentification") @@ -223,7 +223,7 @@ public static Submodel createSubmodel1() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("0173-1#02-AAO677#002") @@ -234,16 +234,16 @@ public static Submodel createSubmodel1() { .qualifiers(new DefaultQualifier.Builder() .value("100") .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) .qualifiers(new DefaultQualifier.Builder() .value("50") .type("http://acplt.org/Qualifier/ExampleQualifier2") - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) .value("http://acplt.org/ValueId/ACPLT") - .valueType(DataTypeDefXSD.STRING) - .valueID(new DefaultReference.Builder() + .valueType(DataTypeDefXsd.STRING) + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ACPLT") @@ -258,7 +258,7 @@ public static Submodel createSubmodel1() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://opcfoundation.org/UA/DI/1.1/DeviceType/Serialnumber") @@ -282,8 +282,8 @@ public static Submodel createSubmodel1() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build())) .value("978-8234-234-342") - .valueType(DataTypeDefXSD.STRING) - .valueID(new DefaultReference.Builder() + .valueType(DataTypeDefXsd.STRING) + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("978-8234-234-342") @@ -306,7 +306,7 @@ public static Submodel createSubmodel2() { .version("0") .build()) .kind(ModellingKind.INSTANCE) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.SUBMODEL) .value("http://acplt.org/SubmodelTemplates/BillOfMaterial") @@ -319,7 +319,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://opcfoundation.org/UA/DI/1.1/DeviceType/Serialnumber") @@ -333,7 +333,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -341,8 +341,8 @@ public static Submodel createSubmodel2() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValue2") - .valueType(DataTypeDefXSD.STRING) - .valueID(new DefaultReference.Builder() + .valueType(DataTypeDefXsd.STRING) + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValue2") @@ -357,7 +357,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -365,8 +365,8 @@ public static Submodel createSubmodel2() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueType(DataTypeDefXSD.STRING) - .valueID(new DefaultReference.Builder() + .valueType(DataTypeDefXsd.STRING) + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") @@ -382,7 +382,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://opcfoundation.org/UA/DI/1.1/DeviceType/Serialnumber") @@ -390,7 +390,7 @@ public static Submodel createSubmodel2() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .entityType(EntityType.SELF_MANAGED_ENTITY) - .globalAssetID("https://acplt.org/Test_Asset2") + .globalAssetId("https://acplt.org/Test_Asset2") .build()) .build(); } @@ -408,7 +408,7 @@ public static Submodel createSubmodel3() { .revision("9") .build()) .kind(ModellingKind.INSTANCE) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelTemplates/ExampleSubmodel") @@ -422,7 +422,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example RelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel RelationshipElement Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleRelationshipElement") @@ -467,7 +467,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example AnnotatedRelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel AnnotatedRelationshipElement Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleAnnotatedRelationshipElement") @@ -508,7 +508,7 @@ public static Submodel createSubmodel3() { .idShort("ExampleProperty3") .category("PARAMETER") .value("some example annotation") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .submodelElements(new DefaultOperation.Builder() @@ -518,7 +518,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Operation object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Operation Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Operations/ExampleOperation") @@ -533,7 +533,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -541,14 +541,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueID(new DefaultReference.Builder() + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .outputVariables(new DefaultOperationVariable.Builder() @@ -559,7 +559,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -567,14 +567,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueID(new DefaultReference.Builder() + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .inoutputVariables(new DefaultOperationVariable.Builder() @@ -585,7 +585,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -593,14 +593,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueID(new DefaultReference.Builder() + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .build()) @@ -611,7 +611,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Capability object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Capability Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Capabilities/ExampleCapability") @@ -628,7 +628,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example BasicEvent object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel BasicEvent Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Events/ExampleBasicEvent") @@ -659,14 +659,14 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example ExampleSubmodelElementListOrdered object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel ExampleSubmodelElementListOrdered Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementLists/ExampleSubmodelElementListOrdered") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .value(new DefaultProperty.Builder() .idShort("ExampleProperty") .category("CONSTANT") @@ -674,7 +674,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -682,14 +682,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueID(new DefaultReference.Builder() + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -698,7 +698,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example value of a MultiLanguageProperty element").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispielswert für ein MultiLanguageProperty-Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/MultiLanguageProperties/ExampleMultiLanguageProperty") @@ -709,7 +709,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example MultiLanguageProperty object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel MultiLanguageProperty Element").language("de").build() )) - .valueID(new DefaultReference.Builder() + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleMultiLanguageValueId") @@ -724,7 +724,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -733,9 +733,9 @@ public static Submodel createSubmodel3() { .build()) .min("0") .max("100") - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -744,7 +744,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -758,7 +758,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Blob object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Blob Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder().type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Blobs/ExampleBlob") .build()) @@ -774,7 +774,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example File object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel File Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Files/ExampleFile") @@ -791,7 +791,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Reference Element object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Reference Element Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE).value( "http://acplt.org/ReferenceElements/ExampleReferenceElement") @@ -918,11 +918,11 @@ public static Submodel createSubmodel4() { .submodelElements(new DefaultSubmodelElementList.Builder() .idShort("ExampleSubmodelElementListUnordered") .orderRelevant(false) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .value(new DefaultProperty.Builder() .idShort("ExampleProperty") .value(null) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -931,9 +931,9 @@ public static Submodel createSubmodel4() { .idShort("ExampleRange") .min(null) .max(null) - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -977,7 +977,7 @@ public static Submodel createSubmodel6() { .version("0") .revision("9") .build()) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelTemplates/ExampleSubmodel") @@ -991,7 +991,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example RelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel RelationshipElement Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleRelationshipElement") @@ -1036,7 +1036,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example AnnotatedRelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel AnnotatedRelationshipElement Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleAnnotatedRelationshipElement") @@ -1077,7 +1077,7 @@ public static Submodel createSubmodel6() { .idShort("ExampleProperty") .category("PARAMETER") .value("some example annotation") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .submodelElements(new DefaultOperation.Builder() @@ -1087,7 +1087,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Operation object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Operation Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Operations/ExampleOperation") @@ -1102,7 +1102,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1111,10 +1111,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .outputVariables(new DefaultOperationVariable.Builder() @@ -1125,7 +1125,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1134,10 +1134,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .inoutputVariables(new DefaultOperationVariable.Builder() @@ -1148,7 +1148,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1157,10 +1157,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .build()) @@ -1171,7 +1171,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Capability object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Capability Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Capabilities/ExampleCapability") @@ -1188,7 +1188,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example BasicEvent object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel BasicEvent Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Events/ExampleBasicEvent") @@ -1215,12 +1215,12 @@ public static Submodel createSubmodel6() { .idShort("ExampleSubmodelElementListOrdered") .category("PARAMETER") .orderRelevant(true) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .description(Arrays.asList( new DefaultLangStringTextType.Builder().text("Example SubmodelElementListOrdered object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementListOrdered Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementLists/ExampleSubmodelElementListOrdered") @@ -1234,7 +1234,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1243,10 +1243,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -1255,7 +1255,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example value of a MultiLanguageProperty element").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispielswert für ein MultiLanguageProperty-Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/MultiLanguageProperties/ExampleMultiLanguageProperty") @@ -1274,7 +1274,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -1283,9 +1283,9 @@ public static Submodel createSubmodel6() { .build()) .min("0") .max("100") - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -1294,7 +1294,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -1308,7 +1308,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Blob object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Blob Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Blobs/ExampleBlob") @@ -1325,7 +1325,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example File object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel File Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Files/ExampleFile") @@ -1342,7 +1342,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Reference Element object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Reference Element Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ReferenceElements/ExampleReferenceElement") @@ -1382,7 +1382,7 @@ public static Submodel createSubmodel7() { .version("0") .revision("9") .build()) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelTemplates/ExampleSubmodel") @@ -1397,7 +1397,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example RelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel RelationshipElement Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleRelationshipElement") @@ -1442,7 +1442,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example AnnotatedRelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel AnnotatedRelationshipElement Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleAnnotatedRelationshipElement") @@ -1487,7 +1487,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Operation object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Operation Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Operations/ExampleOperation") @@ -1502,7 +1502,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1510,7 +1510,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .outputVariables(new DefaultOperationVariable.Builder() @@ -1521,7 +1521,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1529,7 +1529,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .inoutputVariables(new DefaultOperationVariable.Builder() @@ -1540,7 +1540,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1548,7 +1548,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .build()) .build()) @@ -1559,7 +1559,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Capability object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Capability Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Capabilities/ExampleCapability") @@ -1576,7 +1576,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example BasicEvent object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel BasicEvent Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Events/ExampleBasicEvent") @@ -1607,14 +1607,14 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementListOrdered object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementListOrdered Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementLists/ExampleSubmodelElementListOrdered") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .value(new DefaultProperty.Builder() .idShort("ExampleProperty") .category("CONSTANT") @@ -1622,7 +1622,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1630,7 +1630,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -1639,7 +1639,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example MultiLanguageProperty object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel MultiLanguageProperty Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE).value( "http://acplt.org/MultiLanguageProperties/ExampleMultiLanguageProperty") @@ -1654,7 +1654,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -1663,7 +1663,7 @@ public static Submodel createSubmodel7() { .build()) .min(null) .max("100") - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) .value(new DefaultRange.Builder() .idShort("ExampleRange2") @@ -1672,7 +1672,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -1681,9 +1681,9 @@ public static Submodel createSubmodel7() { .build()) .min("0") .max(null) - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) - .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -1692,7 +1692,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -1706,7 +1706,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Blob object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Blob Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Blobs/ExampleBlob") @@ -1722,7 +1722,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example File object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel File Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Files/ExampleFile") @@ -1739,7 +1739,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Reference Element object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Reference Element Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ReferenceElements/ExampleReferenceElement") @@ -1755,7 +1755,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -1845,7 +1845,7 @@ public static ConceptDescription createConceptDescription4() { .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text("Test Spec").language("de").build()) .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text("TestSpec").language("en-us").build()) .unit("SpaceUnit") - .unitID(new DefaultReference.Builder() + .unitId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Units/SpaceUnit") @@ -1859,7 +1859,7 @@ public static ConceptDescription createConceptDescription4() { .valueList(new DefaultValueList.Builder() .valueReferencePairs(new DefaultValueReferencePair.Builder() .value("http://acplt.org/ValueId/ExampleValueId") - .valueID(new DefaultReference.Builder() + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") @@ -1869,7 +1869,7 @@ public static ConceptDescription createConceptDescription4() { .build()) .valueReferencePairs(new DefaultValueReferencePair.Builder() .value("http://acplt.org/ValueId/ExampleValueId2") - .valueID(new DefaultReference.Builder() + .valueId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId2") diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java index 73681dc8b..111153c20 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java @@ -20,7 +20,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeIec61360; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Extension; @@ -43,7 +43,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultProperty; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultReference; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultResource; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetID; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetId; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodel; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementCollection; import org.junit.Assert; @@ -144,11 +144,11 @@ public static AssetAdministrationShell createAAS() { .id(AAS_IDENTIFIER) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetID(HTTP_CUSTOMER_COM_ASSETS_KHBVZJSQKIY) - .specificAssetIds(new DefaultSpecificAssetID.Builder() + .globalAssetId(HTTP_CUSTOMER_COM_ASSETS_KHBVZJSQKIY) + .specificAssetIds(new DefaultSpecificAssetId.Builder() .name(EQUIPMENT_ID) .value(_538FD1B3_F99F_4A52_9C75_72E9FA921270) - .externalSubjectID(new DefaultReference.Builder() + .externalSubjectId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(HTTP_CUSTOMER_COM_SYSTEMS_ERP_012) @@ -156,10 +156,10 @@ public static AssetAdministrationShell createAAS() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .build()) - .specificAssetIds(new DefaultSpecificAssetID.Builder() + .specificAssetIds(new DefaultSpecificAssetId.Builder() .name(DEVICE_ID) .value(QJ_YG_PGGJWKI_HK4_RR_QI_YS_LG) - .externalSubjectID(new DefaultReference.Builder() + .externalSubjectId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(HTTP_CUSTOMER_COM_SYSTEMS_IO_T_1) @@ -200,7 +200,7 @@ public static AssetAdministrationShell createAAS() { public static Submodel createSubmodelTechnicalData() { return new DefaultSubmodel.Builder() - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(SUBMODEL_TECHNICAL_DATA_SEMANTIC_ID) @@ -210,7 +210,7 @@ public static Submodel createSubmodelTechnicalData() { .idShort(SUBMODEL_TECHNICAL_DATA_ID_SHORT) .id(SUBMODEL_TECHNICAL_DATA_ID) .submodelElements(new DefaultProperty.Builder() - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_TECHNICAL_DATA_SEMANTIC_ID_PROPERTY) @@ -220,7 +220,7 @@ public static Submodel createSubmodelTechnicalData() { .idShort(SUBMODEL_TECHNICAL_DATA_PROPERTY_ID_SHORT) .category(SUBMODEL_TECHNICAL_DATA_PROPERTY_CATEGORY) .value(SUBMODEL_TECHNICAL_DATA_PROPERTY_VALUE) - .valueType(DataTypeDefXSD.INTEGER) + .valueType(DataTypeDefXsd.INTEGER) .build()) .build(); } @@ -231,7 +231,7 @@ public static Submodel createSubmodelOperationalData() { .idShort(SUBMODEL_OPERATIONAL_DATA_ID_SHORT) .id(SUBMODEL_OPERATIONAL_DATA_ID) .submodelElements(new DefaultProperty.Builder() - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_OPERATIONAL_DATA_SEMANTIC_ID_PROPERTY) @@ -241,7 +241,7 @@ public static Submodel createSubmodelOperationalData() { .idShort(SUBMODEL_OPERATIONAL_DATA_PROPERTY_ID_SHORT) .category(SUBMODEL_OPERATIONAL_DATA_PROPERTY_CATEGORY) .value(SUBMODEL_OPERATIONAL_DATA_PROPERTY_VALUE) - .valueType(DataTypeDefXSD.INTEGER) + .valueType(DataTypeDefXsd.INTEGER) .build()) .build(); } @@ -252,7 +252,7 @@ public static Submodel createSubmodelDocumentation() { .idShort(SUBMODEL_DOCUMENTATION_ID_SHORT) .id(SUBMODEL_DOCUMENTATION_ID) .submodelElements(new DefaultSubmodelElementCollection.Builder() - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_DOCUMENTATION_ELEMENTCOLLECTION_SEMANTIC_ID) @@ -261,7 +261,7 @@ public static Submodel createSubmodelDocumentation() { .build()) .idShort(SUBMODEL_DOCUMENTATION_ELEMENTCOLLECTION_ID_SHORT) .value(new DefaultProperty.Builder() - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_DOCUMENTATION_PROPERTY_SEMANTIC_ID) @@ -270,10 +270,10 @@ public static Submodel createSubmodelDocumentation() { .build()) .idShort(SUBMODEL_DOCUMENTATION_PROPERTY_ID_SHORT) .value(SUBMODEL_DOCUMENTATION_PROPERTY_VALUE) - .valueType(DataTypeDefXSD.STRING) + .valueType(DataTypeDefXsd.STRING) .build()) .value(new DefaultFile.Builder() - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_DOCUMENTATION_FILE_SEMANTIC_ID) @@ -364,7 +364,7 @@ public static ConceptDescription createConceptDescriptionMaxRotationSpeed() { .preferredName(new DefaultLangStringPreferredNameTypeIec61360.Builder().text(MAX_DREHZAHL).language("de").build()) .preferredName(new DefaultLangStringPreferredNameTypeIec61360.Builder().text(MAX_ROTATIONSPEED).language("en").build()) .unit(_1_MIN) - .unitID(new DefaultReference.Builder() + .unitId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(_0173_1_05_AAA650_002) @@ -401,7 +401,7 @@ public static ConceptDescription createConceptDescriptionRotationSpeed() { .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text(AKTUELLE_DREHZAHL).language("DE").build()) .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text(ACTUAL_ROTATION_SPEED).language("EN").build()) .unit(_1_MIN) - .unitID(new DefaultReference.Builder() + .unitId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(_0173_1_05_AAA650_002) diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java index 40652ceb7..93c4323cc 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java @@ -35,7 +35,7 @@ public class CustomProperty implements Property { protected Reference valueId; - protected DataTypeDefXSD valueType; + protected DataTypeDefXsd valueType; protected List qualifiers; @@ -82,12 +82,12 @@ public boolean equals(Object obj) { } @Override - final public DataTypeDefXSD getValueType() { + final public DataTypeDefXsd getValueType() { return this.valueType; } @Override - final public void setValueType(DataTypeDefXSD dataType) { + final public void setValueType(DataTypeDefXsd dataType) { this.valueType = dataType; } @@ -102,12 +102,12 @@ final public void setValue(String value) { } @Override - final public Reference getValueID() { + final public Reference getValueId() { return valueId; } @Override - final public void setValueID(Reference valueId) { + final public void setValueId(Reference valueId) { this.valueId = valueId; } @@ -172,12 +172,12 @@ final public void setEmbeddedDataSpecifications(List } @Override - final public Reference getSemanticID() { + final public Reference getSemanticId() { return semanticId; } @Override - final public void setSemanticID(Reference semanticId) { + final public void setSemanticId(Reference semanticId) { this.semanticId = semanticId; } diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java index 72261ada7..d8bc3ef3b 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java @@ -16,7 +16,7 @@ package org.eclipse.digitaltwin.aas4j.v3.dataformat.core; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.KeyTypes; import org.eclipse.digitaltwin.aas4j.v3.model.ReferenceTypes; @@ -37,7 +37,7 @@ public class Examples { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.NOT_APPLICABLE) - .globalAssetID("something_eea66fa1") + .globalAssetId("something_eea66fa1") .build()) .build()) .build(); @@ -48,7 +48,7 @@ public class Examples { .extensions(new DefaultExtension.Builder() .name("something_aae6caf4") .value("10233") - .valueType(DataTypeDefXSD.UNSIGNED_SHORT) + .valueType(DataTypeDefXsd.UNSIGNED_SHORT) .refersTo(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.SUBMODEL) @@ -56,7 +56,7 @@ public class Examples { .build()) .type(ReferenceTypes.MODEL_REFERENCE) .build()) - .semanticID(new DefaultReference.Builder() + .semanticId(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("urn:another-company07:4d1bd2cb") @@ -73,7 +73,7 @@ public class Examples { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.NOT_APPLICABLE) - .globalAssetID("something_eea66fa1") + .globalAssetId("something_eea66fa1") .build()) .build()) .build(); diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java index e420e8e53..0d16f6acb 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java @@ -21,8 +21,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; import java.util.Collection; -import org.eclipse.digitaltwin.aas4j.v3.model.AASSubmodelElements; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.AasSubmodelElements; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; public interface SubmodelElementListMixin { @@ -41,16 +41,16 @@ public interface SubmodelElementListMixin { public void setSemanticIdListElement(Reference semanticIdListElement); @JsonProperty("typeValueListElement") - public AASSubmodelElements getTypeValueListElement(); + public AasSubmodelElements getTypeValueListElement(); @JsonProperty("typeValueListElement") - public void setTypeValueListElement(AASSubmodelElements typeValueListElement); + public void setTypeValueListElement(AasSubmodelElements typeValueListElement); @JsonProperty("valueTypeListElement") - public DataTypeDefXSD getValueTypeListElement(); + public DataTypeDefXsd getValueTypeListElement(); @JsonProperty("valueTypeListElement") - public void setValueTypeListElement(DataTypeDefXSD valueTypeListElement); + public void setValueTypeListElement(DataTypeDefXsd valueTypeListElement); @JsonProperty("value") public Collection getValues(); diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java index 8a07eb1ea..f8500515c 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java @@ -132,7 +132,7 @@ public void testSerializeAssetInfo() throws SerializationException, Deserializat AssetInformation assetInfo = new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) .assetType("asset-type") - .globalAssetID("global-asset-id").build(); + .globalAssetId("global-asset-id").build(); String jsonString = new JsonSerializer().write(assetInfo); assertNotNull(jsonString); AssetInformation assetInfo2 = new JsonDeserializer().read(jsonString, AssetInformation.class); @@ -145,7 +145,7 @@ public void testDirectlySerializeAssetInfo() throws JsonProcessingException { AssetInformation assetInfo = new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) .assetType("asset-type") - .globalAssetID("global-asset-id").build(); + .globalAssetId("global-asset-id").build(); ObjectMapper mapper = ObjectMapperFactory.createMapper(); String jsonString = mapper.writeValueAsString(assetInfo); assertNotNull(jsonString); diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java index 6d35239d7..3f09276df 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java @@ -37,7 +37,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultKey; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultReference; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultResource; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetID; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetId; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementList; public class Examples { @@ -58,11 +58,11 @@ public class Examples { .id("https://example.org/AssetAdministrationShell") .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetID("https://example.org/Asset") - .specificAssetIds(new DefaultSpecificAssetID.Builder() + .globalAssetId("https://example.org/Asset") + .specificAssetIds(new DefaultSpecificAssetId.Builder() .name("ExampleAssetId") .value("ExampleValue") - .externalSubjectID(new DefaultReference.Builder() + .externalSubjectId(new DefaultReference.Builder() .type(ReferenceTypes.EXTERNAL_REFERENCE) .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java index e795faa56..a2004e30d 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java @@ -14,6 +14,6 @@ public class ValueReferencePairNodeDeserializer implements CustomJsonNodeDeseria public ValueReferencePair readValue(JsonNode node, JsonParser parser) throws IOException { String value = node.get("value").asText(); Reference valueId = DeserializationHelper.createInstanceFromNode(parser, node.get("valueId"), Reference.class); - return new DefaultValueReferencePair.Builder().value(value).valueID(valueId).build(); + return new DefaultValueReferencePair.Builder().value(value).valueId(valueId).build(); } } diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java index 19304faf5..31cbdd303 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java @@ -19,7 +19,7 @@ import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; import org.eclipse.digitaltwin.aas4j.v3.model.File; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetID; +import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; @@ -29,11 +29,11 @@ public interface AssetInformationMixin { @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetIds") - public List getSpecificAssetIds(); + public List getSpecificAssetIds(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetIds") - public void setSpecificAssetIds(List specificAssetIds); + public void setSpecificAssetIds(List SpecificAssetIds); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "globalAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "globalAssetId") diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java index ab98d6027..49131ecdf 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java @@ -16,7 +16,7 @@ package org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.mixins; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.QualifierKind; import org.eclipse.digitaltwin.aas4j.v3.model.Reference; @@ -36,7 +36,7 @@ public interface QualifierMixin { void setType(String type); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "valueType") - void setType(DataTypeDefXSD valueType); + void setType(DataTypeDefXsd valueType); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "value") void setValue(String value); diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java index 0af6f1b47..f90380e97 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java @@ -16,10 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.mixins; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; @JsonPropertyOrder({"path", "contentType"}) public interface ResourceMixin { @@ -28,5 +28,5 @@ public interface ResourceMixin { public String getPath(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "contentType") - public DataTypeDefXSD getContentType(); + public DataTypeDefXsd getContentType(); } diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIdMixin.java similarity index 94% rename from dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java rename to dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIdMixin.java index 511735600..54463ac98 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIdMixin.java @@ -22,7 +22,7 @@ import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; @JsonPropertyOrder({"hasSemantics", "name", "value", "externalSubjectId"}) -public interface SpecificAssetIDMixin { +public interface SpecificAssetIdMixin { @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "name") public String getName(); @@ -31,5 +31,5 @@ public interface SpecificAssetIDMixin { public String getValue(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "externalSubjectId") - public Reference getExternalSubjectID(); + public Reference getExternalSubjectId(); } diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java index bd95e887b..2364a2172 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java @@ -20,8 +20,8 @@ import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.deserialization.SubmodelElementsDeserializer; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.serialization.SubmodelElementsSerializer; -import org.eclipse.digitaltwin.aas4j.v3.model.AASSubmodelElements; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.AasSubmodelElements; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.Reference; import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; @@ -48,14 +48,14 @@ public interface SubmodelElementListMixin { public void setSemanticIdListElement(Reference semanticIdListElement); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "typeValueListElement") - public AASSubmodelElements getTypeValueListElement(); + public AasSubmodelElements getTypeValueListElement(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "typeValueListElement") - public void setTypeValueListElement(AASSubmodelElements typeValueListElement); + public void setTypeValueListElement(AasSubmodelElements typeValueListElement); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "valueTypeListElement") - public DataTypeDefXSD getValueTypeListElement(); + public DataTypeDefXsd getValueTypeListElement(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "valueTypeListElement") - public void setValueTypeListElement(DataTypeDefXSD valueTypeListElement); + public void setValueTypeListElement(DataTypeDefXsd valueTypeListElement); } diff --git a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java index c50574d3e..48ee65d92 100644 --- a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java +++ b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java @@ -31,7 +31,7 @@ import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Submodel; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAssetAdministrationShell; @@ -128,7 +128,7 @@ public void validateMinimalOperationAgainstXsdSchema() throws SerializationExcep .value(new DefaultProperty.Builder() .idShort("inputProperty") .value("1") - .valueType(DataTypeDefXSD.INT) + .valueType(DataTypeDefXsd.INT) .build()) .build()) .build()) @@ -140,7 +140,7 @@ public void validateMinimalOperationAgainstXsdSchema() throws SerializationExcep @Test public void validateGYearAgainstXsdSchema() throws SerializationException, SAXException { - Submodel submodel = new DefaultSubmodel.Builder().id("yearTestSm").submodelElements(new DefaultProperty.Builder().idShort("yearTestProp").valueType(DataTypeDefXSD.GYEAR).build()).build(); + Submodel submodel = new DefaultSubmodel.Builder().id("yearTestSm").submodelElements(new DefaultProperty.Builder().idShort("yearTestProp").valueType(DataTypeDefXsd.GYEAR).build()).build(); String xml = new XmlSerializer().write(new DefaultEnvironment.Builder().submodels(submodel).build()); Set errors = validateAgainstXsdSchema(xml); assertTrue(errors.isEmpty()); From 5b309383d93ad165963d72d5ab59dac525096df2 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Tue, 29 Aug 2023 16:21:27 +0200 Subject: [PATCH 05/18] Fix the JSON serialization/deserialization tests --- .../v3/dataformat/json/JsonDeserializer.java | 59 +++---------------- .../v3/dataformat/json/JsonSerializer.java | 39 +----------- .../dataformat/json/ObjectMapperFactory.java | 40 ++++--------- .../ReflectionAnnotationIntrospector.java | 8 +-- .../ReflectionAnnotationIntrospectorTest.java | 1 - 5 files changed, 27 insertions(+), 120 deletions(-) rename dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/{internal => }/ReflectionAnnotationIntrospector.java (93%) diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java index 03fdc9ca9..1786fa355 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java @@ -27,73 +27,30 @@ import java.util.List; import java.util.stream.Collectors; -import com.fasterxml.jackson.databind.module.SimpleModule; +import com.fasterxml.jackson.databind.ObjectMapper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.DeserializationException; -import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.deserialization.EnumDeserializer; -import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.util.ReflectionHelper; -import org.eclipse.digitaltwin.aas4j.v3.dataformat.json.internal.ReflectionAnnotationIntrospector; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Referable; import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.core.type.TypeReference; -import com.fasterxml.jackson.databind.DeserializationFeature; import com.fasterxml.jackson.databind.JsonNode; -import com.fasterxml.jackson.databind.json.JsonMapper; -//import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.module.SimpleAbstractTypeResolver; import static org.eclipse.digitaltwin.aas4j.v3.dataformat.json.ObjectMapperFactory.createMapper; -//import static org.eclipse.digitaltwin.aas4j.v3.dataformat.json.ObjectMapperFactory.createTypeResolver; - +import static org.eclipse.digitaltwin.aas4j.v3.dataformat.json.ObjectMapperFactory.createTypeResolver; /** * Class for deserializing/parsing AAS JSON documents. */ public class JsonDeserializer { - - protected JsonMapper mapper; -// protected ObjectMapper mapper; - protected SimpleAbstractTypeResolver typeResolver; - private static final Charset DEFAULT_CHARSET = StandardCharsets.UTF_8; + protected ObjectMapper mapper; + protected final SimpleAbstractTypeResolver typeResolver; public JsonDeserializer() { - initTypeResolver(); - buildMapper(); -// typeResolver = createTypeResolver(); -// mapper = createMapper(typeResolver); - } - - protected void buildMapper() { - mapper = JsonMapper.builder() - .enable(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY) - .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES) - .annotationIntrospector(new ReflectionAnnotationIntrospector()) - .addModule(buildEnumModule()) - .addModule(buildImplementationModule()) - .build(); - ReflectionHelper.JSON_MIXINS.entrySet().forEach(x -> mapper.addMixIn(x.getKey(), x.getValue())); - } - - @SuppressWarnings("unchecked") - private void initTypeResolver() { - typeResolver = new SimpleAbstractTypeResolver(); - ReflectionHelper.DEFAULT_IMPLEMENTATIONS - .stream() - .forEach(x -> typeResolver.addMapping(x.getInterfaceType(), x.getImplementationType())); - } - - protected SimpleModule buildEnumModule() { - SimpleModule module = new SimpleModule(); - ReflectionHelper.ENUMS.forEach(x -> module.addDeserializer(x, new EnumDeserializer<>(x))); - return module; - } - - protected SimpleModule buildImplementationModule() { - SimpleModule module = new SimpleModule(); - module.setAbstractTypes(typeResolver); - return module; + typeResolver = createTypeResolver(); + mapper = createMapper(typeResolver); } /** @@ -161,7 +118,7 @@ public Environment read(InputStream src, Charset charset) throws Deserialization * @throws FileNotFoundException if file is not present * @throws DeserializationException if deserialization fails */ - public Environment read(java.io.File file, Charset charset) + public Environment read(File file, Charset charset) throws FileNotFoundException, DeserializationException { return read(new FileInputStream(file), charset); } @@ -174,7 +131,7 @@ public Environment read(java.io.File file, Charset charset) * @throws FileNotFoundException if the file is not present * @throws DeserializationException if deserialization fails */ - public Environment read(java.io.File file) throws FileNotFoundException, DeserializationException { + public Environment read(File file) throws FileNotFoundException, DeserializationException { return read(file, DEFAULT_CHARSET); } diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java index 84bb9b21a..e03057a44 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java @@ -21,61 +21,28 @@ import java.util.Collection; import java.util.List; +import com.fasterxml.jackson.databind.ObjectMapper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.SerializationException; -import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.serialization.EnumSerializer; -import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.util.ReflectionHelper; -import org.eclipse.digitaltwin.aas4j.v3.dataformat.json.internal.ReflectionAnnotationIntrospector; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Referable; -import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.DeserializationFeature; import com.fasterxml.jackson.databind.JsonNode; -import com.fasterxml.jackson.databind.SerializationFeature; -import com.fasterxml.jackson.databind.json.JsonMapper; -import com.fasterxml.jackson.databind.module.SimpleModule; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.io.OutputStream; import java.io.OutputStreamWriter; -import java.util.Objects; - -//import com.fasterxml.jackson.core.JsonProcessingException; -//import com.fasterxml.jackson.databind.ObjectMapper; -//import com.fasterxml.jackson.databind.ObjectWriter; -// -//import java.util.List; /** * Class for serializing an instance of AssetAdministrationShellEnvironment or Referables to JSON. */ public class JsonSerializer { - -// protected final ObjectMapper mapper; - protected JsonMapper mapper; - private static final Charset DEFAULT_CHARSET = StandardCharsets.UTF_8; + protected final ObjectMapper mapper; public JsonSerializer() { - buildMapper(); - } - - protected void buildMapper() { - mapper = JsonMapper.builder().enable(SerializationFeature.INDENT_OUTPUT) - .enable(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY) - .serializationInclusion(JsonInclude.Include.NON_NULL) - .addModule(buildEnumModule()) - .annotationIntrospector(new ReflectionAnnotationIntrospector()) - .build(); - ReflectionHelper.JSON_MIXINS.entrySet().forEach(x -> mapper.addMixIn(x.getKey(), x.getValue())); - } - - protected SimpleModule buildEnumModule() { - SimpleModule module = new SimpleModule(); - module.addSerializer(Enum.class, new EnumSerializer()); - return module; + mapper = ObjectMapperFactory.createMapper(); } /** diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java index 4e80cdca9..6a0ae0dd9 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ObjectMapperFactory.java @@ -1,19 +1,3 @@ -/* - * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (c) 2022 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.dataformat.json; import com.fasterxml.jackson.annotation.JsonInclude; @@ -23,9 +7,9 @@ import com.fasterxml.jackson.databind.json.JsonMapper; import com.fasterxml.jackson.databind.module.SimpleAbstractTypeResolver; import com.fasterxml.jackson.databind.module.SimpleModule; -//import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.ReflectionHelper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.deserialization.EnumDeserializer; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.serialization.EnumSerializer; +import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.util.ReflectionHelper; /** * This class contains the initialization code used by the JsonSerializer and JsonDeserializer. It also contains a @@ -65,18 +49,18 @@ public static ObjectMapper createMapper() { * @return the configured object mapper. According to the Jackson documentation the ObjectMapper class is * thread-safe. */ - static JsonMapper createMapper(SimpleAbstractTypeResolver typeResolver) { - JsonMapper mapper = JsonMapper.builder() + static ObjectMapper createMapper(SimpleAbstractTypeResolver typeResolver) { + ObjectMapper mapper = JsonMapper.builder() .enable(SerializationFeature.INDENT_OUTPUT) .enable(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY) .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES) .serializationInclusion(JsonInclude.Include.NON_NULL) .serializationInclusion(JsonInclude.Include.NON_EMPTY) -// .annotationIntrospector(new ReflectionAnnotationIntrospector()) + .annotationIntrospector(new ReflectionAnnotationIntrospector()) .addModule(buildEnumModule()) .addModule(buildTypeResolverModule(typeResolver)) .build(); -// ReflectionHelper.JSON_MIXINS.entrySet().forEach(x -> mapper.addMixIn(x.getKey(), x.getValue())); + ReflectionHelper.JSON_MIXINS.entrySet().forEach(x -> mapper.addMixIn(x.getKey(), x.getValue())); return mapper; } @@ -87,9 +71,9 @@ static JsonMapper createMapper(SimpleAbstractTypeResolver typeResolver) { */ static SimpleAbstractTypeResolver createTypeResolver() { SimpleAbstractTypeResolver typeResolver = new SimpleAbstractTypeResolver(); -// ReflectionHelper.DEFAULT_IMPLEMENTATIONS -// .stream() -// .forEach(x -> typeResolver.addMapping(x.getInterfaceType(), x.getImplementationType())); + ReflectionHelper.DEFAULT_IMPLEMENTATIONS + .stream() + .forEach(x -> typeResolver.addMapping(x.getInterfaceType(), x.getImplementationType())); return typeResolver; } @@ -104,10 +88,10 @@ private static SimpleModule buildTypeResolverModule(SimpleAbstractTypeResolver t private static SimpleModule buildEnumModule() { SimpleModule module = new SimpleModule(); -// ReflectionHelper.ENUMS.forEach(x -> { -// module.addDeserializer(x, new EnumDeserializer<>(x)); -// module.addSerializer(x, new EnumSerializer()); -// }); + ReflectionHelper.ENUMS.forEach(x -> { + module.addDeserializer(x, new EnumDeserializer<>(x)); + module.addSerializer(x, new EnumSerializer()); + }); return module; } } diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/internal/ReflectionAnnotationIntrospector.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ReflectionAnnotationIntrospector.java similarity index 93% rename from dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/internal/ReflectionAnnotationIntrospector.java rename to dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ReflectionAnnotationIntrospector.java index 7aa2d6560..258bba1db 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/internal/ReflectionAnnotationIntrospector.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ReflectionAnnotationIntrospector.java @@ -1,5 +1,6 @@ /* * 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. @@ -13,7 +14,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.eclipse.digitaltwin.aas4j.v3.dataformat.json.internal; +package org.eclipse.digitaltwin.aas4j.v3.dataformat.json; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -31,7 +32,7 @@ import java.util.stream.Collectors; /** - * This class helps to dynamically decide how to de-/serialize classes and + * This utility class has package-private visibility and helps to dynamically decide how to de-/serialize classes and * properties defined in the AAS model library. * * This is equivalent to adding the following annotations @@ -52,7 +53,7 @@ * * */ -public class ReflectionAnnotationIntrospector extends JacksonAnnotationIntrospector { +class ReflectionAnnotationIntrospector extends JacksonAnnotationIntrospector { private static final long serialVersionUID = 1L; @@ -108,5 +109,4 @@ public JsonInclude.Value findPropertyInclusion(Annotated a) { } return result; } - } diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ReflectionAnnotationIntrospectorTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ReflectionAnnotationIntrospectorTest.java index a020dd4a9..e391295a6 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ReflectionAnnotationIntrospectorTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/ReflectionAnnotationIntrospectorTest.java @@ -27,7 +27,6 @@ import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.CustomSubProperty; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.CustomSubmodel; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.CustomSubmodel2; -import org.eclipse.digitaltwin.aas4j.v3.dataformat.json.internal.ReflectionAnnotationIntrospector; import org.eclipse.digitaltwin.aas4j.v3.dataformat.json.mixins.ReferenceMixin; import org.junit.Before; import org.junit.Test; From 65e70f95cfeab0907b6074e726605bee15d2ecd5 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 11:15:07 +0200 Subject: [PATCH 06/18] Update JsonSerializer.java --- .../digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java index 84bb9b21a..f6cf9f438 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java @@ -49,7 +49,7 @@ //import java.util.List; /** - * Class for serializing an instance of AssetAdministrationShellEnvironment or Referables to JSON. + * Class for serializing an instance of AssetAdministrationShellEnvironment or Referables to JSON. */ public class JsonSerializer { From 389c68af599a7a2653f4a46a034daeb6a3909580 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 14:47:53 +0200 Subject: [PATCH 07/18] Fix the model and compile errors --- ...ssetAdministrationShellElementVisitor.java | 8 +- ...ministrationShellElementWalkerVisitor.java | 12 +- .../core/serialization/EnumSerializer.java | 8 +- .../aas4j/v3/dataformat/core/AASFull.java | 238 +++++++++--------- .../aas4j/v3/dataformat/core/AASSimple.java | 36 +-- .../v3/dataformat/core/CustomProperty.java | 14 +- .../aas4j/v3/dataformat/core/Examples.java | 10 +- .../json/mixins/SubmodelElementListMixin.java | 12 +- .../dataformat/json/JsonSerializerTest.java | 4 +- .../v3/dataformat/json/util/Examples.java | 8 +- .../ValueReferencePairNodeDeserializer.java | 2 +- .../xml/mixins/AssetInformationMixin.java | 6 +- .../dataformat/xml/mixins/QualifierMixin.java | 4 +- .../dataformat/xml/mixins/ResourceMixin.java | 4 +- ...IdMixin.java => SpecificAssetIDMixin.java} | 6 +- .../xml/mixins/SubmodelElementListMixin.java | 12 +- .../v3/dataformat/xml/XmlSerializerTest.java | 7 +- .../aas4j/v3/model/AASSubmodelElements.java | 39 ++- .../aas4j/v3/model/AbstractLangString.java | 3 +- .../v3/model/AdministrativeInformation.java | 55 ++-- .../model/AnnotatedRelationshipElement.java | 1 - .../v3/model/AssetAdministrationShell.java | 37 ++- .../AssetAdministrationShellDescriptor.java | 186 -------------- .../aas4j/v3/model/AssetInformation.java | 81 +++--- .../digitaltwin/aas4j/v3/model/AssetKind.java | 1 - .../aas4j/v3/model/BasicEventElement.java | 119 +++++---- .../digitaltwin/aas4j/v3/model/Blob.java | 37 ++- .../aas4j/v3/model/Capability.java | 1 - .../aas4j/v3/model/ConceptDescription.java | 5 +- .../aas4j/v3/model/DataElement.java | 1 - .../v3/model/DataSpecificationContent.java | 1 - .../v3/model/DataSpecificationIec61360.java | 193 +++++++------- .../aas4j/v3/model/DataTypeDefXSD.java | 65 +++-- .../aas4j/v3/model/DataTypeIec61360.java | 41 ++- .../aas4j/v3/model/Descriptor.java | 49 ---- .../digitaltwin/aas4j/v3/model/Direction.java | 1 - .../v3/model/EmbeddedDataSpecification.java | 1 - .../digitaltwin/aas4j/v3/model/Endpoint.java | 61 ----- .../digitaltwin/aas4j/v3/model/Entity.java | 63 +++-- .../aas4j/v3/model/EntityType.java | 1 - .../aas4j/v3/model/Environment.java | 37 ++- .../aas4j/v3/model/EventElement.java | 1 - .../aas4j/v3/model/EventPayload.java | 131 +++++----- .../digitaltwin/aas4j/v3/model/Extension.java | 37 ++- .../digitaltwin/aas4j/v3/model/File.java | 37 ++- .../aas4j/v3/model/HasDataSpecification.java | 3 +- .../aas4j/v3/model/HasExtensions.java | 1 - .../digitaltwin/aas4j/v3/model/HasKind.java | 1 - .../aas4j/v3/model/HasSemantics.java | 17 +- .../aas4j/v3/model/Identifiable.java | 1 - .../digitaltwin/aas4j/v3/model/Key.java | 1 - .../digitaltwin/aas4j/v3/model/KeyTypes.java | 1 - .../aas4j/v3/model/LangString.java | 93 ------- .../LangStringDefinitionTypeIec61360.java | 1 - .../aas4j/v3/model/LangStringNameType.java | 1 - .../LangStringPreferredNameTypeIec61360.java | 1 - .../LangStringShortNameTypeIec61360.java | 1 - .../aas4j/v3/model/LangStringTextType.java | 1 - .../digitaltwin/aas4j/v3/model/LevelType.java | 39 ++- .../aas4j/v3/model/ModellingKind.java | 1 - .../aas4j/v3/model/MultiLanguageProperty.java | 19 +- .../digitaltwin/aas4j/v3/model/Operation.java | 39 ++- .../aas4j/v3/model/OperationVariable.java | 1 - .../digitaltwin/aas4j/v3/model/Property.java | 53 ++-- .../aas4j/v3/model/ProtocolInformation.java | 135 ---------- .../aas4j/v3/model/Qualifiable.java | 1 - .../digitaltwin/aas4j/v3/model/Qualifier.java | 53 ++-- .../aas4j/v3/model/QualifierKind.java | 3 +- .../digitaltwin/aas4j/v3/model/Range.java | 37 ++- .../digitaltwin/aas4j/v3/model/Referable.java | 49 ++-- .../digitaltwin/aas4j/v3/model/Reference.java | 55 ++-- .../aas4j/v3/model/ReferenceElement.java | 1 - .../aas4j/v3/model/ReferenceTypes.java | 1 - .../aas4j/v3/model/RelationshipElement.java | 1 - .../digitaltwin/aas4j/v3/model/Resource.java | 37 ++- .../aas4j/v3/model/SpecificAssetID.java | 57 +++-- .../aas4j/v3/model/StateOfEvent.java | 1 - .../digitaltwin/aas4j/v3/model/Submodel.java | 3 +- .../aas4j/v3/model/SubmodelDescriptor.java | 133 ---------- .../aas4j/v3/model/SubmodelElement.java | 7 +- .../v3/model/SubmodelElementCollection.java | 11 +- .../aas4j/v3/model/SubmodelElementList.java | 57 +++-- .../digitaltwin/aas4j/v3/model/ValueList.java | 1 - .../aas4j/v3/model/ValueReferencePair.java | 19 +- .../aas4j/v3/model/annotations/IRI.java | 1 - .../v3/model/annotations/KnownSubtypes.java | 1 - .../v3/model/builder/AbstractBuilder.java | 1 - .../AdministrativeInformationBuilder.java | 31 ++- .../AnnotatedRelationshipElementBuilder.java | 101 ++++---- .../AssetAdministrationShellBuilder.java | 69 +++-- ...tAdministrationShellDescriptorBuilder.java | 145 ----------- .../builder/AssetInformationBuilder.java | 53 ++-- .../builder/BasicEventElementBuilder.java | 163 ++++++------ .../aas4j/v3/model/builder/BlobBuilder.java | 121 +++++---- .../aas4j/v3/model/builder/Builder.java | 1 - .../v3/model/builder/CapabilityBuilder.java | 101 ++++---- .../builder/ConceptDescriptionBuilder.java | 55 ++-- .../DataSpecificationIec61360Builder.java | 131 +++++----- .../v3/model/builder/DescriptorBuilder.java | 46 ---- .../EmbeddedDataSpecificationBuilder.java | 1 - .../v3/model/builder/EndpointBuilder.java | 46 ---- .../aas4j/v3/model/builder/EntityBuilder.java | 159 ++++++------ .../v3/model/builder/EnvironmentBuilder.java | 41 ++- .../v3/model/builder/EventPayloadBuilder.java | 71 +++--- .../v3/model/builder/ExtendableBuilder.java | 1 - .../v3/model/builder/ExtensionBuilder.java | 53 ++-- .../aas4j/v3/model/builder/FileBuilder.java | 121 +++++---- .../aas4j/v3/model/builder/KeyBuilder.java | 1 - ...ngStringDefinitionTypeIec61360Builder.java | 1 - .../builder/LangStringNameTypeBuilder.java | 1 - ...tringPreferredNameTypeIec61360Builder.java | 1 - ...angStringShortNameTypeIec61360Builder.java | 1 - .../builder/LangStringTextTypeBuilder.java | 1 - .../v3/model/builder/LevelTypeBuilder.java | 23 +- .../builder/MultiLanguagePropertyBuilder.java | 117 +++++---- .../v3/model/builder/OperationBuilder.java | 145 ++++++----- .../builder/OperationVariableBuilder.java | 1 - .../v3/model/builder/PropertyBuilder.java | 131 +++++----- .../builder/ProtocolInformationBuilder.java | 88 ------- .../v3/model/builder/QualifierBuilder.java | 43 ++-- .../aas4j/v3/model/builder/RangeBuilder.java | 121 +++++---- .../v3/model/builder/ReferenceBuilder.java | 41 ++- .../builder/ReferenceElementBuilder.java | 101 ++++---- .../builder/RelationshipElementBuilder.java | 101 ++++---- .../v3/model/builder/ResourceBuilder.java | 21 +- .../model/builder/SpecificAssetIDBuilder.java | 41 ++- .../v3/model/builder/SubmodelBuilder.java | 131 +++++----- .../builder/SubmodelDescriptorBuilder.java | 117 --------- .../SubmodelElementCollectionBuilder.java | 110 ++++---- .../builder/SubmodelElementListBuilder.java | 141 ++++++----- .../v3/model/builder/ValueListBuilder.java | 1 - .../builder/ValueReferencePairBuilder.java | 11 +- .../DefaultAdministrativeInformation.java | 55 ++-- .../DefaultAnnotatedRelationshipElement.java | 80 +++--- .../impl/DefaultAssetAdministrationShell.java | 80 +++--- ...ultAssetAdministrationShellDescriptor.java | 216 ---------------- .../model/impl/DefaultAssetInformation.java | 68 +++-- .../model/impl/DefaultBasicEventElement.java | 164 ++++++------ .../aas4j/v3/model/impl/DefaultBlob.java | 105 ++++---- .../v3/model/impl/DefaultCapability.java | 79 +++--- .../model/impl/DefaultConceptDescription.java | 44 ++-- .../DefaultDataSpecificationIec61360.java | 172 ++++++------- .../v3/model/impl/DefaultDescriptor.java | 80 ------ .../DefaultEmbeddedDataSpecification.java | 13 +- .../aas4j/v3/model/impl/DefaultEndpoint.java | 93 ------- .../aas4j/v3/model/impl/DefaultEntity.java | 133 +++++----- .../v3/model/impl/DefaultEnvironment.java | 38 ++- .../v3/model/impl/DefaultEventPayload.java | 116 ++++----- .../aas4j/v3/model/impl/DefaultExtension.java | 59 ++--- .../aas4j/v3/model/impl/DefaultFile.java | 105 ++++---- .../aas4j/v3/model/impl/DefaultKey.java | 13 +- ...faultLangStringDefinitionTypeIec61360.java | 17 +- .../model/impl/DefaultLangStringNameType.java | 13 +- ...ltLangStringPreferredNameTypeIec61360.java | 17 +- ...efaultLangStringShortNameTypeIec61360.java | 17 +- .../model/impl/DefaultLangStringTextType.java | 13 +- .../aas4j/v3/model/impl/DefaultLevelType.java | 47 ++-- .../impl/DefaultMultiLanguageProperty.java | 101 ++++---- .../aas4j/v3/model/impl/DefaultOperation.java | 110 ++++---- .../model/impl/DefaultOperationVariable.java | 8 - .../aas4j/v3/model/impl/DefaultProperty.java | 124 +++++---- .../impl/DefaultProtocolInformation.java | 152 ----------- .../aas4j/v3/model/impl/DefaultQualifier.java | 72 +++--- .../aas4j/v3/model/impl/DefaultRange.java | 108 ++++---- .../aas4j/v3/model/impl/DefaultReference.java | 54 ++-- .../model/impl/DefaultReferenceElement.java | 80 +++--- .../impl/DefaultRelationshipElement.java | 81 +++--- .../aas4j/v3/model/impl/DefaultResource.java | 37 ++- .../v3/model/impl/DefaultSpecificAssetID.java | 86 +++---- .../aas4j/v3/model/impl/DefaultSubmodel.java | 116 ++++----- .../model/impl/DefaultSubmodelDescriptor.java | 174 ------------- .../DefaultSubmodelElementCollection.java | 89 ++++--- .../impl/DefaultSubmodelElementList.java | 128 +++++----- .../aas4j/v3/model/impl/DefaultValueList.java | 8 - .../model/impl/DefaultValueReferencePair.java | 29 +-- 175 files changed, 3393 insertions(+), 5618 deletions(-) rename dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/{SpecificAssetIdMixin.java => SpecificAssetIDMixin.java} (94%) delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangString.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java delete mode 100644 model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java index 1d6e63b4d..f9b13eceb 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementVisitor.java @@ -53,7 +53,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.ReferenceElement; import org.eclipse.digitaltwin.aas4j.v3.model.RelationshipElement; import org.eclipse.digitaltwin.aas4j.v3.model.Resource; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; +import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetID; import org.eclipse.digitaltwin.aas4j.v3.model.Submodel; import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElementCollection; @@ -132,8 +132,8 @@ public default void visit(HasSemantics hasSemantics) { Class type = hasSemantics.getClass(); if (Extension.class.isAssignableFrom(type)) { visit((Extension) hasSemantics); - } else if (SpecificAssetId.class.isAssignableFrom(type)) { - visit((SpecificAssetId) hasSemantics); + } else if (SpecificAssetID.class.isAssignableFrom(type)) { + visit((SpecificAssetID) hasSemantics); } else if (Submodel.class.isAssignableFrom(type)) { visit((Submodel) hasSemantics); } else if (SubmodelElement.class.isAssignableFrom(type)) { @@ -245,7 +245,7 @@ public default void visit(Extension extension) { public default void visit(File file) { } - public default void visit(SpecificAssetId identifierKeyValuePair) { + public default void visit(SpecificAssetID identifierKeyValuePair) { } public default void visit(Key key) { diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java index e58231115..110bb2f4a 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java @@ -98,7 +98,7 @@ public default void visit(HasSemantics hasSemantics) { if (hasSemantics == null) { return; } - visit(hasSemantics.getSemanticId()); + visit(hasSemantics.getSemanticID()); hasSemantics.getSupplementalSemanticIds().forEach(x->visit(x)); AssetAdministrationShellElementVisitor.super.visit(hasSemantics); } @@ -113,11 +113,11 @@ public default void visit(Identifiable identifiable) { } @Override - public default void visit(SpecificAssetId specificAssetId) { + public default void visit(SpecificAssetID specificAssetId) { if (specificAssetId == null) { return; } - visit(specificAssetId.getExternalSubjectId()); + visit(specificAssetId.getExternalSubjectID()); AssetAdministrationShellElementVisitor.super.visit(specificAssetId); } @@ -127,7 +127,7 @@ public default void visit(MultiLanguageProperty multiLanguageProperty) { return; } multiLanguageProperty.getValue().forEach(x -> visit(x)); - visit(multiLanguageProperty.getValueId()); + visit(multiLanguageProperty.getValueID()); AssetAdministrationShellElementVisitor.super.visit(multiLanguageProperty); } @@ -145,7 +145,7 @@ public default void visit(Property property) { if (property == null) { return; } - visit(property.getValueId()); + visit(property.getValueID()); AssetAdministrationShellElementVisitor.super.visit(property); } @@ -163,7 +163,7 @@ public default void visit(Qualifier qualifier) { if (qualifier == null) { return; } - visit(qualifier.getValueId()); + visit(qualifier.getValueID()); AssetAdministrationShellElementVisitor.super.visit(qualifier); } diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java index 147bfadf3..7d95737e8 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java @@ -19,7 +19,7 @@ import java.io.IOException; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.util.ReflectionHelper; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeIec61360; import org.eclipse.digitaltwin.aas4j.v3.model.Direction; import org.eclipse.digitaltwin.aas4j.v3.model.StateOfEvent; @@ -38,11 +38,11 @@ public class EnumSerializer extends JsonSerializer { @Override public void serialize(Enum value, JsonGenerator gen, SerializerProvider provider) throws IOException { - if (value instanceof DataTypeDefXsd) { + if (value instanceof DataTypeDefXSD) { // only for the DataTypeDefXsd notation - if (value.equals(DataTypeDefXsd.ANY_URI)) { + if (value.equals(DataTypeDefXSD.ANY_URI)) { gen.writeString("xs:anyURI"); - } else if (value.equals(DataTypeDefXsd.NON_NEGATIVE_INTEGER)) { + } else if (value.equals(DataTypeDefXSD.NON_NEGATIVE_INTEGER)) { gen.writeString("xs:nonNegativeInteger"); } else if(isTimeRelatedValue(value)) { handleTimeRelatedValue(gen, value); diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java index 4833a5850..790f5054a 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java @@ -18,11 +18,11 @@ import java.util.Arrays; import java.util.Base64; -import org.eclipse.digitaltwin.aas4j.v3.model.AasSubmodelElements; +import org.eclipse.digitaltwin.aas4j.v3.model.AASSubmodelElements; import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeIec61360; import org.eclipse.digitaltwin.aas4j.v3.model.Direction; import org.eclipse.digitaltwin.aas4j.v3.model.EntityType; @@ -106,7 +106,7 @@ public static AssetAdministrationShell createAAS1() { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetId("https://acplt.org/Test_Asset") + .globalAssetID("https://acplt.org/Test_Asset") .build()) .submodels(new DefaultReference.Builder() .keys(new DefaultKey.Builder() @@ -138,7 +138,7 @@ public static AssetAdministrationShell createAAS2() { .id("https://acplt.org/Test_AssetAdministrationShell_Mandatory") .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetId("https://acplt.org/Test_Asset_Mandatory") + .globalAssetID("https://acplt.org/Test_Asset_Mandatory") .build()) .submodels(new DefaultReference.Builder() .keys(new DefaultKey.Builder() @@ -163,7 +163,7 @@ public static AssetAdministrationShell createAAS3() { .id("https://acplt.org/Test_AssetAdministrationShell2_Mandatory") .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetId("https://acplt.org/Test_Asset_Mandatory") + .globalAssetID("https://acplt.org/Test_Asset_Mandatory") .build()) .build(); } @@ -182,7 +182,7 @@ public static AssetAdministrationShell createAAS4() { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetId("https://acplt.org/Test_Asset_Missing") + .globalAssetID("https://acplt.org/Test_Asset_Missing") .build()) .submodels(new DefaultReference.Builder() .keys(new DefaultKey.Builder() @@ -207,7 +207,7 @@ public static Submodel createSubmodel1() { .revision("9") .build()) .kind(ModellingKind.INSTANCE) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.SUBMODEL) .value("http://acplt.org/SubmodelTemplates/AssetIdentification") @@ -223,7 +223,7 @@ public static Submodel createSubmodel1() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("0173-1#02-AAO677#002") @@ -234,16 +234,16 @@ public static Submodel createSubmodel1() { .qualifiers(new DefaultQualifier.Builder() .value("100") .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) .qualifiers(new DefaultQualifier.Builder() .value("50") .type("http://acplt.org/Qualifier/ExampleQualifier2") - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) .value("http://acplt.org/ValueId/ACPLT") - .valueType(DataTypeDefXsd.STRING) - .valueId(new DefaultReference.Builder() + .valueType(DataTypeDefXSD.STRING) + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ACPLT") @@ -258,7 +258,7 @@ public static Submodel createSubmodel1() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://opcfoundation.org/UA/DI/1.1/DeviceType/Serialnumber") @@ -282,8 +282,8 @@ public static Submodel createSubmodel1() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build())) .value("978-8234-234-342") - .valueType(DataTypeDefXsd.STRING) - .valueId(new DefaultReference.Builder() + .valueType(DataTypeDefXSD.STRING) + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("978-8234-234-342") @@ -306,7 +306,7 @@ public static Submodel createSubmodel2() { .version("0") .build()) .kind(ModellingKind.INSTANCE) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.SUBMODEL) .value("http://acplt.org/SubmodelTemplates/BillOfMaterial") @@ -319,7 +319,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://opcfoundation.org/UA/DI/1.1/DeviceType/Serialnumber") @@ -333,7 +333,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -341,8 +341,8 @@ public static Submodel createSubmodel2() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValue2") - .valueType(DataTypeDefXsd.STRING) - .valueId(new DefaultReference.Builder() + .valueType(DataTypeDefXSD.STRING) + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValue2") @@ -357,7 +357,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -365,8 +365,8 @@ public static Submodel createSubmodel2() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueType(DataTypeDefXsd.STRING) - .valueId(new DefaultReference.Builder() + .valueType(DataTypeDefXSD.STRING) + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") @@ -382,7 +382,7 @@ public static Submodel createSubmodel2() { new DefaultLangStringTextType.Builder().text("Legally valid designation of the natural or judicial person which is directly responsible for the design, production, packaging and labeling of a product in respect to its being brought into circulation.").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Bezeichnung für eine natürliche oder juristische Person, die für die Auslegung, Herstellung und Verpackung sowie die Etikettierung eines Produkts im Hinblick auf das 'Inverkehrbringen' im eigenen Namen verantwortlich ist").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://opcfoundation.org/UA/DI/1.1/DeviceType/Serialnumber") @@ -390,7 +390,7 @@ public static Submodel createSubmodel2() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .entityType(EntityType.SELF_MANAGED_ENTITY) - .globalAssetId("https://acplt.org/Test_Asset2") + .globalAssetID("https://acplt.org/Test_Asset2") .build()) .build(); } @@ -408,7 +408,7 @@ public static Submodel createSubmodel3() { .revision("9") .build()) .kind(ModellingKind.INSTANCE) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelTemplates/ExampleSubmodel") @@ -422,7 +422,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example RelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel RelationshipElement Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleRelationshipElement") @@ -467,7 +467,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example AnnotatedRelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel AnnotatedRelationshipElement Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleAnnotatedRelationshipElement") @@ -508,7 +508,7 @@ public static Submodel createSubmodel3() { .idShort("ExampleProperty3") .category("PARAMETER") .value("some example annotation") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .submodelElements(new DefaultOperation.Builder() @@ -518,7 +518,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Operation object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Operation Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Operations/ExampleOperation") @@ -533,7 +533,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -541,14 +541,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueId(new DefaultReference.Builder() + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .outputVariables(new DefaultOperationVariable.Builder() @@ -559,7 +559,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -567,14 +567,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueId(new DefaultReference.Builder() + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .inoutputVariables(new DefaultOperationVariable.Builder() @@ -585,7 +585,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -593,14 +593,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueId(new DefaultReference.Builder() + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .build()) @@ -611,7 +611,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Capability object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Capability Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Capabilities/ExampleCapability") @@ -628,7 +628,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example BasicEvent object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel BasicEvent Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Events/ExampleBasicEvent") @@ -659,14 +659,14 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example ExampleSubmodelElementListOrdered object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel ExampleSubmodelElementListOrdered Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementLists/ExampleSubmodelElementListOrdered") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .value(new DefaultProperty.Builder() .idShort("ExampleProperty") .category("CONSTANT") @@ -674,7 +674,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -682,14 +682,14 @@ public static Submodel createSubmodel3() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value("http://acplt.org/ValueId/ExampleValueId") - .valueId(new DefaultReference.Builder() + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -698,7 +698,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example value of a MultiLanguageProperty element").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispielswert für ein MultiLanguageProperty-Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/MultiLanguageProperties/ExampleMultiLanguageProperty") @@ -709,7 +709,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example MultiLanguageProperty object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel MultiLanguageProperty Element").language("de").build() )) - .valueId(new DefaultReference.Builder() + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleMultiLanguageValueId") @@ -724,7 +724,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -733,9 +733,9 @@ public static Submodel createSubmodel3() { .build()) .min("0") .max("100") - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -744,7 +744,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -758,7 +758,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Blob object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Blob Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder().type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Blobs/ExampleBlob") .build()) @@ -774,7 +774,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example File object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel File Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Files/ExampleFile") @@ -791,7 +791,7 @@ public static Submodel createSubmodel3() { new DefaultLangStringTextType.Builder().text("Example Reference Element object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Reference Element Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE).value( "http://acplt.org/ReferenceElements/ExampleReferenceElement") @@ -918,11 +918,11 @@ public static Submodel createSubmodel4() { .submodelElements(new DefaultSubmodelElementList.Builder() .idShort("ExampleSubmodelElementListUnordered") .orderRelevant(false) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .value(new DefaultProperty.Builder() .idShort("ExampleProperty") .value(null) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -931,9 +931,9 @@ public static Submodel createSubmodel4() { .idShort("ExampleRange") .min(null) .max(null) - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -977,7 +977,7 @@ public static Submodel createSubmodel6() { .version("0") .revision("9") .build()) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelTemplates/ExampleSubmodel") @@ -991,7 +991,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example RelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel RelationshipElement Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleRelationshipElement") @@ -1036,7 +1036,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example AnnotatedRelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel AnnotatedRelationshipElement Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleAnnotatedRelationshipElement") @@ -1077,7 +1077,7 @@ public static Submodel createSubmodel6() { .idShort("ExampleProperty") .category("PARAMETER") .value("some example annotation") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .submodelElements(new DefaultOperation.Builder() @@ -1087,7 +1087,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Operation object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Operation Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Operations/ExampleOperation") @@ -1102,7 +1102,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1111,10 +1111,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .outputVariables(new DefaultOperationVariable.Builder() @@ -1125,7 +1125,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1134,10 +1134,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .inoutputVariables(new DefaultOperationVariable.Builder() @@ -1148,7 +1148,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1157,10 +1157,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .build()) @@ -1171,7 +1171,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Capability object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Capability Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Capabilities/ExampleCapability") @@ -1188,7 +1188,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example BasicEvent object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel BasicEvent Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Events/ExampleBasicEvent") @@ -1215,12 +1215,12 @@ public static Submodel createSubmodel6() { .idShort("ExampleSubmodelElementListOrdered") .category("PARAMETER") .orderRelevant(true) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .description(Arrays.asList( new DefaultLangStringTextType.Builder().text("Example SubmodelElementListOrdered object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementListOrdered Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementLists/ExampleSubmodelElementListOrdered") @@ -1234,7 +1234,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1243,10 +1243,10 @@ public static Submodel createSubmodel6() { .build()) .qualifiers(new DefaultQualifier.Builder() .type("http://acplt.org/Qualifier/ExampleQualifier") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value("exampleValue") - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -1255,7 +1255,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example value of a MultiLanguageProperty element").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispielswert für ein MultiLanguageProperty-Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/MultiLanguageProperties/ExampleMultiLanguageProperty") @@ -1274,7 +1274,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -1283,9 +1283,9 @@ public static Submodel createSubmodel6() { .build()) .min("0") .max("100") - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -1294,7 +1294,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -1308,7 +1308,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Blob object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Blob Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Blobs/ExampleBlob") @@ -1325,7 +1325,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example File object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel File Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Files/ExampleFile") @@ -1342,7 +1342,7 @@ public static Submodel createSubmodel6() { new DefaultLangStringTextType.Builder().text("Example Reference Element object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Reference Element Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ReferenceElements/ExampleReferenceElement") @@ -1382,7 +1382,7 @@ public static Submodel createSubmodel7() { .version("0") .revision("9") .build()) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelTemplates/ExampleSubmodel") @@ -1397,7 +1397,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example RelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel RelationshipElement Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleRelationshipElement") @@ -1442,7 +1442,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example AnnotatedRelationshipElement object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel AnnotatedRelationshipElement Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/RelationshipElements/ExampleAnnotatedRelationshipElement") @@ -1487,7 +1487,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Operation object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Operation Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Operations/ExampleOperation") @@ -1502,7 +1502,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1510,7 +1510,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .outputVariables(new DefaultOperationVariable.Builder() @@ -1521,7 +1521,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1529,7 +1529,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .inoutputVariables(new DefaultOperationVariable.Builder() @@ -1540,7 +1540,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1548,7 +1548,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .build()) .build()) @@ -1559,7 +1559,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Capability object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Capability Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Capabilities/ExampleCapability") @@ -1576,7 +1576,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example BasicEvent object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel BasicEvent Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Events/ExampleBasicEvent") @@ -1607,14 +1607,14 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementListOrdered object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementListOrdered Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementLists/ExampleSubmodelElementListOrdered") .build()) .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .value(new DefaultProperty.Builder() .idShort("ExampleProperty") .category("CONSTANT") @@ -1622,7 +1622,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Property object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Property Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Properties/ExampleProperty") @@ -1630,7 +1630,7 @@ public static Submodel createSubmodel7() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .value(null) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value(new DefaultMultiLanguageProperty.Builder() .idShort("ExampleMultiLanguageProperty") @@ -1639,7 +1639,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example MultiLanguageProperty object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel MultiLanguageProperty Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE).value( "http://acplt.org/MultiLanguageProperties/ExampleMultiLanguageProperty") @@ -1654,7 +1654,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -1663,7 +1663,7 @@ public static Submodel createSubmodel7() { .build()) .min(null) .max("100") - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) .value(new DefaultRange.Builder() .idShort("ExampleRange2") @@ -1672,7 +1672,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Range object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Range Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Ranges/ExampleRange") @@ -1681,9 +1681,9 @@ public static Submodel createSubmodel7() { .build()) .min("0") .max(null) - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) - .typeValueListElement(AasSubmodelElements.SUBMODEL_ELEMENT) + .typeValueListElement(AASSubmodelElements.SUBMODEL_ELEMENT) .build()) .submodelElements(new DefaultSubmodelElementCollection.Builder() .idShort("ExampleSubmodelElementCollection") @@ -1692,7 +1692,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -1706,7 +1706,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Blob object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Blob Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Blobs/ExampleBlob") @@ -1722,7 +1722,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example File object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel File Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Files/ExampleFile") @@ -1739,7 +1739,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example Reference Element object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel Reference Element Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ReferenceElements/ExampleReferenceElement") @@ -1755,7 +1755,7 @@ public static Submodel createSubmodel7() { new DefaultLangStringTextType.Builder().text("Example SubmodelElementCollection object").language("en-us").build(), new DefaultLangStringTextType.Builder().text("Beispiel SubmodelElementCollection Element").language("de").build() )) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/SubmodelElementCollections/ExampleSubmodelElementCollection") @@ -1845,7 +1845,7 @@ public static ConceptDescription createConceptDescription4() { .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text("Test Spec").language("de").build()) .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text("TestSpec").language("en-us").build()) .unit("SpaceUnit") - .unitId(new DefaultReference.Builder() + .unitID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/Units/SpaceUnit") @@ -1859,7 +1859,7 @@ public static ConceptDescription createConceptDescription4() { .valueList(new DefaultValueList.Builder() .valueReferencePairs(new DefaultValueReferencePair.Builder() .value("http://acplt.org/ValueId/ExampleValueId") - .valueId(new DefaultReference.Builder() + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId") @@ -1869,7 +1869,7 @@ public static ConceptDescription createConceptDescription4() { .build()) .valueReferencePairs(new DefaultValueReferencePair.Builder() .value("http://acplt.org/ValueId/ExampleValueId2") - .valueId(new DefaultReference.Builder() + .valueID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("http://acplt.org/ValueId/ExampleValueId2") @@ -1906,4 +1906,4 @@ public static Environment createEnvironment() { .build(); } -} +} \ No newline at end of file diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java index 111153c20..73681dc8b 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASSimple.java @@ -20,7 +20,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeIec61360; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Extension; @@ -43,7 +43,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultProperty; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultReference; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultResource; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetId; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetID; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodel; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementCollection; import org.junit.Assert; @@ -144,11 +144,11 @@ public static AssetAdministrationShell createAAS() { .id(AAS_IDENTIFIER) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetId(HTTP_CUSTOMER_COM_ASSETS_KHBVZJSQKIY) - .specificAssetIds(new DefaultSpecificAssetId.Builder() + .globalAssetID(HTTP_CUSTOMER_COM_ASSETS_KHBVZJSQKIY) + .specificAssetIds(new DefaultSpecificAssetID.Builder() .name(EQUIPMENT_ID) .value(_538FD1B3_F99F_4A52_9C75_72E9FA921270) - .externalSubjectId(new DefaultReference.Builder() + .externalSubjectID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(HTTP_CUSTOMER_COM_SYSTEMS_ERP_012) @@ -156,10 +156,10 @@ public static AssetAdministrationShell createAAS() { .type(ReferenceTypes.EXTERNAL_REFERENCE) .build()) .build()) - .specificAssetIds(new DefaultSpecificAssetId.Builder() + .specificAssetIds(new DefaultSpecificAssetID.Builder() .name(DEVICE_ID) .value(QJ_YG_PGGJWKI_HK4_RR_QI_YS_LG) - .externalSubjectId(new DefaultReference.Builder() + .externalSubjectID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(HTTP_CUSTOMER_COM_SYSTEMS_IO_T_1) @@ -200,7 +200,7 @@ public static AssetAdministrationShell createAAS() { public static Submodel createSubmodelTechnicalData() { return new DefaultSubmodel.Builder() - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(SUBMODEL_TECHNICAL_DATA_SEMANTIC_ID) @@ -210,7 +210,7 @@ public static Submodel createSubmodelTechnicalData() { .idShort(SUBMODEL_TECHNICAL_DATA_ID_SHORT) .id(SUBMODEL_TECHNICAL_DATA_ID) .submodelElements(new DefaultProperty.Builder() - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_TECHNICAL_DATA_SEMANTIC_ID_PROPERTY) @@ -220,7 +220,7 @@ public static Submodel createSubmodelTechnicalData() { .idShort(SUBMODEL_TECHNICAL_DATA_PROPERTY_ID_SHORT) .category(SUBMODEL_TECHNICAL_DATA_PROPERTY_CATEGORY) .value(SUBMODEL_TECHNICAL_DATA_PROPERTY_VALUE) - .valueType(DataTypeDefXsd.INTEGER) + .valueType(DataTypeDefXSD.INTEGER) .build()) .build(); } @@ -231,7 +231,7 @@ public static Submodel createSubmodelOperationalData() { .idShort(SUBMODEL_OPERATIONAL_DATA_ID_SHORT) .id(SUBMODEL_OPERATIONAL_DATA_ID) .submodelElements(new DefaultProperty.Builder() - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_OPERATIONAL_DATA_SEMANTIC_ID_PROPERTY) @@ -241,7 +241,7 @@ public static Submodel createSubmodelOperationalData() { .idShort(SUBMODEL_OPERATIONAL_DATA_PROPERTY_ID_SHORT) .category(SUBMODEL_OPERATIONAL_DATA_PROPERTY_CATEGORY) .value(SUBMODEL_OPERATIONAL_DATA_PROPERTY_VALUE) - .valueType(DataTypeDefXsd.INTEGER) + .valueType(DataTypeDefXSD.INTEGER) .build()) .build(); } @@ -252,7 +252,7 @@ public static Submodel createSubmodelDocumentation() { .idShort(SUBMODEL_DOCUMENTATION_ID_SHORT) .id(SUBMODEL_DOCUMENTATION_ID) .submodelElements(new DefaultSubmodelElementCollection.Builder() - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_DOCUMENTATION_ELEMENTCOLLECTION_SEMANTIC_ID) @@ -261,7 +261,7 @@ public static Submodel createSubmodelDocumentation() { .build()) .idShort(SUBMODEL_DOCUMENTATION_ELEMENTCOLLECTION_ID_SHORT) .value(new DefaultProperty.Builder() - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_DOCUMENTATION_PROPERTY_SEMANTIC_ID) @@ -270,10 +270,10 @@ public static Submodel createSubmodelDocumentation() { .build()) .idShort(SUBMODEL_DOCUMENTATION_PROPERTY_ID_SHORT) .value(SUBMODEL_DOCUMENTATION_PROPERTY_VALUE) - .valueType(DataTypeDefXsd.STRING) + .valueType(DataTypeDefXSD.STRING) .build()) .value(new DefaultFile.Builder() - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.CONCEPT_DESCRIPTION) .value(SUBMODEL_DOCUMENTATION_FILE_SEMANTIC_ID) @@ -364,7 +364,7 @@ public static ConceptDescription createConceptDescriptionMaxRotationSpeed() { .preferredName(new DefaultLangStringPreferredNameTypeIec61360.Builder().text(MAX_DREHZAHL).language("de").build()) .preferredName(new DefaultLangStringPreferredNameTypeIec61360.Builder().text(MAX_ROTATIONSPEED).language("en").build()) .unit(_1_MIN) - .unitId(new DefaultReference.Builder() + .unitID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(_0173_1_05_AAA650_002) @@ -401,7 +401,7 @@ public static ConceptDescription createConceptDescriptionRotationSpeed() { .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text(AKTUELLE_DREHZAHL).language("DE").build()) .shortName(new DefaultLangStringShortNameTypeIec61360.Builder().text(ACTUAL_ROTATION_SPEED).language("EN").build()) .unit(_1_MIN) - .unitId(new DefaultReference.Builder() + .unitID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value(_0173_1_05_AAA650_002) diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java index 93c4323cc..40652ceb7 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/CustomProperty.java @@ -35,7 +35,7 @@ public class CustomProperty implements Property { protected Reference valueId; - protected DataTypeDefXsd valueType; + protected DataTypeDefXSD valueType; protected List qualifiers; @@ -82,12 +82,12 @@ public boolean equals(Object obj) { } @Override - final public DataTypeDefXsd getValueType() { + final public DataTypeDefXSD getValueType() { return this.valueType; } @Override - final public void setValueType(DataTypeDefXsd dataType) { + final public void setValueType(DataTypeDefXSD dataType) { this.valueType = dataType; } @@ -102,12 +102,12 @@ final public void setValue(String value) { } @Override - final public Reference getValueId() { + final public Reference getValueID() { return valueId; } @Override - final public void setValueId(Reference valueId) { + final public void setValueID(Reference valueId) { this.valueId = valueId; } @@ -172,12 +172,12 @@ final public void setEmbeddedDataSpecifications(List } @Override - final public Reference getSemanticId() { + final public Reference getSemanticID() { return semanticId; } @Override - final public void setSemanticId(Reference semanticId) { + final public void setSemanticID(Reference semanticId) { this.semanticId = semanticId; } diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java index d8bc3ef3b..72261ada7 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/Examples.java @@ -16,7 +16,7 @@ package org.eclipse.digitaltwin.aas4j.v3.dataformat.core; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.KeyTypes; import org.eclipse.digitaltwin.aas4j.v3.model.ReferenceTypes; @@ -37,7 +37,7 @@ public class Examples { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.NOT_APPLICABLE) - .globalAssetId("something_eea66fa1") + .globalAssetID("something_eea66fa1") .build()) .build()) .build(); @@ -48,7 +48,7 @@ public class Examples { .extensions(new DefaultExtension.Builder() .name("something_aae6caf4") .value("10233") - .valueType(DataTypeDefXsd.UNSIGNED_SHORT) + .valueType(DataTypeDefXSD.UNSIGNED_SHORT) .refersTo(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.SUBMODEL) @@ -56,7 +56,7 @@ public class Examples { .build()) .type(ReferenceTypes.MODEL_REFERENCE) .build()) - .semanticId(new DefaultReference.Builder() + .semanticID(new DefaultReference.Builder() .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) .value("urn:another-company07:4d1bd2cb") @@ -73,7 +73,7 @@ public class Examples { .build()) .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.NOT_APPLICABLE) - .globalAssetId("something_eea66fa1") + .globalAssetID("something_eea66fa1") .build()) .build()) .build(); diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java index 0d16f6acb..e420e8e53 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/mixins/SubmodelElementListMixin.java @@ -21,8 +21,8 @@ import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; import java.util.Collection; -import org.eclipse.digitaltwin.aas4j.v3.model.AasSubmodelElements; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.AASSubmodelElements; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; public interface SubmodelElementListMixin { @@ -41,16 +41,16 @@ public interface SubmodelElementListMixin { public void setSemanticIdListElement(Reference semanticIdListElement); @JsonProperty("typeValueListElement") - public AasSubmodelElements getTypeValueListElement(); + public AASSubmodelElements getTypeValueListElement(); @JsonProperty("typeValueListElement") - public void setTypeValueListElement(AasSubmodelElements typeValueListElement); + public void setTypeValueListElement(AASSubmodelElements typeValueListElement); @JsonProperty("valueTypeListElement") - public DataTypeDefXsd getValueTypeListElement(); + public DataTypeDefXSD getValueTypeListElement(); @JsonProperty("valueTypeListElement") - public void setValueTypeListElement(DataTypeDefXsd valueTypeListElement); + public void setValueTypeListElement(DataTypeDefXSD valueTypeListElement); @JsonProperty("value") public Collection getValues(); diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java index f8500515c..8a07eb1ea 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java @@ -132,7 +132,7 @@ public void testSerializeAssetInfo() throws SerializationException, Deserializat AssetInformation assetInfo = new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) .assetType("asset-type") - .globalAssetId("global-asset-id").build(); + .globalAssetID("global-asset-id").build(); String jsonString = new JsonSerializer().write(assetInfo); assertNotNull(jsonString); AssetInformation assetInfo2 = new JsonDeserializer().read(jsonString, AssetInformation.class); @@ -145,7 +145,7 @@ public void testDirectlySerializeAssetInfo() throws JsonProcessingException { AssetInformation assetInfo = new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) .assetType("asset-type") - .globalAssetId("global-asset-id").build(); + .globalAssetID("global-asset-id").build(); ObjectMapper mapper = ObjectMapperFactory.createMapper(); String jsonString = mapper.writeValueAsString(assetInfo); assertNotNull(jsonString); diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java index 3f09276df..6d35239d7 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/util/Examples.java @@ -37,7 +37,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultKey; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultReference; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultResource; -import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetId; +import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSpecificAssetID; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementList; public class Examples { @@ -58,11 +58,11 @@ public class Examples { .id("https://example.org/AssetAdministrationShell") .assetInformation(new DefaultAssetInformation.Builder() .assetKind(AssetKind.INSTANCE) - .globalAssetId("https://example.org/Asset") - .specificAssetIds(new DefaultSpecificAssetId.Builder() + .globalAssetID("https://example.org/Asset") + .specificAssetIds(new DefaultSpecificAssetID.Builder() .name("ExampleAssetId") .value("ExampleValue") - .externalSubjectId(new DefaultReference.Builder() + .externalSubjectID(new DefaultReference.Builder() .type(ReferenceTypes.EXTERNAL_REFERENCE) .keys(new DefaultKey.Builder() .type(KeyTypes.GLOBAL_REFERENCE) diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java index a2004e30d..e795faa56 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/deserialization/ValueReferencePairNodeDeserializer.java @@ -14,6 +14,6 @@ public class ValueReferencePairNodeDeserializer implements CustomJsonNodeDeseria public ValueReferencePair readValue(JsonNode node, JsonParser parser) throws IOException { String value = node.get("value").asText(); Reference valueId = DeserializationHelper.createInstanceFromNode(parser, node.get("valueId"), Reference.class); - return new DefaultValueReferencePair.Builder().value(value).valueId(valueId).build(); + return new DefaultValueReferencePair.Builder().value(value).valueID(valueId).build(); } } diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java index 31cbdd303..dbd93710c 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java @@ -19,7 +19,7 @@ import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; import org.eclipse.digitaltwin.aas4j.v3.model.File; -import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId; +import org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetID; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; @@ -29,11 +29,11 @@ public interface AssetInformationMixin { @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetIds") - public List getSpecificAssetIds(); + public List getSpecificAssetIds(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetIds") - public void setSpecificAssetIds(List SpecificAssetIds); + public void setSpecificAssetIds(List SpecificAssetIds); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "globalAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "globalAssetId") diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java index 49131ecdf..ab98d6027 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/QualifierMixin.java @@ -16,7 +16,7 @@ package org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.mixins; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.QualifierKind; import org.eclipse.digitaltwin.aas4j.v3.model.Reference; @@ -36,7 +36,7 @@ public interface QualifierMixin { void setType(String type); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "valueType") - void setType(DataTypeDefXsd valueType); + void setType(DataTypeDefXSD valueType); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "value") void setValue(String value); diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java index f90380e97..9e21bcdf3 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java @@ -19,7 +19,7 @@ import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; @JsonPropertyOrder({"path", "contentType"}) public interface ResourceMixin { @@ -28,5 +28,5 @@ public interface ResourceMixin { public String getPath(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "contentType") - public DataTypeDefXsd getContentType(); + public DataTypeDefXSD getContentType(); } diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIdMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java similarity index 94% rename from dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIdMixin.java rename to dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java index 54463ac98..737e67da4 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIdMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java @@ -22,7 +22,7 @@ import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; @JsonPropertyOrder({"hasSemantics", "name", "value", "externalSubjectId"}) -public interface SpecificAssetIdMixin { +public interface SpecificAssetIDMixin { @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "name") public String getName(); @@ -31,5 +31,5 @@ public interface SpecificAssetIdMixin { public String getValue(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "externalSubjectId") - public Reference getExternalSubjectId(); -} + public Reference getExternalSubjectID(); +} \ No newline at end of file diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java index 2364a2172..bd95e887b 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SubmodelElementListMixin.java @@ -20,8 +20,8 @@ import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.deserialization.SubmodelElementsDeserializer; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.serialization.SubmodelElementsSerializer; -import org.eclipse.digitaltwin.aas4j.v3.model.AasSubmodelElements; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.AASSubmodelElements; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.Reference; import org.eclipse.digitaltwin.aas4j.v3.model.SubmodelElement; @@ -48,14 +48,14 @@ public interface SubmodelElementListMixin { public void setSemanticIdListElement(Reference semanticIdListElement); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "typeValueListElement") - public AasSubmodelElements getTypeValueListElement(); + public AASSubmodelElements getTypeValueListElement(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "typeValueListElement") - public void setTypeValueListElement(AasSubmodelElements typeValueListElement); + public void setTypeValueListElement(AASSubmodelElements typeValueListElement); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "valueTypeListElement") - public DataTypeDefXsd getValueTypeListElement(); + public DataTypeDefXSD getValueTypeListElement(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "valueTypeListElement") - public void setValueTypeListElement(DataTypeDefXsd valueTypeListElement); + public void setValueTypeListElement(DataTypeDefXSD valueTypeListElement); } diff --git a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java index 48ee65d92..767ba4481 100644 --- a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java +++ b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java @@ -31,7 +31,7 @@ import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; import org.eclipse.digitaltwin.aas4j.v3.model.AssetKind; import org.eclipse.digitaltwin.aas4j.v3.model.ConceptDescription; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Submodel; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultAssetAdministrationShell; @@ -128,7 +128,7 @@ public void validateMinimalOperationAgainstXsdSchema() throws SerializationExcep .value(new DefaultProperty.Builder() .idShort("inputProperty") .value("1") - .valueType(DataTypeDefXsd.INT) + .valueType(DataTypeDefXSD.INT) .build()) .build()) .build()) @@ -140,7 +140,8 @@ public void validateMinimalOperationAgainstXsdSchema() throws SerializationExcep @Test public void validateGYearAgainstXsdSchema() throws SerializationException, SAXException { - Submodel submodel = new DefaultSubmodel.Builder().id("yearTestSm").submodelElements(new DefaultProperty.Builder().idShort("yearTestProp").valueType(DataTypeDefXsd.GYEAR).build()).build(); + Submodel submodel = new DefaultSubmodel.Builder().id("yearTestSm").submodelElements( + new DefaultProperty.Builder().idShort("yearTestProp").valueType(DataTypeDefXSD.GYEAR).build()).build(); String xml = new XmlSerializer().write(new DefaultEnvironment.Builder().submodels(submodel).build()); Set errors = validateAgainstXsdSchema(xml); assertTrue(errors.isEmpty()); 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..23009d63b 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,92 +22,92 @@ /** * Enumeration of all possible elements of a 'SubmodelElementList'. */ -@IRI("aas:AasSubmodelElements") -public enum AasSubmodelElements { +@IRI("aas:AASSubmodelElements") +public enum AASSubmodelElements { /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/AnnotatedRelationshipElement") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/AnnotatedRelationshipElement") ANNOTATED_RELATIONSHIP_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/BasicEventElement") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/BasicEventElement") BASIC_EVENT_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Blob") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Blob") BLOB, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Capability") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Capability") CAPABILITY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/DataElement") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/DataElement") DATA_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Entity") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Entity") ENTITY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/EventElement") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/EventElement") EVENT_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/File") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/File") FILE, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/MultiLanguageProperty") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/MultiLanguageProperty") MULTI_LANGUAGE_PROPERTY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Operation") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Operation") OPERATION, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Property") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Property") PROPERTY, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/Range") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/Range") RANGE, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/ReferenceElement") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/ReferenceElement") REFERENCE_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/RelationshipElement") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/RelationshipElement") RELATIONSHIP_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/SubmodelElement") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/SubmodelElement") SUBMODEL_ELEMENT, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/SubmodelElementCollection") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/SubmodelElementCollection") SUBMODEL_ELEMENT_COLLECTION, /** */ - @IRI("https://admin-shell.io/aas/3/0/AasSubmodelElements/SubmodelElementList") + @IRI("https://admin-shell.io/aas/3/0/AASSubmodelElements/SubmodelElementList") SUBMODEL_ELEMENT_LIST; } 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..c50f75ab4 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 @@ -1,6 +1,5 @@ /* * 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 @@ -25,9 +24,9 @@ * Strings with language tags */ @KnownSubtypes({ + @KnownSubtypes.Type(value = LangStringDefinitionTypeIec61360.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) }) 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..e5c3ff60f 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 @@ -1,6 +1,5 @@ /* * 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 @@ -30,23 +29,23 @@ public interface AdministrativeInformation extends HasDataSpecification { /** - * Version of the element. + * The subject ID of the subject responsible for making the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator * - * @return Returns the String for the property version. + * @return Returns the Reference for the property creator. */ - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/version") - String getVersion(); + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/creator") + Reference getCreator(); /** - * Version of the element. + * The subject ID of the subject responsible for making the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator * - * @param version desired value for the property version. + * @param creator desired value for the property creator. */ - void setVersion(String version); + void setCreator(Reference creator); /** * Revision of the element. @@ -68,41 +67,41 @@ public interface AdministrativeInformation extends HasDataSpecification { void setRevision(String revision); /** - * The subject ID of the subject responsible for making the element. + * Identifier of the template that guided the creation of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID * - * @return Returns the Reference for the property creator. + * @return Returns the String for the property templateID. */ - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/creator") - Reference getCreator(); + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID") + String getTemplateID(); /** - * The subject ID of the subject responsible for making the element. + * Identifier of the template that guided the creation of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/creator + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID * - * @param creator desired value for the property creator. + * @param templateID desired value for the property templateID. */ - void setCreator(Reference creator); + void setTemplateID(String templateID); /** - * Identifier of the template that guided the creation of the element. + * Version of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version * - * @return Returns the String for the property templateId. + * @return Returns the String for the property version. */ - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId") - String getTemplateId(); + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/version") + String getVersion(); /** - * Identifier of the template that guided the creation of the element. + * Version of the element. * - * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId + * More information under https://admin-shell.io/aas/3/0/AdministrativeInformation/version * - * @param templateId desired value for the property templateId. + * @param version desired value for the property version. */ - void setTemplateId(String templateId); + void setVersion(String version); } 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..841ea2032 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 @@ -1,6 +1,5 @@ /* * 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 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..238314362 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 @@ -1,6 +1,5 @@ /* * 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 @@ -31,42 +30,42 @@ public interface AssetAdministrationShell extends HasDataSpecification, Identifiable { /** - * The reference to the AAS the AAS was derived from. + * Meta-information about the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation * - * @return Returns the Reference for the property derivedFrom. + * @return Returns the AssetInformation for the property assetInformation. */ - @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom") - Reference getDerivedFrom(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation") + AssetInformation getAssetInformation(); /** - * The reference to the AAS the AAS was derived from. + * Meta-information about the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation * - * @param derivedFrom desired value for the property derivedFrom. + * @param assetInformation desired value for the property assetInformation. */ - void setDerivedFrom(Reference derivedFrom); + void setAssetInformation(AssetInformation assetInformation); /** - * Meta-information about the asset the AAS is representing. + * The reference to the AAS the AAS was derived from. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom * - * @return Returns the AssetInformation for the property assetInformation. + * @return Returns the Reference for the property derivedFrom. */ - @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation") - AssetInformation getAssetInformation(); + @IRI("https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom") + Reference getDerivedFrom(); /** - * Meta-information about the asset the AAS is representing. + * The reference to the AAS the AAS was derived from. * - * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/assetInformation + * More information under https://admin-shell.io/aas/3/0/AssetAdministrationShell/derivedFrom * - * @param assetInformation desired value for the property assetInformation. + * @param derivedFrom desired value for the property derivedFrom. */ - void setAssetInformation(AssetInformation assetInformation); + void setDerivedFrom(Reference derivedFrom); /** * References to submodels of the AAS. 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 deleted file mode 100644 index bca665c23..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/AssetAdministrationShellDescriptor.java +++ /dev/null @@ -1,186 +0,0 @@ -/* - * Copyright (c) 2023 SAP SE - * Copyright (C) 2023 SAP SE or an SAP affiliate company. All rights reserved. - * - * 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.impl.DefaultAssetAdministrationShellDescriptor; - -import java.util.List; - -/** -*/ -@KnownSubtypes({ - @KnownSubtypes.Type(value = DefaultAssetAdministrationShellDescriptor.class) -}) -public interface AssetAdministrationShellDescriptor extends Descriptor { - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration - * - * @return Returns the AdministrativeInformation for the property administration. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration") - AdministrativeInformation getAdministration(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/administration - * - * @param administration desired value for the property administration. - */ - void setAdministration(AdministrativeInformation administration); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description - * - * @return Returns the LangStringSet for the property description. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description") - List getDescription(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/description - * - * @param description desired value for the property description. - */ - void setDescription(List description); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName - * - * @return Returns the LangStringSet for the property displayName. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName") - List getDisplayName(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/displayName - * - * @param displayName desired value for the property displayName. - */ - void setDisplayName(List displayName); - - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId - * - * @return Returns the String for the property idShort. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId") - Reference getGlobalAssetId(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId - * - * @param globalAssetId desired value for the property globalAssetId. - */ - void setGlobalAssetId(Reference globalAssetId); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort - * - * @return Returns the String for the property idShort. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort") - String getIdShort(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort - * - * @param idShort desired value for the property idShort. - */ - void setIdShort(String idShort); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id - * - * @return Returns the String for the property identification. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id") - String getId(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id - * - * @param id desired value for the property identification. - */ - void setId(String id); - - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind - * - * @return Returns the AssetKind for the property assetKind. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind") - AssetKind getAssetKind(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind - * - * @param assetKind desired value for the property assetKind. - */ - void setAssetKind(AssetKind assetKind); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetId - * - * @return Returns the String for the property specificAssetId. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds") - SpecificAssetId getSpecificAssetIds(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds - * - * @param specificAssetIds desired value for the property specificAssetIds. - */ - void setSpecificAssetIds(SpecificAssetId specificAssetIds); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor - * - * @return Returns the String for the property submodelDescriptor. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor") - List getSubmodelDescriptor(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor - * - * @param submodelDescriptor desired value for the property submodelDescriptor. - */ - void setSubmodelDescriptor(List submodelDescriptor); - -} 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..517cb9db6 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 @@ -1,6 +1,5 @@ /* * 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 @@ -51,83 +50,83 @@ public interface AssetInformation { void setAssetKind(AssetKind assetKind); /** - * Global identifier of the asset the AAS is representing. + * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset + * under consideration as identified by 'globalAssetID'. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId + * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType * - * @return Returns the String for the property globalAssetId. + * @return Returns the String for the property assetType. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId") - String getGlobalAssetId(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/assetType") + String getAssetType(); /** - * Global identifier of the asset the AAS is representing. + * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset + * under consideration as identified by 'globalAssetID'. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId + * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType * - * @param globalAssetId desired value for the property globalAssetId. + * @param assetType desired value for the property assetType. */ - void setGlobalAssetId(String globalAssetId); + void setAssetType(String assetType); /** - * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial - * number etc. + * Thumbnail of the asset represented by the Asset Administration Shell. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds + * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail * - * @return Returns the List of SpecificAssetIds for the property specificAssetIds. + * @return Returns the Resource for the property defaultThumbnail. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds") - List getSpecificAssetIds(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail") + Resource getDefaultThumbnail(); /** - * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial - * number etc. + * Thumbnail of the asset represented by the Asset Administration Shell. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds + * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail * - * @param specificAssetIds desired value for the property specificAssetIds. + * @param defaultThumbnail desired value for the property defaultThumbnail. */ - void setSpecificAssetIds(List specificAssetIds); + void setDefaultThumbnail(Resource defaultThumbnail); /** - * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset - * under consideration as identified by 'globalAssetId'. + * Global identifier of the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType + * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID * - * @return Returns the String for the property assetType. + * @return Returns the String for the property globalAssetID. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/assetType") - String getAssetType(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID") + String getGlobalAssetID(); /** - * In case 'assetKind' is applicable the 'assetType' is the asset ID of the type asset of the asset - * under consideration as identified by 'globalAssetId'. + * Global identifier of the asset the AAS is representing. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/assetType + * More information under https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID * - * @param assetType desired value for the property assetType. + * @param globalAssetID desired value for the property globalAssetID. */ - void setAssetType(String assetType); + void setGlobalAssetID(String globalAssetID); /** - * Thumbnail of the asset represented by the Asset Administration Shell. + * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial + * number etc. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail + * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds * - * @return Returns the Resource for the property defaultThumbnail. + * @return Returns the List of SpecificAssetIDs for the property specificAssetIds. */ - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail") - Resource getDefaultThumbnail(); + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds") + List getSpecificAssetIds(); /** - * Thumbnail of the asset represented by the Asset Administration Shell. + * Additional domain-specific, typically proprietary identifier for the asset like e.g., serial + * number etc. * - * More information under https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail + * More information under https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds * - * @param defaultThumbnail desired value for the property defaultThumbnail. + * @param specificAssetIds desired value for the property specificAssetIds. */ - void setDefaultThumbnail(Resource defaultThumbnail); + void setSpecificAssetIds(List specificAssetIds); } 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..70ea05c93 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 @@ -1,6 +1,5 @@ /* * 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 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..2364f88f2 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 @@ -1,6 +1,5 @@ /* * 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 @@ -29,27 +28,6 @@ }) public interface BasicEventElement extends EventElement { - /** - * Reference to the 'Referable', which defines the scope of the event. Can be - * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. - * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed - * - * @return Returns the Reference for the property observed. - */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/observed") - Reference getObserved(); - - /** - * Reference to the 'Referable', which defines the scope of the event. Can be - * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. - * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed - * - * @param observed desired value for the property observed. - */ - void setObserved(Reference observed); - /** * Direction of event. * @@ -70,44 +48,42 @@ public interface BasicEventElement extends EventElement { void setDirection(Direction direction); /** - * State of event. + * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate * - * @return Returns the StateOfEvent for the property state. + * @return Returns the String for the property lastUpdate. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/state") - StateOfEvent getState(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate") + String getLastUpdate(); /** - * State of event. + * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate * - * @param state desired value for the property state. + * @param lastUpdate desired value for the property lastUpdate. */ - void setState(StateOfEvent state); + void setLastUpdate(String lastUpdate); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * For input direction: not applicable. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval * - * @return Returns the String for the property messageTopic. + * @return Returns the String for the property maxInterval. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic") - String getMessageTopic(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval") + String getMaxInterval(); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * For input direction: not applicable. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval * - * @param messageTopic desired value for the property messageTopic. + * @param maxInterval desired value for the property maxInterval. */ - void setMessageTopic(String messageTopic); + void setMaxInterval(String maxInterval); /** * Information, which outer message infrastructure shall handle messages for the 'EventElement'. @@ -133,23 +109,25 @@ public interface BasicEventElement extends EventElement { void setMessageBroker(Reference messageBroker); /** - * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic * - * @return Returns the String for the property lastUpdate. + * @return Returns the String for the property messageTopic. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate") - String getLastUpdate(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic") + String getMessageTopic(); /** - * Timestamp in UTC, when the last event was received (input direction) or sent (output direction). + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/lastUpdate + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/messageTopic * - * @param lastUpdate desired value for the property lastUpdate. + * @param messageTopic desired value for the property messageTopic. */ - void setLastUpdate(String lastUpdate); + void setMessageTopic(String messageTopic); /** * For input direction, reports on the maximum frequency, the software entity behind the respective @@ -173,22 +151,43 @@ public interface BasicEventElement extends EventElement { void setMinInterval(String minInterval); /** - * For input direction: not applicable. + * Reference to the 'Referable', which defines the scope of the event. Can be + * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed * - * @return Returns the String for the property maxInterval. + * @return Returns the Reference for the property observed. */ - @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval") - String getMaxInterval(); + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/observed") + Reference getObserved(); /** - * For input direction: not applicable. + * Reference to the 'Referable', which defines the scope of the event. Can be + * 'AssetAdministrationShell', 'Submodel', or 'SubmodelElement'. * - * More information under https://admin-shell.io/aas/3/0/BasicEventElement/maxInterval + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/observed * - * @param maxInterval desired value for the property maxInterval. + * @param observed desired value for the property observed. */ - void setMaxInterval(String maxInterval); + void setObserved(Reference observed); + + /** + * State of event. + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state + * + * @return Returns the StateOfEvent for the property state. + */ + @IRI("https://admin-shell.io/aas/3/0/BasicEventElement/state") + StateOfEvent getState(); + + /** + * State of event. + * + * More information under https://admin-shell.io/aas/3/0/BasicEventElement/state + * + * @param state desired value for the property state. + */ + void setState(StateOfEvent state); } 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..8ea957078 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 @@ -1,6 +1,5 @@ /* * 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 @@ -31,41 +30,41 @@ public interface Blob extends DataElement { /** - * The value of the 'Blob' instance of a blob data element. + * Content type of the content of the 'Blob'. * - * More information under https://admin-shell.io/aas/3/0/Blob/value + * More information under https://admin-shell.io/aas/3/0/Blob/contentType * - * @return Returns the byte[] for the property value. + * @return Returns the String for the property contentType. */ - @IRI("https://admin-shell.io/aas/3/0/Blob/value") - byte[] getValue(); + @IRI("https://admin-shell.io/aas/3/0/Blob/contentType") + String getContentType(); /** - * The value of the 'Blob' instance of a blob data element. + * Content type of the content of the 'Blob'. * - * More information under https://admin-shell.io/aas/3/0/Blob/value + * More information under https://admin-shell.io/aas/3/0/Blob/contentType * - * @param value desired value for the property value. + * @param contentType desired value for the property contentType. */ - void setValue(byte[] value); + void setContentType(String contentType); /** - * Content type of the content of the 'Blob'. + * The value of the 'Blob' instance of a blob data element. * - * More information under https://admin-shell.io/aas/3/0/Blob/contentType + * More information under https://admin-shell.io/aas/3/0/Blob/value * - * @return Returns the String for the property contentType. + * @return Returns the byte[] for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/Blob/contentType") - String getContentType(); + @IRI("https://admin-shell.io/aas/3/0/Blob/value") + byte[] getValue(); /** - * Content type of the content of the 'Blob'. + * The value of the 'Blob' instance of a blob data element. * - * More information under https://admin-shell.io/aas/3/0/Blob/contentType + * More information under https://admin-shell.io/aas/3/0/Blob/value * - * @param contentType desired value for the property contentType. + * @param value desired value for the property value. */ - void setContentType(String contentType); + void setValue(byte[] 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..26cb02ec6 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 @@ -1,6 +1,5 @@ /* * 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 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..a18fe9266 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 @@ -1,6 +1,5 @@ /* * 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 @@ -46,8 +45,8 @@ public interface ConceptDescription extends HasDataSpecification, Identifiable { * * More information under https://admin-shell.io/aas/3/0/ConceptDescription/isCaseOf * - * @param isCaseOfs desired value for the property isCaseOf. + * @param isCaseOf desired value for the property isCaseOf. */ - void setIsCaseOf(List isCaseOfs); + void setIsCaseOf(List isCaseOf); } 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..3c848efab 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 @@ -1,6 +1,5 @@ /* * 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 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..c6ba9d955 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 @@ -1,6 +1,5 @@ /* * 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 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..c0b5a1b18 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 @@ -1,6 +1,5 @@ /* * 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 @@ -32,80 +31,99 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { /** - * Preferred name + * Data Type * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType * - * @return Returns the List of LangStringPreferredNameTypeIec61360s for the property preferredName. + * @return Returns the DataTypeIec61360 for the property dataType. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName") - List getPreferredName(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/dataType") + DataTypeIec61360 getDataType(); /** - * Preferred name + * Data Type * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType * - * @param preferredNames desired value for the property preferredName. + * @param dataType desired value for the property dataType. */ - void setPreferredName(List preferredNames); + void setDataType(DataTypeIec61360 dataType); /** - * Short name + * Definition in different languages * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition * - * @return Returns the List of LangStringShortNameTypeIec61360s for the property shortName. + * @return Returns the List of LangStringDefinitionTypeIEC61360s for the property definition. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName") - List getShortName(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/definition") + List getDefinition(); /** - * Short name + * Definition in different languages * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition * - * @param shortNames desired value for the property shortName. + * @param definition desired value for the property definition. */ - void setShortName(List shortNames); + void setDefinition(List definition); /** - * Unit + * Set of levels. * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType * - * @return Returns the String for the property unit. + * @return Returns the LevelType for the property levelType. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit") - String getUnit(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType") + LevelType getLevelType(); /** - * Unit + * Set of levels. * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType * - * @param unit desired value for the property unit. + * @param levelType desired value for the property levelType. */ - void setUnit(String unit); + void setLevelType(LevelType levelType); /** - * Unique unit id + * Preferred name * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName * - * @return Returns the Reference for the property unitId. + * @return Returns the List of LangStringPreferredNameTypeIEC61360s for the property preferredName. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId") - Reference getUnitId(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/preferredName") + List getPreferredName(); /** - * Unique unit id + * Preferred name * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName * - * @param unitId desired value for the property unitId. + * @param preferredName desired value for the property preferredName. */ - void setUnitId(Reference unitId); + void setPreferredName(List preferredName); + + /** + * Short name + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName + * + * @return Returns the List of LangStringShortNameTypeIEC61360s for the property shortName. + */ + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/shortName") + List getShortName(); + + /** + * Short name + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName + * + * @param shortName desired value for the property shortName. + */ + void setShortName(List shortName); /** * Source of definition @@ -115,7 +133,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the String for the property sourceOfDefinition. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/sourceOfDefinition") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/sourceOfDefinition") String getSourceOfDefinition(); /** @@ -135,7 +153,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the String for the property symbol. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/symbol") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/symbol") String getSymbol(); /** @@ -148,42 +166,61 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { void setSymbol(String symbol); /** - * Data Type + * Unit * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit * - * @return Returns the DataTypeIec61360 for the property dataType. + * @return Returns the String for the property unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType") - DataTypeIec61360 getDataType(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unit") + String getUnit(); /** - * Data Type + * Unit * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit * - * @param dataType desired value for the property dataType. + * @param unit desired value for the property unit. */ - void setDataType(DataTypeIec61360 dataType); + void setUnit(String unit); /** - * Definition in different languages + * Unique unit id * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitID * - * @return Returns the List of LangStringDefinitionTypeIec61360s for the property definition. + * @return Returns the Reference for the property unitID. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition") - List getDefinition(); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unitID") + Reference getUnitID(); /** - * Definition in different languages + * Unique unit id * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitID + * + * @param unitID desired value for the property unitID. + */ + void setUnitID(Reference unitID); + + /** + * Value + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value * - * @param definitions desired value for the property definition. + * @return Returns the String for the property value. */ - void setDefinition(List definitions); + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/value") + String getValue(); + + /** + * Value + * + * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value + * + * @param value desired value for the property value. + */ + void setValue(String value); /** * Value Format @@ -192,7 +229,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the String for the property valueFormat. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueFormat") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueFormat") String getValueFormat(); /** @@ -211,7 +248,7 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { * * @return Returns the ValueList for the property valueList. */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueList") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueList") ValueList getValueList(); /** @@ -223,42 +260,4 @@ public interface DataSpecificationIec61360 extends DataSpecificationContent { */ void setValueList(ValueList valueList); - /** - * Value - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value - * - * @return Returns the String for the property value. - */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value") - String getValue(); - - /** - * Value - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value - * - * @param value desired value for the property value. - */ - void setValue(String value); - - /** - * Set of levels. - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType - * - * @return Returns the LevelType for the property levelType. - */ - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType") - LevelType getLevelType(); - - /** - * Set of levels. - * - * More information under https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType - * - * @param levelType desired value for the property levelType. - */ - void setLevelType(LevelType levelType); - } 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..7452b2596 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,157 +22,157 @@ /** * Enumeration listing all XSD anySimpleTypes */ -@IRI("aas:DataTypeDefXsd") -public enum DataTypeDefXsd { +@IRI("aas:DataTypeDefXSD") +public enum DataTypeDefXSD { /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/AnyUri") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/AnyUri") ANY_URI, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Base64Binary") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Base64Binary") BASE64BINARY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Boolean") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Boolean") BOOLEAN, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Byte") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Byte") BYTE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Date") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Date") DATE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/DateTime") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/DateTime") DATE_TIME, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Decimal") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Decimal") DECIMAL, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Double") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Double") DOUBLE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Duration") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Duration") DURATION, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Float") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Float") FLOAT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GDay") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GDay") GDAY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GMonth") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GMonth") GMONTH, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GMonthDay") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GMonthDay") GMONTH_DAY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GYear") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GYear") GYEAR, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/GYearMonth") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/GYearMonth") GYEAR_MONTH, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/HexBinary") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/HexBinary") HEX_BINARY, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Int") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Int") INT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Integer") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Integer") INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Long") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Long") LONG, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/NegativeInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/NegativeInteger") NEGATIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/NonNegativeInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/NonNegativeInteger") NON_NEGATIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/NonPositiveInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/NonPositiveInteger") NON_POSITIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/PositiveInteger") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/PositiveInteger") POSITIVE_INTEGER, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Short") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Short") SHORT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/String") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/String") STRING, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/Time") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/Time") TIME, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedByte") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedByte") UNSIGNED_BYTE, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedInt") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedInt") UNSIGNED_INT, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedLong") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedLong") UNSIGNED_LONG, /** */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXsd/UnsignedShort") + @IRI("https://admin-shell.io/aas/3/0/DataTypeDefXSD/UnsignedShort") UNSIGNED_SHORT; } 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..a77873cda 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 @@ -1,6 +1,5 @@ /* * 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 @@ -22,129 +21,129 @@ /** */ -@IRI("aas:DataTypeIec61360") +@IRI("aas:DataTypeIEC61360") public enum DataTypeIec61360 { /** * values containing the content of a file. Values may be binaries. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Blob") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Blob") BLOB, /** * values representing truth of logic or Boolean algebra (TRUE, FALSE) */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Boolean") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Boolean") BOOLEAN, /** * values containing a calendar date, conformant to ISO 8601:2004 Format yyyy-mm-dd Example from IEC * 61360-1:2017: "1999-05-31" is the [DATE] representation of: "31 May 1999". */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Date") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Date") DATE, /** * values containing an address to a file. The values are of type URI and can represent an absolute * or relative path. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/File") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/File") FILE, /** * Values containing string with any sequence of characters, using the syntax of HTML5 (see W3C * Recommendation 28:2014) */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Html") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Html") HTML, /** * values containing values of type INTEGER but are no currencies or measures */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/IntegerCount") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/IntegerCount") INTEGER_COUNT, /** * values containing values of type INTEGER that are currencies */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/IntegerCurrency") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/IntegerCurrency") INTEGER_CURRENCY, /** * values containing values that are measure of type INTEGER. In addition such a value comes with a * physical unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/IntegerMeasure") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/IntegerMeasure") INTEGER_MEASURE, /** * values conforming to ISO/IEC 11179 series global identifier sequences */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Irdi") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Irdi") IRDI, /** * values containing values of type STRING conformant to Rfc 3987 */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Iri") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Iri") IRI, /** * values containing values of type rational */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Rational") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Rational") RATIONAL, /** * values containing values of type rational. In addition such a value comes with a physical unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RationalMeasure") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RationalMeasure") RATIONAL_MEASURE, /** * values containing numbers that can be written as a terminating or non-terminating decimal; a * rational or irrational number but are no currencies or measures */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RealCount") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RealCount") REAL_COUNT, /** * values containing values of type REAL that are currencies */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RealCurrency") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RealCurrency") REAL_CURRENCY, /** * values containing values that are measures of type REAL. In addition such a value comes with a * physical unit. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/RealMeasure") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/RealMeasure") REAL_MEASURE, /** * values consisting of sequence of characters but cannot be translated into other languages */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/String") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/String") STRING, /** * values containing string but shall be represented as different string in different languages */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/StringTranslatable") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/StringTranslatable") STRING_TRANSLATABLE, /** * values containing a time, conformant to ISO 8601:2004 but restricted to what is allowed in the * corresponding type in xml. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Time") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Time") TIME, /** * values containing a time, conformant to ISO 8601:2004 but restricted to what is allowed in the * corresponding type in xml. */ - @IRI("https://admin-shell.io/aas/3/0/DataTypeIec61360/Timestamp") + @IRI("https://admin-shell.io/aas/3/0/DataTypeIEC61360/Timestamp") TIMESTAMP; } 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 deleted file mode 100644 index a06e883fc..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Descriptor.java +++ /dev/null @@ -1,49 +0,0 @@ -/* - * 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. - * - * 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.impl.DefaultDescriptor; - -/** -*/ -@KnownSubtypes({ - @KnownSubtypes.Type(value = DefaultDescriptor.class), - @KnownSubtypes.Type(value = SubmodelDescriptor.class) -}) -public interface Descriptor { - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints - * - * @return Returns the List of Endpoints for the property endpoints. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") - List getEndpoints(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints - * - * @param endpoints desired value for the property endpoints. - */ - void setEndpoints(List endpoints); - -} 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..9a556a503 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 @@ -1,6 +1,5 @@ /* * 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 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..5be85af48 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 @@ -1,6 +1,5 @@ /* * 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 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 deleted file mode 100644 index fa8b8fee6..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/Endpoint.java +++ /dev/null @@ -1,61 +0,0 @@ -/* - * 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. - * - * 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.impl.DefaultEndpoint; - -@KnownSubtypes({ - @KnownSubtypes.Type(value = DefaultEndpoint.class) -}) -public interface Endpoint { - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/interface - * - * @return Returns the String for the property interface. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/interface") - String getInterface(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/interface - * - * @param interfaceValue desired value for the property interface. - */ - void setInterface(String interfaceValue); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation - * - * @return Returns the ProtocolInformation for the property protocolInformation. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation") - ProtocolInformation getProtocolInformation(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/Endpoint/protocolInformation - * - * @param protocolInformation desired value for the property protocolInformation. - */ - void setProtocolInformation(ProtocolInformation 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..17c09503a 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 @@ -1,6 +1,5 @@ /* * 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 @@ -30,27 +29,6 @@ }) public interface Entity extends SubmodelElement { - /** - * Describes statements applicable to the entity by a set of submodel elements, typically with a - * qualified value. - * - * More information under https://admin-shell.io/aas/3/0/Entity/statements - * - * @return Returns the List of SubmodelElements for the property statements. - */ - @IRI("https://admin-shell.io/aas/3/0/Entity/statements") - List getStatements(); - - /** - * Describes statements applicable to the entity by a set of submodel elements, typically with a - * qualified value. - * - * More information under https://admin-shell.io/aas/3/0/Entity/statements - * - * @param statements desired value for the property statements. - */ - void setStatements(List statements); - /** * Describes whether the entity is a co-managed entity or a self-managed entity. * @@ -73,21 +51,21 @@ public interface Entity extends SubmodelElement { /** * Global identifier of the asset the entity is representing. * - * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetId + * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetID * - * @return Returns the String for the property globalAssetId. + * @return Returns the String for the property globalAssetID. */ - @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetId") - String getGlobalAssetId(); + @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetID") + String getGlobalAssetID(); /** * Global identifier of the asset the entity is representing. * - * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetId + * More information under https://admin-shell.io/aas/3/0/Entity/globalAssetID * - * @param globalAssetId desired value for the property globalAssetId. + * @param globalAssetID desired value for the property globalAssetID. */ - void setGlobalAssetId(String globalAssetId); + void setGlobalAssetID(String globalAssetID); /** * Reference to a specific asset ID representing a supplementary identifier of the asset represented @@ -95,10 +73,10 @@ public interface Entity extends SubmodelElement { * * More information under https://admin-shell.io/aas/3/0/Entity/specificAssetIds * - * @return Returns the List of SpecificAssetIds for the property specificAssetIds. + * @return Returns the List of SpecificAssetIDs for the property specificAssetIds. */ @IRI("https://admin-shell.io/aas/3/0/Entity/specificAssetIds") - List getSpecificAssetIds(); + List getSpecificAssetIds(); /** * Reference to a specific asset ID representing a supplementary identifier of the asset represented @@ -108,6 +86,27 @@ public interface Entity extends SubmodelElement { * * @param specificAssetIds desired value for the property specificAssetIds. */ - void setSpecificAssetIds(List specificAssetIds); + void setSpecificAssetIds(List specificAssetIds); + + /** + * Describes statements applicable to the entity by a set of submodel elements, typically with a + * qualified value. + * + * More information under https://admin-shell.io/aas/3/0/Entity/statements + * + * @return Returns the List of SubmodelElements for the property statements. + */ + @IRI("https://admin-shell.io/aas/3/0/Entity/statements") + List getStatements(); + + /** + * Describes statements applicable to the entity by a set of submodel elements, typically with a + * qualified value. + * + * More information under https://admin-shell.io/aas/3/0/Entity/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/EntityType.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/EntityType.java index 233102815..5fec4fe06 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 @@ -1,6 +1,5 @@ /* * 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 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..5485872b9 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 @@ -1,6 +1,5 @@ /* * 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 @@ -50,41 +49,41 @@ public interface Environment { void setAssetAdministrationShells(List assetAdministrationShells); /** - * Submodel + * Concept description * - * More information under https://admin-shell.io/aas/3/0/Environment/submodels + * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions * - * @return Returns the List of Submodels for the property submodels. + * @return Returns the List of ConceptDescriptions for the property conceptDescriptions. */ - @IRI("https://admin-shell.io/aas/3/0/Environment/submodels") - List getSubmodels(); + @IRI("https://admin-shell.io/aas/3/0/Environment/conceptDescriptions") + List getConceptDescriptions(); /** - * Submodel + * Concept description * - * More information under https://admin-shell.io/aas/3/0/Environment/submodels + * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions * - * @param submodels desired value for the property submodels. + * @param conceptDescriptions desired value for the property conceptDescriptions. */ - void setSubmodels(List submodels); + void setConceptDescriptions(List conceptDescriptions); /** - * Concept description + * Submodel * - * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions + * More information under https://admin-shell.io/aas/3/0/Environment/submodels * - * @return Returns the List of ConceptDescriptions for the property conceptDescriptions. + * @return Returns the List of Submodels for the property submodels. */ - @IRI("https://admin-shell.io/aas/3/0/Environment/conceptDescriptions") - List getConceptDescriptions(); + @IRI("https://admin-shell.io/aas/3/0/Environment/submodels") + List getSubmodels(); /** - * Concept description + * Submodel * - * More information under https://admin-shell.io/aas/3/0/Environment/conceptDescriptions + * More information under https://admin-shell.io/aas/3/0/Environment/submodels * - * @param conceptDescriptions desired value for the property conceptDescriptions. + * @param submodels desired value for the property submodels. */ - void setConceptDescriptions(List conceptDescriptions); + void setSubmodels(List submodels); } 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..02818c712 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 @@ -1,6 +1,5 @@ /* * 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 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..f971df611 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 @@ -1,6 +1,5 @@ /* * 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 @@ -30,122 +29,120 @@ public interface EventPayload { /** - * Reference to the source event element, including identification of 'AssetAdministrationShell', - * 'Submodel', 'SubmodelElement''s. + * Reference to the referable, which defines the scope of the event. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/source + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference * - * @return Returns the Reference for the property source. + * @return Returns the Reference for the property observableReference. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/source") - Reference getSource(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableReference") + Reference getObservableReference(); /** - * Reference to the source event element, including identification of 'AssetAdministrationShell', - * 'Submodel', 'SubmodelElement''s. + * Reference to the referable, which defines the scope of the event. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/source + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference * - * @param source desired value for the property source. + * @param observableReference desired value for the property observableReference. */ - void setSource(Reference source); + void setObservableReference(Reference observableReference); /** - * 'semanticId' of the source event element, if available + * 'semanticID' of the referable which defines the scope of the event, if available. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID * - * @return Returns the Reference for the property sourceSemanticId. + * @return Returns the Reference for the property observableSemanticID. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId") - Reference getSourceSemanticId(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID") + Reference getObservableSemanticID(); /** - * 'semanticId' of the source event element, if available + * 'semanticID' of the referable which defines the scope of the event, if available. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId + * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID * - * @param sourceSemanticId desired value for the property sourceSemanticId. + * @param observableSemanticID desired value for the property observableSemanticID. */ - void setSourceSemanticId(Reference sourceSemanticId); + void setObservableSemanticID(Reference observableSemanticID); /** - * Reference to the referable, which defines the scope of the event. + * Event specific payload. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference + * More information under https://admin-shell.io/aas/3/0/EventPayload/payload * - * @return Returns the Reference for the property observableReference. + * @return Returns the byte[] for the property payload. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableReference") - Reference getObservableReference(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/payload") + byte[] getPayload(); /** - * Reference to the referable, which defines the scope of the event. + * Event specific payload. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableReference + * More information under https://admin-shell.io/aas/3/0/EventPayload/payload * - * @param observableReference desired value for the property observableReference. + * @param payload desired value for the property payload. */ - void setObservableReference(Reference observableReference); + void setPayload(byte[] payload); /** - * 'semanticId' of the referable which defines the scope of the event, if available. + * Reference to the source event element, including identification of 'AssetAdministrationShell', + * 'Submodel', 'SubmodelElement''s. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId + * More information under https://admin-shell.io/aas/3/0/EventPayload/source * - * @return Returns the Reference for the property observableSemanticId. + * @return Returns the Reference for the property source. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId") - Reference getObservableSemanticId(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/source") + Reference getSource(); /** - * 'semanticId' of the referable which defines the scope of the event, if available. + * Reference to the source event element, including identification of 'AssetAdministrationShell', + * 'Submodel', 'SubmodelElement''s. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId + * More information under https://admin-shell.io/aas/3/0/EventPayload/source * - * @param observableSemanticId desired value for the property observableSemanticId. + * @param source desired value for the property source. */ - void setObservableSemanticId(Reference observableSemanticId); + void setSource(Reference source); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * 'semanticID' of the source event element, if available * - * More information under https://admin-shell.io/aas/3/0/EventPayload/topic + * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID * - * @return Returns the String for the property topic. + * @return Returns the Reference for the property sourceSemanticID. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/topic") - String getTopic(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID") + Reference getSourceSemanticID(); /** - * Information for the outer message infrastructure for scheduling the event to the respective - * communication channel. + * 'semanticID' of the source event element, if available * - * More information under https://admin-shell.io/aas/3/0/EventPayload/topic + * More information under https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID * - * @param topic desired value for the property topic. + * @param sourceSemanticID desired value for the property sourceSemanticID. */ - void setTopic(String topic); + void setSourceSemanticID(Reference sourceSemanticID); /** * Subject, who/which initiated the creation. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectId + * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectID * - * @return Returns the Reference for the property subjectId. + * @return Returns the Reference for the property subjectID. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectId") - Reference getSubjectId(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectID") + Reference getSubjectID(); /** * Subject, who/which initiated the creation. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectId + * More information under https://admin-shell.io/aas/3/0/EventPayload/subjectID * - * @param subjectId desired value for the property subjectId. + * @param subjectID desired value for the property subjectID. */ - void setSubjectId(Reference subjectId); + void setSubjectID(Reference subjectID); /** * Timestamp in UTC, when this event was triggered. @@ -167,22 +164,24 @@ public interface EventPayload { void setTimeStamp(String timeStamp); /** - * Event specific payload. + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/payload + * More information under https://admin-shell.io/aas/3/0/EventPayload/topic * - * @return Returns the byte[] for the property payload. + * @return Returns the String for the property topic. */ - @IRI("https://admin-shell.io/aas/3/0/EventPayload/payload") - byte[] getPayload(); + @IRI("https://admin-shell.io/aas/3/0/EventPayload/topic") + String getTopic(); /** - * Event specific payload. + * Information for the outer message infrastructure for scheduling the event to the respective + * communication channel. * - * More information under https://admin-shell.io/aas/3/0/EventPayload/payload + * More information under https://admin-shell.io/aas/3/0/EventPayload/topic * - * @param payload desired value for the property payload. + * @param topic desired value for the property topic. */ - void setPayload(byte[] payload); + void setTopic(String topic); } 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..9638fe412 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 @@ -1,6 +1,5 @@ /* * 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 @@ -50,23 +49,23 @@ public interface Extension extends HasSemantics { void setName(String name); /** - * Type of the value of the extension. + * Reference to an element the extension refers to. * - * More information under https://admin-shell.io/aas/3/0/Extension/valueType + * More information under https://admin-shell.io/aas/3/0/Extension/refersTo * - * @return Returns the DataTypeDefXsd for the property valueType. + * @return Returns the List of References for the property refersTo. */ - @IRI("https://admin-shell.io/aas/3/0/Extension/valueType") - DataTypeDefXsd getValueType(); + @IRI("https://admin-shell.io/aas/3/0/Extension/refersTo") + List getRefersTo(); /** - * Type of the value of the extension. + * Reference to an element the extension refers to. * - * More information under https://admin-shell.io/aas/3/0/Extension/valueType + * More information under https://admin-shell.io/aas/3/0/Extension/refersTo * - * @param valueType desired value for the property valueType. + * @param refersTo desired value for the property refersTo. */ - void setValueType(DataTypeDefXsd valueType); + void setRefersTo(List refersTo); /** * Value of the extension @@ -88,22 +87,22 @@ public interface Extension extends HasSemantics { void setValue(String value); /** - * Reference to an element the extension refers to. + * Type of the value of the extension. * - * More information under https://admin-shell.io/aas/3/0/Extension/refersTo + * More information under https://admin-shell.io/aas/3/0/Extension/valueType * - * @return Returns the List of References for the property refersTo. + * @return Returns the DataTypeDefXSD for the property valueType. */ - @IRI("https://admin-shell.io/aas/3/0/Extension/refersTo") - List getRefersTo(); + @IRI("https://admin-shell.io/aas/3/0/Extension/valueType") + DataTypeDefXSD getValueType(); /** - * Reference to an element the extension refers to. + * Type of the value of the extension. * - * More information under https://admin-shell.io/aas/3/0/Extension/refersTo + * More information under https://admin-shell.io/aas/3/0/Extension/valueType * - * @param refersTos desired value for the property refersTo. + * @param valueType desired value for the property valueType. */ - void setRefersTo(List refersTos); + void setValueType(DataTypeDefXSD valueType); } 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..6bf0dfc6c 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 @@ -1,6 +1,5 @@ /* * 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 @@ -30,41 +29,41 @@ public interface File extends DataElement { /** - * Path and name of the referenced file (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/File/value + * More information under https://admin-shell.io/aas/3/0/File/contentType * - * @return Returns the String for the property value. + * @return Returns the String for the property contentType. */ - @IRI("https://admin-shell.io/aas/3/0/File/value") - String getValue(); + @IRI("https://admin-shell.io/aas/3/0/File/contentType") + String getContentType(); /** - * Path and name of the referenced file (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/File/value + * More information under https://admin-shell.io/aas/3/0/File/contentType * - * @param value desired value for the property value. + * @param contentType desired value for the property contentType. */ - void setValue(String value); + void setContentType(String contentType); /** - * Content type of the content of the file. + * Path and name of the referenced file (with file extension). * - * More information under https://admin-shell.io/aas/3/0/File/contentType + * More information under https://admin-shell.io/aas/3/0/File/value * - * @return Returns the String for the property contentType. + * @return Returns the String for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/File/contentType") - String getContentType(); + @IRI("https://admin-shell.io/aas/3/0/File/value") + String getValue(); /** - * Content type of the content of the file. + * Path and name of the referenced file (with file extension). * - * More information under https://admin-shell.io/aas/3/0/File/contentType + * More information under https://admin-shell.io/aas/3/0/File/value * - * @param contentType desired value for the property contentType. + * @param value desired value for the property value. */ - void setContentType(String contentType); + 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..c266eda1c 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 @@ -1,6 +1,5 @@ /* * 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 @@ -27,8 +26,8 @@ @KnownSubtypes({ @KnownSubtypes.Type(value = AdministrativeInformation.class), @KnownSubtypes.Type(value = AssetAdministrationShell.class), - @KnownSubtypes.Type(value = ConceptDescription.class), @KnownSubtypes.Type(value = SubmodelElement.class), + @KnownSubtypes.Type(value = ConceptDescription.class), @KnownSubtypes.Type(value = Submodel.class) }) public interface HasDataSpecification { 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..4da4a2342 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 @@ -1,6 +1,5 @@ /* * 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 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..420fed252 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 @@ -1,6 +1,5 @@ /* * 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 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..a5933022c 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 @@ -1,6 +1,5 @@ /* * 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 @@ -25,7 +24,7 @@ * Element that can have a semantic definition plus some supplemental semantic definitions. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = SpecificAssetId.class), + @KnownSubtypes.Type(value = SpecificAssetID.class), @KnownSubtypes.Type(value = SubmodelElement.class), @KnownSubtypes.Type(value = Submodel.class), @KnownSubtypes.Type(value = Extension.class), @@ -37,22 +36,22 @@ public interface HasSemantics { * Identifier of the semantic definition of the element. It is called semantic ID of the element or * also main semantic ID of the element. * - * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticId + * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticID * - * @return Returns the Reference for the property semanticId. + * @return Returns the Reference for the property semanticID. */ - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") - Reference getSemanticId(); + @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticID") + Reference getSemanticID(); /** * Identifier of the semantic definition of the element. It is called semantic ID of the element or * also main semantic ID of the element. * - * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticId + * More information under https://admin-shell.io/aas/3/0/HasSemantics/semanticID * - * @param semanticId desired value for the property semanticId. + * @param semanticID desired value for the property semanticID. */ - void setSemanticId(Reference semanticId); + void setSemanticID(Reference semanticID); /** * Identifier of a supplemental semantic definition of the element. It is called supplemental 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..325a3d6d8 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 @@ -1,6 +1,5 @@ /* * 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 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..e58033a6a 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 @@ -1,6 +1,5 @@ /* * 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 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..c08fef3b8 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 @@ -1,6 +1,5 @@ /* * 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 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 deleted file mode 100644 index 0bd4f3547..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/LangString.java +++ /dev/null @@ -1,93 +0,0 @@ -/* - * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. - * Copyright (c) 2023 SAP SE - * - * 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 java.io.Serializable; -import java.util.Objects; - - -@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..a2153c56c 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 @@ -1,6 +1,5 @@ /* * 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 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..510fa9ff7 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 @@ -1,6 +1,5 @@ /* * 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 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..970690271 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 @@ -1,6 +1,5 @@ /* * 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 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..dfa79c706 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 @@ -1,6 +1,5 @@ /* * 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 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..dc960b950 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 @@ -1,6 +1,5 @@ /* * 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 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..36ca14e5b 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 @@ -1,6 +1,5 @@ /* * 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 @@ -30,6 +29,25 @@ }) public interface LevelType { + /** + * Maximum of the value + * + * More information under https://admin-shell.io/aas/3/0/LevelType/max + * + * @return Returns the boolean for the property max. + */ + @IRI("https://admin-shell.io/aas/3/0/LevelType/max") + boolean getMax(); + + /** + * Maximum of the value + * + * More information under https://admin-shell.io/aas/3/0/LevelType/max + * + * @param max desired value for the property max. + */ + void setMax(boolean max); + /** * Minimum of the value * @@ -87,23 +105,4 @@ public interface LevelType { */ void setTyp(boolean typ); - /** - * Maximum of the value - * - * More information under https://admin-shell.io/aas/3/0/LevelType/max - * - * @return Returns the boolean for the property max. - */ - @IRI("https://admin-shell.io/aas/3/0/LevelType/max") - boolean getMax(); - - /** - * Maximum of the value - * - * More information under https://admin-shell.io/aas/3/0/LevelType/max - * - * @param max desired value for the property max. - */ - void setMax(boolean max); - } 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..070e48af7 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 @@ -1,6 +1,5 @@ /* * 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 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..e2ca85aa4 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 @@ -1,6 +1,5 @@ /* * 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 @@ -45,27 +44,27 @@ public interface MultiLanguageProperty extends DataElement { * * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/value * - * @param values desired value for the property value. + * @param value desired value for the property value. */ - void setValue(List values); + void setValue(List value); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId + * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID * - * @return Returns the Reference for the property valueId. + * @return Returns the Reference for the property valueID. */ - @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId") - Reference getValueId(); + @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID") + Reference getValueID(); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId + * More information under https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID * - * @param valueId desired value for the property valueId. + * @param valueID desired value for the property valueID. */ - void setValueId(Reference valueId); + void setValueID(Reference valueID); } 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..18bb33559 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 @@ -1,6 +1,5 @@ /* * 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 @@ -30,6 +29,25 @@ }) public interface Operation extends SubmodelElement { + /** + * Parameter that is input and output of the operation. + * + * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables + * + * @return Returns the List of OperationVariables for the property inoutputVariables. + */ + @IRI("https://admin-shell.io/aas/3/0/Operation/inoutputVariables") + List getInoutputVariables(); + + /** + * Parameter that is input and output of the operation. + * + * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables + * + * @param inoutputVariables desired value for the property inoutputVariables. + */ + void setInoutputVariables(List inoutputVariables); + /** * Input parameter of the operation. * @@ -68,23 +86,4 @@ public interface Operation extends SubmodelElement { */ void setOutputVariables(List outputVariables); - /** - * Parameter that is input and output of the operation. - * - * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables - * - * @return Returns the List of OperationVariables for the property inoutputVariables. - */ - @IRI("https://admin-shell.io/aas/3/0/Operation/inoutputVariables") - List getInoutputVariables(); - - /** - * Parameter that is input and output of the operation. - * - * More information under https://admin-shell.io/aas/3/0/Operation/inoutputVariables - * - * @param inoutputVariables desired value for the property inoutputVariables. - */ - void setInoutputVariables(List inoutputVariables); - } 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..7b5cf13d6 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 @@ -1,6 +1,5 @@ /* * 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 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..13a195fb3 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 @@ -1,6 +1,5 @@ /* * 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 @@ -29,25 +28,6 @@ }) public interface Property extends DataElement { - /** - * Data type of the value - * - * More information under https://admin-shell.io/aas/3/0/Property/valueType - * - * @return Returns the DataTypeDefXsd for the property valueType. - */ - @IRI("https://admin-shell.io/aas/3/0/Property/valueType") - DataTypeDefXsd getValueType(); - - /** - * Data type of the value - * - * More information under https://admin-shell.io/aas/3/0/Property/valueType - * - * @param valueType desired value for the property valueType. - */ - void setValueType(DataTypeDefXsd valueType); - /** * The value of the property instance. * @@ -70,20 +50,39 @@ public interface Property extends DataElement { /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Property/valueId + * More information under https://admin-shell.io/aas/3/0/Property/valueID * - * @return Returns the Reference for the property valueId. + * @return Returns the Reference for the property valueID. */ - @IRI("https://admin-shell.io/aas/3/0/Property/valueId") - Reference getValueId(); + @IRI("https://admin-shell.io/aas/3/0/Property/valueID") + Reference getValueID(); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Property/valueId + * More information under https://admin-shell.io/aas/3/0/Property/valueID * - * @param valueId desired value for the property valueId. + * @param valueID desired value for the property valueID. + */ + void setValueID(Reference valueID); + + /** + * Data type of the value + * + * More information under https://admin-shell.io/aas/3/0/Property/valueType + * + * @return Returns the DataTypeDefXSD for the property valueType. + */ + @IRI("https://admin-shell.io/aas/3/0/Property/valueType") + DataTypeDefXSD getValueType(); + + /** + * Data type of the value + * + * More information under https://admin-shell.io/aas/3/0/Property/valueType + * + * @param valueType desired value for the property valueType. */ - void setValueId(Reference valueId); + 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 deleted file mode 100644 index 8b4527f69..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/ProtocolInformation.java +++ /dev/null @@ -1,135 +0,0 @@ -/* - * 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. - * - * 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.impl.DefaultProtocolInformation; - -/** -*/ -@KnownSubtypes({ - @KnownSubtypes.Type(value = DefaultProtocolInformation.class) -}) -public interface ProtocolInformation { - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress - * - * @return Returns the String for the property endpointAddress. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress") - String getEndpointAddress(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress - * - * @param endpointAddress desired value for the property endpointAddress. - */ - void setEndpointAddress(String endpointAddress); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol - * - * @return Returns the String for the property endpointProtocol. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol") - String getEndpointProtocol(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol - * - * @param endpointProtocol desired value for the property endpointProtocol. - */ - void setEndpointProtocol(String endpointProtocol); - - /** - * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion - * - * @return Returns the String for the property endpointProtocolVersion. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion") - String getEndpointProtocolVersion(); - - /** - * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion - * - * @param endpointProtocolVersion desired value for the property endpointProtocolVersion. - */ - void setEndpointProtocolVersion(String endpointProtocolVersion); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol - * - * @return Returns the String for the property subprotocol. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol") - String getSubprotocol(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol - * - * @param subprotocol desired value for the property subprotocol. - */ - void setSubprotocol(String subprotocol); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody - * - * @return Returns the String for the property subprotocolBody. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody") - String getSubprotocolBody(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody - * - * @param subprotocolBody desired value for the property subprotocolBody. - */ - void setSubprotocolBody(String subprotocolBody); - - /** - * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding - * - * @return Returns the String for the property subprotocolBodyEncoding. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding") - String getSubprotocolBodyEncoding(); - - /** - * - * More information under - * https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding - * - * @param subprotocolBodyEncoding desired value for the property subprotocolBodyEncoding. - */ - void setSubprotocolBodyEncoding(String 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..c7dcf966d 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 @@ -1,6 +1,5 @@ /* * 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 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..d78e990a8 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 @@ -1,6 +1,5 @@ /* * 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 @@ -68,25 +67,6 @@ public interface Qualifier extends HasSemantics { */ void setType(String type); - /** - * Data type of the qualifier value. - * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType - * - * @return Returns the DataTypeDefXsd for the property valueType. - */ - @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueType") - DataTypeDefXsd getValueType(); - - /** - * Data type of the qualifier value. - * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType - * - * @param valueType desired value for the property valueType. - */ - void setValueType(DataTypeDefXsd valueType); - /** * The qualifier value is the value of the qualifier. * @@ -109,20 +89,39 @@ public interface Qualifier extends HasSemantics { /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueId + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueID * - * @return Returns the Reference for the property valueId. + * @return Returns the Reference for the property valueID. */ - @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueId") - Reference getValueId(); + @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueID") + Reference getValueID(); /** * Reference to the global unique ID of a coded value. * - * More information under https://admin-shell.io/aas/3/0/Qualifier/valueId + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueID * - * @param valueId desired value for the property valueId. + * @param valueID desired value for the property valueID. + */ + void setValueID(Reference valueID); + + /** + * Data type of the qualifier value. + * + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType + * + * @return Returns the DataTypeDefXSD for the property valueType. + */ + @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueType") + DataTypeDefXSD getValueType(); + + /** + * Data type of the qualifier value. + * + * More information under https://admin-shell.io/aas/3/0/Qualifier/valueType + * + * @param valueType desired value for the property valueType. */ - void setValueId(Reference valueId); + void setValueType(DataTypeDefXSD valueType); } 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..776c50f89 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 @@ -1,6 +1,5 @@ /* * 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 @@ -27,7 +26,7 @@ public enum QualifierKind { /** - * qualifies the semantic definition the element is referring to ('semanticId') + * qualifies the semantic definition the element is referring to ('semanticID') */ @IRI("https://admin-shell.io/aas/3/0/QualifierKind/ConceptQualifier") CONCEPT_QUALIFIER, 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..c9d70b9eb 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 @@ -1,6 +1,5 @@ /* * 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 @@ -30,23 +29,23 @@ public interface Range extends DataElement { /** - * Data type of the min und max + * The maximum value of the range. * - * More information under https://admin-shell.io/aas/3/0/Range/valueType + * More information under https://admin-shell.io/aas/3/0/Range/max * - * @return Returns the DataTypeDefXsd for the property valueType. + * @return Returns the String for the property max. */ - @IRI("https://admin-shell.io/aas/3/0/Range/valueType") - DataTypeDefXsd getValueType(); + @IRI("https://admin-shell.io/aas/3/0/Range/max") + String getMax(); /** - * Data type of the min und max + * The maximum value of the range. * - * More information under https://admin-shell.io/aas/3/0/Range/valueType + * More information under https://admin-shell.io/aas/3/0/Range/max * - * @param valueType desired value for the property valueType. + * @param max desired value for the property max. */ - void setValueType(DataTypeDefXsd valueType); + void setMax(String max); /** * The minimum value of the range. @@ -68,22 +67,22 @@ public interface Range extends DataElement { void setMin(String min); /** - * The maximum value of the range. + * Data type of the min und max * - * More information under https://admin-shell.io/aas/3/0/Range/max + * More information under https://admin-shell.io/aas/3/0/Range/valueType * - * @return Returns the String for the property max. + * @return Returns the DataTypeDefXSD for the property valueType. */ - @IRI("https://admin-shell.io/aas/3/0/Range/max") - String getMax(); + @IRI("https://admin-shell.io/aas/3/0/Range/valueType") + DataTypeDefXSD getValueType(); /** - * The maximum value of the range. + * Data type of the min und max * - * More information under https://admin-shell.io/aas/3/0/Range/max + * More information under https://admin-shell.io/aas/3/0/Range/valueType * - * @param max desired value for the property max. + * @param valueType desired value for the property valueType. */ - void setMax(String max); + void setValueType(DataTypeDefXSD valueType); } 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..b8a84a829 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 @@ -1,6 +1,5 @@ /* * 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 @@ -25,8 +24,8 @@ * An element that is referable by its 'idShort'. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = SubmodelElement.class), - @KnownSubtypes.Type(value = Identifiable.class) + @KnownSubtypes.Type(value = Identifiable.class), + @KnownSubtypes.Type(value = SubmodelElement.class) }) public interface Referable extends HasExtensions { @@ -52,25 +51,23 @@ public interface Referable extends HasExtensions { void setCategory(String category); /** - * In case of identifiables this attribute is a short name of the element. In case of referable this - * ID is an identifying string of the element within its name space. + * Description or comments on the element. * - * More information under https://admin-shell.io/aas/3/0/Referable/idShort + * More information under https://admin-shell.io/aas/3/0/Referable/description * - * @return Returns the String for the property idShort. + * @return Returns the List of LangStringTextTypes for the property description. */ - @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") - String getIdShort(); + @IRI("https://admin-shell.io/aas/3/0/Referable/description") + List getDescription(); /** - * In case of identifiables this attribute is a short name of the element. In case of referable this - * ID is an identifying string of the element within its name space. + * Description or comments on the element. * - * More information under https://admin-shell.io/aas/3/0/Referable/idShort + * More information under https://admin-shell.io/aas/3/0/Referable/description * - * @param idShort desired value for the property idShort. + * @param description desired value for the property description. */ - void setIdShort(String idShort); + void setDescription(List description); /** * Display name. Can be provided in several languages. @@ -87,27 +84,29 @@ public interface Referable extends HasExtensions { * * More information under https://admin-shell.io/aas/3/0/Referable/displayName * - * @param displayNames desired value for the property displayName. + * @param displayName desired value for the property displayName. */ - void setDisplayName(List displayNames); + void setDisplayName(List displayName); /** - * Description or comments on the element. + * In case of identifiables this attribute is a short name of the element. In case of referable this + * ID is an identifying string of the element within its name space. * - * More information under https://admin-shell.io/aas/3/0/Referable/description + * More information under https://admin-shell.io/aas/3/0/Referable/idShort * - * @return Returns the List of LangStringTextTypes for the property description. + * @return Returns the String for the property idShort. */ - @IRI("https://admin-shell.io/aas/3/0/Referable/description") - List getDescription(); + @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") + String getIdShort(); /** - * Description or comments on the element. + * In case of identifiables this attribute is a short name of the element. In case of referable this + * ID is an identifying string of the element within its name space. * - * More information under https://admin-shell.io/aas/3/0/Referable/description + * More information under https://admin-shell.io/aas/3/0/Referable/idShort * - * @param descriptions desired value for the property description. + * @param idShort desired value for the property idShort. */ - void setDescription(List descriptions); + void setIdShort(String idShort); } 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..e338f7e63 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 @@ -1,6 +1,5 @@ /* * 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 @@ -31,60 +30,60 @@ public interface Reference { /** - * Type of the reference. + * Unique references in their name space. * - * More information under https://admin-shell.io/aas/3/0/Reference/type + * More information under https://admin-shell.io/aas/3/0/Reference/keys * - * @return Returns the ReferenceTypes for the property type. + * @return Returns the List of Keys for the property keys. */ - @IRI("https://admin-shell.io/aas/3/0/Reference/type") - ReferenceTypes getType(); + @IRI("https://admin-shell.io/aas/3/0/Reference/keys") + List getKeys(); /** - * Type of the reference. + * Unique references in their name space. * - * More information under https://admin-shell.io/aas/3/0/Reference/type + * More information under https://admin-shell.io/aas/3/0/Reference/keys * - * @param type desired value for the property type. + * @param keys desired value for the property keys. */ - void setType(ReferenceTypes type); + void setKeys(List keys); /** - * 'semanticId' of the referenced model element ('type' = 'ModelReference'). + * 'semanticID' of the referenced model element ('type' = 'ModelReference'). * - * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticId + * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticID * - * @return Returns the Reference for the property referredSemanticId. + * @return Returns the Reference for the property referredSemanticID. */ - @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticId") - Reference getReferredSemanticId(); + @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticID") + Reference getReferredSemanticID(); /** - * 'semanticId' of the referenced model element ('type' = 'ModelReference'). + * 'semanticID' of the referenced model element ('type' = 'ModelReference'). * - * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticId + * More information under https://admin-shell.io/aas/3/0/Reference/referredSemanticID * - * @param referredSemanticId desired value for the property referredSemanticId. + * @param referredSemanticID desired value for the property referredSemanticID. */ - void setReferredSemanticId(Reference referredSemanticId); + void setReferredSemanticID(Reference referredSemanticID); /** - * Unique references in their name space. + * Type of the reference. * - * More information under https://admin-shell.io/aas/3/0/Reference/keys + * More information under https://admin-shell.io/aas/3/0/Reference/type * - * @return Returns the List of Keys for the property keys. + * @return Returns the ReferenceTypes for the property type. */ - @IRI("https://admin-shell.io/aas/3/0/Reference/keys") - List getKeys(); + @IRI("https://admin-shell.io/aas/3/0/Reference/type") + ReferenceTypes getType(); /** - * Unique references in their name space. + * Type of the reference. * - * More information under https://admin-shell.io/aas/3/0/Reference/keys + * More information under https://admin-shell.io/aas/3/0/Reference/type * - * @param keys desired value for the property keys. + * @param type desired value for the property type. */ - void setKeys(List keys); + void setType(ReferenceTypes type); } 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..f94d3b5f9 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 @@ -1,6 +1,5 @@ /* * 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 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..6182c32e0 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 @@ -1,6 +1,5 @@ /* * 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 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..ab0b90430 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 @@ -1,6 +1,5 @@ /* * 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 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..78e144ece 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 @@ -1,6 +1,5 @@ /* * 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 @@ -31,41 +30,41 @@ public interface Resource { /** - * Path and name of the resource (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/Resource/path + * More information under https://admin-shell.io/aas/3/0/Resource/contentType * - * @return Returns the String for the property path. + * @return Returns the String for the property contentType. */ - @IRI("https://admin-shell.io/aas/3/0/Resource/path") - String getPath(); + @IRI("https://admin-shell.io/aas/3/0/Resource/contentType") + String getContentType(); /** - * Path and name of the resource (with file extension). + * Content type of the content of the file. * - * More information under https://admin-shell.io/aas/3/0/Resource/path + * More information under https://admin-shell.io/aas/3/0/Resource/contentType * - * @param path desired value for the property path. + * @param contentType desired value for the property contentType. */ - void setPath(String path); + void setContentType(String contentType); /** - * Content type of the content of the file. + * Path and name of the resource (with file extension). * - * More information under https://admin-shell.io/aas/3/0/Resource/contentType + * More information under https://admin-shell.io/aas/3/0/Resource/path * - * @return Returns the String for the property contentType. + * @return Returns the String for the property path. */ - @IRI("https://admin-shell.io/aas/3/0/Resource/contentType") - String getContentType(); + @IRI("https://admin-shell.io/aas/3/0/Resource/path") + String getPath(); /** - * Content type of the content of the file. + * Path and name of the resource (with file extension). * - * More information under https://admin-shell.io/aas/3/0/Resource/contentType + * More information under https://admin-shell.io/aas/3/0/Resource/path * - * @param contentType desired value for the property contentType. + * @param path desired value for the property path. */ - void setContentType(String contentType); + void setPath(String path); } 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..fd90bddd3 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 @@ -1,6 +1,5 @@ /* * 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 @@ -18,31 +17,50 @@ 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.impl.DefaultSpecificAssetID; /** * A specific asset ID describes a generic supplementary identifying attribute of the asset. */ @KnownSubtypes({ - @KnownSubtypes.Type(value = DefaultSpecificAssetId.class) + @KnownSubtypes.Type(value = DefaultSpecificAssetID.class) }) -public interface SpecificAssetId extends HasSemantics { +public interface SpecificAssetID extends HasSemantics { + + /** + * The (external) subject the key belongs to or has meaning to. + * + * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/externalSubjectID + * + * @return Returns the Reference for the property externalSubjectID. + */ + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/externalSubjectID") + Reference getExternalSubjectID(); + + /** + * The (external) subject the key belongs to or has meaning to. + * + * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/externalSubjectID + * + * @param externalSubjectID desired value for the property externalSubjectID. + */ + void setExternalSubjectID(Reference externalSubjectID); /** * Name of the identifier * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/name + * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/name * * @return Returns the String for the property name. */ - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/name") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/name") String getName(); /** * Name of the identifier * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/name + * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/name * * @param name desired value for the property name. */ @@ -51,39 +69,20 @@ public interface SpecificAssetId extends HasSemantics { /** * The value of the specific asset identifier with the corresponding name. * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/value + * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/value * * @return Returns the String for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/value") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/value") String getValue(); /** * The value of the specific asset identifier with the corresponding name. * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/value + * More information under https://admin-shell.io/aas/3/0/SpecificAssetID/value * * @param value desired value for the property value. */ void setValue(String value); - /** - * The (external) subject the key belongs to or has meaning to. - * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/externalSubjectId - * - * @return Returns the Reference for the property externalSubjectId. - */ - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/externalSubjectId") - Reference getExternalSubjectId(); - - /** - * The (external) subject the key belongs to or has meaning to. - * - * More information under https://admin-shell.io/aas/3/0/SpecificAssetId/externalSubjectId - * - * @param externalSubjectId desired value for the property externalSubjectId. - */ - void setExternalSubjectId(Reference externalSubjectId); - } 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..67ec72fe8 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 @@ -1,6 +1,5 @@ /* * 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 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..132c85b2d 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 @@ -1,6 +1,5 @@ /* * 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 @@ -28,7 +27,7 @@ @KnownSubtypes({ @KnownSubtypes.Type(value = DefaultSubmodel.class) }) -public interface Submodel extends HasDataSpecification, HasKind, HasSemantics, Identifiable, Qualifiable { +public interface Submodel extends HasDataSpecification, Identifiable, HasSemantics, HasKind, Qualifiable { /** * 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 deleted file mode 100644 index d6ecec4c5..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/SubmodelDescriptor.java +++ /dev/null @@ -1,133 +0,0 @@ -/* - * 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. - * - * 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.impl.DefaultSubmodelDescriptor; - -import java.util.List; - -/** -*/ -@KnownSubtypes({ - @KnownSubtypes.Type(value = DefaultSubmodelDescriptor.class) -}) -public interface SubmodelDescriptor extends Descriptor { - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration - * - * @return Returns the AdministrativeInformation for the property administration. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration") - AdministrativeInformation getAdministration(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/administration - * - * @param administration desired value for the property administration. - */ - void setAdministration(AdministrativeInformation administration); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description - * - * @return Returns the LangStringSet for the property description. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description") - List getDescription(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/description - * - * @param description desired value for the property description. - */ - void setDescription(List description); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName - * - * @return Returns the LangStringSet for the property displayName. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName") - List getDisplayName(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/displayName - * - * @param displayName desired value for the property displayName. - */ - void setDisplayName(List displayName); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort - * - * @return Returns the String for the property idShort. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort") - String getIdShort(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort - * - * @param idShort desired value for the property idShort. - */ - void setIdShort(String idShort); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id - * - * @return Returns the String for the property id. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id") - String getId(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/id - * - * @param id desired value for the property id. - */ - void setId(String id); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId - * - * @return Returns the Reference for the property semanticId. - */ - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId") - Reference getSemanticId(); - - /** - * - * More information under https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId - * - * @param semanticId desired value for the property semanticId. - */ - void setSemanticId(Reference semanticId); - -} 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..8e9f1af77 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 @@ -1,6 +1,5 @@ /* * 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 @@ -24,15 +23,15 @@ * A submodel element is an element suitable for the description and differentiation of assets. */ @KnownSubtypes({ + @KnownSubtypes.Type(value = RelationshipElement.class), @KnownSubtypes.Type(value = DataElement.class), + @KnownSubtypes.Type(value = EventElement.class), @KnownSubtypes.Type(value = Capability.class), @KnownSubtypes.Type(value = Entity.class), - @KnownSubtypes.Type(value = EventElement.class), @KnownSubtypes.Type(value = Operation.class), - @KnownSubtypes.Type(value = RelationshipElement.class), @KnownSubtypes.Type(value = SubmodelElementCollection.class), @KnownSubtypes.Type(value = SubmodelElementList.class) }) -public interface SubmodelElement extends HasDataSpecification, HasSemantics, Qualifiable, Referable { +public interface SubmodelElement extends HasDataSpecification, HasSemantics, Referable, Qualifiable { } 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..ccfffd58b 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 @@ -1,6 +1,5 @@ /* * 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 @@ -19,7 +18,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.annotations.KnownSubtypes; import org.eclipse.digitaltwin.aas4j.v3.model.impl.DefaultSubmodelElementCollection; -import java.util.List; +import java.util.Collection; /** @@ -36,18 +35,18 @@ public interface SubmodelElementCollection extends SubmodelElement { * * More information under https://admin-shell.io/aas/3/0/SubmodelElementCollection/value * - * @return Returns the List of SubmodelElements for the property value. + * @return Returns the Collection of SubmodelElements for the property value. */ @IRI("https://admin-shell.io/aas/3/0/SubmodelElementCollection/value") - List getValue(); + Collection getValue(); /** * Submodel element contained in the collection. * * More information under https://admin-shell.io/aas/3/0/SubmodelElementCollection/value * - * @param values desired value for the property value. + * @param value desired value for the property value. */ - void setValue(List values); + void setValue(Collection value); } 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..f83b4eb55 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 @@ -1,6 +1,5 @@ /* * 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 @@ -54,31 +53,31 @@ public interface SubmodelElementList extends SubmodelElement { /** * Semantic ID the submodel elements contained in the list match to. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement * - * @return Returns the Reference for the property semanticIdListElement. + * @return Returns the Reference for the property semanticIDListElement. */ - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement") - Reference getSemanticIdListElement(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement") + Reference getSemanticIDListElement(); /** * Semantic ID the submodel elements contained in the list match to. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement * - * @param semanticIdListElement desired value for the property semanticIdListElement. + * @param semanticIDListElement desired value for the property semanticIDListElement. */ - void setSemanticIdListElement(Reference semanticIdListElement); + void setSemanticIDListElement(Reference semanticIDListElement); /** * The submodel element type of the submodel elements contained in the list. * * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/typeValueListElement * - * @return Returns the AasSubmodelElements for the property typeValueListElement. + * @return Returns the AASSubmodelElements for the property typeValueListElement. */ @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/typeValueListElement") - AasSubmodelElements getTypeValueListElement(); + AASSubmodelElements getTypeValueListElement(); /** * The submodel element type of the submodel elements contained in the list. @@ -87,44 +86,44 @@ public interface SubmodelElementList extends SubmodelElement { * * @param typeValueListElement desired value for the property typeValueListElement. */ - void setTypeValueListElement(AasSubmodelElements typeValueListElement); + void setTypeValueListElement(AASSubmodelElements typeValueListElement); /** - * The value type of the submodel element contained in the list. + * Submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value * - * @return Returns the DataTypeDefXsd for the property valueTypeListElement. + * @return Returns the List of SubmodelElements for the property value. */ - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement") - DataTypeDefXsd getValueTypeListElement(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/value") + List getValue(); /** - * The value type of the submodel element contained in the list. + * Submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value * - * @param valueTypeListElement desired value for the property valueTypeListElement. + * @param value desired value for the property value. */ - void setValueTypeListElement(DataTypeDefXsd valueTypeListElement); + void setValue(List value); /** - * Submodel element contained in the list. + * The value type of the submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement * - * @return Returns the List of SubmodelElements for the property value. + * @return Returns the DataTypeDefXSD for the property valueTypeListElement. */ - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/value") - List getValue(); + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement") + DataTypeDefXSD getValueTypeListElement(); /** - * Submodel element contained in the list. + * The value type of the submodel element contained in the list. * - * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/value + * More information under https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement * - * @param values desired value for the property value. + * @param valueTypeListElement desired value for the property valueTypeListElement. */ - void setValue(List values); + void setValueTypeListElement(DataTypeDefXSD valueTypeListElement); } 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..3fa7f75ce 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 @@ -1,6 +1,5 @@ /* * 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 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..8b432070b 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 @@ -1,6 +1,5 @@ /* * 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 @@ -31,7 +30,7 @@ public interface ValueReferencePair { /** - * The value of the referenced concept definition of the value in 'valueId'. + * The value of the referenced concept definition of the value in 'valueID'. * * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/value * @@ -41,7 +40,7 @@ public interface ValueReferencePair { String getValue(); /** - * The value of the referenced concept definition of the value in 'valueId'. + * The value of the referenced concept definition of the value in 'valueID'. * * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/value * @@ -52,20 +51,20 @@ public interface ValueReferencePair { /** * Global unique id of the value. * - * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueId + * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueID * - * @return Returns the Reference for the property valueId. + * @return Returns the Reference for the property valueID. */ - @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueId") - Reference getValueId(); + @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueID") + Reference getValueID(); /** * Global unique id of the value. * - * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueId + * More information under https://admin-shell.io/aas/3/0/ValueReferencePair/valueID * - * @param valueId desired value for the property valueId. + * @param valueID desired value for the property valueID. */ - void setValueId(Reference valueId); + void setValueID(Reference valueID); } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java index 075f2353a..a16de81f0 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/annotations/IRI.java @@ -1,6 +1,5 @@ /* * 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 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..14a7ca309 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 @@ -1,6 +1,5 @@ /* * 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 diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java index 2090757dc..283f216a7 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AbstractBuilder.java @@ -1,6 +1,5 @@ /* * 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 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..25ccb9399 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 @@ -1,6 +1,5 @@ /* * 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 @@ -26,13 +25,13 @@ public abstract class AdministrativeInformationBuilder { /** - * This function allows setting a value for version + * This function allows setting a value for creator * - * @param version desired value to be set - * @return Builder object with new value for version + * @param creator desired value to be set + * @return Builder object with new value for creator */ - public B version(String version) { - getBuildingInstance().setVersion(version); + public B creator(Reference creator) { + getBuildingInstance().setCreator(creator); return getSelf(); } @@ -48,24 +47,24 @@ public B revision(String revision) { } /** - * This function allows setting a value for creator + * This function allows setting a value for templateID * - * @param creator desired value to be set - * @return Builder object with new value for creator + * @param templateID desired value to be set + * @return Builder object with new value for templateID */ - public B creator(Reference creator) { - getBuildingInstance().setCreator(creator); + public B templateID(String templateID) { + getBuildingInstance().setTemplateID(templateID); return getSelf(); } /** - * This function allows setting a value for templateId + * This function allows setting a value for version * - * @param templateId desired value to be set - * @return Builder object with new value for templateId + * @param version desired value to be set + * @return Builder object with new value for version */ - public B templateId(String templateId) { - getBuildingInstance().setTemplateId(templateId); + public B version(String version) { + getBuildingInstance().setVersion(version); return getSelf(); } 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..663bd819f 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 @@ -1,6 +1,5 @@ /* * 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 @@ -90,13 +89,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -123,57 +122,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -189,24 +177,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -231,4 +208,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/AssetAdministrationShellBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellBuilder.java index 51e9059c1..45b103666 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 @@ -1,6 +1,5 @@ /* * 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 @@ -24,24 +23,24 @@ public abstract class AssetAdministrationShellBuilder { /** - * This function allows setting a value for derivedFrom + * This function allows setting a value for assetInformation * - * @param derivedFrom desired value to be set - * @return Builder object with new value for derivedFrom + * @param assetInformation desired value to be set + * @return Builder object with new value for assetInformation */ - public B derivedFrom(Reference derivedFrom) { - getBuildingInstance().setDerivedFrom(derivedFrom); + public B assetInformation(AssetInformation assetInformation) { + getBuildingInstance().setAssetInformation(assetInformation); return getSelf(); } /** - * This function allows setting a value for assetInformation + * This function allows setting a value for derivedFrom * - * @param assetInformation desired value to be set - * @return Builder object with new value for assetInformation + * @param derivedFrom desired value to be set + * @return Builder object with new value for derivedFrom */ - public B assetInformation(AssetInformation assetInformation) { - getBuildingInstance().setAssetInformation(assetInformation); + public B derivedFrom(Reference derivedFrom) { + getBuildingInstance().setDerivedFrom(derivedFrom); return getSelf(); } @@ -123,57 +122,57 @@ public B category(String category) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for displayName + * This function allows adding a value to the List description * - * @param displayNames desired value to be set - * @return Builder object with new value for displayName + * @param description desired value to be added + * @return Builder object with new value for description */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); return getSelf(); } /** - * This function allows adding a value to the List displayName + * This function allows setting a value for displayName * - * @param displayName desired value to be added + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(LangStringNameType displayName) { - getBuildingInstance().getDisplayName().add(displayName); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List displayName * - * @param descriptions desired value to be set - * @return Builder object with new value for description + * @param displayName desired value to be added + * @return Builder object with new value for displayName */ - public B description(List descriptions) { - getBuildingInstance().setDescription(descriptions); + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); 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 deleted file mode 100644 index e0b711277..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/AssetAdministrationShellDescriptorBuilder.java +++ /dev/null @@ -1,145 +0,0 @@ -/* - * 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. - * - * 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 java.util.List; - -public abstract class AssetAdministrationShellDescriptorBuilder> - extends ExtendableBuilder { - - /** - * 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 description - * - * @param description desired value to be set - * @return Builder object with new value for description - */ - public B description(List description) { - getBuildingInstance().setDescription(description); - return getSelf(); - } - - /** - * This function allows setting a value for displayName - * - * @param displayName desired value to be set - * @return Builder object with new value for displayName - */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); - 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 id property - * - * @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 assetKind property - * - * @param assetKind desired value to be set - * @return Builder object with new value for assetId - */ - public B assetKind(AssetKind assetKind) { - getBuildingInstance().setAssetKind(assetKind); - return getSelf(); - } - - /** - * This function allows setting a value for specificAssetId - * - * @param specificAssetId desired value to be set - * @return Builder object with new value for specificAssetId - */ - public B specificAssetId(SpecificAssetId specificAssetId) { - getBuildingInstance().setSpecificAssetIds(specificAssetId); - 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(Reference globalAssetId) { - getBuildingInstance().setGlobalAssetId(globalAssetId); - 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 - */ - public B submodelDescriptor(List submodelDescriptor) { - getBuildingInstance().setSubmodelDescriptor(submodelDescriptor); - 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 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(); - } -} 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..cb3798301 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 @@ -1,6 +1,5 @@ /* * 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 @@ -18,7 +17,7 @@ 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.SpecificAssetID; import java.util.List; @@ -38,57 +37,57 @@ public B assetKind(AssetKind assetKind) { } /** - * This function allows setting a value for globalAssetId + * This function allows setting a value for assetType * - * @param globalAssetId desired value to be set - * @return Builder object with new value for globalAssetId + * @param assetType desired value to be set + * @return Builder object with new value for assetType */ - public B globalAssetId(String globalAssetId) { - getBuildingInstance().setGlobalAssetId(globalAssetId); + public B assetType(String assetType) { + getBuildingInstance().setAssetType(assetType); return getSelf(); } /** - * This function allows setting a value for specificAssetIds + * This function allows setting a value for defaultThumbnail * - * @param specificAssetIds desired value to be set - * @return Builder object with new value for specificAssetIds + * @param defaultThumbnail desired value to be set + * @return Builder object with new value for defaultThumbnail */ - public B specificAssetIds(List specificAssetIds) { - getBuildingInstance().setSpecificAssetIds(specificAssetIds); + public B defaultThumbnail(Resource defaultThumbnail) { + getBuildingInstance().setDefaultThumbnail(defaultThumbnail); return getSelf(); } /** - * This function allows adding a value to the List specificAssetIds + * This function allows setting a value for globalAssetID * - * @param specificAssetIds desired value to be added - * @return Builder object with new value for specificAssetIds + * @param globalAssetID desired value to be set + * @return Builder object with new value for globalAssetID */ - public B specificAssetIds(SpecificAssetId specificAssetIds) { - getBuildingInstance().getSpecificAssetIds().add(specificAssetIds); + public B globalAssetID(String globalAssetID) { + getBuildingInstance().setGlobalAssetID(globalAssetID); return getSelf(); } /** - * This function allows setting a value for assetType + * This function allows setting a value for specificAssetIds * - * @param assetType desired value to be set - * @return Builder object with new value for assetType + * @param specificAssetIds desired value to be set + * @return Builder object with new value for specificAssetIds */ - public B assetType(String assetType) { - getBuildingInstance().setAssetType(assetType); + public B specificAssetIds(List specificAssetIds) { + getBuildingInstance().setSpecificAssetIds(specificAssetIds); return getSelf(); } /** - * This function allows setting a value for defaultThumbnail + * This function allows adding a value to the List specificAssetIds * - * @param defaultThumbnail desired value to be set - * @return Builder object with new value for defaultThumbnail + * @param specificAssetIds desired value to be added + * @return Builder object with new value for specificAssetIds */ - public B defaultThumbnail(Resource defaultThumbnail) { - getBuildingInstance().setDefaultThumbnail(defaultThumbnail); + public B specificAssetIds(SpecificAssetID specificAssetIds) { + getBuildingInstance().getSpecificAssetIds().add(specificAssetIds); return getSelf(); } } 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..01edbf0a3 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,17 +22,6 @@ public abstract class BasicEventElementBuilder> extends ExtendableBuilder { - /** - * This function allows setting a value for observed - * - * @param observed desired value to be set - * @return Builder object with new value for observed - */ - public B observed(Reference observed) { - getBuildingInstance().setObserved(observed); - return getSelf(); - } - /** * This function allows setting a value for direction * @@ -46,24 +34,24 @@ public B direction(Direction direction) { } /** - * This function allows setting a value for state + * This function allows setting a value for lastUpdate * - * @param state desired value to be set - * @return Builder object with new value for state + * @param lastUpdate desired value to be set + * @return Builder object with new value for lastUpdate */ - public B state(StateOfEvent state) { - getBuildingInstance().setState(state); + public B lastUpdate(String lastUpdate) { + getBuildingInstance().setLastUpdate(lastUpdate); return getSelf(); } /** - * This function allows setting a value for messageTopic + * This function allows setting a value for maxInterval * - * @param messageTopic desired value to be set - * @return Builder object with new value for messageTopic + * @param maxInterval desired value to be set + * @return Builder object with new value for maxInterval */ - public B messageTopic(String messageTopic) { - getBuildingInstance().setMessageTopic(messageTopic); + public B maxInterval(String maxInterval) { + getBuildingInstance().setMaxInterval(maxInterval); return getSelf(); } @@ -79,13 +67,13 @@ public B messageBroker(Reference messageBroker) { } /** - * This function allows setting a value for lastUpdate + * This function allows setting a value for messageTopic * - * @param lastUpdate desired value to be set - * @return Builder object with new value for lastUpdate + * @param messageTopic desired value to be set + * @return Builder object with new value for messageTopic */ - public B lastUpdate(String lastUpdate) { - getBuildingInstance().setLastUpdate(lastUpdate); + public B messageTopic(String messageTopic) { + getBuildingInstance().setMessageTopic(messageTopic); return getSelf(); } @@ -101,13 +89,24 @@ public B minInterval(String minInterval) { } /** - * This function allows setting a value for maxInterval + * This function allows setting a value for observed * - * @param maxInterval desired value to be set - * @return Builder object with new value for maxInterval + * @param observed desired value to be set + * @return Builder object with new value for observed */ - public B maxInterval(String maxInterval) { - getBuildingInstance().setMaxInterval(maxInterval); + public B observed(Reference observed) { + getBuildingInstance().setObserved(observed); + return getSelf(); + } + + /** + * This function allows setting a value for state + * + * @param state desired value to be set + * @return Builder object with new value for state + */ + public B state(StateOfEvent state) { + getBuildingInstance().setState(state); return getSelf(); } @@ -134,13 +133,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -167,57 +166,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -233,24 +221,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -275,4 +252,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/BlobBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/BlobBuilder.java index 6fe946097..43f20de00 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,24 +22,24 @@ public abstract class BlobBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for value + * This function allows setting a value for contentType * - * @param value desired value to be set - * @return Builder object with new value for value + * @param contentType desired value to be set + * @return Builder object with new value for contentType */ - public B value(byte[] value) { - getBuildingInstance().setValue(value); + public B contentType(String contentType) { + getBuildingInstance().setContentType(contentType); return getSelf(); } /** - * This function allows setting a value for contentType + * This function allows setting a value for value * - * @param contentType desired value to be set - * @return Builder object with new value for contentType + * @param value desired value to be set + * @return Builder object with new value for value */ - public B contentType(String contentType) { - getBuildingInstance().setContentType(contentType); + public B value(byte[] value) { + getBuildingInstance().setValue(value); return getSelf(); } @@ -67,13 +66,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -100,57 +99,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -166,24 +154,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -208,4 +185,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/Builder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/Builder.java index cdc11013e..7e27dad1f 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/Builder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/Builder.java @@ -1,6 +1,5 @@ /* * 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 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..f62d73756 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 @@ -1,6 +1,5 @@ /* * 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 @@ -45,13 +44,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -78,57 +77,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -144,24 +132,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -186,4 +163,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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..65e871bb3 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 @@ -1,6 +1,5 @@ /* * 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 @@ -26,11 +25,11 @@ public abstract class ConceptDescriptionBuilder isCaseOfs) { - getBuildingInstance().setIsCaseOf(isCaseOfs); + public B isCaseOf(List isCaseOf) { + getBuildingInstance().setIsCaseOf(isCaseOf); return getSelf(); } @@ -101,57 +100,57 @@ public B category(String category) { } /** - * This function allows setting a value for idShort + * This function allows setting a value for description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be set + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for displayName + * This function allows adding a value to the List description * - * @param displayNames desired value to be set - * @return Builder object with new value for displayName + * @param description desired value to be added + * @return Builder object with new value for description */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); return getSelf(); } /** - * This function allows adding a value to the List displayName + * This function allows setting a value for displayName * - * @param displayName desired value to be added + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(LangStringNameType displayName) { - getBuildingInstance().getDisplayName().add(displayName); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } /** - * This function allows setting a value for description + * This function allows adding a value to the List displayName * - * @param descriptions desired value to be set - * @return Builder object with new value for description + * @param displayName desired value to be added + * @return Builder object with new value for displayName */ - public B description(List descriptions) { - getBuildingInstance().setDescription(descriptions); + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); 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..d02d832fe 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,14 +22,58 @@ public abstract class DataSpecificationIec61360Builder> extends ExtendableBuilder { + /** + * This function allows setting a value for dataType + * + * @param dataType desired value to be set + * @return Builder object with new value for dataType + */ + public B dataType(DataTypeIec61360 dataType) { + getBuildingInstance().setDataType(dataType); + return getSelf(); + } + + /** + * This function allows setting a value for definition + * + * @param definition desired value to be set + * @return Builder object with new value for definition + */ + public B definition(List definition) { + getBuildingInstance().setDefinition(definition); + return getSelf(); + } + + /** + * This function allows adding a value to the List definition + * + * @param definition desired value to be added + * @return Builder object with new value for definition + */ + public B definition(LangStringDefinitionTypeIec61360 definition) { + getBuildingInstance().getDefinition().add(definition); + return getSelf(); + } + + /** + * This function allows setting a value for levelType + * + * @param levelType desired value to be set + * @return Builder object with new value for levelType + */ + public B levelType(LevelType levelType) { + getBuildingInstance().setLevelType(levelType); + return getSelf(); + } + /** * This function allows setting a value for preferredName * - * @param preferredNames desired value to be set + * @param preferredName desired value to be set * @return Builder object with new value for preferredName */ - public B preferredName(List preferredNames) { - getBuildingInstance().setPreferredName(preferredNames); + public B preferredName(List preferredName) { + getBuildingInstance().setPreferredName(preferredName); return getSelf(); } @@ -48,11 +91,11 @@ public B preferredName(LangStringPreferredNameTypeIec61360 preferredName) { /** * This function allows setting a value for shortName * - * @param shortNames desired value to be set + * @param shortName desired value to be set * @return Builder object with new value for shortName */ - public B shortName(List shortNames) { - getBuildingInstance().setShortName(shortNames); + public B shortName(List shortName) { + getBuildingInstance().setShortName(shortName); return getSelf(); } @@ -67,28 +110,6 @@ public B shortName(LangStringShortNameTypeIec61360 shortName) { return getSelf(); } - /** - * This function allows setting a value for unit - * - * @param unit desired value to be set - * @return Builder object with new value for unit - */ - public B unit(String unit) { - getBuildingInstance().setUnit(unit); - return getSelf(); - } - - /** - * This function allows setting a value for unitId - * - * @param unitId desired value to be set - * @return Builder object with new value for unitId - */ - public B unitId(Reference unitId) { - getBuildingInstance().setUnitId(unitId); - return getSelf(); - } - /** * This function allows setting a value for sourceOfDefinition * @@ -112,35 +133,35 @@ public B symbol(String symbol) { } /** - * This function allows setting a value for dataType + * This function allows setting a value for unit * - * @param dataType desired value to be set - * @return Builder object with new value for dataType + * @param unit desired value to be set + * @return Builder object with new value for unit */ - public B dataType(DataTypeIec61360 dataType) { - getBuildingInstance().setDataType(dataType); + public B unit(String unit) { + getBuildingInstance().setUnit(unit); return getSelf(); } /** - * This function allows setting a value for definition + * This function allows setting a value for unitID * - * @param definitions desired value to be set - * @return Builder object with new value for definition + * @param unitID desired value to be set + * @return Builder object with new value for unitID */ - public B definition(List definitions) { - getBuildingInstance().setDefinition(definitions); + public B unitID(Reference unitID) { + getBuildingInstance().setUnitID(unitID); return getSelf(); } /** - * This function allows adding a value to the List definition + * This function allows setting a value for value * - * @param definition desired value to be added - * @return Builder object with new value for definition + * @param value desired value to be set + * @return Builder object with new value for value */ - public B definition(LangStringDefinitionTypeIec61360 definition) { - getBuildingInstance().getDefinition().add(definition); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } @@ -166,26 +187,4 @@ public B valueList(ValueList valueList) { 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(); - } - - /** - * This function allows setting a value for levelType - * - * @param levelType desired value to be set - * @return Builder object with new value for levelType - */ - public B levelType(LevelType levelType) { - getBuildingInstance().setLevelType(levelType); - return getSelf(); - } - } 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 deleted file mode 100644 index 85175e975..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/DescriptorBuilder.java +++ /dev/null @@ -1,46 +0,0 @@ -/* - * 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. - * - * 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.Descriptor; -import org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; - -public abstract class DescriptorBuilder> extends ExtendableBuilder { - - /** - * 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 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(); - } -} 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..f88b3561e 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 @@ -1,6 +1,5 @@ /* * 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 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 deleted file mode 100644 index 22c99fe99..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EndpointBuilder.java +++ /dev/null @@ -1,46 +0,0 @@ -/* - * 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. - * - * 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.Endpoint; -import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; - -public abstract class EndpointBuilder> extends ExtendableBuilder { - - /** - * This function allows setting a value for interface - * - * @param interfaceValue desired value to be set - * @return Builder object with new value for interface - */ - public B withInterface(String interfaceValue) { - getBuildingInstance().setInterface(interfaceValue); - return getSelf(); - } - - /** - * This function allows setting a value for protocolInformation - * - * @param protocolInformation desired value to be set - * @return Builder object with new value for protocolInformation - */ - public B protocolInformation(ProtocolInformation protocolInformation) { - getBuildingInstance().setProtocolInformation(protocolInformation); - 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..92e516e17 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 @@ -1,6 +1,5 @@ /* * 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 @@ -22,28 +21,6 @@ public abstract class EntityBuilder> extends ExtendableBuilder { - /** - * 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(SubmodelElement statements) { - getBuildingInstance().getStatements().add(statements); - return getSelf(); - } - /** * This function allows setting a value for entityType * @@ -56,13 +33,13 @@ public B entityType(EntityType entityType) { } /** - * This function allows setting a value for globalAssetId + * This function allows setting a value for globalAssetID * - * @param globalAssetId desired value to be set - * @return Builder object with new 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); + public B globalAssetID(String globalAssetID) { + getBuildingInstance().setGlobalAssetID(globalAssetID); return getSelf(); } @@ -72,7 +49,7 @@ public B globalAssetId(String globalAssetId) { * @param specificAssetIds desired value to be set * @return Builder object with new value for specificAssetIds */ - public B specificAssetIds(List specificAssetIds) { + public B specificAssetIds(List specificAssetIds) { getBuildingInstance().setSpecificAssetIds(specificAssetIds); return getSelf(); } @@ -83,11 +60,33 @@ public B specificAssetIds(List specificAssetIds) { * @param specificAssetIds desired value to be added * @return Builder object with new value for specificAssetIds */ - public B specificAssetIds(SpecificAssetId specificAssetIds) { + public B specificAssetIds(SpecificAssetID 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(SubmodelElement statements) { + getBuildingInstance().getStatements().add(statements); + return getSelf(); + } + /** * This function allows setting a value for embeddedDataSpecifications * @@ -111,13 +110,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -144,57 +143,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -210,24 +198,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -252,4 +229,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/EnvironmentBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/EnvironmentBuilder.java index 60288ffc2..d33b72b90 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 @@ -1,6 +1,5 @@ /* * 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 @@ -48,46 +47,46 @@ public B assetAdministrationShells(AssetAdministrationShell assetAdministrationS } /** - * This function allows setting a value for submodels + * This function allows setting a value for conceptDescriptions * - * @param submodels desired value to be set - * @return Builder object with new value for submodels + * @param conceptDescriptions desired value to be set + * @return Builder object with new value for conceptDescriptions */ - public B submodels(List submodels) { - getBuildingInstance().setSubmodels(submodels); + public B conceptDescriptions(List conceptDescriptions) { + getBuildingInstance().setConceptDescriptions(conceptDescriptions); return getSelf(); } /** - * This function allows adding a value to the List submodels + * This function allows adding a value to the List conceptDescriptions * - * @param submodels desired value to be added - * @return Builder object with new value for submodels + * @param conceptDescriptions desired value to be added + * @return Builder object with new value for conceptDescriptions */ - public B submodels(Submodel submodels) { - getBuildingInstance().getSubmodels().add(submodels); + public B conceptDescriptions(ConceptDescription conceptDescriptions) { + getBuildingInstance().getConceptDescriptions().add(conceptDescriptions); return getSelf(); } /** - * This function allows setting a value for conceptDescriptions + * This function allows setting a value for submodels * - * @param conceptDescriptions desired value to be set - * @return Builder object with new value for conceptDescriptions + * @param submodels desired value to be set + * @return Builder object with new value for submodels */ - public B conceptDescriptions(List conceptDescriptions) { - getBuildingInstance().setConceptDescriptions(conceptDescriptions); + public B submodels(List submodels) { + getBuildingInstance().setSubmodels(submodels); return getSelf(); } /** - * This function allows adding a value to the List conceptDescriptions + * This function allows adding a value to the List submodels * - * @param conceptDescriptions desired value to be added - * @return Builder object with new value for conceptDescriptions + * @param submodels desired value to be added + * @return Builder object with new value for submodels */ - public B conceptDescriptions(ConceptDescription conceptDescriptions) { - getBuildingInstance().getConceptDescriptions().add(conceptDescriptions); + public B submodels(Submodel submodels) { + getBuildingInstance().getSubmodels().add(submodels); return getSelf(); } } 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..d00833379 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,68 +22,68 @@ public abstract class EventPayloadBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for source + * This function allows setting a value for observableReference * - * @param source desired value to be set - * @return Builder object with new value for source + * @param observableReference desired value to be set + * @return Builder object with new value for observableReference */ - public B source(Reference source) { - getBuildingInstance().setSource(source); + public B observableReference(Reference observableReference) { + getBuildingInstance().setObservableReference(observableReference); return getSelf(); } /** - * This function allows setting a value for sourceSemanticId + * This function allows setting a value for observableSemanticID * - * @param sourceSemanticId desired value to be set - * @return Builder object with new value for sourceSemanticId + * @param observableSemanticID desired value to be set + * @return Builder object with new value for observableSemanticID */ - public B sourceSemanticId(Reference sourceSemanticId) { - getBuildingInstance().setSourceSemanticId(sourceSemanticId); + public B observableSemanticID(Reference observableSemanticID) { + getBuildingInstance().setObservableSemanticID(observableSemanticID); return getSelf(); } /** - * This function allows setting a value for observableReference + * This function allows setting a value for payload * - * @param observableReference desired value to be set - * @return Builder object with new value for observableReference + * @param payload desired value to be set + * @return Builder object with new value for payload */ - public B observableReference(Reference observableReference) { - getBuildingInstance().setObservableReference(observableReference); + public B payload(byte[] payload) { + getBuildingInstance().setPayload(payload); return getSelf(); } /** - * This function allows setting a value for observableSemanticId + * This function allows setting a value for source * - * @param observableSemanticId desired value to be set - * @return Builder object with new value for observableSemanticId + * @param source desired value to be set + * @return Builder object with new value for source */ - public B observableSemanticId(Reference observableSemanticId) { - getBuildingInstance().setObservableSemanticId(observableSemanticId); + public B source(Reference source) { + getBuildingInstance().setSource(source); return getSelf(); } /** - * This function allows setting a value for topic + * This function allows setting a value for sourceSemanticID * - * @param topic desired value to be set - * @return Builder object with new value for topic + * @param sourceSemanticID desired value to be set + * @return Builder object with new value for sourceSemanticID */ - public B topic(String topic) { - getBuildingInstance().setTopic(topic); + public B sourceSemanticID(Reference sourceSemanticID) { + getBuildingInstance().setSourceSemanticID(sourceSemanticID); return getSelf(); } /** - * This function allows setting a value for subjectId + * This function allows setting a value for subjectID * - * @param subjectId desired value to be set - * @return Builder object with new value for subjectId + * @param subjectID desired value to be set + * @return Builder object with new value for subjectID */ - public B subjectId(Reference subjectId) { - getBuildingInstance().setSubjectId(subjectId); + public B subjectID(Reference subjectID) { + getBuildingInstance().setSubjectID(subjectID); return getSelf(); } @@ -100,13 +99,13 @@ public B timeStamp(String timeStamp) { } /** - * This function allows setting a value for payload + * This function allows setting a value for topic * - * @param payload desired value to be set - * @return Builder object with new value for payload + * @param topic desired value to be set + * @return Builder object with new value for topic */ - public B payload(byte[] payload) { - getBuildingInstance().setPayload(payload); + public B topic(String topic) { + getBuildingInstance().setTopic(topic); return getSelf(); } } diff --git a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java index f11f39f72..57cf35007 100644 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java +++ b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ExtendableBuilder.java @@ -1,6 +1,5 @@ /* * 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 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..bff2490ca 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 @@ -1,6 +1,5 @@ /* * 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,7 +14,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import org.eclipse.digitaltwin.aas4j.v3.model.Extension; import org.eclipse.digitaltwin.aas4j.v3.model.Reference; @@ -36,57 +35,57 @@ public B name(String name) { } /** - * This function allows setting a value for valueType + * This function allows setting a value for refersTo * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param refersTo desired value to be set + * @return Builder object with new value for refersTo */ - public B valueType(DataTypeDefXsd valueType) { - getBuildingInstance().setValueType(valueType); + public B refersTo(List refersTo) { + getBuildingInstance().setRefersTo(refersTo); return getSelf(); } /** - * This function allows setting a value for value + * This function allows adding a value to the List refersTo * - * @param value desired value to be set - * @return Builder object with new value for value + * @param refersTo desired value to be added + * @return Builder object with new value for refersTo */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B refersTo(Reference refersTo) { + getBuildingInstance().getRefersTo().add(refersTo); return getSelf(); } /** - * This function allows setting a value for refersTo + * This function allows setting a value for value * - * @param refersTos desired value to be set - * @return Builder object with new value for refersTo + * @param value desired value to be set + * @return Builder object with new value for value */ - public B refersTo(List refersTos) { - getBuildingInstance().setRefersTo(refersTos); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows adding a value to the List refersTo + * This function allows setting a value for valueType * - * @param refersTo desired value to be added - * @return Builder object with new value for refersTo + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B refersTo(Reference refersTo) { - getBuildingInstance().getRefersTo().add(refersTo); + public B valueType(DataTypeDefXSD valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } 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..347317d65 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,24 +22,24 @@ public abstract class FileBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for value + * This function allows setting a value for contentType * - * @param value desired value to be set - * @return Builder object with new value for value + * @param contentType desired value to be set + * @return Builder object with new value for contentType */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B contentType(String contentType) { + getBuildingInstance().setContentType(contentType); return getSelf(); } /** - * This function allows setting a value for contentType + * This function allows setting a value for value * - * @param contentType desired value to be set - * @return Builder object with new value for contentType + * @param value desired value to be set + * @return Builder object with new value for value */ - public B contentType(String contentType) { - getBuildingInstance().setContentType(contentType); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } @@ -67,13 +66,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -100,57 +99,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -166,24 +154,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -208,4 +185,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/KeyBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/KeyBuilder.java index 131e0ee5d..f04e9a96c 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 @@ -1,6 +1,5 @@ /* * 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 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..29b8d3f92 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 @@ -1,6 +1,5 @@ /* * 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 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..8b541147d 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 @@ -1,6 +1,5 @@ /* * 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 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..dedd6c541 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 @@ -1,6 +1,5 @@ /* * 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 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..697ef25fc 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 @@ -1,6 +1,5 @@ /* * 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 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..b84b045d8 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 @@ -1,6 +1,5 @@ /* * 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 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..48246a400 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 @@ -1,6 +1,5 @@ /* * 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 @@ -21,6 +20,17 @@ public abstract class LevelTypeBuilder> 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(boolean max) { + getBuildingInstance().setMax(max); + return getSelf(); + } + /** * This function allows setting a value for min * @@ -53,15 +63,4 @@ public B typ(boolean typ) { getBuildingInstance().setTyp(typ); return getSelf(); } - - /** - * 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(boolean max) { - getBuildingInstance().setMax(max); - 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..ac14d8c29 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 @@ -1,6 +1,5 @@ /* * 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 @@ -26,11 +25,11 @@ public abstract class MultiLanguagePropertyBuilder values) { - getBuildingInstance().setValue(values); + public B value(List value) { + getBuildingInstance().setValue(value); return getSelf(); } @@ -46,13 +45,13 @@ public B value(LangStringTextType value) { } /** - * This function allows setting a value for valueId + * This function allows setting a value for valueID * - * @param valueId desired value to be set - * @return Builder object with new value for valueId + * @param valueID desired value to be set + * @return Builder object with new value for valueID */ - public B valueId(Reference valueId) { - getBuildingInstance().setValueId(valueId); + public B valueID(Reference valueID) { + getBuildingInstance().setValueID(valueID); return getSelf(); } @@ -79,13 +78,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -112,57 +111,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -178,24 +166,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -220,4 +197,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/OperationBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationBuilder.java index 8c8b23f59..767c3bd8e 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 @@ -1,6 +1,5 @@ /* * 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 @@ -22,6 +21,28 @@ public abstract class OperationBuilder> extends ExtendableBuilder { + /** + * This function allows setting a value for inoutputVariables + * + * @param inoutputVariables desired value to be set + * @return Builder object with new value for inoutputVariables + */ + public B inoutputVariables(List inoutputVariables) { + getBuildingInstance().setInoutputVariables(inoutputVariables); + return getSelf(); + } + + /** + * This function allows adding a value to the List inoutputVariables + * + * @param inoutputVariables desired value to be added + * @return Builder object with new value for inoutputVariables + */ + public B inoutputVariables(OperationVariable inoutputVariables) { + getBuildingInstance().getInoutputVariables().add(inoutputVariables); + return getSelf(); + } + /** * This function allows setting a value for inputVariables * @@ -66,28 +87,6 @@ public B outputVariables(OperationVariable outputVariables) { return getSelf(); } - /** - * This function allows setting a value for inoutputVariables - * - * @param inoutputVariables desired value to be set - * @return Builder object with new value for inoutputVariables - */ - public B inoutputVariables(List inoutputVariables) { - getBuildingInstance().setInoutputVariables(inoutputVariables); - return getSelf(); - } - - /** - * This function allows adding a value to the List inoutputVariables - * - * @param inoutputVariables desired value to be added - * @return Builder object with new value for inoutputVariables - */ - public B inoutputVariables(OperationVariable inoutputVariables) { - getBuildingInstance().getInoutputVariables().add(inoutputVariables); - return getSelf(); - } - /** * This function allows setting a value for embeddedDataSpecifications * @@ -111,13 +110,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -144,57 +143,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -210,24 +198,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -252,4 +229,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/OperationVariableBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/OperationVariableBuilder.java index cddb89a47..790ee3960 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 @@ -1,6 +1,5 @@ /* * 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 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..234ebf561 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,35 +22,35 @@ public abstract class PropertyBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for valueType + * This function allows setting a value for value * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param value desired value to be set + * @return Builder object with new value for value */ - public B valueType(DataTypeDefXsd valueType) { - getBuildingInstance().setValueType(valueType); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows setting a value for value + * This function allows setting a value for valueID * - * @param value desired value to be set - * @return Builder object with new value for value + * @param valueID desired value to be set + * @return Builder object with new value for valueID */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B valueID(Reference valueID) { + getBuildingInstance().setValueID(valueID); return getSelf(); } /** - * This function allows setting a value for valueId + * This function allows setting a value for valueType * - * @param valueId desired value to be set - * @return Builder object with new value for valueId + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B valueId(Reference valueId) { - getBuildingInstance().setValueId(valueId); + public B valueType(DataTypeDefXSD valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } @@ -78,13 +77,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -111,57 +110,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -177,24 +165,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -219,4 +196,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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 deleted file mode 100644 index e158128d3..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ProtocolInformationBuilder.java +++ /dev/null @@ -1,88 +0,0 @@ -/* - * 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. - * - * 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.ProtocolInformation; - -public abstract class ProtocolInformationBuilder> - extends ExtendableBuilder { - - /** - * This function allows setting a value for endpointAddress - * - * @param endpointAddress desired value to be set - * @return Builder object with new value for endpointAddress - */ - public B endpointAddress(String endpointAddress) { - getBuildingInstance().setEndpointAddress(endpointAddress); - return getSelf(); - } - - /** - * This function allows setting a value for endpointProtocol - * - * @param endpointProtocol desired value to be set - * @return Builder object with new value for endpointProtocol - */ - public B endpointProtocol(String endpointProtocol) { - getBuildingInstance().setEndpointProtocol(endpointProtocol); - return getSelf(); - } - - /** - * This function allows setting a value for endpointProtocolVersion - * - * @param endpointProtocolVersion desired value to be set - * @return Builder object with new value for endpointProtocolVersion - */ - public B endpointProtocolVersion(String endpointProtocolVersion) { - getBuildingInstance().setEndpointProtocolVersion(endpointProtocolVersion); - return getSelf(); - } - - /** - * This function allows setting a value for subprotocol - * - * @param subprotocol desired value to be set - * @return Builder object with new value for subprotocol - */ - public B subprotocol(String subprotocol) { - getBuildingInstance().setSubprotocol(subprotocol); - return getSelf(); - } - - /** - * This function allows setting a value for subprotocolBody - * - * @param subprotocolBody desired value to be set - * @return Builder object with new value for subprotocolBody - */ - public B subprotocolBody(String subprotocolBody) { - getBuildingInstance().setSubprotocolBody(subprotocolBody); - return getSelf(); - } - - /** - * This function allows setting a value for subprotocolBodyEncoding - * - * @param subprotocolBodyEncoding desired value to be set - * @return Builder object with new value for subprotocolBodyEncoding - */ - public B subprotocolBodyEncoding(String subprotocolBodyEncoding) { - getBuildingInstance().setSubprotocolBodyEncoding(subprotocolBodyEncoding); - return getSelf(); - } -} 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..ed8646d44 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 @@ -1,6 +1,5 @@ /* * 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,7 +14,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.builder; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +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; @@ -48,46 +47,46 @@ public B type(String type) { } /** - * This function allows setting a value for valueType + * This function allows setting a value for value * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param value desired value to be set + * @return Builder object with new value for value */ - public B valueType(DataTypeDefXsd valueType) { - getBuildingInstance().setValueType(valueType); + public B value(String value) { + getBuildingInstance().setValue(value); return getSelf(); } /** - * This function allows setting a value for value + * This function allows setting a value for valueID * - * @param value desired value to be set - * @return Builder object with new value for value + * @param valueID desired value to be set + * @return Builder object with new value for valueID */ - public B value(String value) { - getBuildingInstance().setValue(value); + public B valueID(Reference valueID) { + getBuildingInstance().setValueID(valueID); return getSelf(); } /** - * This function allows setting a value for valueId + * This function allows setting a value for valueType * - * @param valueId desired value to be set - * @return Builder object with new value for valueId + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B valueId(Reference valueId) { - getBuildingInstance().setValueId(valueId); + public B valueType(DataTypeDefXSD valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } 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..f265d1700 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 @@ -1,6 +1,5 @@ /* * 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 @@ -23,13 +22,13 @@ public abstract class RangeBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for valueType + * This function allows setting a value for max * - * @param valueType desired value to be set - * @return Builder object with new value for valueType + * @param max desired value to be set + * @return Builder object with new value for max */ - public B valueType(DataTypeDefXsd valueType) { - getBuildingInstance().setValueType(valueType); + public B max(String max) { + getBuildingInstance().setMax(max); return getSelf(); } @@ -45,13 +44,13 @@ public B min(String min) { } /** - * This function allows setting a value for max + * This function allows setting a value for valueType * - * @param max desired value to be set - * @return Builder object with new value for max + * @param valueType desired value to be set + * @return Builder object with new value for valueType */ - public B max(String max) { - getBuildingInstance().setMax(max); + public B valueType(DataTypeDefXSD valueType) { + getBuildingInstance().setValueType(valueType); return getSelf(); } @@ -78,13 +77,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -111,57 +110,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -177,24 +165,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -219,4 +196,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/ReferenceBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ReferenceBuilder.java index afec436d6..734afc5dc 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 @@ -1,6 +1,5 @@ /* * 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 @@ -25,46 +24,46 @@ public abstract class ReferenceBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for type + * This function allows setting a value for keys * - * @param type desired value to be set - * @return Builder object with new value for type + * @param keys desired value to be set + * @return Builder object with new value for keys */ - public B type(ReferenceTypes type) { - getBuildingInstance().setType(type); + public B keys(List keys) { + getBuildingInstance().setKeys(keys); return getSelf(); } /** - * This function allows setting a value for referredSemanticId + * This function allows adding a value to the List keys * - * @param referredSemanticId desired value to be set - * @return Builder object with new value for referredSemanticId + * @param keys desired value to be added + * @return Builder object with new value for keys */ - public B referredSemanticId(Reference referredSemanticId) { - getBuildingInstance().setReferredSemanticId(referredSemanticId); + public B keys(Key keys) { + getBuildingInstance().getKeys().add(keys); return getSelf(); } /** - * This function allows setting a value for keys + * This function allows setting a value for referredSemanticID * - * @param keys desired value to be set - * @return Builder object with new value for keys + * @param referredSemanticID desired value to be set + * @return Builder object with new value for referredSemanticID */ - public B keys(List keys) { - getBuildingInstance().setKeys(keys); + public B referredSemanticID(Reference referredSemanticID) { + getBuildingInstance().setReferredSemanticID(referredSemanticID); return getSelf(); } /** - * This function allows adding a value to the List keys + * This function allows setting a value for type * - * @param keys desired value to be added - * @return Builder object with new value for keys + * @param type desired value to be set + * @return Builder object with new value for type */ - public B keys(Key keys) { - getBuildingInstance().getKeys().add(keys); + public B type(ReferenceTypes type) { + getBuildingInstance().setType(type); return getSelf(); } } 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..35af6b641 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 @@ -1,6 +1,5 @@ /* * 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 @@ -57,13 +56,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -90,57 +89,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -156,24 +144,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -198,4 +175,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/RelationshipElementBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/RelationshipElementBuilder.java index 1d6208913..40079a339 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 @@ -1,6 +1,5 @@ /* * 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 @@ -68,13 +67,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -101,57 +100,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -167,24 +155,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -209,4 +186,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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/ResourceBuilder.java b/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/ResourceBuilder.java index 9fd9b7d69..94a8f727e 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 @@ -1,6 +1,5 @@ /* * 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 @@ -22,24 +21,24 @@ public abstract class ResourceBuilder> extends ExtendableBuilder { /** - * This function allows setting a value for path + * This function allows setting a value for contentType * - * @param path desired value to be set - * @return Builder object with new value for path + * @param contentType desired value to be set + * @return Builder object with new value for contentType */ - public B path(String path) { - getBuildingInstance().setPath(path); + public B contentType(String contentType) { + getBuildingInstance().setContentType(contentType); return getSelf(); } /** - * This function allows setting a value for contentType + * This function allows setting a value for path * - * @param contentType desired value to be set - * @return Builder object with new value for contentType + * @param path desired value to be set + * @return Builder object with new value for path */ - public B contentType(String contentType) { - getBuildingInstance().setContentType(contentType); + public B path(String path) { + getBuildingInstance().setPath(path); 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 df6998dae..4db2e0991 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 @@ -1,10 +1,5 @@ /* * Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V. -<<<<<<< HEAD - * Copyright (c) 2023 SAP SE -======= - * Copyright (c) 2023, SAP SE or an SAP affiliate company ->>>>>>> 32df45a2ecc2825513496d22d7e5423aa8744bba * * 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 @@ -20,14 +15,25 @@ 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 org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetID; import java.util.List; -public abstract class SpecificAssetIdBuilder> +public abstract class SpecificAssetIDBuilder> extends ExtendableBuilder { + /** + * This function allows setting a value for externalSubjectID + * + * @param externalSubjectID desired value to be set + * @return Builder object with new value for externalSubjectID + */ + public B externalSubjectID(Reference externalSubjectID) { + getBuildingInstance().setExternalSubjectID(externalSubjectID); + return getSelf(); + } + /** * This function allows setting a value for name * @@ -51,24 +57,13 @@ public B value(String value) { } /** - * This function allows setting a value for externalSubjectId - * - * @param externalSubjectId desired value to be set - * @return Builder object with new value for externalSubjectId - */ - public B externalSubjectId(Reference externalSubjectId) { - getBuildingInstance().setExternalSubjectId(externalSubjectId); - return getSelf(); - } - - /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } 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..583367d60 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 @@ -1,6 +1,5 @@ /* * 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 @@ -67,79 +66,79 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for kind + * This function allows setting a value for administration * - * @param kind desired value to be set - * @return Builder object with new value for kind + * @param administration desired value to be set + * @return Builder object with new value for administration */ - public B kind(ModellingKind kind) { - getBuildingInstance().setKind(kind); + public B administration(AdministrativeInformation administration) { + getBuildingInstance().setAdministration(administration); return getSelf(); } /** - * This function allows setting a value for semanticId + * This function allows setting a value for id * - * @param semanticId desired value to be set - * @return Builder object with new value for semanticId + * @param id desired value to be set + * @return Builder object with new value for id */ - public B semanticId(Reference semanticId) { - getBuildingInstance().setSemanticId(semanticId); + public B id(String id) { + getBuildingInstance().setId(id); return getSelf(); } /** - * This function allows setting a value for supplementalSemanticIds + * This function allows setting a value for category * - * @param supplementalSemanticIds desired value to be set - * @return Builder object with new value for supplementalSemanticIds + * @param category desired value to be set + * @return Builder object with new value for category */ - public B supplementalSemanticIds(List supplementalSemanticIds) { - getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows adding a value to the List supplementalSemanticIds + * This function allows setting a value for description * - * @param supplementalSemanticIds desired value to be added - * @return Builder object with new value for supplementalSemanticIds + * @param description desired value to be set + * @return Builder object with new value for description */ - public B supplementalSemanticIds(Reference supplementalSemanticIds) { - getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for administration + * This function allows adding a value to the List description * - * @param administration desired value to be set - * @return Builder object with new value for administration + * @param description desired value to be added + * @return Builder object with new value for description */ - public B administration(AdministrativeInformation administration) { - getBuildingInstance().setAdministration(administration); + public B description(LangStringTextType description) { + getBuildingInstance().getDescription().add(description); return getSelf(); } /** - * This function allows setting a value for id + * This function allows setting a value for displayName * - * @param id desired value to be set - * @return Builder object with new value for id + * @param displayName desired value to be set + * @return Builder object with new value for displayName */ - public B id(String id) { - getBuildingInstance().setId(id); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } /** - * This function allows setting a value for category + * This function allows adding a value to the List displayName * - * @param category desired value to be set - * @return Builder object with new value for category + * @param displayName desired value to be added + * @return Builder object with new value for displayName */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B displayName(LangStringNameType displayName) { + getBuildingInstance().getDisplayName().add(displayName); return getSelf(); } @@ -155,68 +154,68 @@ public B idShort(String idShort) { } /** - * This function allows setting a value for displayName + * This function allows setting a value for extensions * - * @param displayNames desired value to be set - * @return Builder object with new value for displayName + * @param extensions desired value to be set + * @return Builder object with new value for extensions */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B extensions(List extensions) { + getBuildingInstance().setExtensions(extensions); return getSelf(); } /** - * This function allows adding a value to the List displayName + * This function allows adding a value to the List extensions * - * @param displayName desired value to be added - * @return Builder object with new value for displayName + * @param extensions desired value to be added + * @return Builder object with new value for extensions */ - public B displayName(LangStringNameType displayName) { - getBuildingInstance().getDisplayName().add(displayName); + public B extensions(Extension extensions) { + getBuildingInstance().getExtensions().add(extensions); return getSelf(); } /** - * This function allows setting a value for description + * This function allows setting a value for semanticID * - * @param descriptions desired value to be set - * @return Builder object with new value for description + * @param semanticID desired value to be set + * @return Builder object with new value for semanticID */ - public B description(List descriptions) { - getBuildingInstance().setDescription(descriptions); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } /** - * This function allows adding a value to the List description + * This function allows setting a value for supplementalSemanticIds * - * @param description desired value to be added - * @return Builder object with new value for description + * @param supplementalSemanticIds desired value to be set + * @return Builder object with new value for supplementalSemanticIds */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B supplementalSemanticIds(List supplementalSemanticIds) { + getBuildingInstance().setSupplementalSemanticIds(supplementalSemanticIds); return getSelf(); } /** - * This function allows setting a value for extensions + * This function allows adding a value to the List supplementalSemanticIds * - * @param extensions desired value to be set - * @return Builder object with new value for extensions + * @param supplementalSemanticIds desired value to be added + * @return Builder object with new value for supplementalSemanticIds */ - public B extensions(List extensions) { - getBuildingInstance().setExtensions(extensions); + public B supplementalSemanticIds(Reference supplementalSemanticIds) { + getBuildingInstance().getSupplementalSemanticIds().add(supplementalSemanticIds); return getSelf(); } /** - * This function allows adding a value to the List extensions + * This function allows setting a value for kind * - * @param extensions desired value to be added - * @return Builder object with new value for extensions + * @param kind desired value to be set + * @return Builder object with new value for kind */ - public B extensions(Extension extensions) { - getBuildingInstance().getExtensions().add(extensions); + 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 deleted file mode 100644 index ae034da25..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/builder/SubmodelDescriptorBuilder.java +++ /dev/null @@ -1,117 +0,0 @@ -/* - * 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. - * - * 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.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; - -public abstract class SubmodelDescriptorBuilder> - extends ExtendableBuilder { - - /** - * 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 description - * - * @param description desired value to be set - * @return Builder object with new value for description - */ - public B description(List description) { - getBuildingInstance().setDescription(description); - return getSelf(); - } - - /** - * This function allows setting a value for displayName - * - * @param displayName desired value to be set - * @return Builder object with new value for displayName - */ - public B displayName(List displayName) { - getBuildingInstance().setDisplayName(displayName); - 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 identification - * - * @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 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 endpoints - * - * @param endpoints desired value to be set - * @return Builder object with new value for endpoints - */ - 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(); - } -} 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 ec1010f09..44b318ea5 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 @@ -1,6 +1,5 @@ /* * 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 @@ -17,6 +16,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.*; +import java.util.Collection; import java.util.List; @@ -25,12 +25,12 @@ public abstract class SubmodelElementCollectionBuilder values) { - getBuildingInstance().setValue(values); + public B value(Collection value) { + getBuildingInstance().setValue(value); return getSelf(); } @@ -68,13 +68,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -101,57 +101,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -167,24 +156,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -209,4 +187,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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..c81241e0a 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 @@ -1,6 +1,5 @@ /* * 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 @@ -35,13 +34,13 @@ public B orderRelevant(boolean orderRelevant) { } /** - * This function allows setting a value for semanticIdListElement + * This function allows setting a value for semanticIDListElement * - * @param semanticIdListElement desired value to be set - * @return Builder object with new 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); + public B semanticIDListElement(Reference semanticIDListElement) { + getBuildingInstance().setSemanticIDListElement(semanticIDListElement); return getSelf(); } @@ -51,30 +50,19 @@ public B semanticIdListElement(Reference semanticIdListElement) { * @param typeValueListElement desired value to be set * @return Builder object with new value for typeValueListElement */ - public B typeValueListElement(AasSubmodelElements typeValueListElement) { + public B typeValueListElement(AASSubmodelElements 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 value * - * @param values desired value to be set + * @param value desired value to be set * @return Builder object with new value for value */ - public B value(List values) { - getBuildingInstance().setValue(values); + public B value(List value) { + getBuildingInstance().setValue(value); return getSelf(); } @@ -89,6 +77,17 @@ public B value(SubmodelElement value) { 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 embeddedDataSpecifications * @@ -112,13 +111,13 @@ public B embeddedDataSpecifications(EmbeddedDataSpecification embeddedDataSpecif } /** - * This function allows setting a value for semanticId + * This function allows setting a value for semanticID * - * @param semanticId desired value to be set - * @return Builder object with new 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); + public B semanticID(Reference semanticID) { + getBuildingInstance().setSemanticID(semanticID); return getSelf(); } @@ -145,57 +144,46 @@ public B supplementalSemanticIds(Reference supplementalSemanticIds) { } /** - * 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 + * This function allows setting a value for category * - * @param qualifiers desired value to be added - * @return Builder object with new value for qualifiers + * @param category desired value to be set + * @return Builder object with new value for category */ - public B qualifiers(Qualifier qualifiers) { - getBuildingInstance().getQualifiers().add(qualifiers); + public B category(String category) { + getBuildingInstance().setCategory(category); return getSelf(); } /** - * This function allows setting a value for category + * This function allows setting a value for description * - * @param category desired value to be set - * @return Builder object with new value for category + * @param description desired value to be set + * @return Builder object with new value for description */ - public B category(String category) { - getBuildingInstance().setCategory(category); + public B description(List description) { + getBuildingInstance().setDescription(description); return getSelf(); } /** - * This function allows setting a value for idShort + * This function allows adding a value to the List description * - * @param idShort desired value to be set - * @return Builder object with new value for idShort + * @param description desired value to be added + * @return Builder object with new value for description */ - public B idShort(String idShort) { - getBuildingInstance().setIdShort(idShort); + 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 + * @param displayName desired value to be set * @return Builder object with new value for displayName */ - public B displayName(List displayNames) { - getBuildingInstance().setDisplayName(displayNames); + public B displayName(List displayName) { + getBuildingInstance().setDisplayName(displayName); return getSelf(); } @@ -211,24 +199,13 @@ public B displayName(LangStringNameType displayName) { } /** - * 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 + * This function allows setting a value for idShort * - * @param description desired value to be added - * @return Builder object with new value for description + * @param idShort desired value to be set + * @return Builder object with new value for idShort */ - public B description(LangStringTextType description) { - getBuildingInstance().getDescription().add(description); + public B idShort(String idShort) { + getBuildingInstance().setIdShort(idShort); return getSelf(); } @@ -253,4 +230,26 @@ public B extensions(Extension extensions) { getBuildingInstance().getExtensions().add(extensions); 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..3cc977501 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 @@ -1,6 +1,5 @@ /* * 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 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..a3589053e 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 @@ -1,6 +1,5 @@ /* * 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 @@ -35,13 +34,13 @@ public B value(String value) { } /** - * This function allows setting a value for valueId + * This function allows setting a value for valueID * - * @param valueId desired value to be set - * @return Builder object with new value for valueId + * @param valueID desired value to be set + * @return Builder object with new value for valueID */ - public B valueId(Reference valueId) { - getBuildingInstance().setValueId(valueId); + public B valueID(Reference valueID) { + getBuildingInstance().setValueID(valueID); return getSelf(); } } 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..236a00239 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 @@ -1,6 +1,5 @@ /* * 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 @@ -42,8 +41,8 @@ public class DefaultAdministrativeInformation implements AdministrativeInformati @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/revision") protected String revision; - @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateId") - protected String templateId; + @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/templateID") + protected String templateID; @IRI("https://admin-shell.io/aas/3/0/AdministrativeInformation/version") protected String version; @@ -51,14 +50,16 @@ public class DefaultAdministrativeInformation implements AdministrativeInformati @IRI("https://admin-shell.io/aas/3/0/HasDataSpecification/embeddedDataSpecifications") protected List embeddedDataSpecifications = new ArrayList<>(); - public DefaultAdministrativeInformation() {} + public DefaultAdministrativeInformation() { + + } @Override public int hashCode() { - return Objects.hash(this.version, + return Objects.hash(this.creator, this.revision, - this.creator, - this.templateId, + this.templateID, + this.version, this.embeddedDataSpecifications); } @@ -72,22 +73,22 @@ public boolean equals(Object obj) { return false; } else { DefaultAdministrativeInformation other = (DefaultAdministrativeInformation) obj; - return Objects.equals(this.version, other.version) && + return Objects.equals(this.creator, other.creator) && Objects.equals(this.revision, other.revision) && - Objects.equals(this.creator, other.creator) && - Objects.equals(this.templateId, other.templateId) && + Objects.equals(this.templateID, other.templateID) && + Objects.equals(this.version, other.version) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications); } } @Override - public String getVersion() { - return version; + public Reference getCreator() { + return creator; } @Override - public void setVersion(String version) { - this.version = version; + public void setCreator(Reference creator) { + this.creator = creator; } @Override @@ -101,23 +102,23 @@ public void setRevision(String revision) { } @Override - public Reference getCreator() { - return creator; + public String getTemplateID() { + return templateID; } @Override - public void setCreator(Reference creator) { - this.creator = creator; + public void setTemplateID(String templateID) { + this.templateID = templateID; } @Override - public String getTemplateId() { - return templateId; + public String getVersion() { + return version; } @Override - public void setTemplateId(String templateId) { - this.templateId = templateId; + public void setVersion(String version) { + this.version = version; } @Override @@ -130,16 +131,6 @@ public void setEmbeddedDataSpecifications(List embedd this.embeddedDataSpecifications = embeddedDataSpecifications; } - public String toString() { - return String.format( - "DefaultAdministrativeInformation (" + "version=%s," - + "revision=%s," - + "creator=%s," - + "templateId=%s," - + ")", - this.version, this.revision, this.creator, this.templateId); - } - /** * This builder class can be used to construct a DefaultAdministrativeInformation bean. */ 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..722d4ab26 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 @@ -1,6 +1,5 @@ /* * 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 @@ -44,8 +43,8 @@ public class DefaultAnnotatedRelationshipElement implements AnnotatedRelationshi @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -71,7 +70,9 @@ public class DefaultAnnotatedRelationshipElement implements AnnotatedRelationshi @IRI("https://admin-shell.io/aas/3/0/RelationshipElement/second") protected Reference second; - public DefaultAnnotatedRelationshipElement() {} + public DefaultAnnotatedRelationshipElement() { + + } @Override public int hashCode() { @@ -79,14 +80,14 @@ public int hashCode() { this.first, this.second, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -103,14 +104,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.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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -155,13 +156,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -174,16 +175,6 @@ 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; @@ -195,13 +186,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -210,18 +201,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -234,11 +225,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultAnnotatedRelationshipElement (" + "annotations=%s," - + ")", - this.annotations); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..f9d5a7d03 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 @@ -1,6 +1,5 @@ /* * 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,14 +14,21 @@ 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.AdministrativeInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell; +import org.eclipse.digitaltwin.aas4j.v3.model.AssetInformation; +import org.eclipse.digitaltwin.aas4j.v3.model.EmbeddedDataSpecification; +import org.eclipse.digitaltwin.aas4j.v3.model.Extension; +import org.eclipse.digitaltwin.aas4j.v3.model.LangStringNameType; +import org.eclipse.digitaltwin.aas4j.v3.model.LangStringTextType; +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.AssetAdministrationShellBuilder; + /** * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.AssetAdministrationShell @@ -66,20 +72,21 @@ public class DefaultAssetAdministrationShell implements AssetAdministrationShell @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultAssetAdministrationShell() {} + public DefaultAssetAdministrationShell() { + } @Override public int hashCode() { - return Objects.hash(this.derivedFrom, - this.assetInformation, + return Objects.hash(this.assetInformation, + this.derivedFrom, this.submodels, this.embeddedDataSpecifications, this.administration, this.id, this.category, - this.idShort, - this.displayName, this.description, + this.displayName, + this.idShort, this.extensions); } @@ -93,38 +100,38 @@ public boolean equals(Object obj) { return false; } else { DefaultAssetAdministrationShell other = (DefaultAssetAdministrationShell) obj; - return Objects.equals(this.derivedFrom, other.derivedFrom) && - Objects.equals(this.assetInformation, other.assetInformation) && + return Objects.equals(this.assetInformation, other.assetInformation) && + Objects.equals(this.derivedFrom, other.derivedFrom) && 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && Objects.equals(this.extensions, other.extensions); } } @Override - public Reference getDerivedFrom() { - return derivedFrom; + public AssetInformation getAssetInformation() { + return assetInformation; } @Override - public void setDerivedFrom(Reference derivedFrom) { - this.derivedFrom = derivedFrom; + public void setAssetInformation(AssetInformation assetInformation) { + this.assetInformation = assetInformation; } @Override - public AssetInformation getAssetInformation() { - return assetInformation; + public Reference getDerivedFrom() { + return derivedFrom; } @Override - public void setAssetInformation(AssetInformation assetInformation) { - this.assetInformation = assetInformation; + public void setDerivedFrom(Reference derivedFrom) { + this.derivedFrom = derivedFrom; } @Override @@ -178,13 +185,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -193,18 +200,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -217,15 +224,6 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultAssetAdministrationShell (" + "derivedFrom=%s," - + "assetInformation=%s," - + "submodels=%s," - + ")", - this.derivedFrom, this.assetInformation, this.submodels); - } - /** * This builder class can be used to construct a DefaultAssetAdministrationShell bean. */ 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 deleted file mode 100644 index dba5ce9e2..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultAssetAdministrationShellDescriptor.java +++ /dev/null @@ -1,216 +0,0 @@ -/* - * 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. - * - * 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 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; - -@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") - 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/RC02/AssetAdministrationShellDescriptor/displayName") - protected List displayName; - - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/idShort") - protected String idShort; - - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/id") - protected String id; - - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/assetKind") - protected AssetKind assetKind; - - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/globalAssetId") - protected Reference globalAssetId; - - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/specificAssetIds") - protected SpecificAssetId specificAssetId; - - @IRI("https://admin-shell.io/aas/3/0/RC02/AssetAdministrationShellDescriptor/submodelDescriptor") - protected List submodelDescriptor; - - - public DefaultAssetAdministrationShellDescriptor() { - } - - @Override - public int hashCode() { - return Objects.hash(this.administration, - this.description, - this.displayName, - this.idShort, - this.id, - this.globalAssetId, - this.specificAssetId, - this.submodelDescriptor, - this.endpoints); - } - - @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 { - DefaultAssetAdministrationShellDescriptor other = (DefaultAssetAdministrationShellDescriptor) obj; - return Objects.equals(this.administration, other.administration) && - Objects.equals(this.description, other.description) && - Objects.equals(this.displayName, other.displayName) && - Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.id, other.id) && - Objects.equals(this.assetKind, other.assetKind) && - Objects.equals(this.globalAssetId, other.globalAssetId) && - Objects.equals(this.specificAssetId, other.specificAssetId) && - Objects.equals(this.submodelDescriptor, other.submodelDescriptor) && - Objects.equals(this.endpoints, other.endpoints); - } - } - - @Override - public AdministrativeInformation getAdministration() { - return administration; - } - - @Override - public void setAdministration(AdministrativeInformation administration) { - this.administration = administration; - } - - @Override - public List getDescription() { - return description; - } - - @Override - public void setDescription(List description) { - this.description = description; - } - - @Override - public List getDisplayName() { - return displayName; - } - - @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; - } - - @Override - public String getIdShort() { - return idShort; - } - - @Override - public void setIdShort(String idShort) { - this.idShort = idShort; - } - - @Override - public String getId() { - return id; - } - - @Override - public void setId(String id) { - this.id = id; - } - - - @Override - public AssetKind getAssetKind() { - return assetKind; - } - - @Override - public void setAssetKind(AssetKind assetKind) { - this.assetKind = assetKind; - } - - @Override - public Reference getGlobalAssetId() { - return globalAssetId; - } - - @Override - public void setGlobalAssetId(Reference globalAssetId) { - this.globalAssetId = globalAssetId; - } - - @Override - public SpecificAssetId getSpecificAssetIds() { - return specificAssetId; - } - - @Override - public void setSpecificAssetIds(SpecificAssetId specificAssetId) { - this.specificAssetId = specificAssetId; - } - - @Override - public List getSubmodelDescriptor() { - return submodelDescriptor; - } - - @Override - public void setSubmodelDescriptor(List submodelDescriptor) { - this.submodelDescriptor = submodelDescriptor; - } - - - @Override - public List getEndpoints() { - return endpoints; - } - - @Override - public void setEndpoints(List endpoints) { - this.endpoints = endpoints; - } - - /** - * This builder class can be used to construct a DefaultAssetAdministrationShellDescriptor bean. - */ - public static class Builder extends AssetAdministrationShellDescriptorBuilder { - - @Override - protected Builder getSelf() { - return this; - } - - @Override - protected DefaultAssetAdministrationShellDescriptor newBuildingInstance() { - return new DefaultAssetAdministrationShellDescriptor(); - } - } -} 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..ade88005b 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 @@ -1,6 +1,5 @@ /* * 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 @@ -18,7 +17,7 @@ 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.SpecificAssetID; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; import org.eclipse.digitaltwin.aas4j.v3.model.builder.AssetInformationBuilder; @@ -46,21 +45,23 @@ public class DefaultAssetInformation implements AssetInformation { @IRI("https://admin-shell.io/aas/3/0/AssetInformation/defaultThumbnail") protected Resource defaultThumbnail; - @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetId") - protected String globalAssetId; + @IRI("https://admin-shell.io/aas/3/0/AssetInformation/globalAssetID") + protected String globalAssetID; @IRI("https://admin-shell.io/aas/3/0/AssetInformation/specificAssetIds") - protected List specificAssetIds = new ArrayList<>(); + protected List specificAssetIds = new ArrayList<>(); - public DefaultAssetInformation() {} + public DefaultAssetInformation() { + + } @Override public int hashCode() { return Objects.hash(this.assetKind, - this.globalAssetId, - this.specificAssetIds, this.assetType, - this.defaultThumbnail); + this.defaultThumbnail, + this.globalAssetID, + this.specificAssetIds); } @Override @@ -74,10 +75,10 @@ public boolean equals(Object obj) { } else { DefaultAssetInformation other = (DefaultAssetInformation) obj; return Objects.equals(this.assetKind, other.assetKind) && - Objects.equals(this.globalAssetId, other.globalAssetId) && - Objects.equals(this.specificAssetIds, other.specificAssetIds) && Objects.equals(this.assetType, other.assetType) && - Objects.equals(this.defaultThumbnail, other.defaultThumbnail); + Objects.equals(this.defaultThumbnail, other.defaultThumbnail) && + Objects.equals(this.globalAssetID, other.globalAssetID) && + Objects.equals(this.specificAssetIds, other.specificAssetIds); } } @@ -92,54 +93,43 @@ public void setAssetKind(AssetKind assetKind) { } @Override - public String getGlobalAssetId() { - return globalAssetId; + public String getAssetType() { + return assetType; } @Override - public void setGlobalAssetId(String globalAssetId) { - this.globalAssetId = globalAssetId; + public void setAssetType(String assetType) { + this.assetType = assetType; } @Override - public List getSpecificAssetIds() { - return specificAssetIds; + public Resource getDefaultThumbnail() { + return defaultThumbnail; } @Override - public void setSpecificAssetIds(List specificAssetIds) { - this.specificAssetIds = specificAssetIds; + public void setDefaultThumbnail(Resource defaultThumbnail) { + this.defaultThumbnail = defaultThumbnail; } @Override - public String getAssetType() { - return assetType; + public String getGlobalAssetID() { + return globalAssetID; } @Override - public void setAssetType(String assetType) { - this.assetType = assetType; + public void setGlobalAssetID(String globalAssetID) { + this.globalAssetID = globalAssetID; } @Override - public Resource getDefaultThumbnail() { - return defaultThumbnail; + public List getSpecificAssetIds() { + return specificAssetIds; } @Override - public void setDefaultThumbnail(Resource defaultThumbnail) { - this.defaultThumbnail = defaultThumbnail; - } - - public String toString() { - return String.format( - "DefaultAssetInformation (" + "assetKind=%s," - + "globalAssetId=%s," - + "specificAssetIds=%s," - + "assetType=%s," - + "defaultThumbnail=%s," - + ")", - this.assetKind, this.globalAssetId, this.specificAssetIds, this.assetType, this.defaultThumbnail); + public void setSpecificAssetIds(List specificAssetIds) { + this.specificAssetIds = specificAssetIds; } /** 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..035a2c7b0 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 @@ -1,6 +1,5 @@ /* * 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 @@ -63,8 +62,8 @@ public class DefaultBasicEventElement implements BasicEventElement { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -84,27 +83,29 @@ public class DefaultBasicEventElement implements BasicEventElement { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultBasicEventElement() {} + public DefaultBasicEventElement() { + + } @Override public int hashCode() { - return Objects.hash(this.observed, - this.direction, - this.state, - this.messageTopic, - this.messageBroker, + return Objects.hash(this.direction, this.lastUpdate, - this.minInterval, this.maxInterval, + this.messageBroker, + this.messageTopic, + this.minInterval, + this.observed, + this.state, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -117,36 +118,26 @@ public boolean equals(Object obj) { return false; } else { DefaultBasicEventElement other = (DefaultBasicEventElement) obj; - return Objects.equals(this.observed, other.observed) && - Objects.equals(this.direction, other.direction) && - Objects.equals(this.state, other.state) && - Objects.equals(this.messageTopic, other.messageTopic) && - Objects.equals(this.messageBroker, other.messageBroker) && + return Objects.equals(this.direction, other.direction) && Objects.equals(this.lastUpdate, other.lastUpdate) && - Objects.equals(this.minInterval, other.minInterval) && Objects.equals(this.maxInterval, other.maxInterval) && + Objects.equals(this.messageBroker, other.messageBroker) && + Objects.equals(this.messageTopic, other.messageTopic) && + Objects.equals(this.minInterval, other.minInterval) && + Objects.equals(this.observed, other.observed) && + Objects.equals(this.state, other.state) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } - @Override - public Reference getObserved() { - return observed; - } - - @Override - public void setObserved(Reference observed) { - this.observed = observed; - } - @Override public Direction getDirection() { return direction; @@ -158,23 +149,23 @@ public void setDirection(Direction direction) { } @Override - public StateOfEvent getState() { - return state; + public String getLastUpdate() { + return lastUpdate; } @Override - public void setState(StateOfEvent state) { - this.state = state; + public void setLastUpdate(String lastUpdate) { + this.lastUpdate = lastUpdate; } @Override - public String getMessageTopic() { - return messageTopic; + public String getMaxInterval() { + return maxInterval; } @Override - public void setMessageTopic(String messageTopic) { - this.messageTopic = messageTopic; + public void setMaxInterval(String maxInterval) { + this.maxInterval = maxInterval; } @Override @@ -188,13 +179,13 @@ public void setMessageBroker(Reference messageBroker) { } @Override - public String getLastUpdate() { - return lastUpdate; + public String getMessageTopic() { + return messageTopic; } @Override - public void setLastUpdate(String lastUpdate) { - this.lastUpdate = lastUpdate; + public void setMessageTopic(String messageTopic) { + this.messageTopic = messageTopic; } @Override @@ -208,13 +199,23 @@ public void setMinInterval(String minInterval) { } @Override - public String getMaxInterval() { - return maxInterval; + public Reference getObserved() { + return observed; } @Override - public void setMaxInterval(String maxInterval) { - this.maxInterval = maxInterval; + public void setObserved(Reference observed) { + this.observed = observed; + } + + @Override + public StateOfEvent getState() { + return state; + } + + @Override + public void setState(StateOfEvent state) { + this.state = state; } @Override @@ -228,13 +229,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -247,16 +248,6 @@ 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; @@ -268,13 +259,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -283,18 +274,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -307,19 +298,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultBasicEventElement (" + "observed=%s," - + "direction=%s," - + "state=%s," - + "messageTopic=%s," - + "messageBroker=%s," - + "lastUpdate=%s," - + "minInterval=%s," - + "maxInterval=%s," - + ")", - this.observed, this.direction, this.state, this.messageTopic, this.messageBroker, this.lastUpdate, this.minInterval, - this.maxInterval); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..bcb565022 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 @@ -1,6 +1,5 @@ /* * 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 @@ -47,8 +46,8 @@ public class DefaultBlob implements Blob { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -68,21 +67,23 @@ public class DefaultBlob implements Blob { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultBlob() {} + public DefaultBlob() { + + } @Override public int hashCode() { - return Objects.hash(Arrays.hashCode(this.value), - this.contentType, + return Objects.hash(this.contentType, + Arrays.hashCode(this.value), this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -95,38 +96,38 @@ public boolean equals(Object obj) { return false; } else { DefaultBlob other = (DefaultBlob) obj; - return Arrays.equals(this.value, other.value) && - Objects.equals(this.contentType, other.contentType) && + return Objects.equals(this.contentType, other.contentType) && + Arrays.equals(this.value, other.value) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @Override - public byte[] getValue() { - return value; + public String getContentType() { + return contentType; } @Override - public void setValue(byte[] value) { - this.value = value; + public void setContentType(String contentType) { + this.contentType = contentType; } @Override - public String getContentType() { - return contentType; + public byte[] getValue() { + return value; } @Override - public void setContentType(String contentType) { - this.contentType = contentType; + public void setValue(byte[] value) { + this.value = value; } @Override @@ -140,13 +141,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -159,16 +160,6 @@ 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; @@ -180,13 +171,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -195,18 +186,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -219,12 +210,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultBlob (" + "value=%s," - + "contentType=%s," - + ")", - this.value, this.contentType); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..77c89e298 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 @@ -1,6 +1,5 @@ /* * 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 @@ -40,8 +39,8 @@ public class DefaultCapability implements Capability { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -61,19 +60,21 @@ public class DefaultCapability implements Capability { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultCapability() {} + public DefaultCapability() { + + } @Override public int hashCode() { return Objects.hash(this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -87,14 +88,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.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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -109,13 +110,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -128,16 +129,6 @@ 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; @@ -149,13 +140,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -164,18 +155,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -188,12 +179,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultCapability (" - + ")" + @Override + public List getQualifiers() { + return qualifiers; + } - ); + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..558778b24 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 @@ -1,6 +1,5 @@ /* * 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 @@ -61,7 +60,9 @@ public class DefaultConceptDescription implements ConceptDescription { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultConceptDescription() {} + public DefaultConceptDescription() { + + } @Override public int hashCode() { @@ -70,9 +71,9 @@ public int hashCode() { this.administration, this.id, this.category, - this.idShort, - this.displayName, this.description, + this.displayName, + this.idShort, this.extensions); } @@ -91,9 +92,9 @@ public boolean equals(Object obj) { 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && Objects.equals(this.extensions, other.extensions); } } @@ -104,8 +105,8 @@ public List getIsCaseOf() { } @Override - public void setIsCaseOf(List isCaseOfs) { - this.isCaseOf = isCaseOfs; + public void setIsCaseOf(List isCaseOf) { + this.isCaseOf = isCaseOf; } @Override @@ -149,13 +150,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -164,18 +165,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -188,13 +189,6 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultConceptDescription (" + "isCaseOf=%s," - + ")", - this.isCaseOf); - } - /** * This builder class can be used to construct a DefaultConceptDescription bean. */ 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..168d88f21 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 @@ -1,6 +1,5 @@ /* * 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 @@ -32,61 +31,63 @@ * lists conformant to IEC 61360. */ -@IRI("aas:DataSpecificationIec61360") +@IRI("aas:DataSpecificationIEC61360") public class DefaultDataSpecificationIec61360 implements DataSpecificationIec61360 { - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/dataType") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/dataType") protected DataTypeIec61360 dataType; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/definition") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/definition") protected List definition = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/levelType") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/levelType") protected LevelType levelType; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/preferredName") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/preferredName") protected List preferredName = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/shortName") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/shortName") protected List shortName = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/sourceOfDefinition") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/sourceOfDefinition") protected String sourceOfDefinition; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/symbol") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/symbol") protected String symbol; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unit") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unit") protected String unit; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/unitId") - protected Reference unitId; + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/unitID") + protected Reference unitID; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/value") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueFormat") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueFormat") protected String valueFormat; - @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIec61360/valueList") + @IRI("https://admin-shell.io/aas/3/0/DataSpecificationIEC61360/valueList") protected ValueList valueList; - public DefaultDataSpecificationIec61360() {} + public DefaultDataSpecificationIec61360() { + + } @Override public int hashCode() { - return Objects.hash(this.preferredName, + return Objects.hash(this.dataType, + this.definition, + this.levelType, + this.preferredName, this.shortName, - this.unit, - this.unitId, this.sourceOfDefinition, this.symbol, - this.dataType, - this.definition, - this.valueFormat, - this.valueList, + this.unit, + this.unitID, this.value, - this.levelType); + this.valueFormat, + this.valueList); } @Override @@ -99,59 +100,69 @@ public boolean equals(Object obj) { return false; } else { DefaultDataSpecificationIec61360 other = (DefaultDataSpecificationIec61360) obj; - return Objects.equals(this.preferredName, other.preferredName) && + return Objects.equals(this.dataType, other.dataType) && + Objects.equals(this.definition, other.definition) && + Objects.equals(this.levelType, other.levelType) && + Objects.equals(this.preferredName, other.preferredName) && Objects.equals(this.shortName, other.shortName) && - Objects.equals(this.unit, other.unit) && - Objects.equals(this.unitId, other.unitId) && Objects.equals(this.sourceOfDefinition, other.sourceOfDefinition) && Objects.equals(this.symbol, other.symbol) && - Objects.equals(this.dataType, other.dataType) && - Objects.equals(this.definition, other.definition) && - Objects.equals(this.valueFormat, other.valueFormat) && - Objects.equals(this.valueList, other.valueList) && + Objects.equals(this.unit, other.unit) && + Objects.equals(this.unitID, other.unitID) && Objects.equals(this.value, other.value) && - Objects.equals(this.levelType, other.levelType); + Objects.equals(this.valueFormat, other.valueFormat) && + Objects.equals(this.valueList, other.valueList); } } @Override - public List getPreferredName() { - return preferredName; + public DataTypeIec61360 getDataType() { + return dataType; } @Override - public void setPreferredName(List preferredNames) { - this.preferredName = preferredNames; + public void setDataType(DataTypeIec61360 dataType) { + this.dataType = dataType; } @Override - public List getShortName() { - return shortName; + public List getDefinition() { + return definition; } @Override - public void setShortName(List shortNames) { - this.shortName = shortNames; + public void setDefinition(List definition) { + this.definition = definition; } @Override - public String getUnit() { - return unit; + public LevelType getLevelType() { + return levelType; } @Override - public void setUnit(String unit) { - this.unit = unit; + public void setLevelType(LevelType levelType) { + this.levelType = levelType; } @Override - public Reference getUnitId() { - return unitId; + public List getPreferredName() { + return preferredName; + } + + @Override + public void setPreferredName(List preferredName) { + this.preferredName = preferredName; + } + + @Override + public List getShortName() { + return shortName; } @Override - public void setUnitId(Reference unitId) { - this.unitId = unitId; + public void setShortName(List shortName) { + this.shortName = shortName; } @Override @@ -175,23 +186,33 @@ public void setSymbol(String symbol) { } @Override - public DataTypeIec61360 getDataType() { - return dataType; + public String getUnit() { + return unit; } @Override - public void setDataType(DataTypeIec61360 dataType) { - this.dataType = dataType; + public void setUnit(String unit) { + this.unit = unit; } @Override - public List getDefinition() { - return definition; + public Reference getUnitID() { + return unitID; } @Override - public void setDefinition(List definitions) { - this.definition = definitions; + public void setUnitID(Reference unitID) { + this.unitID = unitID; + } + + @Override + public String getValue() { + return value; + } + + @Override + public void setValue(String value) { + this.value = value; } @Override @@ -214,45 +235,6 @@ public void setValueList(ValueList valueList) { this.valueList = valueList; } - @Override - public String getValue() { - return value; - } - - @Override - public void setValue(String value) { - this.value = value; - } - - @Override - public LevelType getLevelType() { - return levelType; - } - - @Override - public void setLevelType(LevelType levelType) { - this.levelType = levelType; - } - - public String toString() { - return String.format( - "DefaultDataSpecificationIec61360 (" + "preferredName=%s," - + "shortName=%s," - + "unit=%s," - + "unitId=%s," - + "sourceOfDefinition=%s," - + "symbol=%s," - + "dataType=%s," - + "definition=%s," - + "valueFormat=%s," - + "valueList=%s," - + "value=%s," - + "levelType=%s," - + ")", - this.preferredName, this.shortName, this.unit, this.unitId, this.sourceOfDefinition, this.symbol, this.dataType, - this.definition, this.valueFormat, this.valueList, this.value, this.levelType); - } - /** * This builder class can be used to construct a DefaultDataSpecificationIec61360 bean. */ 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 deleted file mode 100644 index c1a915ca5..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultDescriptor.java +++ /dev/null @@ -1,80 +0,0 @@ -/* - * 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. - * - * 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 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; - -@IRI("aas:Descriptor") -public class DefaultDescriptor implements Descriptor { - - @IRI("https://admin-shell.io/aas/3/0/RC02/Descriptor/endpoints") - protected List endpoints = new ArrayList<>(); - - public DefaultDescriptor() { - } - - @Override - public int hashCode() { - return Objects.hash(this.endpoints); - } - - @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 { - DefaultDescriptor other = (DefaultDescriptor) obj; - return Objects.equals(this.endpoints, other.endpoints); - } - } - - @Override - public List getEndpoints() { - return endpoints; - } - - @Override - public void setEndpoints(List endpoints) { - this.endpoints = endpoints; - } - - /** - * This builder class can be used to construct a DefaultDescriptor bean. - */ - public static class Builder extends DescriptorBuilder { - - @Override - protected Builder getSelf() { - return this; - } - - @Override - protected DefaultDescriptor newBuildingInstance() { - return new DefaultDescriptor(); - } - } -} 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..4d3135579 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 @@ -1,6 +1,5 @@ /* * 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 @@ -40,7 +39,9 @@ public class DefaultEmbeddedDataSpecification implements EmbeddedDataSpecificati @IRI("https://admin-shell.io/aas/3/0/EmbeddedDataSpecification/dataSpecificationContent") protected DataSpecificationContent dataSpecificationContent; - public DefaultEmbeddedDataSpecification() {} + public DefaultEmbeddedDataSpecification() { + + } @Override public int hashCode() { @@ -83,14 +84,6 @@ public void setDataSpecificationContent(DataSpecificationContent dataSpecificati this.dataSpecificationContent = dataSpecificationContent; } - public String toString() { - return String.format( - "DefaultEmbeddedDataSpecification (" + "dataSpecification=%s," - + "dataSpecificationContent=%s," - + ")", - this.dataSpecification, this.dataSpecificationContent); - } - /** * This builder class can be used to construct a DefaultEmbeddedDataSpecification bean. */ 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 deleted file mode 100644 index 648e4859d..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultEndpoint.java +++ /dev/null @@ -1,93 +0,0 @@ -/* - * 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. - * - * 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 org.eclipse.digitaltwin.aas4j.v3.model.Endpoint; -import org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.EndpointBuilder; - -import java.util.Objects; - -@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/RC02/Endpoint/protocolInformation") - protected ProtocolInformation protocolInformation; - - public DefaultEndpoint() { - } - - @Override - public int hashCode() { - return Objects.hash(this.interfaceValue, - this.protocolInformation); - } - - @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 { - DefaultEndpoint other = (DefaultEndpoint) obj; - return Objects.equals(this.interfaceValue, other.interfaceValue) && - Objects.equals(this.protocolInformation, other.protocolInformation); - } - } - - @Override - public String getInterface() { - return interfaceValue; - } - - @Override - public void setInterface(String interfaceValue) { - this.interfaceValue = interfaceValue; - } - - @Override - public ProtocolInformation getProtocolInformation() { - return protocolInformation; - } - - @Override - public void setProtocolInformation(ProtocolInformation protocolInformation) { - this.protocolInformation = protocolInformation; - } - - /** - * This builder class can be used to construct a DefaultEndpoint bean. - */ - public static class Builder extends EndpointBuilder { - - @Override - protected Builder getSelf() { - return this; - } - - @Override - protected DefaultEndpoint newBuildingInstance() { - return new DefaultEndpoint(); - } - } -} 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..e3a75f9a8 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 @@ -1,6 +1,5 @@ /* * 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 @@ -36,11 +35,11 @@ public class DefaultEntity implements Entity { @IRI("https://admin-shell.io/aas/3/0/Entity/entityType") protected EntityType entityType; - @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetId") - protected String globalAssetId; + @IRI("https://admin-shell.io/aas/3/0/Entity/globalAssetID") + protected String globalAssetID; @IRI("https://admin-shell.io/aas/3/0/Entity/specificAssetIds") - protected List specificAssetIds = new ArrayList<>(); + protected List specificAssetIds = new ArrayList<>(); @IRI("https://admin-shell.io/aas/3/0/Entity/statements") protected List statements = new ArrayList<>(); @@ -51,8 +50,8 @@ public class DefaultEntity implements Entity { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -72,23 +71,25 @@ public class DefaultEntity implements Entity { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultEntity() {} + public DefaultEntity() { + + } @Override public int hashCode() { - return Objects.hash(this.statements, - this.entityType, - this.globalAssetId, + return Objects.hash(this.entityType, + this.globalAssetID, this.specificAssetIds, + this.statements, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -101,32 +102,22 @@ public boolean equals(Object obj) { return false; } else { DefaultEntity other = (DefaultEntity) obj; - return Objects.equals(this.statements, other.statements) && - Objects.equals(this.entityType, other.entityType) && - Objects.equals(this.globalAssetId, other.globalAssetId) && + 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) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } - @Override - public List getStatements() { - return statements; - } - - @Override - public void setStatements(List statements) { - this.statements = statements; - } - @Override public EntityType getEntityType() { return entityType; @@ -138,25 +129,35 @@ public void setEntityType(EntityType entityType) { } @Override - public String getGlobalAssetId() { - return globalAssetId; + public String getGlobalAssetID() { + return globalAssetID; } @Override - public void setGlobalAssetId(String globalAssetId) { - this.globalAssetId = globalAssetId; + public void setGlobalAssetID(String globalAssetID) { + this.globalAssetID = globalAssetID; } @Override - public List getSpecificAssetIds() { + public List getSpecificAssetIds() { return specificAssetIds; } @Override - public void setSpecificAssetIds(List specificAssetIds) { + public void setSpecificAssetIds(List specificAssetIds) { this.specificAssetIds = specificAssetIds; } + @Override + public List getStatements() { + return statements; + } + + @Override + public void setStatements(List statements) { + this.statements = statements; + } + @Override public List getEmbeddedDataSpecifications() { return embeddedDataSpecifications; @@ -168,13 +169,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -187,16 +188,6 @@ 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; @@ -208,13 +199,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -223,18 +214,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -247,14 +238,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultEntity (" + "statements=%s," - + "entityType=%s," - + "globalAssetId=%s," - + "specificAssetIds=%s," - + ")", - this.statements, this.entityType, this.globalAssetId, this.specificAssetIds); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..ae4b92b96 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 @@ -1,6 +1,5 @@ /* * 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 @@ -45,13 +44,15 @@ public class DefaultEnvironment implements Environment { @IRI("https://admin-shell.io/aas/3/0/Environment/submodels") protected List submodels = new ArrayList<>(); - public DefaultEnvironment() {} + public DefaultEnvironment() { + + } @Override public int hashCode() { return Objects.hash(this.assetAdministrationShells, - this.submodels, - this.conceptDescriptions); + this.conceptDescriptions, + this.submodels); } @Override @@ -65,8 +66,8 @@ public boolean equals(Object obj) { } else { DefaultEnvironment other = (DefaultEnvironment) obj; return Objects.equals(this.assetAdministrationShells, other.assetAdministrationShells) && - Objects.equals(this.submodels, other.submodels) && - Objects.equals(this.conceptDescriptions, other.conceptDescriptions); + Objects.equals(this.conceptDescriptions, other.conceptDescriptions) && + Objects.equals(this.submodels, other.submodels); } } @@ -80,16 +81,6 @@ public void setAssetAdministrationShells(List assetAdm this.assetAdministrationShells = assetAdministrationShells; } - @Override - public List getSubmodels() { - return submodels; - } - - @Override - public void setSubmodels(List submodels) { - this.submodels = submodels; - } - @Override public List getConceptDescriptions() { return conceptDescriptions; @@ -100,13 +91,14 @@ public void setConceptDescriptions(List conceptDescriptions) this.conceptDescriptions = conceptDescriptions; } - public String toString() { - return String.format( - "DefaultEnvironment (" + "assetAdministrationShells=%s," - + "submodels=%s," - + "conceptDescriptions=%s," - + ")", - this.assetAdministrationShells, this.submodels, this.conceptDescriptions); + @Override + public List getSubmodels() { + return submodels; + } + + @Override + public void setSubmodels(List submodels) { + this.submodels = submodels; } /** 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..b775a8922 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 @@ -1,6 +1,5 @@ /* * 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 @@ -36,8 +35,8 @@ public class DefaultEventPayload implements EventPayload { @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableReference") protected Reference observableReference; - @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticId") - protected Reference observableSemanticId; + @IRI("https://admin-shell.io/aas/3/0/EventPayload/observableSemanticID") + protected Reference observableSemanticID; @IRI("https://admin-shell.io/aas/3/0/EventPayload/payload") protected byte[] payload; @@ -45,11 +44,11 @@ public class DefaultEventPayload implements EventPayload { @IRI("https://admin-shell.io/aas/3/0/EventPayload/source") protected Reference source; - @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticId") - protected Reference sourceSemanticId; + @IRI("https://admin-shell.io/aas/3/0/EventPayload/sourceSemanticID") + protected Reference sourceSemanticID; - @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectId") - protected Reference subjectId; + @IRI("https://admin-shell.io/aas/3/0/EventPayload/subjectID") + protected Reference subjectID; @IRI("https://admin-shell.io/aas/3/0/EventPayload/timeStamp") protected String timeStamp; @@ -57,18 +56,20 @@ public class DefaultEventPayload implements EventPayload { @IRI("https://admin-shell.io/aas/3/0/EventPayload/topic") protected String topic; - public DefaultEventPayload() {} + public DefaultEventPayload() { + + } @Override public int hashCode() { - return Objects.hash(this.source, - this.sourceSemanticId, - this.observableReference, - this.observableSemanticId, - this.topic, - this.subjectId, + return Objects.hash(this.observableReference, + this.observableSemanticID, + Arrays.hashCode(this.payload), + this.source, + this.sourceSemanticID, + this.subjectID, this.timeStamp, - Arrays.hashCode(this.payload)); + this.topic); } @Override @@ -81,75 +82,75 @@ public boolean equals(Object obj) { return false; } else { DefaultEventPayload other = (DefaultEventPayload) obj; - return Objects.equals(this.source, other.source) && - Objects.equals(this.sourceSemanticId, other.sourceSemanticId) && - Objects.equals(this.observableReference, other.observableReference) && - Objects.equals(this.observableSemanticId, other.observableSemanticId) && - Objects.equals(this.topic, other.topic) && - Objects.equals(this.subjectId, other.subjectId) && + return Objects.equals(this.observableReference, other.observableReference) && + Objects.equals(this.observableSemanticID, other.observableSemanticID) && + Arrays.equals(this.payload, other.payload) && + Objects.equals(this.source, other.source) && + Objects.equals(this.sourceSemanticID, other.sourceSemanticID) && + Objects.equals(this.subjectID, other.subjectID) && Objects.equals(this.timeStamp, other.timeStamp) && - Arrays.equals(this.payload, other.payload); + Objects.equals(this.topic, other.topic); } } @Override - public Reference getSource() { - return source; + public Reference getObservableReference() { + return observableReference; } @Override - public void setSource(Reference source) { - this.source = source; + public void setObservableReference(Reference observableReference) { + this.observableReference = observableReference; } @Override - public Reference getSourceSemanticId() { - return sourceSemanticId; + public Reference getObservableSemanticID() { + return observableSemanticID; } @Override - public void setSourceSemanticId(Reference sourceSemanticId) { - this.sourceSemanticId = sourceSemanticId; + public void setObservableSemanticID(Reference observableSemanticID) { + this.observableSemanticID = observableSemanticID; } @Override - public Reference getObservableReference() { - return observableReference; + public byte[] getPayload() { + return payload; } @Override - public void setObservableReference(Reference observableReference) { - this.observableReference = observableReference; + public void setPayload(byte[] payload) { + this.payload = payload; } @Override - public Reference getObservableSemanticId() { - return observableSemanticId; + public Reference getSource() { + return source; } @Override - public void setObservableSemanticId(Reference observableSemanticId) { - this.observableSemanticId = observableSemanticId; + public void setSource(Reference source) { + this.source = source; } @Override - public String getTopic() { - return topic; + public Reference getSourceSemanticID() { + return sourceSemanticID; } @Override - public void setTopic(String topic) { - this.topic = topic; + public void setSourceSemanticID(Reference sourceSemanticID) { + this.sourceSemanticID = sourceSemanticID; } @Override - public Reference getSubjectId() { - return subjectId; + public Reference getSubjectID() { + return subjectID; } @Override - public void setSubjectId(Reference subjectId) { - this.subjectId = subjectId; + public void setSubjectID(Reference subjectID) { + this.subjectID = subjectID; } @Override @@ -163,28 +164,13 @@ public void setTimeStamp(String timeStamp) { } @Override - public byte[] getPayload() { - return payload; + public String getTopic() { + return topic; } @Override - public void setPayload(byte[] payload) { - this.payload = payload; - } - - public String toString() { - return String.format( - "DefaultEventPayload (" + "source=%s," - + "sourceSemanticId=%s," - + "observableReference=%s," - + "observableSemanticId=%s," - + "topic=%s," - + "subjectId=%s," - + "timeStamp=%s," - + "payload=%s," - + ")", - this.source, this.sourceSemanticId, this.observableReference, this.observableSemanticId, this.topic, this.subjectId, - this.timeStamp, this.payload); + public void setTopic(String topic) { + this.topic = topic; } /** 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..7f0212ad5 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 @@ -1,6 +1,5 @@ /* * 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,7 +14,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +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; @@ -45,23 +44,25 @@ public class DefaultExtension implements Extension { protected String value; @IRI("https://admin-shell.io/aas/3/0/Extension/valueType") - protected DataTypeDefXsd valueType; + protected DataTypeDefXSD valueType; - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") - protected Reference semanticId; + @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<>(); - public DefaultExtension() {} + public DefaultExtension() { + + } @Override public int hashCode() { return Objects.hash(this.name, - this.valueType, - this.value, this.refersTo, - this.semanticId, + this.value, + this.valueType, + this.semanticID, this.supplementalSemanticIds); } @@ -76,10 +77,10 @@ public boolean equals(Object obj) { } else { DefaultExtension other = (DefaultExtension) obj; return Objects.equals(this.name, other.name) && - Objects.equals(this.valueType, other.valueType) && - Objects.equals(this.value, other.value) && Objects.equals(this.refersTo, other.refersTo) && - Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.value, other.value) && + Objects.equals(this.valueType, other.valueType) && + Objects.equals(this.semanticID, other.semanticID) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds); } } @@ -95,13 +96,13 @@ public void setName(String name) { } @Override - public DataTypeDefXsd getValueType() { - return valueType; + public List getRefersTo() { + return refersTo; } @Override - public void setValueType(DataTypeDefXsd valueType) { - this.valueType = valueType; + public void setRefersTo(List refersTo) { + this.refersTo = refersTo; } @Override @@ -115,23 +116,23 @@ public void setValue(String value) { } @Override - public List getRefersTo() { - return refersTo; + public DataTypeDefXSD getValueType() { + return valueType; } @Override - public void setRefersTo(List refersTos) { - this.refersTo = refersTos; + public void setValueType(DataTypeDefXSD valueType) { + this.valueType = valueType; } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -144,16 +145,6 @@ public void setSupplementalSemanticIds(List supplementalSemanticIds) this.supplementalSemanticIds = supplementalSemanticIds; } - public String toString() { - return String.format( - "DefaultExtension (" + "name=%s," - + "valueType=%s," - + "value=%s," - + "refersTo=%s," - + ")", - this.name, this.valueType, this.value, this.refersTo); - } - /** * This builder class can be used to construct a DefaultExtension bean. */ 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..146fed567 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 @@ -1,6 +1,5 @@ /* * 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 @@ -45,8 +44,8 @@ public class DefaultFile implements File { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -66,21 +65,23 @@ public class DefaultFile implements File { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultFile() {} + public DefaultFile() { + + } @Override public int hashCode() { - return Objects.hash(this.value, - this.contentType, + return Objects.hash(this.contentType, + this.value, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -93,38 +94,38 @@ public boolean equals(Object obj) { return false; } else { DefaultFile other = (DefaultFile) obj; - return Objects.equals(this.value, other.value) && - Objects.equals(this.contentType, other.contentType) && + return Objects.equals(this.contentType, other.contentType) && + Objects.equals(this.value, other.value) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @Override - public String getValue() { - return value; + public String getContentType() { + return contentType; } @Override - public void setValue(String value) { - this.value = value; + public void setContentType(String contentType) { + this.contentType = contentType; } @Override - public String getContentType() { - return contentType; + public String getValue() { + return value; } @Override - public void setContentType(String contentType) { - this.contentType = contentType; + public void setValue(String value) { + this.value = value; } @Override @@ -138,13 +139,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -157,16 +158,6 @@ 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; @@ -178,13 +169,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -193,18 +184,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -217,12 +208,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultFile (" + "value=%s," - + "contentType=%s," - + ")", - this.value, this.contentType); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..d098f2840 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 @@ -1,6 +1,5 @@ /* * 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 @@ -38,7 +37,9 @@ public class DefaultKey implements Key { @IRI("https://admin-shell.io/aas/3/0/Key/value") protected String value; - public DefaultKey() {} + public DefaultKey() { + + } @Override public int hashCode() { @@ -81,14 +82,6 @@ public void setValue(String value) { this.value = value; } - public String toString() { - return String.format( - "DefaultKey (" + "type=%s," - + "value=%s," - + ")", - this.type, this.value); - } - /** * This builder class can be used to construct a DefaultKey bean. */ 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..ed0a94c2f 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 @@ -1,6 +1,5 @@ /* * 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 +14,11 @@ 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.LangStringDefinitionTypeIec61360; /** @@ -29,7 +28,7 @@ * String with length 1023 maximum and minimum 1 characters and with language tags */ -@IRI("aas:LangStringDefinitionTypeIec61360") +@IRI("aas:LangStringDefinitionTypeIEC61360") public class DefaultLangStringDefinitionTypeIec61360 implements LangStringDefinitionTypeIec61360 { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/language") @@ -38,7 +37,9 @@ public class DefaultLangStringDefinitionTypeIec61360 implements LangStringDefini @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringDefinitionTypeIec61360() {} + public DefaultLangStringDefinitionTypeIec61360() { + + } @Override public int hashCode() { @@ -81,14 +82,6 @@ public void setText(String text) { this.text = text; } - public String toString() { - return String.format( - "DefaultLangStringDefinitionTypeIec61360 (" - + ")" - - ); - } - /** * This builder class can be used to construct a DefaultLangStringDefinitionTypeIec61360 bean. */ 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..1d165b23d 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 @@ -1,6 +1,5 @@ /* * 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 @@ -37,7 +36,9 @@ public class DefaultLangStringNameType implements LangStringNameType { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringNameType() {} + public DefaultLangStringNameType() { + + } @Override public int hashCode() { @@ -80,14 +81,6 @@ public void setText(String text) { this.text = text; } - public String toString() { - return String.format( - "DefaultLangStringNameType (" - + ")" - - ); - } - /** * This builder class can be used to construct a DefaultLangStringNameType bean. */ 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..6e60307a3 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 @@ -1,6 +1,5 @@ /* * 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 +14,11 @@ 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.LangStringPreferredNameTypeIec61360; /** @@ -29,7 +28,7 @@ * String with length 255 maximum and minimum 1 characters and with language tags */ -@IRI("aas:LangStringPreferredNameTypeIec61360") +@IRI("aas:LangStringPreferredNameTypeIEC61360") public class DefaultLangStringPreferredNameTypeIec61360 implements LangStringPreferredNameTypeIec61360 { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/language") @@ -38,7 +37,9 @@ public class DefaultLangStringPreferredNameTypeIec61360 implements LangStringPre @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringPreferredNameTypeIec61360() {} + public DefaultLangStringPreferredNameTypeIec61360() { + + } @Override public int hashCode() { @@ -81,14 +82,6 @@ public void setText(String text) { this.text = text; } - public String toString() { - return String.format( - "DefaultLangStringPreferredNameTypeIec61360 (" - + ")" - - ); - } - /** * This builder class can be used to construct a DefaultLangStringPreferredNameTypeIec61360 bean. */ 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..adf213af1 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 @@ -1,6 +1,5 @@ /* * 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 +14,11 @@ 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.LangStringShortNameTypeIec61360; /** @@ -29,7 +28,7 @@ * String with length 18 maximum and minimum 1 characters and with language tags */ -@IRI("aas:LangStringShortNameTypeIec61360") +@IRI("aas:LangStringShortNameTypeIEC61360") public class DefaultLangStringShortNameTypeIec61360 implements LangStringShortNameTypeIec61360 { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/language") @@ -38,7 +37,9 @@ public class DefaultLangStringShortNameTypeIec61360 implements LangStringShortNa @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringShortNameTypeIec61360() {} + public DefaultLangStringShortNameTypeIec61360() { + + } @Override public int hashCode() { @@ -81,14 +82,6 @@ public void setText(String text) { this.text = text; } - public String toString() { - return String.format( - "DefaultLangStringShortNameTypeIec61360 (" - + ")" - - ); - } - /** * This builder class can be used to construct a DefaultLangStringShortNameTypeIec61360 bean. */ 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..90c243c77 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 @@ -1,6 +1,5 @@ /* * 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 @@ -37,7 +36,9 @@ public class DefaultLangStringTextType implements LangStringTextType { @IRI("https://admin-shell.io/aas/3/0/AbstractLangString/text") protected String text; - public DefaultLangStringTextType() {} + public DefaultLangStringTextType() { + + } @Override public int hashCode() { @@ -80,14 +81,6 @@ public void setText(String text) { this.text = text; } - public String toString() { - return String.format( - "DefaultLangStringTextType (" - + ")" - - ); - } - /** * This builder class can be used to construct a DefaultLangStringTextType bean. */ 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..5251649b3 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 @@ -1,6 +1,5 @@ /* * 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 @@ -44,14 +43,16 @@ public class DefaultLevelType implements LevelType { @IRI("https://admin-shell.io/aas/3/0/LevelType/typ") protected boolean typ; - public DefaultLevelType() {} + public DefaultLevelType() { + + } @Override public int hashCode() { - return Objects.hash(this.min, + return Objects.hash(this.max, + this.min, this.nom, - this.typ, - this.max); + this.typ); } @Override @@ -64,13 +65,23 @@ public boolean equals(Object obj) { return false; } else { DefaultLevelType other = (DefaultLevelType) obj; - return Objects.equals(this.min, other.min) && + return Objects.equals(this.max, other.max) && + Objects.equals(this.min, other.min) && Objects.equals(this.nom, other.nom) && - Objects.equals(this.typ, other.typ) && - Objects.equals(this.max, other.max); + Objects.equals(this.typ, other.typ); } } + @Override + public boolean getMax() { + return max; + } + + @Override + public void setMax(boolean max) { + this.max = max; + } + @Override public boolean getMin() { return min; @@ -101,26 +112,6 @@ public void setTyp(boolean typ) { this.typ = typ; } - @Override - public boolean getMax() { - return max; - } - - @Override - public void setMax(boolean max) { - this.max = max; - } - - public String toString() { - return String.format( - "DefaultLevelType (" + "min=%s," - + "nom=%s," - + "typ=%s," - + "max=%s," - + ")", - this.min, this.nom, this.typ, this.max); - } - /** * This builder class can be used to construct a DefaultLevelType bean. */ 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..56f9cb8f7 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 @@ -1,6 +1,5 @@ /* * 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 @@ -39,8 +38,8 @@ public class DefaultMultiLanguageProperty implements MultiLanguageProperty { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -48,8 +47,8 @@ public class DefaultMultiLanguageProperty implements MultiLanguageProperty { @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/value") protected List value = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueId") - protected Reference valueId; + @IRI("https://admin-shell.io/aas/3/0/MultiLanguageProperty/valueID") + protected Reference valueID; @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") protected List qualifiers = new ArrayList<>(); @@ -66,21 +65,23 @@ public class DefaultMultiLanguageProperty implements MultiLanguageProperty { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultMultiLanguageProperty() {} + public DefaultMultiLanguageProperty() { + + } @Override public int hashCode() { return Objects.hash(this.value, - this.valueId, + this.valueID, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -94,16 +95,16 @@ public boolean equals(Object obj) { } else { DefaultMultiLanguageProperty other = (DefaultMultiLanguageProperty) obj; return Objects.equals(this.value, other.value) && - Objects.equals(this.valueId, other.valueId) && + Objects.equals(this.valueID, other.valueID) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -113,18 +114,18 @@ public List getValue() { } @Override - public void setValue(List values) { - this.value = values; + public void setValue(List value) { + this.value = value; } @Override - public Reference getValueId() { - return valueId; + public Reference getValueID() { + return valueID; } @Override - public void setValueId(Reference valueId) { - this.valueId = valueId; + public void setValueID(Reference valueID) { + this.valueID = valueID; } @Override @@ -138,13 +139,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -157,16 +158,6 @@ 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; @@ -178,13 +169,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -193,18 +184,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -217,12 +208,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultMultiLanguageProperty (" + "value=%s," - + "valueId=%s," - + ")", - this.value, this.valueId); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..51f9b021d 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 @@ -1,6 +1,5 @@ /* * 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 @@ -39,8 +38,8 @@ public class DefaultOperation implements Operation { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -69,22 +68,24 @@ public class DefaultOperation implements Operation { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultOperation() {} + public DefaultOperation() { + + } @Override public int hashCode() { - return Objects.hash(this.inputVariables, + return Objects.hash(this.inoutputVariables, + this.inputVariables, this.outputVariables, - this.inoutputVariables, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -97,21 +98,31 @@ public boolean equals(Object obj) { return false; } else { DefaultOperation other = (DefaultOperation) obj; - return Objects.equals(this.inputVariables, other.inputVariables) && + return Objects.equals(this.inoutputVariables, other.inoutputVariables) && + Objects.equals(this.inputVariables, other.inputVariables) && 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.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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } + @Override + public List getInoutputVariables() { + return inoutputVariables; + } + + @Override + public void setInoutputVariables(List inoutputVariables) { + this.inoutputVariables = inoutputVariables; + } + @Override public List getInputVariables() { return inputVariables; @@ -132,16 +143,6 @@ public void setOutputVariables(List outputVariables) { this.outputVariables = outputVariables; } - @Override - public List getInoutputVariables() { - return inoutputVariables; - } - - @Override - public void setInoutputVariables(List inoutputVariables) { - this.inoutputVariables = inoutputVariables; - } - @Override public List getEmbeddedDataSpecifications() { return embeddedDataSpecifications; @@ -153,13 +154,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -172,16 +173,6 @@ 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; @@ -193,13 +184,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -208,18 +199,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -232,13 +223,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultOperation (" + "inputVariables=%s," - + "outputVariables=%s," - + "inoutputVariables=%s," - + ")", - this.inputVariables, this.outputVariables, this.inoutputVariables); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..6ba755f0a 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 @@ -1,6 +1,5 @@ /* * 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 @@ -67,13 +66,6 @@ public void setValue(SubmodelElement value) { this.value = value; } - public String toString() { - return String.format( - "DefaultOperationVariable (" + "value=%s," - + ")", - this.value); - } - /** * This builder class can be used to construct a DefaultOperationVariable bean. */ 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..738f5723f 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 @@ -1,6 +1,5 @@ /* * 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 @@ -39,8 +38,8 @@ public class DefaultProperty implements Property { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -48,11 +47,11 @@ public class DefaultProperty implements Property { @IRI("https://admin-shell.io/aas/3/0/Property/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/Property/valueId") - protected Reference valueId; + @IRI("https://admin-shell.io/aas/3/0/Property/valueID") + protected Reference valueID; @IRI("https://admin-shell.io/aas/3/0/Property/valueType") - protected DataTypeDefXsd valueType; + protected DataTypeDefXSD valueType; @IRI("https://admin-shell.io/aas/3/0/Qualifiable/qualifiers") protected List qualifiers = new ArrayList<>(); @@ -69,22 +68,24 @@ public class DefaultProperty implements Property { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultProperty() {} + public DefaultProperty() { + + } @Override public int hashCode() { - return Objects.hash(this.valueType, - this.value, - this.valueId, + return Objects.hash(this.value, + this.valueID, + this.valueType, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -97,49 +98,49 @@ public boolean equals(Object obj) { return false; } else { DefaultProperty other = (DefaultProperty) obj; - return Objects.equals(this.valueType, other.valueType) && - Objects.equals(this.value, other.value) && - Objects.equals(this.valueId, other.valueId) && + return Objects.equals(this.value, other.value) && + Objects.equals(this.valueID, other.valueID) && + Objects.equals(this.valueType, other.valueType) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @Override - public DataTypeDefXsd getValueType() { - return valueType; + public String getValue() { + return value; } @Override - public void setValueType(DataTypeDefXsd valueType) { - this.valueType = valueType; + public void setValue(String value) { + this.value = value; } @Override - public String getValue() { - return value; + public Reference getValueID() { + return valueID; } @Override - public void setValue(String value) { - this.value = value; + public void setValueID(Reference valueID) { + this.valueID = valueID; } @Override - public Reference getValueId() { - return valueId; + public DataTypeDefXSD getValueType() { + return valueType; } @Override - public void setValueId(Reference valueId) { - this.valueId = valueId; + public void setValueType(DataTypeDefXSD valueType) { + this.valueType = valueType; } @Override @@ -153,13 +154,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -172,16 +173,6 @@ 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; @@ -193,13 +184,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -208,18 +199,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -232,13 +223,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultProperty (" + "valueType=%s," - + "value=%s," - + "valueId=%s," - + ")", - this.valueType, this.value, this.valueId); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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 deleted file mode 100644 index 4f2d99fb2..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultProtocolInformation.java +++ /dev/null @@ -1,152 +0,0 @@ -/* - * 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. - * - * 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 org.eclipse.digitaltwin.aas4j.v3.model.ProtocolInformation; -import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.ProtocolInformationBuilder; - -import java.util.Objects; - -@IRI("aas:ProtocolInformation") -public class DefaultProtocolInformation implements ProtocolInformation { - - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointAddress") - protected String endpointAddress; - - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocol") - protected String endpointProtocol; - - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/endpointProtocolVersion") - protected String endpointProtocolVersion; - - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocol") - protected String subprotocol; - - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBody") - protected String subprotocolBody; - - @IRI("https://admin-shell.io/aas/3/0/RC02/ProtocolInformation/subprotocolBodyEncoding") - protected String subprotocolBodyEncoding; - - public DefaultProtocolInformation() { - } - - @Override - public int hashCode() { - return Objects.hash(this.endpointAddress, - this.endpointProtocol, - this.endpointProtocolVersion, - this.subprotocol, - this.subprotocolBody, - this.subprotocolBodyEncoding); - } - - @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 { - DefaultProtocolInformation other = (DefaultProtocolInformation) obj; - return Objects.equals(this.endpointAddress, other.endpointAddress) && - Objects.equals(this.endpointProtocol, other.endpointProtocol) && - Objects.equals(this.endpointProtocolVersion, other.endpointProtocolVersion) && - Objects.equals(this.subprotocol, other.subprotocol) && - Objects.equals(this.subprotocolBody, other.subprotocolBody) && - Objects.equals(this.subprotocolBodyEncoding, other.subprotocolBodyEncoding); - } - } - - @Override - public String getEndpointAddress() { - return endpointAddress; - } - - @Override - public void setEndpointAddress(String endpointAddress) { - this.endpointAddress = endpointAddress; - } - - @Override - public String getEndpointProtocol() { - return endpointProtocol; - } - - @Override - public void setEndpointProtocol(String endpointProtocol) { - this.endpointProtocol = endpointProtocol; - } - - @Override - public String getEndpointProtocolVersion() { - return endpointProtocolVersion; - } - - @Override - public void setEndpointProtocolVersion(String endpointProtocolVersion) { - this.endpointProtocolVersion = endpointProtocolVersion; - } - - @Override - public String getSubprotocol() { - return subprotocol; - } - - @Override - public void setSubprotocol(String subprotocol) { - this.subprotocol = subprotocol; - } - - @Override - public String getSubprotocolBody() { - return subprotocolBody; - } - - @Override - public void setSubprotocolBody(String subprotocolBody) { - this.subprotocolBody = subprotocolBody; - } - - @Override - public String getSubprotocolBodyEncoding() { - return subprotocolBodyEncoding; - } - - @Override - public void setSubprotocolBodyEncoding(String subprotocolBodyEncoding) { - this.subprotocolBodyEncoding = subprotocolBodyEncoding; - } - - /** - * This builder class can be used to construct a DefaultProtocolInformation bean. - */ - public static class Builder extends ProtocolInformationBuilder { - - @Override - protected Builder getSelf() { - return this; - } - - @Override - protected DefaultProtocolInformation newBuildingInstance() { - return new DefaultProtocolInformation(); - } - } -} 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..fc1d46bb3 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 @@ -1,6 +1,5 @@ /* * 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,7 +14,7 @@ package org.eclipse.digitaltwin.aas4j.v3.model.impl; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXsd; +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; @@ -37,8 +36,8 @@ @IRI("aas:Qualifier") public class DefaultQualifier implements Qualifier { - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") - protected Reference semanticId; + @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<>(); @@ -52,22 +51,24 @@ public class DefaultQualifier implements Qualifier { @IRI("https://admin-shell.io/aas/3/0/Qualifier/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueId") - protected Reference valueId; + @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueID") + protected Reference valueID; @IRI("https://admin-shell.io/aas/3/0/Qualifier/valueType") - protected DataTypeDefXsd valueType; + protected DataTypeDefXSD valueType; - public DefaultQualifier() {} + public DefaultQualifier() { + + } @Override public int hashCode() { return Objects.hash(this.kind, this.type, - this.valueType, this.value, - this.valueId, - this.semanticId, + this.valueID, + this.valueType, + this.semanticID, this.supplementalSemanticIds); } @@ -83,10 +84,10 @@ public boolean equals(Object obj) { DefaultQualifier other = (DefaultQualifier) obj; return Objects.equals(this.kind, other.kind) && Objects.equals(this.type, other.type) && - Objects.equals(this.valueType, other.valueType) && Objects.equals(this.value, other.value) && - Objects.equals(this.valueId, other.valueId) && - Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.valueID, other.valueID) && + Objects.equals(this.valueType, other.valueType) && + Objects.equals(this.semanticID, other.semanticID) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds); } } @@ -112,43 +113,43 @@ public void setType(String type) { } @Override - public DataTypeDefXsd getValueType() { - return valueType; + public String getValue() { + return value; } @Override - public void setValueType(DataTypeDefXsd valueType) { - this.valueType = valueType; + public void setValue(String value) { + this.value = value; } @Override - public String getValue() { - return value; + public Reference getValueID() { + return valueID; } @Override - public void setValue(String value) { - this.value = value; + public void setValueID(Reference valueID) { + this.valueID = valueID; } @Override - public Reference getValueId() { - return valueId; + public DataTypeDefXSD getValueType() { + return valueType; } @Override - public void setValueId(Reference valueId) { - this.valueId = valueId; + public void setValueType(DataTypeDefXSD valueType) { + this.valueType = valueType; } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -161,17 +162,6 @@ public void setSupplementalSemanticIds(List supplementalSemanticIds) this.supplementalSemanticIds = supplementalSemanticIds; } - public String toString() { - return String.format( - "DefaultQualifier (" + "kind=%s," - + "type=%s," - + "valueType=%s," - + "value=%s," - + "valueId=%s," - + ")", - this.kind, this.type, this.valueType, this.value, this.valueId); - } - /** * This builder class can be used to construct a DefaultQualifier bean. */ 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..18710604c 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 @@ -1,6 +1,5 @@ /* * 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 @@ -39,8 +38,8 @@ public class DefaultRange implements Range { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -55,7 +54,7 @@ public class DefaultRange implements Range { protected String min; @IRI("https://admin-shell.io/aas/3/0/Range/valueType") - protected DataTypeDefXsd valueType; + protected DataTypeDefXSD valueType; @IRI("https://admin-shell.io/aas/3/0/Referable/category") protected String category; @@ -69,22 +68,24 @@ public class DefaultRange implements Range { @IRI("https://admin-shell.io/aas/3/0/Referable/idShort") protected String idShort; - public DefaultRange() {} + public DefaultRange() { + + } @Override public int hashCode() { - return Objects.hash(this.valueType, + return Objects.hash(this.max, this.min, - this.max, + this.valueType, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -97,29 +98,29 @@ public boolean equals(Object obj) { return false; } else { DefaultRange other = (DefaultRange) obj; - return Objects.equals(this.valueType, other.valueType) && + return Objects.equals(this.max, other.max) && Objects.equals(this.min, other.min) && - Objects.equals(this.max, other.max) && + Objects.equals(this.valueType, other.valueType) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @Override - public DataTypeDefXsd getValueType() { - return valueType; + public String getMax() { + return max; } @Override - public void setValueType(DataTypeDefXsd valueType) { - this.valueType = valueType; + public void setMax(String max) { + this.max = max; } @Override @@ -133,13 +134,13 @@ public void setMin(String min) { } @Override - public String getMax() { - return max; + public DataTypeDefXSD getValueType() { + return valueType; } @Override - public void setMax(String max) { - this.max = max; + public void setValueType(DataTypeDefXSD valueType) { + this.valueType = valueType; } @Override @@ -153,13 +154,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -172,16 +173,6 @@ 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; @@ -193,13 +184,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -208,18 +199,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -232,13 +223,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultRange (" + "valueType=%s," - + "min=%s," - + "max=%s," - + ")", - this.valueType, this.min, this.max); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..3817f9236 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 @@ -1,6 +1,5 @@ /* * 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 @@ -38,19 +37,21 @@ public class DefaultReference implements Reference { @IRI("https://admin-shell.io/aas/3/0/Reference/keys") protected List keys = new ArrayList<>(); - @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticId") - protected Reference referredSemanticId; + @IRI("https://admin-shell.io/aas/3/0/Reference/referredSemanticID") + protected Reference referredSemanticID; @IRI("https://admin-shell.io/aas/3/0/Reference/type") protected ReferenceTypes type; - public DefaultReference() {} + public DefaultReference() { + + } @Override public int hashCode() { - return Objects.hash(this.type, - this.referredSemanticId, - this.keys); + return Objects.hash(this.keys, + this.referredSemanticID, + this.type); } @Override @@ -63,49 +64,40 @@ public boolean equals(Object obj) { return false; } else { DefaultReference other = (DefaultReference) obj; - return Objects.equals(this.type, other.type) && - Objects.equals(this.referredSemanticId, other.referredSemanticId) && - Objects.equals(this.keys, other.keys); + return Objects.equals(this.keys, other.keys) && + Objects.equals(this.referredSemanticID, other.referredSemanticID) && + Objects.equals(this.type, other.type); } } @Override - public ReferenceTypes getType() { - return type; + public List getKeys() { + return keys; } @Override - public void setType(ReferenceTypes type) { - this.type = type; + public void setKeys(List keys) { + this.keys = keys; } @Override - public Reference getReferredSemanticId() { - return referredSemanticId; + public Reference getReferredSemanticID() { + return referredSemanticID; } @Override - public void setReferredSemanticId(Reference referredSemanticId) { - this.referredSemanticId = referredSemanticId; + public void setReferredSemanticID(Reference referredSemanticID) { + this.referredSemanticID = referredSemanticID; } @Override - public List getKeys() { - return keys; + public ReferenceTypes getType() { + return type; } @Override - public void setKeys(List keys) { - this.keys = keys; - } - - public String toString() { - return String.format( - "DefaultReference (" + "type=%s," - + "referredSemanticId=%s," - + "keys=%s," - + ")", - this.type, this.referredSemanticId, this.keys); + public void setType(ReferenceTypes type) { + this.type = 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..3b36d2062 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 @@ -1,6 +1,5 @@ /* * 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 @@ -40,8 +39,8 @@ public class DefaultReferenceElement implements ReferenceElement { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -64,20 +63,22 @@ public class DefaultReferenceElement implements ReferenceElement { @IRI("https://admin-shell.io/aas/3/0/ReferenceElement/value") protected Reference value; - public DefaultReferenceElement() {} + public DefaultReferenceElement() { + + } @Override public int hashCode() { return Objects.hash(this.value, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -92,14 +93,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.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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -124,13 +125,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -143,16 +144,6 @@ 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; @@ -164,13 +155,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -179,18 +170,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -203,11 +194,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultReferenceElement (" + "value=%s," - + ")", - this.value); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..99bd400e0 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 @@ -1,6 +1,5 @@ /* * 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 @@ -40,8 +39,8 @@ public class DefaultRelationshipElement implements RelationshipElement { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -67,21 +66,23 @@ public class DefaultRelationshipElement implements RelationshipElement { @IRI("https://admin-shell.io/aas/3/0/RelationshipElement/second") protected Reference second; - public DefaultRelationshipElement() {} + public DefaultRelationshipElement() { + + } @Override public int hashCode() { return Objects.hash(this.first, this.second, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -97,14 +98,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.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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -139,13 +140,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -158,16 +159,6 @@ 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; @@ -179,13 +170,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -194,18 +185,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -218,12 +209,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultRelationshipElement (" + "first=%s," - + "second=%s," - + ")", - this.first, this.second); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..44b40cb2b 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 @@ -1,6 +1,5 @@ /* * 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 @@ -38,12 +37,14 @@ public class DefaultResource implements Resource { @IRI("https://admin-shell.io/aas/3/0/Resource/path") protected String path; - public DefaultResource() {} + public DefaultResource() { + + } @Override public int hashCode() { - return Objects.hash(this.path, - this.contentType); + return Objects.hash(this.contentType, + this.path); } @Override @@ -56,21 +57,11 @@ public boolean equals(Object obj) { return false; } else { DefaultResource other = (DefaultResource) obj; - return Objects.equals(this.path, other.path) && - Objects.equals(this.contentType, other.contentType); + return Objects.equals(this.contentType, other.contentType) && + Objects.equals(this.path, other.path); } } - @Override - public String getPath() { - return path; - } - - @Override - public void setPath(String path) { - this.path = path; - } - @Override public String getContentType() { return contentType; @@ -81,12 +72,14 @@ public void setContentType(String contentType) { this.contentType = contentType; } - public String toString() { - return String.format( - "DefaultResource (" + "path=%s," - + "contentType=%s," - + ")", - this.path, this.contentType); + @Override + public String getPath() { + return path; + } + + @Override + public void setPath(String path) { + this.path = path; } /** 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..5c35ffb9e 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 @@ -1,6 +1,5 @@ /* * 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 @@ -16,9 +15,9 @@ 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.SpecificAssetID; import org.eclipse.digitaltwin.aas4j.v3.model.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SpecificAssetIdBuilder; +import org.eclipse.digitaltwin.aas4j.v3.model.builder.SpecificAssetIDBuilder; import java.util.ArrayList; import java.util.List; @@ -26,37 +25,39 @@ /** - * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetId + * Default implementation of package org.eclipse.digitaltwin.aas4j.v3.model.SpecificAssetID * * A specific asset ID describes a generic supplementary identifying attribute of the asset. */ -@IRI("aas:SpecificAssetId") -public class DefaultSpecificAssetId implements SpecificAssetId { +@IRI("aas:SpecificAssetID") +public class DefaultSpecificAssetID implements SpecificAssetID { - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") - protected Reference semanticId; + @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/SpecificAssetId/externalSubjectId") - protected Reference externalSubjectId; + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/externalSubjectID") + protected Reference externalSubjectID; - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/name") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/name") protected String name; - @IRI("https://admin-shell.io/aas/3/0/SpecificAssetId/value") + @IRI("https://admin-shell.io/aas/3/0/SpecificAssetID/value") protected String value; - public DefaultSpecificAssetId() {} + public DefaultSpecificAssetID() { + + } @Override public int hashCode() { - return Objects.hash(this.name, + return Objects.hash(this.externalSubjectID, + this.name, this.value, - this.externalSubjectId, - this.semanticId, + this.semanticID, this.supplementalSemanticIds); } @@ -69,15 +70,25 @@ public boolean equals(Object obj) { } else if (this.getClass() != obj.getClass()) { return false; } else { - DefaultSpecificAssetId other = (DefaultSpecificAssetId) obj; - return Objects.equals(this.name, other.name) && + DefaultSpecificAssetID other = (DefaultSpecificAssetID) obj; + return Objects.equals(this.externalSubjectID, other.externalSubjectID) && + Objects.equals(this.name, other.name) && Objects.equals(this.value, other.value) && - Objects.equals(this.externalSubjectId, other.externalSubjectId) && - Objects.equals(this.semanticId, other.semanticId) && + Objects.equals(this.semanticID, other.semanticID) && Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds); } } + @Override + public Reference getExternalSubjectID() { + return externalSubjectID; + } + + @Override + public void setExternalSubjectID(Reference externalSubjectID) { + this.externalSubjectID = externalSubjectID; + } + @Override public String getName() { return name; @@ -99,23 +110,13 @@ public void setValue(String value) { } @Override - public Reference getExternalSubjectId() { - return externalSubjectId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setExternalSubjectId(Reference externalSubjectId) { - this.externalSubjectId = externalSubjectId; - } - - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -128,19 +129,10 @@ public void setSupplementalSemanticIds(List supplementalSemanticIds) this.supplementalSemanticIds = supplementalSemanticIds; } - public String toString() { - return String.format( - "DefaultSpecificAssetId (" + "name=%s," - + "value=%s," - + "externalSubjectId=%s," - + ")", - this.name, this.value, this.externalSubjectId); - } - /** - * This builder class can be used to construct a DefaultSpecificAssetId bean. + * This builder class can be used to construct a DefaultSpecificAssetID bean. */ - public static class Builder extends SpecificAssetIdBuilder { + public static class Builder extends SpecificAssetIDBuilder { @Override protected Builder getSelf() { @@ -148,8 +140,8 @@ protected Builder getSelf() { } @Override - protected DefaultSpecificAssetId newBuildingInstance() { - return new DefaultSpecificAssetId(); + protected DefaultSpecificAssetID newBuildingInstance() { + return new DefaultSpecificAssetID(); } } } 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..17f582dc9 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 @@ -1,6 +1,5 @@ /* * 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 @@ -42,8 +41,8 @@ public class DefaultSubmodel implements Submodel { @IRI("https://admin-shell.io/aas/3/0/HasKind/kind") protected ModellingKind kind; - @IRI("https://admin-shell.io/aas/3/0/HasSemantics/semanticId") - protected Reference semanticId; + @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<>(); @@ -72,22 +71,24 @@ public class DefaultSubmodel implements Submodel { @IRI("https://admin-shell.io/aas/3/0/Submodel/submodelElements") protected List submodelElements = new ArrayList<>(); - public DefaultSubmodel() {} + public DefaultSubmodel() { + + } @Override public int hashCode() { return Objects.hash(this.submodelElements, this.embeddedDataSpecifications, - this.kind, - this.semanticId, - this.supplementalSemanticIds, this.administration, this.id, this.category, - this.idShort, - this.displayName, this.description, + this.displayName, + this.idShort, this.extensions, + this.semanticID, + this.supplementalSemanticIds, + this.kind, this.qualifiers); } @@ -103,16 +104,16 @@ public boolean equals(Object obj) { 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) && - Objects.equals(this.idShort, other.idShort) && - Objects.equals(this.displayName, other.displayName) && Objects.equals(this.description, other.description) && + Objects.equals(this.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.semanticID, other.semanticID) && + Objects.equals(this.supplementalSemanticIds, other.supplementalSemanticIds) && + Objects.equals(this.kind, other.kind) && Objects.equals(this.qualifiers, other.qualifiers); } } @@ -137,36 +138,6 @@ public void setEmbeddedDataSpecifications(List embedd 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; @@ -198,13 +169,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -213,18 +184,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -237,6 +208,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 ModellingKind getKind() { + return kind; + } + + @Override + public void setKind(ModellingKind kind) { + this.kind = kind; + } + @Override public List getQualifiers() { return qualifiers; @@ -247,13 +248,6 @@ public void setQualifiers(List qualifiers) { this.qualifiers = qualifiers; } - public String toString() { - return String.format( - "DefaultSubmodel (" + "submodelElements=%s," - + ")", - this.submodelElements); - } - /** * This builder class can be used to construct a DefaultSubmodel bean. */ 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 deleted file mode 100644 index 8d4025c93..000000000 --- a/model/src/main/java/org/eclipse/digitaltwin/aas4j/v3/model/impl/DefaultSubmodelDescriptor.java +++ /dev/null @@ -1,174 +0,0 @@ -/* - * 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. - * - * 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.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.annotations.IRI; -import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelDescriptorBuilder; - -@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/RC02/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/RC02/SubmodelDescriptor/displayName") - protected List displayName; - - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/idShort") - protected String idShort; - - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/ide") - protected String id; - - @IRI("https://admin-shell.io/aas/3/0/RC02/SubmodelDescriptor/semanticId") - protected Reference semanticId; - - public DefaultSubmodelDescriptor() { - } - - @Override - public int hashCode() { - return Objects.hash(this.administration, - this.description, - this.displayName, - this.idShort, - this.id, - this.semanticId, - this.endpoints); - } - - @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 { - 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.idShort, other.idShort) && - Objects.equals(this.id, other.id) && - Objects.equals(this.semanticId, other.semanticId) && - Objects.equals(this.endpoints, other.endpoints); - } - } - - @Override - public AdministrativeInformation getAdministration() { - return administration; - } - - @Override - public void setAdministration(AdministrativeInformation administration) { - this.administration = administration; - } - - @Override - public List getDescription() { - return description; - } - - @Override - public void setDescription(List description) { - this.description = description; - } - - @Override - public List getDisplayName() { - return displayName; - } - - @Override - public void setDisplayName(List displayName) { - this.displayName = displayName; - } - - @Override - public String getIdShort() { - return idShort; - } - - @Override - public void setIdShort(String idShort) { - this.idShort = idShort; - } - - @Override - public String getId() { - return id; - } - - @Override - public void setId(String id) { - this.id = id; - } - - @Override - public Reference getSemanticId() { - return semanticId; - } - - @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; - } - - @Override - public List getEndpoints() { - return endpoints; - } - - @Override - public void setEndpoints(List endpoints) { - this.endpoints = endpoints; - } - - /** - * This builder class can be used to construct a DefaultSubmodelDescriptor bean. - */ - public static class Builder extends SubmodelDescriptorBuilder { - - @Override - protected Builder getSelf() { - return this; - } - - @Override - protected DefaultSubmodelDescriptor newBuildingInstance() { - return new DefaultSubmodelDescriptor(); - } - } -} 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..2cb74847c 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 @@ -1,6 +1,5 @@ /* * 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 @@ -20,6 +19,7 @@ import org.eclipse.digitaltwin.aas4j.v3.model.builder.SubmodelElementCollectionBuilder; import java.util.ArrayList; +import java.util.Collection; import java.util.List; import java.util.Objects; @@ -41,8 +41,8 @@ public class DefaultSubmodelElementCollection implements SubmodelElementCollecti @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -63,22 +63,24 @@ public class DefaultSubmodelElementCollection implements SubmodelElementCollecti protected String idShort; @IRI("https://admin-shell.io/aas/3/0/SubmodelElementCollection/value") - protected List value = new ArrayList<>(); + protected Collection value = new ArrayList<>(); - public DefaultSubmodelElementCollection() {} + public DefaultSubmodelElementCollection() { + + } @Override public int hashCode() { return Objects.hash(this.value, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -93,25 +95,25 @@ 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.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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @Override - public List getValue() { + public Collection getValue() { return value; } @Override - public void setValue(List values) { - this.value = values; + public void setValue(Collection value) { + this.value = value; } @Override @@ -125,13 +127,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -144,16 +146,6 @@ 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; @@ -165,13 +157,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -180,18 +172,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -204,11 +196,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultSubmodelElementCollection (" + "value=%s," - + ")", - this.value); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..745f21e17 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 @@ -1,6 +1,5 @@ /* * 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 @@ -39,8 +38,8 @@ public class DefaultSubmodelElementList implements SubmodelElementList { @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/semanticID") + protected Reference semanticID; @IRI("https://admin-shell.io/aas/3/0/HasSemantics/supplementalSemanticIds") protected List supplementalSemanticIds = new ArrayList<>(); @@ -63,36 +62,38 @@ public class DefaultSubmodelElementList implements SubmodelElementList { @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/orderRelevant") protected boolean orderRelevant; - @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIdListElement") - protected Reference semanticIdListElement; + @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/semanticIDListElement") + protected Reference semanticIDListElement; @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/typeValueListElement") - protected AasSubmodelElements typeValueListElement; + protected AASSubmodelElements typeValueListElement; @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/value") protected List value = new ArrayList<>(); @IRI("https://admin-shell.io/aas/3/0/SubmodelElementList/valueTypeListElement") - protected DataTypeDefXsd valueTypeListElement; + protected DataTypeDefXSD valueTypeListElement; - public DefaultSubmodelElementList() {} + public DefaultSubmodelElementList() { + + } @Override public int hashCode() { return Objects.hash(this.orderRelevant, - this.semanticIdListElement, + this.semanticIDListElement, this.typeValueListElement, - this.valueTypeListElement, this.value, + this.valueTypeListElement, this.embeddedDataSpecifications, - this.semanticId, + this.semanticID, this.supplementalSemanticIds, - this.qualifiers, this.category, - this.idShort, - this.displayName, this.description, - this.extensions); + this.displayName, + this.idShort, + this.extensions, + this.qualifiers); } @Override @@ -106,19 +107,19 @@ public boolean equals(Object obj) { } else { DefaultSubmodelElementList other = (DefaultSubmodelElementList) obj; return Objects.equals(this.orderRelevant, other.orderRelevant) && - Objects.equals(this.semanticIdListElement, other.semanticIdListElement) && + Objects.equals(this.semanticIDListElement, other.semanticIDListElement) && Objects.equals(this.typeValueListElement, other.typeValueListElement) && - Objects.equals(this.valueTypeListElement, other.valueTypeListElement) && Objects.equals(this.value, other.value) && + Objects.equals(this.valueTypeListElement, other.valueTypeListElement) && Objects.equals(this.embeddedDataSpecifications, other.embeddedDataSpecifications) && - Objects.equals(this.semanticId, other.semanticId) && + 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.displayName, other.displayName) && + Objects.equals(this.idShort, other.idShort) && + Objects.equals(this.extensions, other.extensions) && + Objects.equals(this.qualifiers, other.qualifiers); } } @@ -133,43 +134,43 @@ public void setOrderRelevant(boolean orderRelevant) { } @Override - public Reference getSemanticIdListElement() { - return semanticIdListElement; + public Reference getSemanticIDListElement() { + return semanticIDListElement; } @Override - public void setSemanticIdListElement(Reference semanticIdListElement) { - this.semanticIdListElement = semanticIdListElement; + public void setSemanticIDListElement(Reference semanticIDListElement) { + this.semanticIDListElement = semanticIDListElement; } @Override - public AasSubmodelElements getTypeValueListElement() { + public AASSubmodelElements getTypeValueListElement() { return typeValueListElement; } @Override - public void setTypeValueListElement(AasSubmodelElements typeValueListElement) { + public void setTypeValueListElement(AASSubmodelElements typeValueListElement) { this.typeValueListElement = typeValueListElement; } @Override - public DataTypeDefXsd getValueTypeListElement() { - return valueTypeListElement; + public List getValue() { + return value; } @Override - public void setValueTypeListElement(DataTypeDefXsd valueTypeListElement) { - this.valueTypeListElement = valueTypeListElement; + public void setValue(List value) { + this.value = value; } @Override - public List getValue() { - return value; + public DataTypeDefXSD getValueTypeListElement() { + return valueTypeListElement; } @Override - public void setValue(List values) { - this.value = values; + public void setValueTypeListElement(DataTypeDefXSD valueTypeListElement) { + this.valueTypeListElement = valueTypeListElement; } @Override @@ -183,13 +184,13 @@ public void setEmbeddedDataSpecifications(List embedd } @Override - public Reference getSemanticId() { - return semanticId; + public Reference getSemanticID() { + return semanticID; } @Override - public void setSemanticId(Reference semanticId) { - this.semanticId = semanticId; + public void setSemanticID(Reference semanticID) { + this.semanticID = semanticID; } @Override @@ -202,16 +203,6 @@ 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; @@ -223,13 +214,13 @@ public void setCategory(String category) { } @Override - public String getIdShort() { - return idShort; + public List getDescription() { + return description; } @Override - public void setIdShort(String idShort) { - this.idShort = idShort; + public void setDescription(List description) { + this.description = description; } @Override @@ -238,18 +229,18 @@ public List getDisplayName() { } @Override - public void setDisplayName(List displayNames) { - this.displayName = displayNames; + public void setDisplayName(List displayName) { + this.displayName = displayName; } @Override - public List getDescription() { - return description; + public String getIdShort() { + return idShort; } @Override - public void setDescription(List descriptions) { - this.description = descriptions; + public void setIdShort(String idShort) { + this.idShort = idShort; } @Override @@ -262,15 +253,14 @@ public void setExtensions(List extensions) { this.extensions = extensions; } - public String toString() { - return String.format( - "DefaultSubmodelElementList (" + "orderRelevant=%s," - + "semanticIdListElement=%s," - + "typeValueListElement=%s," - + "valueTypeListElement=%s," - + "value=%s," - + ")", - this.orderRelevant, this.semanticIdListElement, this.typeValueListElement, this.valueTypeListElement, this.value); + @Override + public List getQualifiers() { + return qualifiers; + } + + @Override + public void setQualifiers(List qualifiers) { + this.qualifiers = qualifiers; } /** 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..a4c7d4236 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 @@ -1,6 +1,5 @@ /* * 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 @@ -68,13 +67,6 @@ public void setValueReferencePairs(List valueReferencePairs) this.valueReferencePairs = valueReferencePairs; } - public String toString() { - return String.format( - "DefaultValueList (" + "valueReferencePairs=%s," - + ")", - this.valueReferencePairs); - } - /** * This builder class can be used to construct a DefaultValueList bean. */ 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..fbffa2f47 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 @@ -1,6 +1,5 @@ /* * 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 @@ -36,15 +35,17 @@ public class DefaultValueReferencePair implements ValueReferencePair { @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/value") protected String value; - @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueId") - protected Reference valueId; + @IRI("https://admin-shell.io/aas/3/0/ValueReferencePair/valueID") + protected Reference valueID; - public DefaultValueReferencePair() {} + public DefaultValueReferencePair() { + + } @Override public int hashCode() { return Objects.hash(this.value, - this.valueId); + this.valueID); } @Override @@ -58,7 +59,7 @@ public boolean equals(Object obj) { } else { DefaultValueReferencePair other = (DefaultValueReferencePair) obj; return Objects.equals(this.value, other.value) && - Objects.equals(this.valueId, other.valueId); + Objects.equals(this.valueID, other.valueID); } } @@ -73,21 +74,13 @@ public void setValue(String value) { } @Override - public Reference getValueId() { - return valueId; + public Reference getValueID() { + return valueID; } @Override - public void setValueId(Reference valueId) { - this.valueId = valueId; - } - - public String toString() { - return String.format( - "DefaultValueReferencePair (" + "value=%s," - + "valueId=%s," - + ")", - this.value, this.valueId); + public void setValueID(Reference valueID) { + this.valueID = valueID; } /** From b3b937b98fbe193b95998f2451ccbee35b156cd8 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 14:55:21 +0200 Subject: [PATCH 08/18] Update AssetAdministrationShellElementWalkerVisitor.java --- .../visitor/AssetAdministrationShellElementWalkerVisitor.java | 1 + 1 file changed, 1 insertion(+) diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java index 110bb2f4a..d16f45849 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/internal/visitor/AssetAdministrationShellElementWalkerVisitor.java @@ -295,4 +295,5 @@ public default void visit(Operation operation) { operation.getOutputVariables().forEach(x -> visit(x.getValue())); AssetAdministrationShellElementVisitor.super.visit(operation); } + } From 98c6f930eecac29b68771e667f0ef67e5e805c65 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 14:59:07 +0200 Subject: [PATCH 09/18] Update EnumSerializer.java --- .../aas4j/v3/dataformat/core/serialization/EnumSerializer.java | 1 - 1 file changed, 1 deletion(-) diff --git a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java index 7d95737e8..dadf9bc6c 100644 --- a/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java +++ b/dataformat-core/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/serialization/EnumSerializer.java @@ -1,6 +1,5 @@ /* * 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. From 431ca588d18f287da72ed3f92ec7e85bea0f2311 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 15:00:41 +0200 Subject: [PATCH 10/18] Update AASFull.java --- .../eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java index 790f5054a..4844d4e3c 100644 --- a/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java +++ b/dataformat-core/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/core/AASFull.java @@ -1906,4 +1906,4 @@ public static Environment createEnvironment() { .build(); } -} \ No newline at end of file +} From d3f2e037de5a3b3fcc6ca9b61abc162107857809 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 15:04:08 +0200 Subject: [PATCH 11/18] Update AssetInformationMixin.java --- .../aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java index dbd93710c..19304faf5 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/AssetInformationMixin.java @@ -33,7 +33,7 @@ public interface AssetInformationMixin { @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "specificAssetIds") - public void setSpecificAssetIds(List SpecificAssetIds); + public void setSpecificAssetIds(List specificAssetIds); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "globalAssetId") @JacksonXmlElementWrapper(namespace = AasXmlNamespaceContext.AAS_URI, localName = "globalAssetId") From 5447f5c0b41ff31e860d25c4c7354d5e13205184 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 15:51:05 +0200 Subject: [PATCH 12/18] Cosmetics --- .../aas4j/v3/dataformat/json/JsonDeserializer.java | 6 +++--- .../aas4j/v3/dataformat/json/JsonSerializer.java | 14 +++++++------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java index 1786fa355..b84626510 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializer.java @@ -27,7 +27,6 @@ import java.util.List; import java.util.stream.Collectors; -import com.fasterxml.jackson.databind.ObjectMapper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.DeserializationException; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Referable; @@ -35,6 +34,7 @@ import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.databind.JsonNode; +import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.module.SimpleAbstractTypeResolver; import static org.eclipse.digitaltwin.aas4j.v3.dataformat.json.ObjectMapperFactory.createMapper; @@ -118,7 +118,7 @@ public Environment read(InputStream src, Charset charset) throws Deserialization * @throws FileNotFoundException if file is not present * @throws DeserializationException if deserialization fails */ - public Environment read(File file, Charset charset) + public Environment read(java.io.File file, Charset charset) throws FileNotFoundException, DeserializationException { return read(new FileInputStream(file), charset); } @@ -131,7 +131,7 @@ public Environment read(File file, Charset charset) * @throws FileNotFoundException if the file is not present * @throws DeserializationException if deserialization fails */ - public Environment read(File file) throws FileNotFoundException, DeserializationException { + public Environment read(java.io.File file) throws FileNotFoundException, DeserializationException { return read(file, DEFAULT_CHARSET); } diff --git a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java index bc5a43c1c..9f1e54285 100644 --- a/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java +++ b/dataformat-json/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializer.java @@ -16,26 +16,26 @@ */ package org.eclipse.digitaltwin.aas4j.v3.dataformat.json; +import java.io.FileNotFoundException; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.OutputStream; +import java.io.OutputStreamWriter; import java.nio.charset.Charset; import java.nio.charset.StandardCharsets; import java.util.Collection; import java.util.List; -import com.fasterxml.jackson.databind.ObjectMapper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.SerializationException; import org.eclipse.digitaltwin.aas4j.v3.model.Environment; import org.eclipse.digitaltwin.aas4j.v3.model.Referable; import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.JsonNode; -import java.io.FileNotFoundException; -import java.io.FileOutputStream; -import java.io.IOException; -import java.io.OutputStream; -import java.io.OutputStreamWriter; +import com.fasterxml.jackson.databind.ObjectMapper; /** - * Class for serializing an instance of AssetAdministrationShellEnvironment or Referables to JSON. + * Class for serializing an instance of AssetAdministrationShellEnvironment or Referables to JSON. */ public class JsonSerializer { private static final Charset DEFAULT_CHARSET = StandardCharsets.UTF_8; From b272f50b3cfac2421d42bda01cab789728dd3650 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 15:59:20 +0200 Subject: [PATCH 13/18] Cosmetics --- .../aas4j/v3/dataformat/json/JsonDeserializerTest.java | 1 - .../aas4j/v3/dataformat/json/JsonSerializerTest.java | 1 - .../aas4j/v3/dataformat/xml/mixins/ResourceMixin.java | 2 +- 3 files changed, 1 insertion(+), 3 deletions(-) diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java index 1cc0b22b8..efb511cbe 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonDeserializerTest.java @@ -20,7 +20,6 @@ import com.fasterxml.jackson.databind.ObjectMapper; import static org.junit.Assert.assertEquals; -import com.fasterxml.jackson.databind.ObjectMapper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.AASSimple; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.CustomProperty; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.CustomSubmodel; diff --git a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java index 8a07eb1ea..a34404e7f 100644 --- a/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java +++ b/dataformat-json/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/json/JsonSerializerTest.java @@ -26,7 +26,6 @@ import java.util.List; import java.util.Set; -import com.fasterxml.jackson.databind.ObjectMapper; import org.eclipse.digitaltwin.aas4j.v3.dataformat.DeserializationException; import org.eclipse.digitaltwin.aas4j.v3.dataformat.SerializationException; import org.eclipse.digitaltwin.aas4j.v3.dataformat.core.AASSimple; diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java index 9e21bcdf3..0af6f1b47 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/ResourceMixin.java @@ -16,10 +16,10 @@ package org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.mixins; import org.eclipse.digitaltwin.aas4j.v3.dataformat.xml.internal.AasXmlNamespaceContext; +import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; -import org.eclipse.digitaltwin.aas4j.v3.model.DataTypeDefXSD; @JsonPropertyOrder({"path", "contentType"}) public interface ResourceMixin { From 8a6f9b617601e6df331c562a8c768c25f1460fb0 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 16:04:13 +0200 Subject: [PATCH 14/18] Update SpecificAssetIDMixin.java --- .../aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java index 737e67da4..511735600 100644 --- a/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java +++ b/dataformat-xml/src/main/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/mixins/SpecificAssetIDMixin.java @@ -31,5 +31,5 @@ public interface SpecificAssetIDMixin { public String getValue(); @JacksonXmlProperty(namespace = AasXmlNamespaceContext.AAS_URI, localName = "externalSubjectId") - public Reference getExternalSubjectID(); -} \ No newline at end of file + public Reference getExternalSubjectID(); +} From f94b5325cd34a09b7f194be3f7a62b494b916675 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Wed, 30 Aug 2023 16:06:03 +0200 Subject: [PATCH 15/18] Update XmlSerializerTest.java --- .../digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java index 767ba4481..c50574d3e 100644 --- a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java +++ b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XmlSerializerTest.java @@ -140,8 +140,7 @@ public void validateMinimalOperationAgainstXsdSchema() throws SerializationExcep @Test public void validateGYearAgainstXsdSchema() throws SerializationException, SAXException { - Submodel submodel = new DefaultSubmodel.Builder().id("yearTestSm").submodelElements( - new DefaultProperty.Builder().idShort("yearTestProp").valueType(DataTypeDefXSD.GYEAR).build()).build(); + Submodel submodel = new DefaultSubmodel.Builder().id("yearTestSm").submodelElements(new DefaultProperty.Builder().idShort("yearTestProp").valueType(DataTypeDefXSD.GYEAR).build()).build(); String xml = new XmlSerializer().write(new DefaultEnvironment.Builder().submodels(submodel).build()); Set errors = validateAgainstXsdSchema(xml); assertTrue(errors.isEmpty()); From fd8c0811e89c1a0536a09d46cd9f7486ab21c494 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Thu, 31 Aug 2023 14:09:08 +0200 Subject: [PATCH 16/18] Update XMLDeserializerTest.java --- .../aas4j/v3/dataformat/xml/XMLDeserializerTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XMLDeserializerTest.java b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XMLDeserializerTest.java index 8da48bc62..985054436 100644 --- a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XMLDeserializerTest.java +++ b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/XMLDeserializerTest.java @@ -123,7 +123,7 @@ public void deserializeAASFullConceptDescription() throws FileNotFoundException, @Test public void deserializeAASWithExtensionMinimal() throws SerializationException, SAXException, FileNotFoundException, DeserializationException { Environment env = new XmlDeserializer().read(XmlSerializerTest.AAS_WITH_EXTENSION_MINIMAL); - + //String xml = new XmlSerializer().write(env); Assert.assertEquals(Examples.EXTENSION_MINIMAL, env); } From f8c146629950b836e78fd28e1ca0015a9f910158 Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Thu, 31 Aug 2023 14:47:03 +0200 Subject: [PATCH 17/18] Create test suite to order the tests execution --- .../aas4j/v3/dataformat/xml/TestSuite.java | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/TestSuite.java diff --git a/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/TestSuite.java b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/TestSuite.java new file mode 100644 index 000000000..c8948f2d0 --- /dev/null +++ b/dataformat-xml/src/test/java/org/eclipse/digitaltwin/aas4j/v3/dataformat/xml/TestSuite.java @@ -0,0 +1,15 @@ +package org.eclipse.digitaltwin.aas4j.v3.dataformat.xml; + +import org.junit.runner.RunWith; +import org.junit.runners.Suite; + +@RunWith(Suite.class) +@Suite.SuiteClasses( + { + XmlValidationTest.class, + XMLDeserializerTest.class, + XmlSerializerTest.class, + } +) +public class TestSuite { +} From be347ee18caea551cdcd6e2bffec14628d84643e Mon Sep 17 00:00:00 2001 From: Emil Dinchev Date: Fri, 1 Sep 2023 09:11:21 +0200 Subject: [PATCH 18/18] Execute only the test suite during the build of dataformat-xml --- dataformat-xml/pom.xml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/dataformat-xml/pom.xml b/dataformat-xml/pom.xml index 4ed49f74a..3975d594d 100644 --- a/dataformat-xml/pom.xml +++ b/dataformat-xml/pom.xml @@ -72,4 +72,18 @@ jackson-core + + + + org.apache.maven.plugins + 2.22.2 + maven-surefire-plugin + + + **/TestSuite*.java + + + + +