You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@causeway.apache.org by ah...@apache.org on 2023/09/08 06:32:30 UTC

[causeway] branch master updated: CAUSEWAY-3565: adds withers to ObjectGraph

This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/causeway.git


The following commit(s) were added to refs/heads/master by this push:
     new d4b5422ad7 CAUSEWAY-3565: adds withers to ObjectGraph
d4b5422ad7 is described below

commit d4b5422ad7849cd671d2da93ea5d93718ebdbc8c
Author: andi-huber <ah...@apache.org>
AuthorDate: Fri Sep 8 08:32:24 2023 +0200

    CAUSEWAY-3565: adds withers to ObjectGraph
---
 .../applib/services/metamodel/ObjectGraph.java     | 25 +++++++++++-----------
 1 file changed, 13 insertions(+), 12 deletions(-)

diff --git a/api/applib/src/main/java/org/apache/causeway/applib/services/metamodel/ObjectGraph.java b/api/applib/src/main/java/org/apache/causeway/applib/services/metamodel/ObjectGraph.java
index d9746dd139..3df9f8dda9 100644
--- a/api/applib/src/main/java/org/apache/causeway/applib/services/metamodel/ObjectGraph.java
+++ b/api/applib/src/main/java/org/apache/causeway/applib/services/metamodel/ObjectGraph.java
@@ -29,6 +29,7 @@ import org.springframework.lang.Nullable;
 import org.apache.causeway.commons.internal.collections._Multimaps;
 
 import lombok.NonNull;
+import lombok.With;
 import lombok.val;
 import lombok.experimental.Accessors;
 
@@ -42,27 +43,27 @@ public class ObjectGraph {
 
     @lombok.Value @Accessors(fluent=true)
     public static class Object {
-        private final @NonNull String id;
-        private final @NonNull String packageName;
-        private final @NonNull String name;
-        private final @NonNull Optional<String> stereotype;
+        private final @With @NonNull String id;
+        private final @With @NonNull String packageName;
+        private final @With @NonNull String name;
+        private final @With @NonNull Optional<String> stereotype;
         private final List<ObjectGraph.Field> fields = new ArrayList<>();
     }
 
     @lombok.Value @Accessors(fluent=true)
     public static class Field {
-        private final @NonNull String name;
-        private final @NonNull String elementTypeShortName;
-        private final boolean isPlural;
+        private final @With @NonNull String name;
+        private final @With @NonNull String elementTypeShortName;
+        private final @With boolean isPlural;
     }
 
     @lombok.Value @Accessors(fluent=true)
     public static class Relation {
-        private final @NonNull RelationType relationType;
-        private final @NonNull ObjectGraph.Object from;
-        private final @NonNull ObjectGraph.Object to;
-        private final @NonNull String label;
-        private final @NonNull String label2;
+        private final @With @NonNull RelationType relationType;
+        private final @With @NonNull ObjectGraph.Object from;
+        private final @With @NonNull ObjectGraph.Object to;
+        private final @With @NonNull String label;
+        private final @With @NonNull String label2;
         public String fromId() { return from.id(); }
         public String toId() { return to.id(); }
         public boolean isAssociation() { return relationType!=RelationType.INHERITANCE; }