Skip to content

Commit

Permalink
Remove hash named property from generated code sample
Browse files Browse the repository at this point in the history
  • Loading branch information
calvincestari committed Oct 26, 2022
1 parent b678124 commit 99f9e02
Show file tree
Hide file tree
Showing 53 changed files with 0 additions and 239 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,11 @@ public class AllAnimalsLocalCacheMutation: LocalCacheMutation {

public static var __parentType: ParentType { AnimalKingdomAPI.Interfaces.Animal }
public static var __selections: [Selection] { [
.field("hash", String?.self),
.field("species", String.self),
.field("skinCovering", GraphQLEnum<SkinCovering>?.self),
.inlineFragment(AsBird.self),
] }

public var hash: String? {
get { __data["hash"] }
set { __data["hash"] = newValue }
}
public var species: String {
get { __data["species"] }
set { __data["species"] = newValue }
Expand Down Expand Up @@ -71,10 +66,6 @@ public class AllAnimalsLocalCacheMutation: LocalCacheMutation {
get { __data["wingspan"] }
set { __data["wingspan"] = newValue }
}
public var hash: String? {
get { __data["hash"] }
set { __data["hash"] = newValue }
}
public var species: String {
get { __data["species"] }
set { __data["species"] = newValue }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ public class AllAnimalsQuery: GraphQLQuery {
}
...HeightInMeters
...WarmBloodedDetails
hash
species
skinCovering
... on Pet {
Expand Down Expand Up @@ -81,7 +80,6 @@ public class AllAnimalsQuery: GraphQLQuery {
public static var __parentType: ParentType { AnimalKingdomAPI.Interfaces.Animal }
public static var __selections: [Selection] { [
.field("height", Height.self),
.field("hash", String?.self),
.field("species", String.self),
.field("skinCovering", GraphQLEnum<SkinCovering>?.self),
.field("predators", [Predator].self),
Expand All @@ -94,7 +92,6 @@ public class AllAnimalsQuery: GraphQLQuery {
] }

public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down Expand Up @@ -188,7 +185,6 @@ public class AllAnimalsQuery: GraphQLQuery {
] }

public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down Expand Up @@ -232,7 +228,6 @@ public class AllAnimalsQuery: GraphQLQuery {
] }

public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down Expand Up @@ -283,7 +278,6 @@ public class AllAnimalsQuery: GraphQLQuery {
] }

public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down Expand Up @@ -333,7 +327,6 @@ public class AllAnimalsQuery: GraphQLQuery {

public var isJellicle: Bool { __data["isJellicle"] }
public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down Expand Up @@ -381,7 +374,6 @@ public class AllAnimalsQuery: GraphQLQuery {
] }

public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down Expand Up @@ -423,7 +415,6 @@ public class AllAnimalsQuery: GraphQLQuery {

public var wingspan: Double { __data["wingspan"] }
public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down Expand Up @@ -475,7 +466,6 @@ public class AllAnimalsQuery: GraphQLQuery {
public var favoriteToy: String { __data["favoriteToy"] }
public var birthdate: CustomDate? { __data["birthdate"] }
public var height: Height { __data["height"] }
public var hash: String? { __data["hash"] }
public var species: String { __data["species"] }
public var skinCovering: GraphQLEnum<SkinCovering>? { __data["skinCovering"] }
public var predators: [Predator] { __data["predators"] }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,17 @@ public struct PetSearchFilters: InputObject {
}

public init(
hash: GraphQLNullable<String> = nil,
species: [String],
size: GraphQLNullable<GraphQLEnum<RelativeSize>> = nil,
measurements: GraphQLNullable<MeasurementsInput> = nil
) {
__data = InputDict([
"hash": hash,
"species": species,
"size": size,
"measurements": measurements
])
}

public var hash: GraphQLNullable<String> {
get { __data["hash"] }
set { __data["hash"] = newValue }
}

public var species: [String] {
get { __data["species"] }
set { __data["species"] = newValue }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ public class Bird: MockObject {
public struct MockFields {
@Field<Int>("bodyTemperature") public var bodyTemperature
@Field<String>("favoriteToy") public var favoriteToy
@Field<String>("hash") public var hash
@Field<Height>("height") public var height
@Field<String>("humanName") public var humanName
@Field<ID>("id") public var id
Expand All @@ -29,7 +28,6 @@ public extension Mock where O == Bird {
convenience init(
bodyTemperature: Int? = nil,
favoriteToy: String? = nil,
hash: String? = nil,
height: Mock<Height>? = nil,
humanName: String? = nil,
id: ID? = nil,
Expand All @@ -43,7 +41,6 @@ public extension Mock where O == Bird {
self.init()
self.bodyTemperature = bodyTemperature
self.favoriteToy = favoriteToy
self.hash = hash
self.height = height
self.humanName = humanName
self.id = id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ public class Cat: MockObject {
public struct MockFields {
@Field<Int>("bodyTemperature") public var bodyTemperature
@Field<String>("favoriteToy") public var favoriteToy
@Field<String>("hash") public var hash
@Field<Height>("height") public var height
@Field<String>("humanName") public var humanName
@Field<ID>("id") public var id
Expand All @@ -29,7 +28,6 @@ public extension Mock where O == Cat {
convenience init(
bodyTemperature: Int? = nil,
favoriteToy: String? = nil,
hash: String? = nil,
height: Mock<Height>? = nil,
humanName: String? = nil,
id: ID? = nil,
Expand All @@ -43,7 +41,6 @@ public extension Mock where O == Cat {
self.init()
self.bodyTemperature = bodyTemperature
self.favoriteToy = favoriteToy
self.hash = hash
self.height = height
self.humanName = humanName
self.id = id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ public class Crocodile: MockObject {
public typealias MockValueCollectionType = Array<Mock<Crocodile>>

public struct MockFields {
@Field<String>("hash") public var hash
@Field<Height>("height") public var height
@Field<ID>("id") public var id
@Field<[Animal]>("predators") public var predators
Expand All @@ -21,15 +20,13 @@ public class Crocodile: MockObject {

public extension Mock where O == Crocodile {
convenience init(
hash: String? = nil,
height: Mock<Height>? = nil,
id: ID? = nil,
predators: [AnyMock]? = nil,
skinCovering: GraphQLEnum<SkinCovering>? = nil,
species: String? = nil
) {
self.init()
self.hash = hash
self.height = height
self.id = id
self.predators = predators
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ public class Dog: MockObject {
@Field<CustomDate>("birthdate") public var birthdate
@Field<Int>("bodyTemperature") public var bodyTemperature
@Field<String>("favoriteToy") public var favoriteToy
@Field<String>("hash") public var hash
@Field<Height>("height") public var height
@Field<String>("humanName") public var humanName
@Field<ID>("id") public var id
Expand All @@ -30,7 +29,6 @@ public extension Mock where O == Dog {
birthdate: CustomDate? = nil,
bodyTemperature: Int? = nil,
favoriteToy: String? = nil,
hash: String? = nil,
height: Mock<Height>? = nil,
humanName: String? = nil,
id: ID? = nil,
Expand All @@ -44,7 +42,6 @@ public extension Mock where O == Dog {
self.birthdate = birthdate
self.bodyTemperature = bodyTemperature
self.favoriteToy = favoriteToy
self.hash = hash
self.height = height
self.humanName = humanName
self.id = id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ public class Fish: MockObject {

public struct MockFields {
@Field<String>("favoriteToy") public var favoriteToy
@Field<String>("hash") public var hash
@Field<Height>("height") public var height
@Field<String>("humanName") public var humanName
@Field<ID>("id") public var id
Expand All @@ -25,7 +24,6 @@ public class Fish: MockObject {
public extension Mock where O == Fish {
convenience init(
favoriteToy: String? = nil,
hash: String? = nil,
height: Mock<Height>? = nil,
humanName: String? = nil,
id: ID? = nil,
Expand All @@ -36,7 +34,6 @@ public extension Mock where O == Fish {
) {
self.init()
self.favoriteToy = favoriteToy
self.hash = hash
self.height = height
self.humanName = humanName
self.id = id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ public class Human: MockObject {
public struct MockFields {
@Field<Int>("bodyTemperature") public var bodyTemperature
@Field<String>("firstName") public var firstName
@Field<String>("hash") public var hash
@Field<Height>("height") public var height
@Field<ID>("id") public var id
@Field<Bool>("laysEggs") public var laysEggs
Expand All @@ -26,7 +25,6 @@ public extension Mock where O == Human {
convenience init(
bodyTemperature: Int? = nil,
firstName: String? = nil,
hash: String? = nil,
height: Mock<Height>? = nil,
id: ID? = nil,
laysEggs: Bool? = nil,
Expand All @@ -37,7 +35,6 @@ public extension Mock where O == Human {
self.init()
self.bodyTemperature = bodyTemperature
self.firstName = firstName
self.hash = hash
self.height = height
self.id = id
self.laysEggs = laysEggs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ public class Rat: MockObject {

public struct MockFields {
@Field<String>("favoriteToy") public var favoriteToy
@Field<String>("hash") public var hash
@Field<Height>("height") public var height
@Field<String>("humanName") public var humanName
@Field<ID>("id") public var id
Expand All @@ -25,7 +24,6 @@ public class Rat: MockObject {
public extension Mock where O == Rat {
convenience init(
favoriteToy: String? = nil,
hash: String? = nil,
height: Mock<Height>? = nil,
humanName: String? = nil,
id: ID? = nil,
Expand All @@ -36,7 +34,6 @@ public extension Mock where O == Rat {
) {
self.init()
self.favoriteToy = favoriteToy
self.hash = hash
self.height = height
self.humanName = humanName
self.id = id
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
query AllAnimalsLocalCacheMutation
@apollo_client_ios_localCacheMutation {
allAnimals {
hash
species
skinCovering
... on Bird {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ query AllAnimalsQuery {
}
...HeightInMeters
...WarmBloodedDetails
hash
species
skinCovering
... on Pet {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,13 @@ input MeasurementsInput {
}

input PetSearchFilters {
hash: String
species: [String!]!
size: RelativeSize
measurements: MeasurementsInput
}

interface Animal {
id: ID!
hash: String
species: String!
height: Height!
predators: [Animal!]!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,11 @@ public extension MyGraphQLSchema {

public static var __parentType: ParentType { MyGraphQLSchema.Interfaces.Animal }
public static var __selections: [Selection] { [
.field("hash", String?.self),
.field("species", String.self),
.field("skinCovering", GraphQLEnum<SkinCovering>?.self),
.inlineFragment(AsBird.self),
] }

public var hash: String? {
get { __data["hash"] }
set { __data["hash"] = newValue }
}
public var species: String {
get { __data["species"] }
set { __data["species"] = newValue }
Expand Down Expand Up @@ -72,10 +67,6 @@ public extension MyGraphQLSchema {
get { __data["wingspan"] }
set { __data["wingspan"] = newValue }
}
public var hash: String? {
get { __data["hash"] }
set { __data["hash"] = newValue }
}
public var species: String {
get { __data["species"] }
set { __data["species"] = newValue }
Expand Down
Loading

0 comments on commit 99f9e02

Please sign in to comment.