Files
api/packages/api-contract/src/v2.test.json
T
satellitex 53959d482d Add BTreeSet<V> Codec (#1639)
* add BTreeSet Codec

* Add following BTreeMap

* fix linting

* fix linting

* add validate Types and encode Types

* type def info is incremented.

* fix compareSet
2019-12-18 16:22:54 +01:00

1414 lines
33 KiB
JSON

[
{
"info": 8,
"type": "{\"my_tuple_struct\": {\"cell\": {\"cell\": ([u8;32])}}, \"my_struct\": {\"cell\": {\"cell\": ([u8;32])}}, \"my_clike_enum\": {\"cell\": {\"cell\": ([u8;32])}}, \"my_enum\": {\"cell\": {\"cell\": ([u8;32])}}, \"my_union\": {\"cell\": {\"cell\": ([u8;32])}}}",
"name": "RustStructures",
"namespace": "structures::normal",
"sub": [
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "my_tuple_struct",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 9,
"type": "(u8, u16)",
"name": "TupleStruct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 9,
"type": "(u8, u16)",
"name": "TupleStruct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "my_struct",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 8,
"type": "{\"first\": u8, \"seconds\": u16}",
"name": "Struct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "seconds"
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 8,
"type": "{\"first\": u8, \"seconds\": u16}",
"name": "Struct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "seconds"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "my_clike_enum",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 3,
"type": "[\"FirstVariant\", \"SecondVariant\", \"ThirdVariant\"]",
"name": "ClikeEnum",
"namespace": "structures",
"sub": [
{
"ext": {
"discriminant": 0
},
"info": 6,
"name": "FirstVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 1
},
"info": 6,
"name": "SecondVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 42
},
"info": 6,
"name": "ThirdVariant",
"type": "Null"
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 3,
"type": "[\"FirstVariant\", \"SecondVariant\", \"ThirdVariant\"]",
"name": "ClikeEnum",
"namespace": "structures",
"sub": [
{
"ext": {
"discriminant": 0
},
"info": 6,
"name": "FirstVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 1
},
"info": 6,
"name": "SecondVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 42
},
"info": 6,
"name": "ThirdVariant",
"type": "Null"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "my_enum",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 3,
"type": "{\"NoData\": Null, \"TupleVariant\": (u8, u16), \"StructVariant\": {\"first\": u8, \"second\": u16}}",
"name": "RustEnum",
"namespace": "structures",
"sub": [
{
"info": 6,
"name": "NoData",
"type": "Null"
},
{
"info": 9,
"name": "TupleVariant",
"type": "(u8, u16)",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
},
{
"info": 8,
"name": "StructVariant",
"type": "{\"first\": u8, \"second\": u16}",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 3,
"type": "{\"NoData\": Null, \"TupleVariant\": (u8, u16), \"StructVariant\": {\"first\": u8, \"second\": u16}}",
"name": "RustEnum",
"namespace": "structures",
"sub": [
{
"info": 6,
"name": "NoData",
"type": "Null"
},
{
"info": 9,
"name": "TupleVariant",
"type": "(u8, u16)",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
},
{
"info": 8,
"name": "StructVariant",
"type": "{\"first\": u8, \"second\": u16}",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "my_union",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 10,
"type": "{\"first\": u8, \"second\": u16}",
"name": "Union",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 10,
"type": "{\"first\": u8, \"second\": u16}",
"name": "Union",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "Value",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 9,
"type": "(u8, u16)",
"name": "TupleStruct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 9,
"type": "(u8, u16)",
"name": "TupleStruct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 9,
"type": "(u8, u16)",
"name": "TupleStruct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
},
{
"info": 6,
"type": "u8"
},
{
"info": 6,
"type": "u16"
},
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "SyncCell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 9,
"type": "(u8, u16)",
"name": "TupleStruct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
},
{
"info": 9,
"type": "([u8;32])",
"name": "Key",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
},
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
}
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "Value",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 8,
"type": "{\"first\": u8, \"seconds\": u16}",
"name": "Struct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "seconds"
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 8,
"type": "{\"first\": u8, \"seconds\": u16}",
"name": "Struct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "seconds"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 8,
"type": "{\"first\": u8, \"seconds\": u16}",
"name": "Struct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "seconds"
}
]
},
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "SyncCell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 8,
"type": "{\"first\": u8, \"seconds\": u16}",
"name": "Struct",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "seconds"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "Value",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 3,
"type": "[\"FirstVariant\", \"SecondVariant\", \"ThirdVariant\"]",
"name": "ClikeEnum",
"namespace": "structures",
"sub": [
{
"ext": {
"discriminant": 0
},
"info": 6,
"name": "FirstVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 1
},
"info": 6,
"name": "SecondVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 42
},
"info": 6,
"name": "ThirdVariant",
"type": "Null"
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 3,
"type": "[\"FirstVariant\", \"SecondVariant\", \"ThirdVariant\"]",
"name": "ClikeEnum",
"namespace": "structures",
"sub": [
{
"ext": {
"discriminant": 0
},
"info": 6,
"name": "FirstVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 1
},
"info": 6,
"name": "SecondVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 42
},
"info": 6,
"name": "ThirdVariant",
"type": "Null"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 3,
"type": "[\"FirstVariant\", \"SecondVariant\", \"ThirdVariant\"]",
"name": "ClikeEnum",
"namespace": "structures",
"sub": [
{
"ext": {
"discriminant": 0
},
"info": 6,
"name": "FirstVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 1
},
"info": 6,
"name": "SecondVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 42
},
"info": 6,
"name": "ThirdVariant",
"type": "Null"
}
]
},
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "SyncCell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 3,
"type": "[\"FirstVariant\", \"SecondVariant\", \"ThirdVariant\"]",
"name": "ClikeEnum",
"namespace": "structures",
"sub": [
{
"ext": {
"discriminant": 0
},
"info": 6,
"name": "FirstVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 1
},
"info": 6,
"name": "SecondVariant",
"type": "Null"
},
{
"ext": {
"discriminant": 42
},
"info": 6,
"name": "ThirdVariant",
"type": "Null"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "Value",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 3,
"type": "{\"NoData\": Null, \"TupleVariant\": (u8, u16), \"StructVariant\": {\"first\": u8, \"second\": u16}}",
"name": "RustEnum",
"namespace": "structures",
"sub": [
{
"info": 6,
"name": "NoData",
"type": "Null"
},
{
"info": 9,
"name": "TupleVariant",
"type": "(u8, u16)",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
},
{
"info": 8,
"name": "StructVariant",
"type": "{\"first\": u8, \"second\": u16}",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 3,
"type": "{\"NoData\": Null, \"TupleVariant\": (u8, u16), \"StructVariant\": {\"first\": u8, \"second\": u16}}",
"name": "RustEnum",
"namespace": "structures",
"sub": [
{
"info": 6,
"name": "NoData",
"type": "Null"
},
{
"info": 9,
"name": "TupleVariant",
"type": "(u8, u16)",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
},
{
"info": 8,
"name": "StructVariant",
"type": "{\"first\": u8, \"second\": u16}",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 3,
"type": "{\"NoData\": Null, \"TupleVariant\": (u8, u16), \"StructVariant\": {\"first\": u8, \"second\": u16}}",
"name": "RustEnum",
"namespace": "structures",
"sub": [
{
"info": 6,
"name": "NoData",
"type": "Null"
},
{
"info": 9,
"name": "TupleVariant",
"type": "(u8, u16)",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
},
{
"info": 8,
"name": "StructVariant",
"type": "{\"first\": u8, \"second\": u16}",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "SyncCell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 3,
"type": "{\"NoData\": Null, \"TupleVariant\": (u8, u16), \"StructVariant\": {\"first\": u8, \"second\": u16}}",
"name": "RustEnum",
"namespace": "structures",
"sub": [
{
"info": 6,
"name": "NoData",
"type": "Null"
},
{
"info": 9,
"name": "TupleVariant",
"type": "(u8, u16)",
"sub": [
{
"info": 6,
"type": "u8",
"index": 0
},
{
"info": 6,
"type": "u16",
"index": 1
}
]
},
{
"info": 8,
"name": "StructVariant",
"type": "{\"first\": u8, \"second\": u16}",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
},
{
"info": 8,
"type": "{\"cell\": {\"cell\": ([u8;32])}}",
"name": "Value",
"namespace": "ink_core::storage::value",
"params": [
{
"info": 10,
"type": "{\"first\": u8, \"second\": u16}",
"name": "Union",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
],
"sub": [
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "cell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 10,
"type": "{\"first\": u8, \"second\": u16}",
"name": "Union",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]
},
{
"info": 10,
"type": "{\"first\": u8, \"second\": u16}",
"name": "Union",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
},
{
"info": 8,
"type": "{\"cell\": ([u8;32])}",
"name": "SyncCell",
"namespace": "ink_core::storage::cell::sync_cell",
"params": [
{
"info": 10,
"type": "{\"first\": u8, \"second\": u16}",
"name": "Union",
"namespace": "structures",
"sub": [
{
"info": 6,
"type": "u8",
"name": "first"
},
{
"info": 6,
"type": "u16",
"name": "second"
}
]
}
],
"sub": [
{
"info": 9,
"type": "([u8;32])",
"name": "cell",
"namespace": "ink_core::storage::key",
"sub": [
{
"info": 12,
"type": "[u8;32]",
"ext": {
"length": 32,
"type": ""
},
"sub": {
"info": 6,
"type": "u8"
},
"index": 0
}
]
}
]
}
]