@akashnetwork/chain-sdk 1.0.0-alpha.30 → 1.0.0-alpha.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (163) hide show
  1. package/dist/cjs/bla.cjs +7 -0
  2. package/dist/cjs/bla.cjs.map +7 -0
  3. package/dist/cjs/generated/createNodeSDK.cjs +95 -76
  4. package/dist/cjs/generated/createNodeSDK.cjs.map +2 -2
  5. package/dist/cjs/generated/protos/akash/bme/v1/params.cjs +18 -2
  6. package/dist/cjs/generated/protos/akash/bme/v1/params.cjs.map +2 -2
  7. package/dist/cjs/generated/protos/akash/bme/v1/types.cjs +65 -2
  8. package/dist/cjs/generated/protos/akash/bme/v1/types.cjs.map +2 -2
  9. package/dist/cjs/generated/protos/akash/deployment/v1/deployment.cjs +68 -2
  10. package/dist/cjs/generated/protos/akash/deployment/v1/deployment.cjs.map +2 -2
  11. package/dist/cjs/generated/protos/akash/deployment/v1beta4/deploymentmsg.cjs +17 -2
  12. package/dist/cjs/generated/protos/akash/deployment/v1beta4/deploymentmsg.cjs.map +2 -2
  13. package/dist/cjs/generated/protos/akash/discovery/v1/akash.cjs +64 -2
  14. package/dist/cjs/generated/protos/akash/discovery/v1/akash.cjs.map +2 -2
  15. package/dist/cjs/generated/protos/akash/discovery/v1/client_info.cjs +150 -1
  16. package/dist/cjs/generated/protos/akash/discovery/v1/client_info.cjs.map +2 -2
  17. package/dist/cjs/generated/protos/akash/discovery/v1/service.cjs +115 -0
  18. package/dist/cjs/generated/protos/akash/discovery/v1/service.cjs.map +7 -0
  19. package/dist/cjs/generated/protos/akash/discovery/v1/service_akash.cjs +39 -0
  20. package/dist/cjs/generated/protos/akash/discovery/v1/service_akash.cjs.map +7 -0
  21. package/dist/cjs/generated/protos/akash/market/v1/event.cjs +93 -0
  22. package/dist/cjs/generated/protos/akash/market/v1/event.cjs.map +3 -3
  23. package/dist/cjs/generated/protos/akash/market/v1/lease.cjs +32 -2
  24. package/dist/cjs/generated/protos/akash/market/v1/lease.cjs.map +2 -2
  25. package/dist/cjs/generated/protos/akash/market/v1/reclamation.cjs +138 -0
  26. package/dist/cjs/generated/protos/akash/market/v1/reclamation.cjs.map +7 -0
  27. package/dist/cjs/generated/protos/akash/market/v1beta5/bid.cjs +25 -2
  28. package/dist/cjs/generated/protos/akash/market/v1beta5/bid.cjs.map +2 -2
  29. package/dist/cjs/generated/protos/akash/market/v1beta5/bidmsg.cjs +18 -2
  30. package/dist/cjs/generated/protos/akash/market/v1beta5/bidmsg.cjs.map +2 -2
  31. package/dist/cjs/generated/protos/akash/market/v1beta5/leasemsg.cjs +103 -0
  32. package/dist/cjs/generated/protos/akash/market/v1beta5/leasemsg.cjs.map +2 -2
  33. package/dist/cjs/generated/protos/akash/market/v1beta5/order.cjs +18 -2
  34. package/dist/cjs/generated/protos/akash/market/v1beta5/order.cjs.map +2 -2
  35. package/dist/cjs/generated/protos/akash/market/v1beta5/params.cjs +39 -2
  36. package/dist/cjs/generated/protos/akash/market/v1beta5/params.cjs.map +2 -2
  37. package/dist/cjs/generated/protos/akash/market/v1beta5/service_akash.cjs +8 -0
  38. package/dist/cjs/generated/protos/akash/market/v1beta5/service_akash.cjs.map +2 -2
  39. package/dist/cjs/generated/protos/index.akash.v1.cjs +9 -0
  40. package/dist/cjs/generated/protos/index.akash.v1.cjs.map +2 -2
  41. package/dist/cjs/generated/protos/index.akash.v1beta5.cjs +2 -0
  42. package/dist/cjs/generated/protos/index.akash.v1beta5.cjs.map +2 -2
  43. package/dist/cjs/network/config.cjs +3 -7
  44. package/dist/cjs/network/config.cjs.map +2 -2
  45. package/dist/cjs/sdk/provider/auth/jwt/types.cjs.map +1 -1
  46. package/dist/cjs/sdk/provider/auth/jwt/validateJwtPayload.cjs +1058 -1259
  47. package/dist/cjs/sdk/provider/auth/jwt/validateJwtPayload.cjs.map +2 -2
  48. package/dist/cjs/sdl/index.cjs +0 -4
  49. package/dist/cjs/sdl/index.cjs.map +2 -2
  50. package/dist/cjs/sdl/manifest/generateManifest.cjs +2 -3
  51. package/dist/cjs/sdl/manifest/generateManifest.cjs.map +2 -2
  52. package/dist/cjs/sdl/validateSDL/validateSDL.cjs +4 -36
  53. package/dist/cjs/sdl/validateSDL/validateSDL.cjs.map +2 -2
  54. package/dist/cjs/sdl/validateSDL/validateSDLInput.cjs +49 -50
  55. package/dist/cjs/sdl/validateSDL/validateSDLInput.cjs.map +2 -2
  56. package/dist/cjs/test.cjs +2 -0
  57. package/dist/cjs/test.cjs.map +7 -0
  58. package/dist/esm/{chunk-JAPXWQ3D.js → chunk-7XWZXYD2.js} +2 -2
  59. package/dist/esm/{chunk-5RTSSO7K.js → chunk-B7H4H62Z.js} +3 -3
  60. package/dist/esm/chunk-E4KEMLL4.js +413 -0
  61. package/dist/esm/chunk-E4KEMLL4.js.map +7 -0
  62. package/dist/esm/{chunk-H5WUFEMM.js → chunk-EG6EVQGI.js} +23 -5
  63. package/dist/esm/chunk-EG6EVQGI.js.map +7 -0
  64. package/dist/esm/{chunk-5YIS3XNX.js → chunk-EXKSXOV2.js} +2 -2
  65. package/dist/esm/{chunk-TXQ2BR6G.js → chunk-IFAXXMON.js} +126 -5
  66. package/dist/esm/chunk-IFAXXMON.js.map +7 -0
  67. package/dist/esm/chunk-IMR6WS6F.js +93 -0
  68. package/dist/esm/chunk-IMR6WS6F.js.map +7 -0
  69. package/dist/esm/{chunk-LKYHOABO.js → chunk-IPOIF4A2.js} +170 -37
  70. package/dist/esm/chunk-IPOIF4A2.js.map +7 -0
  71. package/dist/esm/{chunk-PFJG3V3A.js → chunk-ITPLCNJB.js} +84 -5
  72. package/dist/esm/chunk-ITPLCNJB.js.map +7 -0
  73. package/dist/esm/{chunk-YSOG5YCI.js → chunk-KM336UKV.js} +1203 -2125
  74. package/dist/esm/chunk-KM336UKV.js.map +7 -0
  75. package/dist/esm/{chunk-KFWTFROT.js → chunk-M5SAGBGR.js} +42 -3
  76. package/dist/esm/chunk-M5SAGBGR.js.map +7 -0
  77. package/dist/esm/{chunk-OHAEKHAC.js → chunk-NPGGO3JN.js} +37 -55
  78. package/dist/esm/chunk-NPGGO3JN.js.map +7 -0
  79. package/dist/esm/{chunk-HDAINZXA.js → chunk-RKOP2GYL.js} +50 -7
  80. package/dist/esm/chunk-RKOP2GYL.js.map +7 -0
  81. package/dist/esm/{chunk-VZZ4GN23.js → chunk-T5PKT4I6.js} +6 -4
  82. package/dist/esm/{chunk-VZZ4GN23.js.map → chunk-T5PKT4I6.js.map} +1 -1
  83. package/dist/esm/{chunk-B4MMOAAO.js → chunk-WI3EWXXI.js} +2 -2
  84. package/dist/esm/generated/protos/index.akash.v1.js +180 -182
  85. package/dist/esm/generated/protos/index.akash.v1.js.map +4 -4
  86. package/dist/esm/generated/protos/index.akash.v1beta1.js +7 -7
  87. package/dist/esm/generated/protos/index.akash.v1beta4.js +6 -4
  88. package/dist/esm/generated/protos/index.akash.v1beta5.js +10 -4
  89. package/dist/esm/generated/protos/index.akash.v1beta5.js.map +1 -1
  90. package/dist/esm/generated/protos/index.akash.v2.js +6 -6
  91. package/dist/esm/generated/protos/index.provider.akash.v1.js +16 -15
  92. package/dist/esm/index.js +10 -12
  93. package/dist/esm/index.web.js +9 -11
  94. package/dist/esm/{query_akash-3UBRLLRZ.js → query_akash-3IY2DKPB.js} +3 -3
  95. package/dist/esm/{query_akash-CKZRI7R6.js → query_akash-OKZLG4MG.js} +5 -3
  96. package/dist/esm/{query_akash-CKZRI7R6.js.map → query_akash-OKZLG4MG.js.map} +1 -1
  97. package/dist/esm/{query_akash-3LAHGVQJ.js → query_akash-ZITEPCYB.js} +6 -4
  98. package/dist/esm/{query_akash-3LAHGVQJ.js.map → query_akash-ZITEPCYB.js.map} +1 -1
  99. package/dist/esm/{service_akash-UFTUJDPM.js → service_akash-2CH5FJ4J.js} +3 -3
  100. package/dist/esm/{service_akash-5JSE44LJ.js → service_akash-BLDT6YCO.js} +5 -3
  101. package/dist/esm/{service_akash-5JSE44LJ.js.map → service_akash-BLDT6YCO.js.map} +1 -1
  102. package/dist/esm/{service_akash-QEN5EQUY.js → service_akash-DZETPXWM.js} +15 -4
  103. package/dist/esm/service_akash-DZETPXWM.js.map +7 -0
  104. package/dist/esm/service_akash-K7FWCKUQ.js +25 -0
  105. package/dist/esm/service_akash-K7FWCKUQ.js.map +7 -0
  106. package/dist/esm/{service_akash-FI6WXDZP.js → service_akash-VOFSDZEK.js} +4 -3
  107. package/dist/esm/{service_akash-FI6WXDZP.js.map → service_akash-VOFSDZEK.js.map} +1 -1
  108. package/dist/sdl-schema.yaml +1 -1
  109. package/dist/tsconfig.build.tsbuildinfo +1 -1
  110. package/dist/types/bla.d.ts +1 -0
  111. package/dist/types/generated/createNodeSDK.d.ts +30 -0
  112. package/dist/types/generated/protos/akash/bme/v1/params.d.ts +5 -0
  113. package/dist/types/generated/protos/akash/bme/v1/types.d.ts +19 -1
  114. package/dist/types/generated/protos/akash/deployment/v1/deployment.d.ts +15 -0
  115. package/dist/types/generated/protos/akash/deployment/v1beta4/deploymentmsg.d.ts +6 -1
  116. package/dist/types/generated/protos/akash/discovery/v1/akash.d.ts +16 -2
  117. package/dist/types/generated/protos/akash/discovery/v1/client_info.d.ts +18 -0
  118. package/dist/types/generated/protos/akash/discovery/v1/service.d.ts +12 -0
  119. package/dist/types/generated/protos/akash/discovery/v1/service_akash.d.ts +13 -0
  120. package/dist/types/generated/protos/akash/market/v1/event.d.ts +11 -0
  121. package/dist/types/generated/protos/akash/market/v1/lease.d.ts +8 -0
  122. package/dist/types/generated/protos/akash/market/v1/reclamation.d.ts +22 -0
  123. package/dist/types/generated/protos/akash/market/v1beta5/bid.d.ts +3 -0
  124. package/dist/types/generated/protos/akash/market/v1beta5/bidmsg.d.ts +7 -0
  125. package/dist/types/generated/protos/akash/market/v1beta5/leasemsg.d.ts +12 -0
  126. package/dist/types/generated/protos/akash/market/v1beta5/order.d.ts +6 -0
  127. package/dist/types/generated/protos/akash/market/v1beta5/params.d.ts +5 -0
  128. package/dist/types/generated/protos/akash/market/v1beta5/service_akash.d.ts +7 -1
  129. package/dist/types/generated/protos/index.akash.v1.d.ts +5 -3
  130. package/dist/types/generated/protos/index.akash.v1beta5.d.ts +1 -1
  131. package/dist/types/network/config.d.ts +4 -5
  132. package/dist/types/sdk/chain/createChainNodeSDK.d.ts +6 -0
  133. package/dist/types/sdk/chain/createChainNodeWebSDK.d.ts +6 -0
  134. package/dist/types/sdk/chain/helpers.d.ts +1 -1
  135. package/dist/types/sdk/provider/auth/jwt/types.d.ts +4 -58
  136. package/dist/types/sdk/provider/auth/jwt/validateJwtPayload.d.ts +273 -225
  137. package/dist/types/sdl/index.d.ts +0 -2
  138. package/dist/types/sdl/manifest/generateManifest.d.ts +1 -2
  139. package/dist/types/sdl/validateSDL/validateSDL.d.ts +2 -3
  140. package/dist/types/sdl/validateSDL/validateSDLInput.d.ts +5 -5
  141. package/dist/types/test.d.ts +1 -0
  142. package/package.json +13 -15
  143. package/dist/cjs/sdl/SDL/SDL.cjs +0 -718
  144. package/dist/cjs/sdl/SDL/SDL.cjs.map +0 -7
  145. package/dist/cjs/sdl/SDL/SdlValidationError.cjs +0 -46
  146. package/dist/cjs/sdl/SDL/SdlValidationError.cjs.map +0 -7
  147. package/dist/esm/chunk-H5WUFEMM.js.map +0 -7
  148. package/dist/esm/chunk-HDAINZXA.js.map +0 -7
  149. package/dist/esm/chunk-KFWTFROT.js.map +0 -7
  150. package/dist/esm/chunk-LKYHOABO.js.map +0 -7
  151. package/dist/esm/chunk-OHAEKHAC.js.map +0 -7
  152. package/dist/esm/chunk-PFJG3V3A.js.map +0 -7
  153. package/dist/esm/chunk-TXQ2BR6G.js.map +0 -7
  154. package/dist/esm/chunk-YSOG5YCI.js.map +0 -7
  155. package/dist/esm/service_akash-QEN5EQUY.js.map +0 -7
  156. package/dist/types/sdl/SDL/SDL.d.ts +0 -439
  157. package/dist/types/sdl/SDL/SdlValidationError.d.ts +0 -18
  158. /package/dist/esm/{chunk-JAPXWQ3D.js.map → chunk-7XWZXYD2.js.map} +0 -0
  159. /package/dist/esm/{chunk-5RTSSO7K.js.map → chunk-B7H4H62Z.js.map} +0 -0
  160. /package/dist/esm/{chunk-5YIS3XNX.js.map → chunk-EXKSXOV2.js.map} +0 -0
  161. /package/dist/esm/{chunk-B4MMOAAO.js.map → chunk-WI3EWXXI.js.map} +0 -0
  162. /package/dist/esm/{query_akash-3UBRLLRZ.js.map → query_akash-3IY2DKPB.js.map} +0 -0
  163. /package/dist/esm/{service_akash-UFTUJDPM.js.map → service_akash-2CH5FJ4J.js.map} +0 -0
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../src/generated/protos/akash/market/v1/lease.ts"],
4
- "sourcesContent": ["import { isSet } from \"../../../../../encoding/typeEncodingHelpers.ts\"\nimport type { DeepPartial, MessageFns } from \"../../../../../encoding/typeEncodingHelpers.ts\"\n// Code generated by protoc-gen-ts_proto. DO NOT EDIT.\n// versions:\n// protoc-gen-ts_proto v2.7.7\n// protoc unknown\n// source: akash/market/v1/lease.proto\n\n/* eslint-disable */\nimport { BinaryReader, BinaryWriter } from \"@bufbuild/protobuf/wire\";\nimport Long from \"long\";\nimport { DecCoin } from \"../../../cosmos/base/v1beta1/coin.ts\";\nimport { LeaseClosedReason, leaseClosedReasonFromJSON, leaseClosedReasonToJSON } from \"./types.ts\";\n\n/** LeaseID stores bid details of lease. */\nexport interface LeaseID {\n /**\n * Owner is the account bech32 address of the user who owns the deployment.\n * It is a string representing a valid bech32 account address.\n *\n * Example:\n * \"akash1...\"\n */\n owner: string;\n /**\n * Dseq (deployment sequence number) is a unique numeric identifier for the deployment.\n * It is used to differentiate deployments created by the same owner.\n */\n dseq: Long;\n /**\n * Gseq (group sequence number) is a unique numeric identifier for the group.\n * It is used to differentiate groups created by the same owner in a deployment.\n */\n gseq: number;\n /**\n * Oseq (order sequence) distinguishes multiple orders associated with a single deployment.\n * Oseq is incremented when a lease associated with an existing deployment is closed, and a new order is generated.\n */\n oseq: number;\n /**\n * Provider is the account bech32 address of the provider making the bid.\n * It is a string representing a valid account bech32 address.\n *\n * Example:\n * \"akash1...\"\n */\n provider: string;\n /** BSeq (bid sequence) distinguishes multiple bids associated with a single deployment from same provider. */\n bseq: number;\n}\n\n/**\n * Lease stores LeaseID, state of lease and price.\n * The Lease defines the terms under which the provider allocates resources to fulfill\n * the tenant's deployment requirements.\n * Leases are paid from the tenant to the provider through a deposit and withdraw mechanism and are priced in blocks.\n */\nexport interface Lease {\n /** Id is the unique identifier of the Lease. */\n id:\n | LeaseID\n | undefined;\n /** State represents the state of the Lease. */\n state: Lease_State;\n /** Price holds the settled price for the Lease. */\n price:\n | DecCoin\n | undefined;\n /** CreatedAt is the block height at which the Lease was created. */\n createdAt: Long;\n /** ClosedOn is the block height at which the Lease was closed. */\n closedOn: Long;\n reason: LeaseClosedReason;\n}\n\n/** State is an enum which refers to state of lease. */\nexport enum Lease_State {\n /** invalid - Prefix should start with 0 in enum. So declaring dummy state. */\n invalid = 0,\n /** active - LeaseActive denotes state for lease active. */\n active = 1,\n /** insufficient_funds - LeaseInsufficientFunds denotes state for lease insufficient_funds. */\n insufficient_funds = 2,\n /** closed - LeaseClosed denotes state for lease closed. */\n closed = 3,\n UNRECOGNIZED = -1,\n}\n\nexport function lease_StateFromJSON(object: any): Lease_State {\n switch (object) {\n case 0:\n case \"invalid\":\n return Lease_State.invalid;\n case 1:\n case \"active\":\n return Lease_State.active;\n case 2:\n case \"insufficient_funds\":\n return Lease_State.insufficient_funds;\n case 3:\n case \"closed\":\n return Lease_State.closed;\n case -1:\n case \"UNRECOGNIZED\":\n default:\n return Lease_State.UNRECOGNIZED;\n }\n}\n\nexport function lease_StateToJSON(object: Lease_State): string {\n switch (object) {\n case Lease_State.invalid:\n return \"invalid\";\n case Lease_State.active:\n return \"active\";\n case Lease_State.insufficient_funds:\n return \"insufficient_funds\";\n case Lease_State.closed:\n return \"closed\";\n case Lease_State.UNRECOGNIZED:\n default:\n return \"UNRECOGNIZED\";\n }\n}\n\nfunction createBaseLeaseID(): LeaseID {\n return { owner: \"\", dseq: Long.UZERO, gseq: 0, oseq: 0, provider: \"\", bseq: 0 };\n}\n\nexport const LeaseID: MessageFns<LeaseID, \"akash.market.v1.LeaseID\"> = {\n $type: \"akash.market.v1.LeaseID\" as const,\n\n encode(message: LeaseID, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.owner !== \"\") {\n writer.uint32(10).string(message.owner);\n }\n if (!message.dseq.equals(Long.UZERO)) {\n writer.uint32(16).uint64(message.dseq.toString());\n }\n if (message.gseq !== 0) {\n writer.uint32(24).uint32(message.gseq);\n }\n if (message.oseq !== 0) {\n writer.uint32(32).uint32(message.oseq);\n }\n if (message.provider !== \"\") {\n writer.uint32(42).string(message.provider);\n }\n if (message.bseq !== 0) {\n writer.uint32(48).uint32(message.bseq);\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): LeaseID {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseLeaseID();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.owner = reader.string();\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.dseq = Long.fromString(reader.uint64().toString(), true);\n continue;\n }\n case 3: {\n if (tag !== 24) {\n break;\n }\n\n message.gseq = reader.uint32();\n continue;\n }\n case 4: {\n if (tag !== 32) {\n break;\n }\n\n message.oseq = reader.uint32();\n continue;\n }\n case 5: {\n if (tag !== 42) {\n break;\n }\n\n message.provider = reader.string();\n continue;\n }\n case 6: {\n if (tag !== 48) {\n break;\n }\n\n message.bseq = reader.uint32();\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): LeaseID {\n return {\n owner: isSet(object.owner) ? globalThis.String(object.owner) : \"\",\n dseq: isSet(object.dseq) ? Long.fromValue(object.dseq) : Long.UZERO,\n gseq: isSet(object.gseq) ? globalThis.Number(object.gseq) : 0,\n oseq: isSet(object.oseq) ? globalThis.Number(object.oseq) : 0,\n provider: isSet(object.provider) ? globalThis.String(object.provider) : \"\",\n bseq: isSet(object.bseq) ? globalThis.Number(object.bseq) : 0,\n };\n },\n\n toJSON(message: LeaseID): unknown {\n const obj: any = {};\n if (message.owner !== \"\") {\n obj.owner = message.owner;\n }\n if (!message.dseq.equals(Long.UZERO)) {\n obj.dseq = (message.dseq || Long.UZERO).toString();\n }\n if (message.gseq !== 0) {\n obj.gseq = Math.round(message.gseq);\n }\n if (message.oseq !== 0) {\n obj.oseq = Math.round(message.oseq);\n }\n if (message.provider !== \"\") {\n obj.provider = message.provider;\n }\n if (message.bseq !== 0) {\n obj.bseq = Math.round(message.bseq);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<LeaseID>): LeaseID {\n const message = createBaseLeaseID();\n message.owner = object.owner ?? \"\";\n message.dseq = (object.dseq !== undefined && object.dseq !== null) ? Long.fromValue(object.dseq) : Long.UZERO;\n message.gseq = object.gseq ?? 0;\n message.oseq = object.oseq ?? 0;\n message.provider = object.provider ?? \"\";\n message.bseq = object.bseq ?? 0;\n return message;\n },\n};\n\nfunction createBaseLease(): Lease {\n return { id: undefined, state: 0, price: undefined, createdAt: Long.ZERO, closedOn: Long.ZERO, reason: 0 };\n}\n\nexport const Lease: MessageFns<Lease, \"akash.market.v1.Lease\"> = {\n $type: \"akash.market.v1.Lease\" as const,\n\n encode(message: Lease, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n LeaseID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.state !== 0) {\n writer.uint32(16).int32(message.state);\n }\n if (message.price !== undefined) {\n DecCoin.encode(message.price, writer.uint32(26).fork()).join();\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n writer.uint32(32).int64(message.createdAt.toString());\n }\n if (!message.closedOn.equals(Long.ZERO)) {\n writer.uint32(40).int64(message.closedOn.toString());\n }\n if (message.reason !== 0) {\n writer.uint32(48).int32(message.reason);\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): Lease {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseLease();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = LeaseID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.state = reader.int32() as any;\n continue;\n }\n case 3: {\n if (tag !== 26) {\n break;\n }\n\n message.price = DecCoin.decode(reader, reader.uint32());\n continue;\n }\n case 4: {\n if (tag !== 32) {\n break;\n }\n\n message.createdAt = Long.fromString(reader.int64().toString());\n continue;\n }\n case 5: {\n if (tag !== 40) {\n break;\n }\n\n message.closedOn = Long.fromString(reader.int64().toString());\n continue;\n }\n case 6: {\n if (tag !== 48) {\n break;\n }\n\n message.reason = reader.int32() as any;\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): Lease {\n return {\n id: isSet(object.id) ? LeaseID.fromJSON(object.id) : undefined,\n state: isSet(object.state) ? lease_StateFromJSON(object.state) : 0,\n price: isSet(object.price) ? DecCoin.fromJSON(object.price) : undefined,\n createdAt: isSet(object.created_at) ? Long.fromValue(object.created_at) : Long.ZERO,\n closedOn: isSet(object.closed_on) ? Long.fromValue(object.closed_on) : Long.ZERO,\n reason: isSet(object.reason) ? leaseClosedReasonFromJSON(object.reason) : 0,\n };\n },\n\n toJSON(message: Lease): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = LeaseID.toJSON(message.id);\n }\n if (message.state !== 0) {\n obj.state = lease_StateToJSON(message.state);\n }\n if (message.price !== undefined) {\n obj.price = DecCoin.toJSON(message.price);\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n obj.created_at = (message.createdAt || Long.ZERO).toString();\n }\n if (!message.closedOn.equals(Long.ZERO)) {\n obj.closed_on = (message.closedOn || Long.ZERO).toString();\n }\n if (message.reason !== 0) {\n obj.reason = leaseClosedReasonToJSON(message.reason);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<Lease>): Lease {\n const message = createBaseLease();\n message.id = (object.id !== undefined && object.id !== null) ? LeaseID.fromPartial(object.id) : undefined;\n message.state = object.state ?? 0;\n message.price = (object.price !== undefined && object.price !== null)\n ? DecCoin.fromPartial(object.price)\n : undefined;\n message.createdAt = (object.createdAt !== undefined && object.createdAt !== null)\n ? Long.fromValue(object.createdAt)\n : Long.ZERO;\n message.closedOn = (object.closedOn !== undefined && object.closedOn !== null)\n ? Long.fromValue(object.closedOn)\n : Long.ZERO;\n message.reason = object.reason ?? 0;\n return message;\n },\n};\n\ntype Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;\n\ntype _unused_DeepPartial<T> = T extends Builtin ? T\n : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>\n : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>\n : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }\n : Partial<T>;\n\nfunction _unused_isSet(value: any): boolean {\n return value !== null && value !== undefined;\n}\n\ninterface _unused_MessageFns<T, V extends string> {\n readonly $type: V;\n encode(message: T, writer?: BinaryWriter): BinaryWriter;\n decode(input: BinaryReader | Uint8Array, length?: number): T;\n fromJSON(object: any): T;\n toJSON(message: T): unknown;\n create(base?: DeepPartial<T>): T;\n fromPartial(object: DeepPartial<T>): T;\n}\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAsB;AAStB,kBAA2C;AAC3C,kBAA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AAS,OAAO,YAAAA,QAAK,IAAI,GAAG;AACvC,UAAI,aAAa,QAAQ,YAAY,YAAAA,QAAK,MAAM,SAAS;AAAA,IAC3D;AACA,QAAI,QAAQ,WAAW,GAAG;AACxB,UAAI,aAAS,sCAAwB,QAAQ,MAAM;AAAA,IACrD;AACA,WAAO;AAAA,EACT;AAAA,EACA,YAAY,QAAmC;AAC7C,UAAM,UAAU,gBAAgB;AAChC,YAAQ,KAAM,OAAO,OAAO,UAAa,OAAO,OAAO,OAAQ,QAAQ,YAAY,OAAO,EAAE,IAAI;AAChG,YAAQ,QAAQ,OAAO,SAAS;AAChC,YAAQ,QAAS,OAAO,UAAU,UAAa,OAAO,UAAU,OAC5D,oBAAQ,YAAY,OAAO,KAAK,IAChC;AACJ,YAAQ,YAAa,OAAO,cAAc,UAAa,OAAO,cAAc,OACxE,YAAAA,QAAK,UAAU,OAAO,SAAS,IAC/B,YAAAA,QAAK;AACT,YAAQ,WAAY,OAAO,aAAa,UAAa,OAAO,aAAa,OACrE,YAAAA,QAAK,UAAU,OAAO,QAAQ,IAC9B,YAAAA,QAAK;AACT,YAAQ,SAAS,OAAO,UAAU;AAClC,WAAO;AAAA,EACT;AACF;AAUA,SAAS,cAAc,OAAqB;AAC1C,SAAO,UAAU,QAAQ,UAAU;AACrC;",
4
+ "sourcesContent": ["import { isSet } from \"../../../../../encoding/typeEncodingHelpers.ts\"\nimport type { DeepPartial, MessageFns } from \"../../../../../encoding/typeEncodingHelpers.ts\"\n// Code generated by protoc-gen-ts_proto. DO NOT EDIT.\n// versions:\n// protoc-gen-ts_proto v2.7.7\n// protoc unknown\n// source: akash/market/v1/lease.proto\n\n/* eslint-disable */\nimport { BinaryReader, BinaryWriter } from \"@bufbuild/protobuf/wire\";\nimport Long from \"long\";\nimport { DecCoin } from \"../../../cosmos/base/v1beta1/coin.ts\";\nimport { Reclamation } from \"./reclamation.ts\";\nimport { LeaseClosedReason, leaseClosedReasonFromJSON, leaseClosedReasonToJSON } from \"./types.ts\";\n\n/** LeaseID stores bid details of lease. */\nexport interface LeaseID {\n /**\n * Owner is the account bech32 address of the user who owns the deployment.\n * It is a string representing a valid bech32 account address.\n *\n * Example:\n * \"akash1...\"\n */\n owner: string;\n /**\n * Dseq (deployment sequence number) is a unique numeric identifier for the deployment.\n * It is used to differentiate deployments created by the same owner.\n */\n dseq: Long;\n /**\n * Gseq (group sequence number) is a unique numeric identifier for the group.\n * It is used to differentiate groups created by the same owner in a deployment.\n */\n gseq: number;\n /**\n * Oseq (order sequence) distinguishes multiple orders associated with a single deployment.\n * Oseq is incremented when a lease associated with an existing deployment is closed, and a new order is generated.\n */\n oseq: number;\n /**\n * Provider is the account bech32 address of the provider making the bid.\n * It is a string representing a valid account bech32 address.\n *\n * Example:\n * \"akash1...\"\n */\n provider: string;\n /** BSeq (bid sequence) distinguishes multiple bids associated with a single deployment from same provider. */\n bseq: number;\n}\n\n/**\n * Lease stores LeaseID, state of lease and price.\n * The Lease defines the terms under which the provider allocates resources to fulfill\n * the tenant's deployment requirements.\n * Leases are paid from the tenant to the provider through a deposit and withdraw mechanism and are priced in blocks.\n */\nexport interface Lease {\n /** Id is the unique identifier of the Lease. */\n id:\n | LeaseID\n | undefined;\n /** State represents the state of the Lease. */\n state: Lease_State;\n /** Price holds the settled price for the Lease. */\n price:\n | DecCoin\n | undefined;\n /** CreatedAt is the block height at which the Lease was created. */\n createdAt: Long;\n /** ClosedOn is the block height at which the Lease was closed. */\n closedOn: Long;\n reason: LeaseClosedReason;\n /**\n * Reclamation holds reclamation configuration and state, if applicable.\n * Nil if reclamation is not configured for this lease.\n */\n reclamation: Reclamation | undefined;\n}\n\n/** State is an enum which refers to state of lease. */\nexport enum Lease_State {\n /** invalid - Prefix should start with 0 in enum. So declaring dummy state. */\n invalid = 0,\n /** active - LeaseActive denotes state for lease active. */\n active = 1,\n /** insufficient_funds - LeaseInsufficientFunds denotes state for lease insufficient_funds. */\n insufficient_funds = 2,\n /** closed - LeaseClosed denotes state for lease closed. */\n closed = 3,\n /** reclaiming - LeaseReclaiming denotes a lease in reclamation (grace period before closure). */\n reclaiming = 4,\n UNRECOGNIZED = -1,\n}\n\nexport function lease_StateFromJSON(object: any): Lease_State {\n switch (object) {\n case 0:\n case \"invalid\":\n return Lease_State.invalid;\n case 1:\n case \"active\":\n return Lease_State.active;\n case 2:\n case \"insufficient_funds\":\n return Lease_State.insufficient_funds;\n case 3:\n case \"closed\":\n return Lease_State.closed;\n case 4:\n case \"reclaiming\":\n return Lease_State.reclaiming;\n case -1:\n case \"UNRECOGNIZED\":\n default:\n return Lease_State.UNRECOGNIZED;\n }\n}\n\nexport function lease_StateToJSON(object: Lease_State): string {\n switch (object) {\n case Lease_State.invalid:\n return \"invalid\";\n case Lease_State.active:\n return \"active\";\n case Lease_State.insufficient_funds:\n return \"insufficient_funds\";\n case Lease_State.closed:\n return \"closed\";\n case Lease_State.reclaiming:\n return \"reclaiming\";\n case Lease_State.UNRECOGNIZED:\n default:\n return \"UNRECOGNIZED\";\n }\n}\n\nfunction createBaseLeaseID(): LeaseID {\n return { owner: \"\", dseq: Long.UZERO, gseq: 0, oseq: 0, provider: \"\", bseq: 0 };\n}\n\nexport const LeaseID: MessageFns<LeaseID, \"akash.market.v1.LeaseID\"> = {\n $type: \"akash.market.v1.LeaseID\" as const,\n\n encode(message: LeaseID, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.owner !== \"\") {\n writer.uint32(10).string(message.owner);\n }\n if (!message.dseq.equals(Long.UZERO)) {\n writer.uint32(16).uint64(message.dseq.toString());\n }\n if (message.gseq !== 0) {\n writer.uint32(24).uint32(message.gseq);\n }\n if (message.oseq !== 0) {\n writer.uint32(32).uint32(message.oseq);\n }\n if (message.provider !== \"\") {\n writer.uint32(42).string(message.provider);\n }\n if (message.bseq !== 0) {\n writer.uint32(48).uint32(message.bseq);\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): LeaseID {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseLeaseID();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.owner = reader.string();\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.dseq = Long.fromString(reader.uint64().toString(), true);\n continue;\n }\n case 3: {\n if (tag !== 24) {\n break;\n }\n\n message.gseq = reader.uint32();\n continue;\n }\n case 4: {\n if (tag !== 32) {\n break;\n }\n\n message.oseq = reader.uint32();\n continue;\n }\n case 5: {\n if (tag !== 42) {\n break;\n }\n\n message.provider = reader.string();\n continue;\n }\n case 6: {\n if (tag !== 48) {\n break;\n }\n\n message.bseq = reader.uint32();\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): LeaseID {\n return {\n owner: isSet(object.owner) ? globalThis.String(object.owner) : \"\",\n dseq: isSet(object.dseq) ? Long.fromValue(object.dseq) : Long.UZERO,\n gseq: isSet(object.gseq) ? globalThis.Number(object.gseq) : 0,\n oseq: isSet(object.oseq) ? globalThis.Number(object.oseq) : 0,\n provider: isSet(object.provider) ? globalThis.String(object.provider) : \"\",\n bseq: isSet(object.bseq) ? globalThis.Number(object.bseq) : 0,\n };\n },\n\n toJSON(message: LeaseID): unknown {\n const obj: any = {};\n if (message.owner !== \"\") {\n obj.owner = message.owner;\n }\n if (!message.dseq.equals(Long.UZERO)) {\n obj.dseq = (message.dseq || Long.UZERO).toString();\n }\n if (message.gseq !== 0) {\n obj.gseq = Math.round(message.gseq);\n }\n if (message.oseq !== 0) {\n obj.oseq = Math.round(message.oseq);\n }\n if (message.provider !== \"\") {\n obj.provider = message.provider;\n }\n if (message.bseq !== 0) {\n obj.bseq = Math.round(message.bseq);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<LeaseID>): LeaseID {\n const message = createBaseLeaseID();\n message.owner = object.owner ?? \"\";\n message.dseq = (object.dseq !== undefined && object.dseq !== null) ? Long.fromValue(object.dseq) : Long.UZERO;\n message.gseq = object.gseq ?? 0;\n message.oseq = object.oseq ?? 0;\n message.provider = object.provider ?? \"\";\n message.bseq = object.bseq ?? 0;\n return message;\n },\n};\n\nfunction createBaseLease(): Lease {\n return {\n id: undefined,\n state: 0,\n price: undefined,\n createdAt: Long.ZERO,\n closedOn: Long.ZERO,\n reason: 0,\n reclamation: undefined,\n };\n}\n\nexport const Lease: MessageFns<Lease, \"akash.market.v1.Lease\"> = {\n $type: \"akash.market.v1.Lease\" as const,\n\n encode(message: Lease, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n LeaseID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.state !== 0) {\n writer.uint32(16).int32(message.state);\n }\n if (message.price !== undefined) {\n DecCoin.encode(message.price, writer.uint32(26).fork()).join();\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n writer.uint32(32).int64(message.createdAt.toString());\n }\n if (!message.closedOn.equals(Long.ZERO)) {\n writer.uint32(40).int64(message.closedOn.toString());\n }\n if (message.reason !== 0) {\n writer.uint32(48).int32(message.reason);\n }\n if (message.reclamation !== undefined) {\n Reclamation.encode(message.reclamation, writer.uint32(58).fork()).join();\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): Lease {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseLease();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = LeaseID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.state = reader.int32() as any;\n continue;\n }\n case 3: {\n if (tag !== 26) {\n break;\n }\n\n message.price = DecCoin.decode(reader, reader.uint32());\n continue;\n }\n case 4: {\n if (tag !== 32) {\n break;\n }\n\n message.createdAt = Long.fromString(reader.int64().toString());\n continue;\n }\n case 5: {\n if (tag !== 40) {\n break;\n }\n\n message.closedOn = Long.fromString(reader.int64().toString());\n continue;\n }\n case 6: {\n if (tag !== 48) {\n break;\n }\n\n message.reason = reader.int32() as any;\n continue;\n }\n case 7: {\n if (tag !== 58) {\n break;\n }\n\n message.reclamation = Reclamation.decode(reader, reader.uint32());\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): Lease {\n return {\n id: isSet(object.id) ? LeaseID.fromJSON(object.id) : undefined,\n state: isSet(object.state) ? lease_StateFromJSON(object.state) : 0,\n price: isSet(object.price) ? DecCoin.fromJSON(object.price) : undefined,\n createdAt: isSet(object.created_at) ? Long.fromValue(object.created_at) : Long.ZERO,\n closedOn: isSet(object.closed_on) ? Long.fromValue(object.closed_on) : Long.ZERO,\n reason: isSet(object.reason) ? leaseClosedReasonFromJSON(object.reason) : 0,\n reclamation: isSet(object.reclamation) ? Reclamation.fromJSON(object.reclamation) : undefined,\n };\n },\n\n toJSON(message: Lease): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = LeaseID.toJSON(message.id);\n }\n if (message.state !== 0) {\n obj.state = lease_StateToJSON(message.state);\n }\n if (message.price !== undefined) {\n obj.price = DecCoin.toJSON(message.price);\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n obj.created_at = (message.createdAt || Long.ZERO).toString();\n }\n if (!message.closedOn.equals(Long.ZERO)) {\n obj.closed_on = (message.closedOn || Long.ZERO).toString();\n }\n if (message.reason !== 0) {\n obj.reason = leaseClosedReasonToJSON(message.reason);\n }\n if (message.reclamation !== undefined) {\n obj.reclamation = Reclamation.toJSON(message.reclamation);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<Lease>): Lease {\n const message = createBaseLease();\n message.id = (object.id !== undefined && object.id !== null) ? LeaseID.fromPartial(object.id) : undefined;\n message.state = object.state ?? 0;\n message.price = (object.price !== undefined && object.price !== null)\n ? DecCoin.fromPartial(object.price)\n : undefined;\n message.createdAt = (object.createdAt !== undefined && object.createdAt !== null)\n ? Long.fromValue(object.createdAt)\n : Long.ZERO;\n message.closedOn = (object.closedOn !== undefined && object.closedOn !== null)\n ? Long.fromValue(object.closedOn)\n : Long.ZERO;\n message.reason = object.reason ?? 0;\n message.reclamation = (object.reclamation !== undefined && object.reclamation !== null)\n ? Reclamation.fromPartial(object.reclamation)\n : undefined;\n return message;\n },\n};\n\ntype Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;\n\ntype _unused_DeepPartial<T> = T extends Builtin ? T\n : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>\n : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>\n : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }\n : Partial<T>;\n\nfunction _unused_isSet(value: any): boolean {\n return value !== null && value !== undefined;\n}\n\ninterface _unused_MessageFns<T, V extends string> {\n readonly $type: V;\n encode(message: T, writer?: BinaryWriter): BinaryWriter;\n decode(input: BinaryReader | Uint8Array, length?: number): T;\n fromJSON(object: any): T;\n toJSON(message: T): unknown;\n create(base?: DeepPartial<T>): T;\n fromPartial(object: DeepPartial<T>): T;\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAsB;AAStB,kBAA2C;AAC3C,kBAAiB;AACjB,kBAAwB;AACxB,yBAA4B;AAC5B,mBAAsF;AAqE/E,IAAK,cAAL,kBAAKA,iBAAL;AAEL,EAAAA,0BAAA,aAAU,KAAV;AAEA,EAAAA,0BAAA,YAAS,KAAT;AAEA,EAAAA,0BAAA,wBAAqB,KAArB;AAEA,EAAAA,0BAAA,YAAS,KAAT;AAEA,EAAAA,0BAAA,gBAAa,KAAb;AACA,EAAAA,0BAAA,kBA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6
6
  "names": ["Lease_State", "Long"]
7
7
  }
@@ -0,0 +1,138 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var reclamation_exports = {};
30
+ __export(reclamation_exports, {
31
+ Reclamation: () => Reclamation
32
+ });
33
+ module.exports = __toCommonJS(reclamation_exports);
34
+ var import_typeEncodingHelpers = require("../../../../../encoding/typeEncodingHelpers.cjs");
35
+ var import_wire = require("@bufbuild/protobuf/wire");
36
+ var import_long = __toESM(require("long"), 1);
37
+ var import_duration = require("../../../google/protobuf/duration.cjs");
38
+ var import_types = require("./types.cjs");
39
+ function createBaseReclamation() {
40
+ return { window: void 0, startedAt: import_long.default.ZERO, deadline: import_long.default.ZERO, reason: 0 };
41
+ }
42
+ const Reclamation = {
43
+ $type: "akash.market.v1.Reclamation",
44
+ encode(message, writer = new import_wire.BinaryWriter()) {
45
+ if (message.window !== void 0) {
46
+ import_duration.Duration.encode(message.window, writer.uint32(10).fork()).join();
47
+ }
48
+ if (!message.startedAt.equals(import_long.default.ZERO)) {
49
+ writer.uint32(16).int64(message.startedAt.toString());
50
+ }
51
+ if (!message.deadline.equals(import_long.default.ZERO)) {
52
+ writer.uint32(24).int64(message.deadline.toString());
53
+ }
54
+ if (message.reason !== 0) {
55
+ writer.uint32(32).int32(message.reason);
56
+ }
57
+ return writer;
58
+ },
59
+ decode(input, length) {
60
+ const reader = input instanceof import_wire.BinaryReader ? input : new import_wire.BinaryReader(input);
61
+ const end = length === void 0 ? reader.len : reader.pos + length;
62
+ const message = createBaseReclamation();
63
+ while (reader.pos < end) {
64
+ const tag = reader.uint32();
65
+ switch (tag >>> 3) {
66
+ case 1: {
67
+ if (tag !== 10) {
68
+ break;
69
+ }
70
+ message.window = import_duration.Duration.decode(reader, reader.uint32());
71
+ continue;
72
+ }
73
+ case 2: {
74
+ if (tag !== 16) {
75
+ break;
76
+ }
77
+ message.startedAt = import_long.default.fromString(reader.int64().toString());
78
+ continue;
79
+ }
80
+ case 3: {
81
+ if (tag !== 24) {
82
+ break;
83
+ }
84
+ message.deadline = import_long.default.fromString(reader.int64().toString());
85
+ continue;
86
+ }
87
+ case 4: {
88
+ if (tag !== 32) {
89
+ break;
90
+ }
91
+ message.reason = reader.int32();
92
+ continue;
93
+ }
94
+ }
95
+ if ((tag & 7) === 4 || tag === 0) {
96
+ break;
97
+ }
98
+ reader.skip(tag & 7);
99
+ }
100
+ return message;
101
+ },
102
+ fromJSON(object) {
103
+ return {
104
+ window: (0, import_typeEncodingHelpers.isSet)(object.window) ? import_duration.Duration.fromJSON(object.window) : void 0,
105
+ startedAt: (0, import_typeEncodingHelpers.isSet)(object.started_at) ? import_long.default.fromValue(object.started_at) : import_long.default.ZERO,
106
+ deadline: (0, import_typeEncodingHelpers.isSet)(object.deadline) ? import_long.default.fromValue(object.deadline) : import_long.default.ZERO,
107
+ reason: (0, import_typeEncodingHelpers.isSet)(object.reason) ? (0, import_types.leaseClosedReasonFromJSON)(object.reason) : 0
108
+ };
109
+ },
110
+ toJSON(message) {
111
+ const obj = {};
112
+ if (message.window !== void 0) {
113
+ obj.window = import_duration.Duration.toJSON(message.window);
114
+ }
115
+ if (!message.startedAt.equals(import_long.default.ZERO)) {
116
+ obj.started_at = (message.startedAt || import_long.default.ZERO).toString();
117
+ }
118
+ if (!message.deadline.equals(import_long.default.ZERO)) {
119
+ obj.deadline = (message.deadline || import_long.default.ZERO).toString();
120
+ }
121
+ if (message.reason !== 0) {
122
+ obj.reason = (0, import_types.leaseClosedReasonToJSON)(message.reason);
123
+ }
124
+ return obj;
125
+ },
126
+ fromPartial(object) {
127
+ const message = createBaseReclamation();
128
+ message.window = object.window !== void 0 && object.window !== null ? import_duration.Duration.fromPartial(object.window) : void 0;
129
+ message.startedAt = object.startedAt !== void 0 && object.startedAt !== null ? import_long.default.fromValue(object.startedAt) : import_long.default.ZERO;
130
+ message.deadline = object.deadline !== void 0 && object.deadline !== null ? import_long.default.fromValue(object.deadline) : import_long.default.ZERO;
131
+ message.reason = object.reason ?? 0;
132
+ return message;
133
+ }
134
+ };
135
+ function _unused_isSet(value) {
136
+ return value !== null && value !== void 0;
137
+ }
138
+ //# sourceMappingURL=reclamation.cjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../src/generated/protos/akash/market/v1/reclamation.ts"],
4
+ "sourcesContent": ["import { isSet } from \"../../../../../encoding/typeEncodingHelpers.ts\"\nimport type { DeepPartial, MessageFns } from \"../../../../../encoding/typeEncodingHelpers.ts\"\n// Code generated by protoc-gen-ts_proto. DO NOT EDIT.\n// versions:\n// protoc-gen-ts_proto v2.7.7\n// protoc unknown\n// source: akash/market/v1/reclamation.proto\n\n/* eslint-disable */\nimport { BinaryReader, BinaryWriter } from \"@bufbuild/protobuf/wire\";\nimport Long from \"long\";\nimport { Duration } from \"../../../google/protobuf/duration.ts\";\nimport { LeaseClosedReason, leaseClosedReasonFromJSON, leaseClosedReasonToJSON } from \"./types.ts\";\n\n/** Reclamation defines the runtime reclamation state stored on a Lease. */\nexport interface Reclamation {\n /** window is the negotiated reclamation window duration (from the winning bid). */\n window:\n | Duration\n | undefined;\n /**\n * started_at is the block height at which reclamation was initiated.\n * Zero means reclamation has not been started yet.\n */\n startedAt: Long;\n /**\n * deadline is the unix timestamp at which the reclamation window expires.\n * Zero means reclamation has not been started yet.\n */\n deadline: Long;\n /** reason is the provider's stated reason for reclamation. */\n reason: LeaseClosedReason;\n}\n\nfunction createBaseReclamation(): Reclamation {\n return { window: undefined, startedAt: Long.ZERO, deadline: Long.ZERO, reason: 0 };\n}\n\nexport const Reclamation: MessageFns<Reclamation, \"akash.market.v1.Reclamation\"> = {\n $type: \"akash.market.v1.Reclamation\" as const,\n\n encode(message: Reclamation, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.window !== undefined) {\n Duration.encode(message.window, writer.uint32(10).fork()).join();\n }\n if (!message.startedAt.equals(Long.ZERO)) {\n writer.uint32(16).int64(message.startedAt.toString());\n }\n if (!message.deadline.equals(Long.ZERO)) {\n writer.uint32(24).int64(message.deadline.toString());\n }\n if (message.reason !== 0) {\n writer.uint32(32).int32(message.reason);\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): Reclamation {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseReclamation();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.window = Duration.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.startedAt = Long.fromString(reader.int64().toString());\n continue;\n }\n case 3: {\n if (tag !== 24) {\n break;\n }\n\n message.deadline = Long.fromString(reader.int64().toString());\n continue;\n }\n case 4: {\n if (tag !== 32) {\n break;\n }\n\n message.reason = reader.int32() as any;\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): Reclamation {\n return {\n window: isSet(object.window) ? Duration.fromJSON(object.window) : undefined,\n startedAt: isSet(object.started_at) ? Long.fromValue(object.started_at) : Long.ZERO,\n deadline: isSet(object.deadline) ? Long.fromValue(object.deadline) : Long.ZERO,\n reason: isSet(object.reason) ? leaseClosedReasonFromJSON(object.reason) : 0,\n };\n },\n\n toJSON(message: Reclamation): unknown {\n const obj: any = {};\n if (message.window !== undefined) {\n obj.window = Duration.toJSON(message.window);\n }\n if (!message.startedAt.equals(Long.ZERO)) {\n obj.started_at = (message.startedAt || Long.ZERO).toString();\n }\n if (!message.deadline.equals(Long.ZERO)) {\n obj.deadline = (message.deadline || Long.ZERO).toString();\n }\n if (message.reason !== 0) {\n obj.reason = leaseClosedReasonToJSON(message.reason);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<Reclamation>): Reclamation {\n const message = createBaseReclamation();\n message.window = (object.window !== undefined && object.window !== null)\n ? Duration.fromPartial(object.window)\n : undefined;\n message.startedAt = (object.startedAt !== undefined && object.startedAt !== null)\n ? Long.fromValue(object.startedAt)\n : Long.ZERO;\n message.deadline = (object.deadline !== undefined && object.deadline !== null)\n ? Long.fromValue(object.deadline)\n : Long.ZERO;\n message.reason = object.reason ?? 0;\n return message;\n },\n};\n\ntype Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;\n\ntype _unused_DeepPartial<T> = T extends Builtin ? T\n : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>\n : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>\n : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }\n : Partial<T>;\n\nfunction _unused_isSet(value: any): boolean {\n return value !== null && value !== undefined;\n}\n\ninterface _unused_MessageFns<T, V extends string> {\n readonly $type: V;\n encode(message: T, writer?: BinaryWriter): BinaryWriter;\n decode(input: BinaryReader | Uint8Array, length?: number): T;\n fromJSON(object: any): T;\n toJSON(message: T): unknown;\n create(base?: DeepPartial<T>): T;\n fromPartial(object: DeepPartial<T>): T;\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAsB;AAStB,kBAA2C;AAC3C,kBAAiB;AACjB,sBAAyB;AACzB,mBAAsF;AAsBtF,SAAS,wBAAqC;AAC5C,SAAO,EAAE,QAAQ,QAAW,WAAW,YAAAA,QAAK,MAAM,UAAU,YAAAA,QAAK,MAAM,QAAQ,EAAE;AACnF;AAEO,MAAM,cAAsE;AAAA,EACjF,OAAO;AAAA,EAEP,OAAO,SAAsB,SAAuB,IAAI,yBAAa,GAAiB;AACpF,QAAI,QAAQ,WAAW,QAAW;AAChC,+BAAS,OAAO,QAAQ,QAAQ,OAAO,OAAO,EAAE,EAAE,KAAK,CAAC,EAAE,KAAK;AAAA,IACjE;AACA,QAAI,CAAC,QAAQ,UAAU,OAAO,YAAAA,QAAK,IAAI,GAAG;AACxC,aAAO,OAAO,EAAE,EAAE,MAAM,QAAQ,UAAU,SAAS,CAAC;AAAA,IACtD;AACA,QAAI,CAAC,QAAQ,SAAS,OAAO,YAAAA,QAAK,IAAI,GAAG;AACvC,aAAO,OAAO,EAAE,EAAE,MAAM,QAAQ,SAAS,SAAS,CAAC;AAAA,IACrD;AACA,QAAI,QAAQ,WAAW,GAAG;AACxB,aAAO,OAAO,EAAE,EAAE,MAAM,QAAQ,MAAM;AAAA,IACxC;AACA,WAAO;AAAA,EACT;AAAA,EAEA,OAAO,OAAkC,QAA8B;AACrE,UAAM,SAAS,iBAAiB,2BAAe,QAAQ,IAAI,yBAAa,KAAK;AAC7E,UAAM,MAAM,WAAW,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AAA,EAEA,OAAO,SAA+B;AACpC,UAAM,MAAW,CAAC;AAClB,QAAI,QAAQ,WAAW,QAAW;AAChC,UAAI,SAAS,yBAAS,OAAO,QAAQ,MAAM;AAAA,IAC7C;AACA,QAAI,CAAC,QAAQ,UAAU,OAAO,YAAAA,QAAK,IAAI,GAAG;AACxC,UAAI,cAAc,QAAQ,aAAa,YAAAA,QAAK,MAAM,SAAS;AAAA,IAC7D;AACA,QAAI,CAAC,QAAQ,SAAS,OAAO,YAAAA,QAAK,IAAI,GAAG;AACvC,UAAI,YAAY,QAAQ,YAAY,YAAAA,QAAK,MAAM,SAAS;AAAA,IAC1D;AACA,QAAI,QAAQ,WAAW,GAAG;AACxB,UAAI,aAAS,sCAAwB,QAAQ,MAAM;AAAA,IACrD;AACA,WAAO;AAAA,EACT;AAAA,EACA,YAAY,QAA+C;AACzD,UAAM,UAAU,sBAAsB;AACtC,YAAQ,SAAU,OAAO,WAAW,UAAa,OAAO,WAAW,OAC/D,yBAAS,YAAY,OAAO,MAAM,IAClC;AACJ,YAAQ,YAAa,OAAO,cAAc,UAAa,OAAO,cAAc,OACxE,YAAAA,QAAK,UAAU,OAAO,SAAS,IAC/B,YAAAA,QAAK;AACT,YAAQ,WAAY,OAAO,aAAa,UAAa,OAAO,aAAa,OACrE,YAAAA,QAAK,UAAU,OAAO,QAAQ,IAC9B,YAAAA,QAAK;AACT,YAAQ,SAAS,OAAO,UAAU;AAClC,WAAO;AAAA,EACT;AACF;AAUA,SAAS,cAAc,OAAqB;AAC1C,SAAO,UAAU,QAAQ,UAAU;AACrC;",
6
+ "names": ["Long"]
7
+ }
@@ -38,6 +38,7 @@ var import_typeEncodingHelpers = require("../../../../../encoding/typeEncodingHe
38
38
  var import_wire = require("@bufbuild/protobuf/wire");
39
39
  var import_long = __toESM(require("long"), 1);
40
40
  var import_coin = require("../../../cosmos/base/v1beta1/coin.cjs");
41
+ var import_duration = require("../../../google/protobuf/duration.cjs");
41
42
  var import_bid = require("../v1/bid.cjs");
42
43
  var import_resourcesoffer = require("./resourcesoffer.cjs");
43
44
  var Bid_State = /* @__PURE__ */ ((Bid_State2) => {
@@ -90,7 +91,14 @@ function bid_StateToJSON(object) {
90
91
  }
91
92
  }
92
93
  function createBaseBid() {
93
- return { id: void 0, state: 0, price: void 0, createdAt: import_long.default.ZERO, resourcesOffer: [] };
94
+ return {
95
+ id: void 0,
96
+ state: 0,
97
+ price: void 0,
98
+ createdAt: import_long.default.ZERO,
99
+ resourcesOffer: [],
100
+ reclamationWindow: void 0
101
+ };
94
102
  }
95
103
  const Bid = {
96
104
  $type: "akash.market.v1beta5.Bid",
@@ -110,6 +118,9 @@ const Bid = {
110
118
  for (const v of message.resourcesOffer) {
111
119
  import_resourcesoffer.ResourceOffer.encode(v, writer.uint32(42).fork()).join();
112
120
  }
121
+ if (message.reclamationWindow !== void 0) {
122
+ import_duration.Duration.encode(message.reclamationWindow, writer.uint32(50).fork()).join();
123
+ }
113
124
  return writer;
114
125
  },
115
126
  decode(input, length) {
@@ -154,6 +165,13 @@ const Bid = {
154
165
  message.resourcesOffer.push(import_resourcesoffer.ResourceOffer.decode(reader, reader.uint32()));
155
166
  continue;
156
167
  }
168
+ case 6: {
169
+ if (tag !== 50) {
170
+ break;
171
+ }
172
+ message.reclamationWindow = import_duration.Duration.decode(reader, reader.uint32());
173
+ continue;
174
+ }
157
175
  }
158
176
  if ((tag & 7) === 4 || tag === 0) {
159
177
  break;
@@ -168,7 +186,8 @@ const Bid = {
168
186
  state: (0, import_typeEncodingHelpers.isSet)(object.state) ? bid_StateFromJSON(object.state) : 0,
169
187
  price: (0, import_typeEncodingHelpers.isSet)(object.price) ? import_coin.DecCoin.fromJSON(object.price) : void 0,
170
188
  createdAt: (0, import_typeEncodingHelpers.isSet)(object.created_at) ? import_long.default.fromValue(object.created_at) : import_long.default.ZERO,
171
- resourcesOffer: globalThis.Array.isArray(object?.resources_offer) ? object.resources_offer.map((e) => import_resourcesoffer.ResourceOffer.fromJSON(e)) : []
189
+ resourcesOffer: globalThis.Array.isArray(object?.resources_offer) ? object.resources_offer.map((e) => import_resourcesoffer.ResourceOffer.fromJSON(e)) : [],
190
+ reclamationWindow: (0, import_typeEncodingHelpers.isSet)(object.reclamation_window) ? import_duration.Duration.fromJSON(object.reclamation_window) : void 0
172
191
  };
173
192
  },
174
193
  toJSON(message) {
@@ -188,6 +207,9 @@ const Bid = {
188
207
  if (message.resourcesOffer?.length) {
189
208
  obj.resources_offer = message.resourcesOffer.map((e) => import_resourcesoffer.ResourceOffer.toJSON(e));
190
209
  }
210
+ if (message.reclamationWindow !== void 0) {
211
+ obj.reclamation_window = import_duration.Duration.toJSON(message.reclamationWindow);
212
+ }
191
213
  return obj;
192
214
  },
193
215
  fromPartial(object) {
@@ -197,6 +219,7 @@ const Bid = {
197
219
  message.price = object.price !== void 0 && object.price !== null ? import_coin.DecCoin.fromPartial(object.price) : void 0;
198
220
  message.createdAt = object.createdAt !== void 0 && object.createdAt !== null ? import_long.default.fromValue(object.createdAt) : import_long.default.ZERO;
199
221
  message.resourcesOffer = object.resourcesOffer?.map((e) => import_resourcesoffer.ResourceOffer.fromPartial(e)) || [];
222
+ message.reclamationWindow = object.reclamationWindow !== void 0 && object.reclamationWindow !== null ? import_duration.Duration.fromPartial(object.reclamationWindow) : void 0;
200
223
  return message;
201
224
  }
202
225
  };
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../src/generated/protos/akash/market/v1beta5/bid.ts"],
4
- "sourcesContent": ["import { isSet } from \"../../../../../encoding/typeEncodingHelpers.ts\"\nimport type { DeepPartial, MessageFns } from \"../../../../../encoding/typeEncodingHelpers.ts\"\n// Code generated by protoc-gen-ts_proto. DO NOT EDIT.\n// versions:\n// protoc-gen-ts_proto v2.7.7\n// protoc unknown\n// source: akash/market/v1beta5/bid.proto\n\n/* eslint-disable */\nimport { BinaryReader, BinaryWriter } from \"@bufbuild/protobuf/wire\";\nimport Long from \"long\";\nimport { DecCoin } from \"../../../cosmos/base/v1beta1/coin.ts\";\nimport { BidID } from \"../v1/bid.ts\";\nimport { ResourceOffer } from \"./resourcesoffer.ts\";\n\n/** Bid stores BidID, state of bid and price. */\nexport interface Bid {\n /**\n * BidID stores owner and all other seq numbers.\n * A successful bid becomes a Lease(ID).\n */\n id:\n | BidID\n | undefined;\n /** State represents the state of the Bid. */\n state: Bid_State;\n /** Price holds the pricing stated on the Bid. */\n price:\n | DecCoin\n | undefined;\n /** CreatedAt is the block height at which the Bid was created. */\n createdAt: Long;\n /** ResourceOffer is a list of offers. */\n resourcesOffer: ResourceOffer[];\n}\n\n/** BidState is an enum which refers to state of bid. */\nexport enum Bid_State {\n /** invalid - Prefix should start with 0 in enum. So declaring dummy state. */\n invalid = 0,\n /** open - BidOpen denotes state for bid open. */\n open = 1,\n /** active - BidMatched denotes state for bid open. */\n active = 2,\n /** lost - BidLost denotes state for bid lost. */\n lost = 3,\n /** closed - BidClosed denotes state for bid closed. */\n closed = 4,\n UNRECOGNIZED = -1,\n}\n\nexport function bid_StateFromJSON(object: any): Bid_State {\n switch (object) {\n case 0:\n case \"invalid\":\n return Bid_State.invalid;\n case 1:\n case \"open\":\n return Bid_State.open;\n case 2:\n case \"active\":\n return Bid_State.active;\n case 3:\n case \"lost\":\n return Bid_State.lost;\n case 4:\n case \"closed\":\n return Bid_State.closed;\n case -1:\n case \"UNRECOGNIZED\":\n default:\n return Bid_State.UNRECOGNIZED;\n }\n}\n\nexport function bid_StateToJSON(object: Bid_State): string {\n switch (object) {\n case Bid_State.invalid:\n return \"invalid\";\n case Bid_State.open:\n return \"open\";\n case Bid_State.active:\n return \"active\";\n case Bid_State.lost:\n return \"lost\";\n case Bid_State.closed:\n return \"closed\";\n case Bid_State.UNRECOGNIZED:\n default:\n return \"UNRECOGNIZED\";\n }\n}\n\nfunction createBaseBid(): Bid {\n return { id: undefined, state: 0, price: undefined, createdAt: Long.ZERO, resourcesOffer: [] };\n}\n\nexport const Bid: MessageFns<Bid, \"akash.market.v1beta5.Bid\"> = {\n $type: \"akash.market.v1beta5.Bid\" as const,\n\n encode(message: Bid, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n BidID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.state !== 0) {\n writer.uint32(16).int32(message.state);\n }\n if (message.price !== undefined) {\n DecCoin.encode(message.price, writer.uint32(26).fork()).join();\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n writer.uint32(32).int64(message.createdAt.toString());\n }\n for (const v of message.resourcesOffer) {\n ResourceOffer.encode(v!, writer.uint32(42).fork()).join();\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): Bid {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseBid();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = BidID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.state = reader.int32() as any;\n continue;\n }\n case 3: {\n if (tag !== 26) {\n break;\n }\n\n message.price = DecCoin.decode(reader, reader.uint32());\n continue;\n }\n case 4: {\n if (tag !== 32) {\n break;\n }\n\n message.createdAt = Long.fromString(reader.int64().toString());\n continue;\n }\n case 5: {\n if (tag !== 42) {\n break;\n }\n\n message.resourcesOffer.push(ResourceOffer.decode(reader, reader.uint32()));\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): Bid {\n return {\n id: isSet(object.id) ? BidID.fromJSON(object.id) : undefined,\n state: isSet(object.state) ? bid_StateFromJSON(object.state) : 0,\n price: isSet(object.price) ? DecCoin.fromJSON(object.price) : undefined,\n createdAt: isSet(object.created_at) ? Long.fromValue(object.created_at) : Long.ZERO,\n resourcesOffer: globalThis.Array.isArray(object?.resources_offer)\n ? object.resources_offer.map((e: any) => ResourceOffer.fromJSON(e))\n : [],\n };\n },\n\n toJSON(message: Bid): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = BidID.toJSON(message.id);\n }\n if (message.state !== 0) {\n obj.state = bid_StateToJSON(message.state);\n }\n if (message.price !== undefined) {\n obj.price = DecCoin.toJSON(message.price);\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n obj.created_at = (message.createdAt || Long.ZERO).toString();\n }\n if (message.resourcesOffer?.length) {\n obj.resources_offer = message.resourcesOffer.map((e) => ResourceOffer.toJSON(e));\n }\n return obj;\n },\n fromPartial(object: DeepPartial<Bid>): Bid {\n const message = createBaseBid();\n message.id = (object.id !== undefined && object.id !== null) ? BidID.fromPartial(object.id) : undefined;\n message.state = object.state ?? 0;\n message.price = (object.price !== undefined && object.price !== null)\n ? DecCoin.fromPartial(object.price)\n : undefined;\n message.createdAt = (object.createdAt !== undefined && object.createdAt !== null)\n ? Long.fromValue(object.createdAt)\n : Long.ZERO;\n message.resourcesOffer = object.resourcesOffer?.map((e) => ResourceOffer.fromPartial(e)) || [];\n return message;\n },\n};\n\ntype Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;\n\ntype _unused_DeepPartial<T> = T extends Builtin ? T\n : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>\n : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>\n : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }\n : Partial<T>;\n\nfunction _unused_isSet(value: any): boolean {\n return value !== null && value !== undefined;\n}\n\ninterface _unused_MessageFns<T, V extends string> {\n readonly $type: V;\n encode(message: T, writer?: BinaryWriter): BinaryWriter;\n decode(input: BinaryReader | Uint8Array, length?: number): T;\n fromJSON(object: any): T;\n toJSON(message: T): unknown;\n create(base?: DeepPartial<T>): T;\n fromPartial(object: DeepPartial<T>): T;\n}\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;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,oBAAQ,OAAO,QAAQ,KAAK;AAAA,IAC1C;AACA,QAAI,CAAC,QAAQ,UAAU,OAAO,YAAAA,QAAK,IAAI,GAAG;AACxC,UAAI,cAAc,QAAQ,aAAa,YAAAA,QAAK,MAAM,SAAS;AAAA,IAC7D;AACA,QAAI,QAAQ,gBAAgB,QAAQ;AAClC,UAAI,kBAAkB,QAAQ,eAAe,IAAI,CAAC,MAAM,oCAAc,OAAO,CAAC,CAAC;AAAA,IACjF;AACA,WAAO;AAAA,EACT;AAAA,EACA,YAAY,QAA+B;AACzC,UAAM,UAAU,cAAc;AAC9B,YAAQ,KAAM,OAAO,OAAO,UAAa,OAAO,OAAO,OAAQ,iBAAM,YAAY,OAAO,EAAE,IAAI;AAC9F,YAAQ,QAAQ,OAAO,SAAS;AAChC,YAAQ,QAAS,OAAO,UAAU,UAAa,OAAO,UAAU,OAC5D,oBAAQ,YAAY,OAAO,KAAK,IAChC;AACJ,YAAQ,YAAa,OAAO,cAAc,UAAa,OAAO,cAAc,OACxE,YAAAA,QAAK,UAAU,OAAO,SAAS,IAC/B,YAAAA,QAAK;AACT,YAAQ,iBAAiB,OAAO,gBAAgB,IAAI,CAAC,MAAM,oCAAc,YAAY,CAAC,CAAC,KAAK,CAAC;AAC7F,WAAO;AAAA,EACT;AACF;AAUA,SAAS,cAAc,OAAqB;AAC1C,SAAO,UAAU,QAAQ,UAAU;AACrC;",
4
+ "sourcesContent": ["import { isSet } from \"../../../../../encoding/typeEncodingHelpers.ts\"\nimport type { DeepPartial, MessageFns } from \"../../../../../encoding/typeEncodingHelpers.ts\"\n// Code generated by protoc-gen-ts_proto. DO NOT EDIT.\n// versions:\n// protoc-gen-ts_proto v2.7.7\n// protoc unknown\n// source: akash/market/v1beta5/bid.proto\n\n/* eslint-disable */\nimport { BinaryReader, BinaryWriter } from \"@bufbuild/protobuf/wire\";\nimport Long from \"long\";\nimport { DecCoin } from \"../../../cosmos/base/v1beta1/coin.ts\";\nimport { Duration } from \"../../../google/protobuf/duration.ts\";\nimport { BidID } from \"../v1/bid.ts\";\nimport { ResourceOffer } from \"./resourcesoffer.ts\";\n\n/** Bid stores BidID, state of bid and price. */\nexport interface Bid {\n /**\n * BidID stores owner and all other seq numbers.\n * A successful bid becomes a Lease(ID).\n */\n id:\n | BidID\n | undefined;\n /** State represents the state of the Bid. */\n state: Bid_State;\n /** Price holds the pricing stated on the Bid. */\n price:\n | DecCoin\n | undefined;\n /** CreatedAt is the block height at which the Bid was created. */\n createdAt: Long;\n /** ResourceOffer is a list of offers. */\n resourcesOffer: ResourceOffer[];\n /** reclamation_window is the reclamation window offered by this provider. */\n reclamationWindow: Duration | undefined;\n}\n\n/** BidState is an enum which refers to state of bid. */\nexport enum Bid_State {\n /** invalid - Prefix should start with 0 in enum. So declaring dummy state. */\n invalid = 0,\n /** open - BidOpen denotes state for bid open. */\n open = 1,\n /** active - BidMatched denotes state for bid open. */\n active = 2,\n /** lost - BidLost denotes state for bid lost. */\n lost = 3,\n /** closed - BidClosed denotes state for bid closed. */\n closed = 4,\n UNRECOGNIZED = -1,\n}\n\nexport function bid_StateFromJSON(object: any): Bid_State {\n switch (object) {\n case 0:\n case \"invalid\":\n return Bid_State.invalid;\n case 1:\n case \"open\":\n return Bid_State.open;\n case 2:\n case \"active\":\n return Bid_State.active;\n case 3:\n case \"lost\":\n return Bid_State.lost;\n case 4:\n case \"closed\":\n return Bid_State.closed;\n case -1:\n case \"UNRECOGNIZED\":\n default:\n return Bid_State.UNRECOGNIZED;\n }\n}\n\nexport function bid_StateToJSON(object: Bid_State): string {\n switch (object) {\n case Bid_State.invalid:\n return \"invalid\";\n case Bid_State.open:\n return \"open\";\n case Bid_State.active:\n return \"active\";\n case Bid_State.lost:\n return \"lost\";\n case Bid_State.closed:\n return \"closed\";\n case Bid_State.UNRECOGNIZED:\n default:\n return \"UNRECOGNIZED\";\n }\n}\n\nfunction createBaseBid(): Bid {\n return {\n id: undefined,\n state: 0,\n price: undefined,\n createdAt: Long.ZERO,\n resourcesOffer: [],\n reclamationWindow: undefined,\n };\n}\n\nexport const Bid: MessageFns<Bid, \"akash.market.v1beta5.Bid\"> = {\n $type: \"akash.market.v1beta5.Bid\" as const,\n\n encode(message: Bid, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n BidID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.state !== 0) {\n writer.uint32(16).int32(message.state);\n }\n if (message.price !== undefined) {\n DecCoin.encode(message.price, writer.uint32(26).fork()).join();\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n writer.uint32(32).int64(message.createdAt.toString());\n }\n for (const v of message.resourcesOffer) {\n ResourceOffer.encode(v!, writer.uint32(42).fork()).join();\n }\n if (message.reclamationWindow !== undefined) {\n Duration.encode(message.reclamationWindow, writer.uint32(50).fork()).join();\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): Bid {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseBid();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = BidID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.state = reader.int32() as any;\n continue;\n }\n case 3: {\n if (tag !== 26) {\n break;\n }\n\n message.price = DecCoin.decode(reader, reader.uint32());\n continue;\n }\n case 4: {\n if (tag !== 32) {\n break;\n }\n\n message.createdAt = Long.fromString(reader.int64().toString());\n continue;\n }\n case 5: {\n if (tag !== 42) {\n break;\n }\n\n message.resourcesOffer.push(ResourceOffer.decode(reader, reader.uint32()));\n continue;\n }\n case 6: {\n if (tag !== 50) {\n break;\n }\n\n message.reclamationWindow = Duration.decode(reader, reader.uint32());\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): Bid {\n return {\n id: isSet(object.id) ? BidID.fromJSON(object.id) : undefined,\n state: isSet(object.state) ? bid_StateFromJSON(object.state) : 0,\n price: isSet(object.price) ? DecCoin.fromJSON(object.price) : undefined,\n createdAt: isSet(object.created_at) ? Long.fromValue(object.created_at) : Long.ZERO,\n resourcesOffer: globalThis.Array.isArray(object?.resources_offer)\n ? object.resources_offer.map((e: any) => ResourceOffer.fromJSON(e))\n : [],\n reclamationWindow: isSet(object.reclamation_window) ? Duration.fromJSON(object.reclamation_window) : undefined,\n };\n },\n\n toJSON(message: Bid): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = BidID.toJSON(message.id);\n }\n if (message.state !== 0) {\n obj.state = bid_StateToJSON(message.state);\n }\n if (message.price !== undefined) {\n obj.price = DecCoin.toJSON(message.price);\n }\n if (!message.createdAt.equals(Long.ZERO)) {\n obj.created_at = (message.createdAt || Long.ZERO).toString();\n }\n if (message.resourcesOffer?.length) {\n obj.resources_offer = message.resourcesOffer.map((e) => ResourceOffer.toJSON(e));\n }\n if (message.reclamationWindow !== undefined) {\n obj.reclamation_window = Duration.toJSON(message.reclamationWindow);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<Bid>): Bid {\n const message = createBaseBid();\n message.id = (object.id !== undefined && object.id !== null) ? BidID.fromPartial(object.id) : undefined;\n message.state = object.state ?? 0;\n message.price = (object.price !== undefined && object.price !== null)\n ? DecCoin.fromPartial(object.price)\n : undefined;\n message.createdAt = (object.createdAt !== undefined && object.createdAt !== null)\n ? Long.fromValue(object.createdAt)\n : Long.ZERO;\n message.resourcesOffer = object.resourcesOffer?.map((e) => ResourceOffer.fromPartial(e)) || [];\n message.reclamationWindow = (object.reclamationWindow !== undefined && object.reclamationWindow !== null)\n ? Duration.fromPartial(object.reclamationWindow)\n : undefined;\n return message;\n },\n};\n\ntype Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;\n\ntype _unused_DeepPartial<T> = T extends Builtin ? T\n : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>\n : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>\n : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }\n : Partial<T>;\n\nfunction _unused_isSet(value: any): boolean {\n return value !== null && value !== undefined;\n}\n\ninterface _unused_MessageFns<T, V extends string> {\n readonly $type: V;\n encode(message: T, writer?: BinaryWriter): BinaryWriter;\n decode(input: BinaryReader | Uint8Array, length?: number): T;\n fromJSON(object: any): T;\n toJSON(message: T): unknown;\n create(base?: DeepPartial<T>): T;\n fromPartial(object: DeepPartial<T>): T;\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAsB;AAStB,kBAA2C;AAC3C,kBAAiB;AACjB,kBAAwB;AACxB,sBAAyB;AACzB,iBAAsB;AACtB,4BAA8B;AA0BvB,IAAK,YAAL,kBAAKA,eAAL;AAEL,EAAAA,sBAAA,aAAU,KAAV;AAEA,EAAAA,sBAAA,UAAO,KAAP;AAEA,EAAAA,sBAAA,YAAS,KAAT;AAEA,EAAAA,sBAAA,UAAO,KAAP;AAEA,EAAAA,sBAAA,YAAS,KAAT;AACA,EAAAA,sBAAA,kBAAe,MAAf;AAXU,SAAAA;AAAA,GAAA;AAcL,SAAS,kBAAkB,QAAwB;AACxD,UAAQ,QAAQ;AAAA,IACd,KAAK;AAAA,IACL,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AAAA,IACL,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AAAA,IACL,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AAAA,IACL,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AAAA,IACL,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AAAA,IACL,KAAK;AAAA,IACL;AACE,aAAO;AAAA,EACX;AACF;AAEO,SAAS,gBAAgB,QAA2B;AACzD,UAAQ,QAAQ;AAAA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WAAO;AAAA,EACT;AAAA,EACA,YAAY,QAA+B;AACzC,UAAM,UAAU,cAAc;AAC9B,YAAQ,KAAM,OAAO,OAAO,UAAa,OAAO,OAAO,OAAQ,iBAAM,YAAY,OAAO,EAAE,IAAI;AAC9F,YAAQ,QAAQ,OAAO,SAAS;AAChC,YAAQ,QAAS,OAAO,UAAU,UAAa,OAAO,UAAU,OAC5D,oBAAQ,YAAY,OAAO,KAAK,IAChC;AACJ,YAAQ,YAAa,OAAO,cAAc,UAAa,OAAO,cAAc,OACxE,YAAAA,QAAK,UAAU,OAAO,SAAS,IAC/B,YAAAA,QAAK;AACT,YAAQ,iBAAiB,OAAO,gBAAgB,IAAI,CAAC,MAAM,oCAAc,YAAY,CAAC,CAAC,KAAK,CAAC;AAC7F,YAAQ,oBAAqB,OAAO,sBAAsB,UAAa,OAAO,sBAAsB,OAChG,yBAAS,YAAY,OAAO,iBAAiB,IAC7C;AACJ,WAAO;AAAA,EACT;AACF;AAUA,SAAS,cAAc,OAAqB;AAC1C,SAAO,UAAU,QAAQ,UAAU;AACrC;",
6
6
  "names": ["Bid_State", "Long"]
7
7
  }
@@ -27,12 +27,13 @@ module.exports = __toCommonJS(bidmsg_exports);
27
27
  var import_typeEncodingHelpers = require("../../../../../encoding/typeEncodingHelpers.cjs");
28
28
  var import_wire = require("@bufbuild/protobuf/wire");
29
29
  var import_coin = require("../../../cosmos/base/v1beta1/coin.cjs");
30
+ var import_duration = require("../../../google/protobuf/duration.cjs");
30
31
  var import_deposit = require("../../base/deposit/v1/deposit.cjs");
31
32
  var import_bid = require("../v1/bid.cjs");
32
33
  var import_types = require("../v1/types.cjs");
33
34
  var import_resourcesoffer = require("./resourcesoffer.cjs");
34
35
  function createBaseMsgCreateBid() {
35
- return { id: void 0, price: void 0, deposit: void 0, resourcesOffer: [] };
36
+ return { id: void 0, price: void 0, deposit: void 0, resourcesOffer: [], reclamationWindow: void 0 };
36
37
  }
37
38
  const MsgCreateBid = {
38
39
  $type: "akash.market.v1beta5.MsgCreateBid",
@@ -49,6 +50,9 @@ const MsgCreateBid = {
49
50
  for (const v of message.resourcesOffer) {
50
51
  import_resourcesoffer.ResourceOffer.encode(v, writer.uint32(34).fork()).join();
51
52
  }
53
+ if (message.reclamationWindow !== void 0) {
54
+ import_duration.Duration.encode(message.reclamationWindow, writer.uint32(42).fork()).join();
55
+ }
52
56
  return writer;
53
57
  },
54
58
  decode(input, length) {
@@ -86,6 +90,13 @@ const MsgCreateBid = {
86
90
  message.resourcesOffer.push(import_resourcesoffer.ResourceOffer.decode(reader, reader.uint32()));
87
91
  continue;
88
92
  }
93
+ case 5: {
94
+ if (tag !== 42) {
95
+ break;
96
+ }
97
+ message.reclamationWindow = import_duration.Duration.decode(reader, reader.uint32());
98
+ continue;
99
+ }
89
100
  }
90
101
  if ((tag & 7) === 4 || tag === 0) {
91
102
  break;
@@ -99,7 +110,8 @@ const MsgCreateBid = {
99
110
  id: (0, import_typeEncodingHelpers.isSet)(object.id) ? import_bid.BidID.fromJSON(object.id) : void 0,
100
111
  price: (0, import_typeEncodingHelpers.isSet)(object.price) ? import_coin.DecCoin.fromJSON(object.price) : void 0,
101
112
  deposit: (0, import_typeEncodingHelpers.isSet)(object.deposit) ? import_deposit.Deposit.fromJSON(object.deposit) : void 0,
102
- resourcesOffer: globalThis.Array.isArray(object?.resources_offer) ? object.resources_offer.map((e) => import_resourcesoffer.ResourceOffer.fromJSON(e)) : []
113
+ resourcesOffer: globalThis.Array.isArray(object?.resources_offer) ? object.resources_offer.map((e) => import_resourcesoffer.ResourceOffer.fromJSON(e)) : [],
114
+ reclamationWindow: (0, import_typeEncodingHelpers.isSet)(object.reclamation_window) ? import_duration.Duration.fromJSON(object.reclamation_window) : void 0
103
115
  };
104
116
  },
105
117
  toJSON(message) {
@@ -116,6 +128,9 @@ const MsgCreateBid = {
116
128
  if (message.resourcesOffer?.length) {
117
129
  obj.resources_offer = message.resourcesOffer.map((e) => import_resourcesoffer.ResourceOffer.toJSON(e));
118
130
  }
131
+ if (message.reclamationWindow !== void 0) {
132
+ obj.reclamation_window = import_duration.Duration.toJSON(message.reclamationWindow);
133
+ }
119
134
  return obj;
120
135
  },
121
136
  fromPartial(object) {
@@ -124,6 +139,7 @@ const MsgCreateBid = {
124
139
  message.price = object.price !== void 0 && object.price !== null ? import_coin.DecCoin.fromPartial(object.price) : void 0;
125
140
  message.deposit = object.deposit !== void 0 && object.deposit !== null ? import_deposit.Deposit.fromPartial(object.deposit) : void 0;
126
141
  message.resourcesOffer = object.resourcesOffer?.map((e) => import_resourcesoffer.ResourceOffer.fromPartial(e)) || [];
142
+ message.reclamationWindow = object.reclamationWindow !== void 0 && object.reclamationWindow !== null ? import_duration.Duration.fromPartial(object.reclamationWindow) : void 0;
127
143
  return message;
128
144
  }
129
145
  };
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../src/generated/protos/akash/market/v1beta5/bidmsg.ts"],
4
- "sourcesContent": ["import { isSet } from \"../../../../../encoding/typeEncodingHelpers.ts\"\nimport type { DeepPartial, MessageFns } from \"../../../../../encoding/typeEncodingHelpers.ts\"\n// Code generated by protoc-gen-ts_proto. DO NOT EDIT.\n// versions:\n// protoc-gen-ts_proto v2.7.7\n// protoc unknown\n// source: akash/market/v1beta5/bidmsg.proto\n\n/* eslint-disable */\nimport { BinaryReader, BinaryWriter } from \"@bufbuild/protobuf/wire\";\nimport Long from \"long\";\nimport { DecCoin } from \"../../../cosmos/base/v1beta1/coin.ts\";\nimport { Deposit } from \"../../base/deposit/v1/deposit.ts\";\nimport { BidID } from \"../v1/bid.ts\";\nimport { LeaseClosedReason, leaseClosedReasonFromJSON, leaseClosedReasonToJSON } from \"../v1/types.ts\";\nimport { ResourceOffer } from \"./resourcesoffer.ts\";\n\n/** MsgCreateBid defines an SDK message for creating Bid. */\nexport interface MsgCreateBid {\n id:\n | BidID\n | undefined;\n /** Price holds the pricing stated on the Bid. */\n price:\n | DecCoin\n | undefined;\n /** Deposit holds the amount of coins to deposit. */\n deposit:\n | Deposit\n | undefined;\n /** ResourceOffer is a list of resource offers. */\n resourcesOffer: ResourceOffer[];\n}\n\n/** MsgCreateBidResponse defines the Msg/CreateBid response type. */\nexport interface MsgCreateBidResponse {\n}\n\n/** MsgCloseBid defines an SDK message for closing bid. */\nexport interface MsgCloseBid {\n /** Id is the unique identifier of the Bid. */\n id: BidID | undefined;\n reason: LeaseClosedReason;\n}\n\n/** MsgCloseBidResponse defines the Msg/CloseBid response type. */\nexport interface MsgCloseBidResponse {\n}\n\nfunction createBaseMsgCreateBid(): MsgCreateBid {\n return { id: undefined, price: undefined, deposit: undefined, resourcesOffer: [] };\n}\n\nexport const MsgCreateBid: MessageFns<MsgCreateBid, \"akash.market.v1beta5.MsgCreateBid\"> = {\n $type: \"akash.market.v1beta5.MsgCreateBid\" as const,\n\n encode(message: MsgCreateBid, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n BidID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.price !== undefined) {\n DecCoin.encode(message.price, writer.uint32(18).fork()).join();\n }\n if (message.deposit !== undefined) {\n Deposit.encode(message.deposit, writer.uint32(26).fork()).join();\n }\n for (const v of message.resourcesOffer) {\n ResourceOffer.encode(v!, writer.uint32(34).fork()).join();\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCreateBid {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCreateBid();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = BidID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 18) {\n break;\n }\n\n message.price = DecCoin.decode(reader, reader.uint32());\n continue;\n }\n case 3: {\n if (tag !== 26) {\n break;\n }\n\n message.deposit = Deposit.decode(reader, reader.uint32());\n continue;\n }\n case 4: {\n if (tag !== 34) {\n break;\n }\n\n message.resourcesOffer.push(ResourceOffer.decode(reader, reader.uint32()));\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): MsgCreateBid {\n return {\n id: isSet(object.id) ? BidID.fromJSON(object.id) : undefined,\n price: isSet(object.price) ? DecCoin.fromJSON(object.price) : undefined,\n deposit: isSet(object.deposit) ? Deposit.fromJSON(object.deposit) : undefined,\n resourcesOffer: globalThis.Array.isArray(object?.resources_offer)\n ? object.resources_offer.map((e: any) => ResourceOffer.fromJSON(e))\n : [],\n };\n },\n\n toJSON(message: MsgCreateBid): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = BidID.toJSON(message.id);\n }\n if (message.price !== undefined) {\n obj.price = DecCoin.toJSON(message.price);\n }\n if (message.deposit !== undefined) {\n obj.deposit = Deposit.toJSON(message.deposit);\n }\n if (message.resourcesOffer?.length) {\n obj.resources_offer = message.resourcesOffer.map((e) => ResourceOffer.toJSON(e));\n }\n return obj;\n },\n fromPartial(object: DeepPartial<MsgCreateBid>): MsgCreateBid {\n const message = createBaseMsgCreateBid();\n message.id = (object.id !== undefined && object.id !== null) ? BidID.fromPartial(object.id) : undefined;\n message.price = (object.price !== undefined && object.price !== null)\n ? DecCoin.fromPartial(object.price)\n : undefined;\n message.deposit = (object.deposit !== undefined && object.deposit !== null)\n ? Deposit.fromPartial(object.deposit)\n : undefined;\n message.resourcesOffer = object.resourcesOffer?.map((e) => ResourceOffer.fromPartial(e)) || [];\n return message;\n },\n};\n\nfunction createBaseMsgCreateBidResponse(): MsgCreateBidResponse {\n return {};\n}\n\nexport const MsgCreateBidResponse: MessageFns<MsgCreateBidResponse, \"akash.market.v1beta5.MsgCreateBidResponse\"> = {\n $type: \"akash.market.v1beta5.MsgCreateBidResponse\" as const,\n\n encode(_: MsgCreateBidResponse, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCreateBidResponse {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCreateBidResponse();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(_: any): MsgCreateBidResponse {\n return {};\n },\n\n toJSON(_: MsgCreateBidResponse): unknown {\n const obj: any = {};\n return obj;\n },\n fromPartial(_: DeepPartial<MsgCreateBidResponse>): MsgCreateBidResponse {\n const message = createBaseMsgCreateBidResponse();\n return message;\n },\n};\n\nfunction createBaseMsgCloseBid(): MsgCloseBid {\n return { id: undefined, reason: 0 };\n}\n\nexport const MsgCloseBid: MessageFns<MsgCloseBid, \"akash.market.v1beta5.MsgCloseBid\"> = {\n $type: \"akash.market.v1beta5.MsgCloseBid\" as const,\n\n encode(message: MsgCloseBid, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n BidID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.reason !== 0) {\n writer.uint32(16).int32(message.reason);\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCloseBid {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCloseBid();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = BidID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.reason = reader.int32() as any;\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): MsgCloseBid {\n return {\n id: isSet(object.id) ? BidID.fromJSON(object.id) : undefined,\n reason: isSet(object.reason) ? leaseClosedReasonFromJSON(object.reason) : 0,\n };\n },\n\n toJSON(message: MsgCloseBid): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = BidID.toJSON(message.id);\n }\n if (message.reason !== 0) {\n obj.reason = leaseClosedReasonToJSON(message.reason);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<MsgCloseBid>): MsgCloseBid {\n const message = createBaseMsgCloseBid();\n message.id = (object.id !== undefined && object.id !== null) ? BidID.fromPartial(object.id) : undefined;\n message.reason = object.reason ?? 0;\n return message;\n },\n};\n\nfunction createBaseMsgCloseBidResponse(): MsgCloseBidResponse {\n return {};\n}\n\nexport const MsgCloseBidResponse: MessageFns<MsgCloseBidResponse, \"akash.market.v1beta5.MsgCloseBidResponse\"> = {\n $type: \"akash.market.v1beta5.MsgCloseBidResponse\" as const,\n\n encode(_: MsgCloseBidResponse, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCloseBidResponse {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCloseBidResponse();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(_: any): MsgCloseBidResponse {\n return {};\n },\n\n toJSON(_: MsgCloseBidResponse): unknown {\n const obj: any = {};\n return obj;\n },\n fromPartial(_: DeepPartial<MsgCloseBidResponse>): MsgCloseBidResponse {\n const message = createBaseMsgCloseBidResponse();\n return message;\n },\n};\n\ntype Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;\n\ntype _unused_DeepPartial<T> = T extends Builtin ? T\n : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>\n : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>\n : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }\n : Partial<T>;\n\nfunction _unused_isSet(value: any): boolean {\n return value !== null && value !== undefined;\n}\n\ninterface _unused_MessageFns<T, V extends string> {\n readonly $type: V;\n encode(message: T, writer?: BinaryWriter): BinaryWriter;\n decode(input: BinaryReader | Uint8Array, length?: number): T;\n fromJSON(object: any): T;\n toJSON(message: T): unknown;\n create(base?: DeepPartial<T>): T;\n fromPartial(object: DeepPartial<T>): T;\n}\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAsB;AAStB,kBAA2C;AAE3C,kBAAwB;AACxB,qBAAwB;AACxB,iBAAsB;AACtB,mBAAsF;AACtF,4BAA8B;AAkC9B,SAAS,yBAAuC;AAC9C,SAAO,EAAE,IAAI,QAAW,OAAO,QAAW,SAAS,QAAW,gBAAgB,CAAC,EAAE;AACnF;AAEO,MAAM,eAA8E;AAAA,EACzF,OAAO;AAAA,EAEP,OAAO,SAAuB,SAAuB,IAAI,yBAAa,GAAiB;AACrF,QAAI,QAAQ,OAAO,QAAW;AAC5B,uBAAM,OAAO,QAAQ,IAAI,OAAO,OAAO,EAAE,EAAE,KAAK,CAAC,EAAE,KAAK;AAAA,IAC1D;AACA,QAAI,QAAQ,UAAU,QAAW;AAC/B,0BAAQ,OAAO,QAAQ,OAAO,OAAO,OAAO,EAAE,EAAE,KAAK,CAAC,EAAE,KAAK;AAAA,IAC/D;AACA,QAAI,QAAQ,YAAY,QAAW;AACjC,6BAAQ,OAAO,QAAQ,SAAS,OAAO,OAAO,EAAE,EAAE,KAAK,CAAC,EAAE,KAAK;AAAA,IACjE;AACA,eAAW,KAAK,QAAQ,gBAAgB;AACtC,0CAAc,OAAO,GAAI,OAAO,OAAO,EAAE,EAAE,KAAK,CAAC,EAAE,KAAK;AAAA,IAC1D;AACA,WAAO;AAAA,EACT;AAAA,EAEA,OAAO,OAAk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S,iBAAiB,2BAAe,QAAQ,IAAI,yBAAa,KAAK;AAC7E,UAAM,MAAM,WAAW,SAAY,OAAO,MAAM,OAAO,MAAM;AAC7D,UAAM,UAAU,8BAA8B;AAC9C,WAAO,OAAO,MAAM,KAAK;AACvB,YAAM,MAAM,OAAO,OAAO;AAC1B,cAAQ,QAAQ,GAAG;AAAA,MACnB;AACA,WAAK,MAAM,OAAO,KAAK,QAAQ,GAAG;AAChC;AAAA,MACF;AACA,aAAO,KAAK,MAAM,CAAC;AAAA,IACrB;AACA,WAAO;AAAA,EACT;AAAA,EAEA,SAAS,GAA6B;AACpC,WAAO,CAAC;AAAA,EACV;AAAA,EAEA,OAAO,GAAiC;AACtC,UAAM,MAAW,CAAC;AAClB,WAAO;AAAA,EACT;AAAA,EACA,YAAY,GAA0D;AACpE,UAAM,UAAU,8BAA8B;AAC9C,WAAO;AAAA,EACT;AACF;AAUA,SAAS,cAAc,OAAqB;AAC1C,SAAO,UAAU,QAAQ,UAAU;AACrC;",
4
+ "sourcesContent": ["import { isSet } from \"../../../../../encoding/typeEncodingHelpers.ts\"\nimport type { DeepPartial, MessageFns } from \"../../../../../encoding/typeEncodingHelpers.ts\"\n// Code generated by protoc-gen-ts_proto. DO NOT EDIT.\n// versions:\n// protoc-gen-ts_proto v2.7.7\n// protoc unknown\n// source: akash/market/v1beta5/bidmsg.proto\n\n/* eslint-disable */\nimport { BinaryReader, BinaryWriter } from \"@bufbuild/protobuf/wire\";\nimport Long from \"long\";\nimport { DecCoin } from \"../../../cosmos/base/v1beta1/coin.ts\";\nimport { Duration } from \"../../../google/protobuf/duration.ts\";\nimport { Deposit } from \"../../base/deposit/v1/deposit.ts\";\nimport { BidID } from \"../v1/bid.ts\";\nimport { LeaseClosedReason, leaseClosedReasonFromJSON, leaseClosedReasonToJSON } from \"../v1/types.ts\";\nimport { ResourceOffer } from \"./resourcesoffer.ts\";\n\n/** MsgCreateBid defines an SDK message for creating Bid. */\nexport interface MsgCreateBid {\n id:\n | BidID\n | undefined;\n /** Price holds the pricing stated on the Bid. */\n price:\n | DecCoin\n | undefined;\n /** Deposit holds the amount of coins to deposit. */\n deposit:\n | Deposit\n | undefined;\n /** ResourceOffer is a list of resource offers. */\n resourcesOffer: ResourceOffer[];\n /**\n * reclamation_window is the reclamation window duration the provider offers.\n * If the order requires reclamation, this must be >= the order's min_window.\n * Nil means the provider does not offer reclamation on this bid.\n */\n reclamationWindow: Duration | undefined;\n}\n\n/** MsgCreateBidResponse defines the Msg/CreateBid response type. */\nexport interface MsgCreateBidResponse {\n}\n\n/** MsgCloseBid defines an SDK message for closing bid. */\nexport interface MsgCloseBid {\n /** Id is the unique identifier of the Bid. */\n id: BidID | undefined;\n reason: LeaseClosedReason;\n}\n\n/** MsgCloseBidResponse defines the Msg/CloseBid response type. */\nexport interface MsgCloseBidResponse {\n}\n\nfunction createBaseMsgCreateBid(): MsgCreateBid {\n return { id: undefined, price: undefined, deposit: undefined, resourcesOffer: [], reclamationWindow: undefined };\n}\n\nexport const MsgCreateBid: MessageFns<MsgCreateBid, \"akash.market.v1beta5.MsgCreateBid\"> = {\n $type: \"akash.market.v1beta5.MsgCreateBid\" as const,\n\n encode(message: MsgCreateBid, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n BidID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.price !== undefined) {\n DecCoin.encode(message.price, writer.uint32(18).fork()).join();\n }\n if (message.deposit !== undefined) {\n Deposit.encode(message.deposit, writer.uint32(26).fork()).join();\n }\n for (const v of message.resourcesOffer) {\n ResourceOffer.encode(v!, writer.uint32(34).fork()).join();\n }\n if (message.reclamationWindow !== undefined) {\n Duration.encode(message.reclamationWindow, writer.uint32(42).fork()).join();\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCreateBid {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCreateBid();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = BidID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 18) {\n break;\n }\n\n message.price = DecCoin.decode(reader, reader.uint32());\n continue;\n }\n case 3: {\n if (tag !== 26) {\n break;\n }\n\n message.deposit = Deposit.decode(reader, reader.uint32());\n continue;\n }\n case 4: {\n if (tag !== 34) {\n break;\n }\n\n message.resourcesOffer.push(ResourceOffer.decode(reader, reader.uint32()));\n continue;\n }\n case 5: {\n if (tag !== 42) {\n break;\n }\n\n message.reclamationWindow = Duration.decode(reader, reader.uint32());\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): MsgCreateBid {\n return {\n id: isSet(object.id) ? BidID.fromJSON(object.id) : undefined,\n price: isSet(object.price) ? DecCoin.fromJSON(object.price) : undefined,\n deposit: isSet(object.deposit) ? Deposit.fromJSON(object.deposit) : undefined,\n resourcesOffer: globalThis.Array.isArray(object?.resources_offer)\n ? object.resources_offer.map((e: any) => ResourceOffer.fromJSON(e))\n : [],\n reclamationWindow: isSet(object.reclamation_window) ? Duration.fromJSON(object.reclamation_window) : undefined,\n };\n },\n\n toJSON(message: MsgCreateBid): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = BidID.toJSON(message.id);\n }\n if (message.price !== undefined) {\n obj.price = DecCoin.toJSON(message.price);\n }\n if (message.deposit !== undefined) {\n obj.deposit = Deposit.toJSON(message.deposit);\n }\n if (message.resourcesOffer?.length) {\n obj.resources_offer = message.resourcesOffer.map((e) => ResourceOffer.toJSON(e));\n }\n if (message.reclamationWindow !== undefined) {\n obj.reclamation_window = Duration.toJSON(message.reclamationWindow);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<MsgCreateBid>): MsgCreateBid {\n const message = createBaseMsgCreateBid();\n message.id = (object.id !== undefined && object.id !== null) ? BidID.fromPartial(object.id) : undefined;\n message.price = (object.price !== undefined && object.price !== null)\n ? DecCoin.fromPartial(object.price)\n : undefined;\n message.deposit = (object.deposit !== undefined && object.deposit !== null)\n ? Deposit.fromPartial(object.deposit)\n : undefined;\n message.resourcesOffer = object.resourcesOffer?.map((e) => ResourceOffer.fromPartial(e)) || [];\n message.reclamationWindow = (object.reclamationWindow !== undefined && object.reclamationWindow !== null)\n ? Duration.fromPartial(object.reclamationWindow)\n : undefined;\n return message;\n },\n};\n\nfunction createBaseMsgCreateBidResponse(): MsgCreateBidResponse {\n return {};\n}\n\nexport const MsgCreateBidResponse: MessageFns<MsgCreateBidResponse, \"akash.market.v1beta5.MsgCreateBidResponse\"> = {\n $type: \"akash.market.v1beta5.MsgCreateBidResponse\" as const,\n\n encode(_: MsgCreateBidResponse, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCreateBidResponse {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCreateBidResponse();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(_: any): MsgCreateBidResponse {\n return {};\n },\n\n toJSON(_: MsgCreateBidResponse): unknown {\n const obj: any = {};\n return obj;\n },\n fromPartial(_: DeepPartial<MsgCreateBidResponse>): MsgCreateBidResponse {\n const message = createBaseMsgCreateBidResponse();\n return message;\n },\n};\n\nfunction createBaseMsgCloseBid(): MsgCloseBid {\n return { id: undefined, reason: 0 };\n}\n\nexport const MsgCloseBid: MessageFns<MsgCloseBid, \"akash.market.v1beta5.MsgCloseBid\"> = {\n $type: \"akash.market.v1beta5.MsgCloseBid\" as const,\n\n encode(message: MsgCloseBid, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n if (message.id !== undefined) {\n BidID.encode(message.id, writer.uint32(10).fork()).join();\n }\n if (message.reason !== 0) {\n writer.uint32(16).int32(message.reason);\n }\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCloseBid {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCloseBid();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n case 1: {\n if (tag !== 10) {\n break;\n }\n\n message.id = BidID.decode(reader, reader.uint32());\n continue;\n }\n case 2: {\n if (tag !== 16) {\n break;\n }\n\n message.reason = reader.int32() as any;\n continue;\n }\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(object: any): MsgCloseBid {\n return {\n id: isSet(object.id) ? BidID.fromJSON(object.id) : undefined,\n reason: isSet(object.reason) ? leaseClosedReasonFromJSON(object.reason) : 0,\n };\n },\n\n toJSON(message: MsgCloseBid): unknown {\n const obj: any = {};\n if (message.id !== undefined) {\n obj.id = BidID.toJSON(message.id);\n }\n if (message.reason !== 0) {\n obj.reason = leaseClosedReasonToJSON(message.reason);\n }\n return obj;\n },\n fromPartial(object: DeepPartial<MsgCloseBid>): MsgCloseBid {\n const message = createBaseMsgCloseBid();\n message.id = (object.id !== undefined && object.id !== null) ? BidID.fromPartial(object.id) : undefined;\n message.reason = object.reason ?? 0;\n return message;\n },\n};\n\nfunction createBaseMsgCloseBidResponse(): MsgCloseBidResponse {\n return {};\n}\n\nexport const MsgCloseBidResponse: MessageFns<MsgCloseBidResponse, \"akash.market.v1beta5.MsgCloseBidResponse\"> = {\n $type: \"akash.market.v1beta5.MsgCloseBidResponse\" as const,\n\n encode(_: MsgCloseBidResponse, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {\n return writer;\n },\n\n decode(input: BinaryReader | Uint8Array, length?: number): MsgCloseBidResponse {\n const reader = input instanceof BinaryReader ? input : new BinaryReader(input);\n const end = length === undefined ? reader.len : reader.pos + length;\n const message = createBaseMsgCloseBidResponse();\n while (reader.pos < end) {\n const tag = reader.uint32();\n switch (tag >>> 3) {\n }\n if ((tag & 7) === 4 || tag === 0) {\n break;\n }\n reader.skip(tag & 7);\n }\n return message;\n },\n\n fromJSON(_: any): MsgCloseBidResponse {\n return {};\n },\n\n toJSON(_: MsgCloseBidResponse): unknown {\n const obj: any = {};\n return obj;\n },\n fromPartial(_: DeepPartial<MsgCloseBidResponse>): MsgCloseBidResponse {\n const message = createBaseMsgCloseBidResponse();\n return message;\n },\n};\n\ntype Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;\n\ntype _unused_DeepPartial<T> = T extends Builtin ? T\n : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>\n : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>\n : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }\n : Partial<T>;\n\nfunction _unused_isSet(value: any): boolean {\n return value !== null && value !== undefined;\n}\n\ninterface _unused_MessageFns<T, V extends string> {\n readonly $type: V;\n encode(message: T, writer?: BinaryWriter): BinaryWriter;\n decode(input: BinaryReader | Uint8Array, length?: number): T;\n fromJSON(object: any): T;\n toJSON(message: T): unknown;\n create(base?: DeepPartial<T>): T;\n fromPartial(object: DeepPartial<T>): T;\n}\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAsB;AAStB,kBAA2C;AAE3C,kBAAwB;AACxB,sBAAyB;AACzB,qBAAwB;AACxB,iBAAsB;AACtB,mBAAsF;AACtF,4BAA8B;AAwC9B,SAAS,yBAAuC;AAC9C,SAAO,EAAE,IAAI,QAAW,OAAO,QAAW,SAAS,QAAW,gBAAgB,CAAC,GAAG,mBAAmB,OAAU;AACjH;AAEO,MAAM,eAA8E;AAAA,EACzF,OAAO;AAAA,EA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