Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RCNet-V3 #693

Merged
merged 6 commits into from
Aug 31, 2023
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/radixdlt/swift-engine-toolkit",
"state" : {
"branch" : "release/grape",
"revision" : "41786c2d4cee1a4306ede7d4f33bbc37520046b8"
"branch" : "release/rcnet-v3",
"revision" : "2f6fa524e0191acb3c25cc35966cd4d23039886a"
}
},
{
Expand Down
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1026,7 +1026,7 @@ package.addModules([
dependencies: [
"Cryptography",
.product(name: "EngineToolkit", package: "swift-engine-toolkit") {
.package(url: "https://github.com/radixdlt/swift-engine-toolkit", branch: "release/grape")
.package(url: "https://github.com/radixdlt/swift-engine-toolkit", branch: "release/rcnet-v3")
},
],
tests: .no
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,22 +20,18 @@ public struct EntityMetadataCollection: Codable, Hashable {

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [EntityMetadataItem]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [EntityMetadataItem]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [EntityMetadataItem]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -45,7 +41,6 @@ public struct EntityMetadataCollection: Codable, Hashable {
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,22 +20,18 @@ public struct FungibleResourcesCollection: Codable, Hashable {

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [FungibleResourcesCollectionItem]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [FungibleResourcesCollectionItem]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [FungibleResourcesCollectionItem]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -45,7 +41,6 @@ public struct FungibleResourcesCollection: Codable, Hashable {
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,18 @@ public struct FungibleResourcesCollectionItemVaultAggregatedVault: Codable, Hash

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [FungibleResourcesCollectionItemVaultAggregatedVaultItem]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [FungibleResourcesCollectionItemVaultAggregatedVaultItem]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [FungibleResourcesCollectionItemVaultAggregatedVaultItem]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -44,7 +40,6 @@ public struct FungibleResourcesCollectionItemVaultAggregatedVault: Codable, Hash
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,22 +20,18 @@ public struct NonFungibleIdsCollection: Codable, Hashable {

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [String]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [String]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [String]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -45,7 +41,6 @@ public struct NonFungibleIdsCollection: Codable, Hashable {
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,22 +20,18 @@ public struct NonFungibleResourcesCollection: Codable, Hashable {

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [NonFungibleResourcesCollectionItem]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [NonFungibleResourcesCollectionItem]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [NonFungibleResourcesCollectionItem]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -45,7 +41,6 @@ public struct NonFungibleResourcesCollection: Codable, Hashable {
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,18 @@ public struct NonFungibleResourcesCollectionItemVaultAggregatedVault: Codable, H

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [NonFungibleResourcesCollectionItemVaultAggregatedVaultItem]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [NonFungibleResourcesCollectionItemVaultAggregatedVaultItem]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [NonFungibleResourcesCollectionItemVaultAggregatedVaultItem]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -44,7 +40,6 @@ public struct NonFungibleResourcesCollectionItemVaultAggregatedVault: Codable, H
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ extension GatewayAPI {
public struct NonFungibleResourcesCollectionItemVaultAggregatedVaultItem: Codable, Hashable {

public private(set) var totalCount: Int64
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [String]?
Expand All @@ -28,9 +26,8 @@ public struct NonFungibleResourcesCollectionItemVaultAggregatedVaultItem: Codabl
/** TBD */
public private(set) var lastUpdatedAtStateVersion: Int64

public init(totalCount: Int64, previousCursor: String? = nil, nextCursor: String? = nil, items: [String]? = nil, vaultAddress: String, lastUpdatedAtStateVersion: Int64) {
public init(totalCount: Int64, nextCursor: String? = nil, items: [String]? = nil, vaultAddress: String, lastUpdatedAtStateVersion: Int64) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
self.vaultAddress = vaultAddress
Expand All @@ -39,7 +36,6 @@ public struct NonFungibleResourcesCollectionItemVaultAggregatedVaultItem: Codabl

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
case vaultAddress = "vault_address"
Expand All @@ -51,7 +47,6 @@ public struct NonFungibleResourcesCollectionItemVaultAggregatedVaultItem: Codabl
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encode(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encodeIfPresent(items, forKey: .items)
try container.encode(vaultAddress, forKey: .vaultAddress)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,22 +20,18 @@ public struct OptionalNonFungibleIdsCollection: Codable, Hashable {

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [String]?

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [String]? = nil) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [String]? = nil) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -45,7 +41,6 @@ public struct OptionalNonFungibleIdsCollection: Codable, Hashable {
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encodeIfPresent(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,16 @@ public struct ResultSetCursorMixin: Codable, Hashable {

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
}

Expand All @@ -41,7 +37,6 @@ public struct ResultSetCursorMixin: Codable, Hashable {
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,18 @@ public struct StateEntityDetailsResponsePackageDetailsBlueprintCollection: Codab

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [StateEntityDetailsResponsePackageDetailsBlueprintItem]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [StateEntityDetailsResponsePackageDetailsBlueprintItem]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [StateEntityDetailsResponsePackageDetailsBlueprintItem]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -44,7 +40,6 @@ public struct StateEntityDetailsResponsePackageDetailsBlueprintCollection: Codab
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,18 @@ public struct StateEntityDetailsResponsePackageDetailsSchemaCollection: Codable,

/** Total number of items in underlying collection, fragment of which is available in `items` collection. */
public private(set) var totalCount: Int64?
/** If specified, contains a cursor to query previous page of the `items` collection. */
public private(set) var previousCursor: String?
/** If specified, contains a cursor to query next page of the `items` collection. */
public private(set) var nextCursor: String?
public private(set) var items: [StateEntityDetailsResponsePackageDetailsSchemaItem]

public init(totalCount: Int64? = nil, previousCursor: String? = nil, nextCursor: String? = nil, items: [StateEntityDetailsResponsePackageDetailsSchemaItem]) {
public init(totalCount: Int64? = nil, nextCursor: String? = nil, items: [StateEntityDetailsResponsePackageDetailsSchemaItem]) {
self.totalCount = totalCount
self.previousCursor = previousCursor
self.nextCursor = nextCursor
self.items = items
}

public enum CodingKeys: String, CodingKey, CaseIterable {
case totalCount = "total_count"
case previousCursor = "previous_cursor"
case nextCursor = "next_cursor"
case items
}
Expand All @@ -44,7 +40,6 @@ public struct StateEntityDetailsResponsePackageDetailsSchemaCollection: Codable,
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(totalCount, forKey: .totalCount)
try container.encodeIfPresent(previousCursor, forKey: .previousCursor)
try container.encodeIfPresent(nextCursor, forKey: .nextCursor)
try container.encode(items, forKey: .items)
}
Expand Down
Loading
Loading