This is an automated email from the ASF dual-hosted git repository. danhaywood pushed a commit to branch CAUSEWAY-3676 in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 50a218ca4b621c5ef28091c72890ab7796315bce Author: danhaywood <[email protected]> AuthorDate: Sun Jan 21 14:28:50 2024 +0000 CAUSEWAY-3676: renames mutation type --- .../viewer/graphql/model/domain/GqlvMutations.java | 2 +- .../viewer/graphql/model/util/TypeNames.java | 4 +- .../test/e2e/Schema_IntegTest.schema.approved.json | 44 +++++++++++----------- ...chema_IntegTest.schema_types_name.approved.json | 22 +++++------ .../graphql/test/src/test/resources/schema.gql | 44 +++++++++++----------- 5 files changed, 58 insertions(+), 58 deletions(-) diff --git a/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/domain/GqlvMutations.java b/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/domain/GqlvMutations.java index 76a489c306..d5320aa02e 100644 --- a/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/domain/GqlvMutations.java +++ b/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/domain/GqlvMutations.java @@ -34,7 +34,7 @@ public class GqlvMutations implements GqlvActionHolder { this.holder = holder; this.codeRegistryBuilder = codeRegistryBuilder; - objectTypeBuilder = newObject().name(TypeNames.mutatorTypeNameFor(this.holder.getObjectSpecification())); + objectTypeBuilder = newObject().name(TypeNames.mutationsTypeNameFor(this.holder.getObjectSpecification())); } diff --git a/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/util/TypeNames.java b/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/util/TypeNames.java index 3ba5b46d7a..b34420cb24 100644 --- a/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/util/TypeNames.java +++ b/incubator/viewers/graphql/model/src/main/java/org/apache/causeway/viewer/graphql/model/util/TypeNames.java @@ -33,8 +33,8 @@ public final class TypeNames { return objectTypeNameFor(objectSpecification) + "__meta"; } - public static String mutatorTypeNameFor(ObjectSpecification objectSpecification) { - return objectTypeNameFor(objectSpecification) + "__mutators"; + public static String mutationsTypeNameFor(ObjectSpecification objectSpecification) { + return objectTypeNameFor(objectSpecification) + "__mutations"; } public static String inputTypeNameFor(ObjectSpecification objectSpecification) { diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json index 30558e24a8..48597cbcc3 100644 --- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json +++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json @@ -1370,7 +1370,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "causeway_applib_PropertyNode__mutators", + "name" : "causeway_applib_PropertyNode__mutations", "ofType" : null }, "isDeprecated" : false, @@ -1443,7 +1443,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "causeway_applib_PropertyNode__mutators", + "name" : "causeway_applib_PropertyNode__mutations", "description" : null, "fields" : [ { "name" : "streamChildNodes", @@ -1976,7 +1976,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "causeway_applib_node_ActionNode__mutators", + "name" : "causeway_applib_node_ActionNode__mutations", "ofType" : null }, "isDeprecated" : false, @@ -2049,7 +2049,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "causeway_applib_node_ActionNode__mutators", + "name" : "causeway_applib_node_ActionNode__mutations", "description" : null, "fields" : [ { "name" : "streamChildNodes", @@ -2133,7 +2133,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "causeway_applib_node_CollectionNode__mutators", + "name" : "causeway_applib_node_CollectionNode__mutations", "ofType" : null }, "isDeprecated" : false, @@ -2206,7 +2206,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "causeway_applib_node_CollectionNode__mutators", + "name" : "causeway_applib_node_CollectionNode__mutations", "description" : null, "fields" : [ { "name" : "streamChildNodes", @@ -4872,7 +4872,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_Either__mutators", + "name" : "org_apache_causeway_commons_functional_Either__mutations", "ofType" : null }, "isDeprecated" : false, @@ -4945,7 +4945,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_Either__mutators", + "name" : "org_apache_causeway_commons_functional_Either__mutations", "description" : null, "fields" : [ { "name" : "accept", @@ -5147,7 +5147,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_Railway__mutators", + "name" : "org_apache_causeway_commons_functional_Railway__mutations", "ofType" : null }, "isDeprecated" : false, @@ -5220,7 +5220,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_Railway__mutators", + "name" : "org_apache_causeway_commons_functional_Railway__mutations", "description" : null, "fields" : [ { "name" : "chain", @@ -5368,7 +5368,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__mutators", + "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__mutations", "ofType" : null }, "isDeprecated" : false, @@ -5441,7 +5441,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__mutators", + "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__mutations", "description" : null, "fields" : [ { "name" : "andThen", @@ -5517,7 +5517,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_ThrowingFunction__mutators", + "name" : "org_apache_causeway_commons_functional_ThrowingFunction__mutations", "ofType" : null }, "isDeprecated" : false, @@ -5590,7 +5590,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_ThrowingFunction__mutators", + "name" : "org_apache_causeway_commons_functional_ThrowingFunction__mutations", "description" : null, "fields" : [ { "name" : "andThen", @@ -5690,7 +5690,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__mutators", + "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__mutations", "ofType" : null }, "isDeprecated" : false, @@ -5763,7 +5763,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__mutators", + "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__mutations", "description" : null, "fields" : [ { "name" : "callUncatched", @@ -5876,7 +5876,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_Try__mutators", + "name" : "org_apache_causeway_commons_functional_Try__mutations", "ofType" : null }, "isDeprecated" : false, @@ -5949,7 +5949,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "org_apache_causeway_commons_functional_Try__mutators", + "name" : "org_apache_causeway_commons_functional_Try__mutations", "description" : null, "fields" : [ { "name" : "accept", @@ -6555,7 +6555,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutators", + "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutations", "ofType" : null }, "isDeprecated" : false, @@ -6628,7 +6628,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutators", + "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutations", "description" : null, "fields" : [ { "name" : "streamChildNodes", @@ -6975,7 +6975,7 @@ "args" : [ ], "type" : { "kind" : "OBJECT", - "name" : "university_dept_DeptHead__mutators", + "name" : "university_dept_DeptHead__mutations", "ofType" : null }, "isDeprecated" : false, @@ -7107,7 +7107,7 @@ "possibleTypes" : null }, { "kind" : "OBJECT", - "name" : "university_dept_DeptHead__mutators", + "name" : "university_dept_DeptHead__mutations", "description" : null, "fields" : [ { "name" : "changeDepartment", diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json index 187c044465..034a8b2a25 100644 --- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json +++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json @@ -52,7 +52,7 @@ }, { "name" : "causeway_applib_PropertyNode__meta" }, { - "name" : "causeway_applib_PropertyNode__mutators" + "name" : "causeway_applib_PropertyNode__mutations" }, { "name" : "causeway_applib_RoleMemento" }, { @@ -80,7 +80,7 @@ }, { "name" : "causeway_applib_node_ActionNode__meta" }, { - "name" : "causeway_applib_node_ActionNode__mutators" + "name" : "causeway_applib_node_ActionNode__mutations" }, { "name" : "causeway_applib_node_CollectionNode" }, { @@ -88,7 +88,7 @@ }, { "name" : "causeway_applib_node_CollectionNode__meta" }, { - "name" : "causeway_applib_node_CollectionNode__mutators" + "name" : "causeway_applib_node_CollectionNode__mutations" }, { "name" : "causeway_applib_node_FacetAttrNode" }, { @@ -232,7 +232,7 @@ }, { "name" : "org_apache_causeway_commons_functional_Either__meta" }, { - "name" : "org_apache_causeway_commons_functional_Either__mutators" + "name" : "org_apache_causeway_commons_functional_Either__mutations" }, { "name" : "org_apache_causeway_commons_functional_Railway" }, { @@ -240,7 +240,7 @@ }, { "name" : "org_apache_causeway_commons_functional_Railway__meta" }, { - "name" : "org_apache_causeway_commons_functional_Railway__mutators" + "name" : "org_apache_causeway_commons_functional_Railway__mutations" }, { "name" : "org_apache_causeway_commons_functional_ThrowingConsumer" }, { @@ -248,7 +248,7 @@ }, { "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__meta" }, { - "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__mutators" + "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__mutations" }, { "name" : "org_apache_causeway_commons_functional_ThrowingFunction" }, { @@ -256,7 +256,7 @@ }, { "name" : "org_apache_causeway_commons_functional_ThrowingFunction__meta" }, { - "name" : "org_apache_causeway_commons_functional_ThrowingFunction__mutators" + "name" : "org_apache_causeway_commons_functional_ThrowingFunction__mutations" }, { "name" : "org_apache_causeway_commons_functional_ThrowingRunnable" }, { @@ -264,7 +264,7 @@ }, { "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__meta" }, { - "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__mutators" + "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__mutations" }, { "name" : "org_apache_causeway_commons_functional_Try" }, { @@ -272,7 +272,7 @@ }, { "name" : "org_apache_causeway_commons_functional_Try__meta" }, { - "name" : "org_apache_causeway_commons_functional_Try__mutators" + "name" : "org_apache_causeway_commons_functional_Try__mutations" }, { "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode" }, { @@ -286,7 +286,7 @@ }, { "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__meta" }, { - "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutators" + "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutations" }, { "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript" }, { @@ -310,7 +310,7 @@ }, { "name" : "university_dept_DeptHead__meta" }, { - "name" : "university_dept_DeptHead__mutators" + "name" : "university_dept_DeptHead__mutations" } ] } } diff --git a/incubator/viewers/graphql/test/src/test/resources/schema.gql b/incubator/viewers/graphql/test/src/test/resources/schema.gql index e2cc0124de..0bbeabb0c6 100644 --- a/incubator/viewers/graphql/test/src/test/resources/schema.gql +++ b/incubator/viewers/graphql/test/src/test/resources/schema.gql @@ -68,7 +68,7 @@ type causeway_applib_ParameterNode__meta { type causeway_applib_PropertyNode { _gql_meta: causeway_applib_PropertyNode__meta - _gql_mutations: causeway_applib_PropertyNode__mutators + _gql_mutations: causeway_applib_PropertyNode__mutations mixedIn: String! parentNode: causeway_applib_TypeNode! property: String! @@ -79,7 +79,7 @@ type causeway_applib_PropertyNode__meta { logicalTypeName: String! } -type causeway_applib_PropertyNode__mutators { +type causeway_applib_PropertyNode__mutations { streamChildNodes: java_util_stream_Stream } @@ -130,7 +130,7 @@ type causeway_applib_UserMenu { type causeway_applib_node_ActionNode { _gql_meta: causeway_applib_node_ActionNode__meta - _gql_mutations: causeway_applib_node_ActionNode__mutators + _gql_mutations: causeway_applib_node_ActionNode__mutations action: String! mixedIn: String! parentNode: causeway_applib_TypeNode! @@ -141,13 +141,13 @@ type causeway_applib_node_ActionNode__meta { logicalTypeName: String! } -type causeway_applib_node_ActionNode__mutators { +type causeway_applib_node_ActionNode__mutations { streamChildNodes: java_util_stream_Stream } type causeway_applib_node_CollectionNode { _gql_meta: causeway_applib_node_CollectionNode__meta - _gql_mutations: causeway_applib_node_CollectionNode__mutators + _gql_mutations: causeway_applib_node_CollectionNode__mutations collection: String! mixedIn: String! parentNode: causeway_applib_TypeNode! @@ -158,7 +158,7 @@ type causeway_applib_node_CollectionNode__meta { logicalTypeName: String! } -type causeway_applib_node_CollectionNode__mutators { +type causeway_applib_node_CollectionNode__mutations { streamChildNodes: java_util_stream_Stream } @@ -423,7 +423,7 @@ type java_util_stream_Stream__meta { type org_apache_causeway_commons_functional_Either { _gql_meta: org_apache_causeway_commons_functional_Either__meta - _gql_mutations: org_apache_causeway_commons_functional_Either__mutators + _gql_mutations: org_apache_causeway_commons_functional_Either__mutations left: String! right: String! } @@ -433,7 +433,7 @@ type org_apache_causeway_commons_functional_Either__meta { logicalTypeName: String! } -type org_apache_causeway_commons_functional_Either__mutators { +type org_apache_causeway_commons_functional_Either__mutations { accept(leftConsumer: java_util_function_Consumer__input!, rightConsumer: java_util_function_Consumer__input!): String left: String map(leftMapper: java_util_function_Function__input!, rightMapper: java_util_function_Function__input!): org_apache_causeway_commons_functional_Either @@ -444,7 +444,7 @@ type org_apache_causeway_commons_functional_Either__mutators { type org_apache_causeway_commons_functional_Railway { _gql_meta: org_apache_causeway_commons_functional_Railway__meta - _gql_mutations: org_apache_causeway_commons_functional_Railway__mutators + _gql_mutations: org_apache_causeway_commons_functional_Railway__mutations failure: String! success: String! } @@ -454,7 +454,7 @@ type org_apache_causeway_commons_functional_Railway__meta { logicalTypeName: String! } -type org_apache_causeway_commons_functional_Railway__mutators { +type org_apache_causeway_commons_functional_Railway__mutations { chain(chainingFunction: org_apache_causeway_commons_functional_ThrowingFunction__input!): org_apache_causeway_commons_functional_Railway ifFailure(failureConsumer: org_apache_causeway_commons_functional_ThrowingConsumer__input!): org_apache_causeway_commons_functional_Railway ifSuccess(successConsumer: org_apache_causeway_commons_functional_ThrowingConsumer__input!): org_apache_causeway_commons_functional_Railway @@ -464,7 +464,7 @@ type org_apache_causeway_commons_functional_Railway__mutators { type org_apache_causeway_commons_functional_ThrowingConsumer { _gql_meta: org_apache_causeway_commons_functional_ThrowingConsumer__meta - _gql_mutations: org_apache_causeway_commons_functional_ThrowingConsumer__mutators + _gql_mutations: org_apache_causeway_commons_functional_ThrowingConsumer__mutations } type org_apache_causeway_commons_functional_ThrowingConsumer__meta { @@ -472,14 +472,14 @@ type org_apache_causeway_commons_functional_ThrowingConsumer__meta { logicalTypeName: String! } -type org_apache_causeway_commons_functional_ThrowingConsumer__mutators { +type org_apache_causeway_commons_functional_ThrowingConsumer__mutations { andThen(arg0: java_util_function_Consumer__input!): java_util_function_Consumer throwing(exceptionWrapper: java_util_function_BiFunction__input!): org_apache_causeway_commons_functional_ThrowingConsumer } type org_apache_causeway_commons_functional_ThrowingFunction { _gql_meta: org_apache_causeway_commons_functional_ThrowingFunction__meta - _gql_mutations: org_apache_causeway_commons_functional_ThrowingFunction__mutators + _gql_mutations: org_apache_causeway_commons_functional_ThrowingFunction__mutations } type org_apache_causeway_commons_functional_ThrowingFunction__meta { @@ -487,7 +487,7 @@ type org_apache_causeway_commons_functional_ThrowingFunction__meta { logicalTypeName: String! } -type org_apache_causeway_commons_functional_ThrowingFunction__mutators { +type org_apache_causeway_commons_functional_ThrowingFunction__mutations { andThen(arg0: java_util_function_Function__input!): java_util_function_Function compose(arg0: java_util_function_Function__input!): java_util_function_Function throwing(exceptionWrapper: java_util_function_BiFunction__input!): org_apache_causeway_commons_functional_ThrowingFunction @@ -495,7 +495,7 @@ type org_apache_causeway_commons_functional_ThrowingFunction__mutators { type org_apache_causeway_commons_functional_ThrowingRunnable { _gql_meta: org_apache_causeway_commons_functional_ThrowingRunnable__meta - _gql_mutations: org_apache_causeway_commons_functional_ThrowingRunnable__mutators + _gql_mutations: org_apache_causeway_commons_functional_ThrowingRunnable__mutations } type org_apache_causeway_commons_functional_ThrowingRunnable__meta { @@ -503,7 +503,7 @@ type org_apache_causeway_commons_functional_ThrowingRunnable__meta { logicalTypeName: String! } -type org_apache_causeway_commons_functional_ThrowingRunnable__mutators { +type org_apache_causeway_commons_functional_ThrowingRunnable__mutations { callUncatched: String run: String runUncatched: String @@ -513,7 +513,7 @@ type org_apache_causeway_commons_functional_ThrowingRunnable__mutators { type org_apache_causeway_commons_functional_Try { _gql_meta: org_apache_causeway_commons_functional_Try__meta - _gql_mutations: org_apache_causeway_commons_functional_Try__mutators + _gql_mutations: org_apache_causeway_commons_functional_Try__mutations failure: String! success: String! } @@ -523,7 +523,7 @@ type org_apache_causeway_commons_functional_Try__meta { logicalTypeName: String! } -type org_apache_causeway_commons_functional_Try__mutators { +type org_apache_causeway_commons_functional_Try__mutations { accept(failureConsumer: org_apache_causeway_commons_functional_ThrowingConsumer__input!, successConsumer: org_apache_causeway_commons_functional_ThrowingConsumer__input!): org_apache_causeway_commons_functional_Try flatMapSuccess(successMapper: org_apache_causeway_commons_functional_ThrowingFunction__input!): org_apache_causeway_commons_functional_Try flatMapSuccessAsNullable(successMapper: org_apache_causeway_commons_functional_ThrowingFunction__input!): org_apache_causeway_commons_functional_Try @@ -557,7 +557,7 @@ type org_apache_causeway_core_metamodel_inspect_model_MMNode__meta { type org_apache_causeway_core_metamodel_inspect_model_MemberNode { _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MemberNode__meta - _gql_mutations: org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutators + _gql_mutations: org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutations mixedIn: String! parentNode: causeway_applib_TypeNode! } @@ -567,7 +567,7 @@ type org_apache_causeway_core_metamodel_inspect_model_MemberNode__meta { logicalTypeName: String! } -type org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutators { +type org_apache_causeway_core_metamodel_inspect_model_MemberNode__mutations { streamChildNodes: java_util_stream_Stream } @@ -601,7 +601,7 @@ type university_dept_Department__meta { type university_dept_DeptHead { _gql_meta: university_dept_DeptHead__meta - _gql_mutations: university_dept_DeptHead__mutators + _gql_mutations: university_dept_DeptHead__mutations department: university_dept_Department name: String } @@ -617,7 +617,7 @@ type university_dept_DeptHead__meta { version: String } -type university_dept_DeptHead__mutators { +type university_dept_DeptHead__mutations { changeDepartment(department: university_dept_Department__input!): university_dept_DeptHead changeName(newName: String!): university_dept_DeptHead }
