Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Socket
Sign inDemoInstall

@neo-one/client-common

Package Overview
Dependencies
Maintainers
3
Versions
64
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@neo-one/client-common - npm Package Compare versions

Comparing version 2.6.0 to 2.6.1-alpha.5

1

dist/cjs/BinaryWriter.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.BinaryWriter = void 0;
const bn_js_1 = require("bn.js");

@@ -4,0 +5,0 @@ const common_1 = require("./common");

46

dist/cjs/common.d.ts

@@ -58,10 +58,10 @@ /// <reference types="node" />

GAS_ASSET_HASH: string;
uInt160ToBuffer: (value: string | UInt160) => Buffer;
uInt160ToBuffer: (value: UInt160 | UInt160Hex) => Buffer;
add0x: (value: string) => string;
strip0x: (value: string) => string;
asUInt160: (value: {}) => UInt160;
uInt160ToHex: (value: UInt160) => string;
hexToUInt160: (value: string | UInt160) => UInt160;
uInt160ToString: (value: string | UInt160) => string;
stringToUInt160: (value: string | UInt160) => UInt160;
uInt160ToHex: (value: UInt160) => UInt160Hex;
hexToUInt160: (value: UInt160Hex | UInt160) => UInt160;
uInt160ToString: (value: UInt160 | UInt160Hex) => string;
stringToUInt160: (value: UInt160Hex | UInt160) => UInt160;
uInt160Equal: (a: UInt160, b: UInt160) => boolean;

@@ -74,32 +74,32 @@ isUInt160: (value: {}) => value is UInt160;

asECPoint: (value: {}) => ECPoint;
uInt256ToBuffer: (value: string | UInt256) => Buffer;
uInt256ToBuffer: (value: UInt256 | UInt256Hex) => Buffer;
bufferToUInt256: (value: {}) => UInt256;
uInt256ToHex: (value: UInt256) => string;
hexToUInt256: (value: string | UInt256) => UInt256;
uInt256ToString: (value: string | UInt256) => string;
stringToUInt256: (value: string | UInt256) => UInt256;
uInt256ToHex: (value: UInt256) => UInt256Hex;
hexToUInt256: (value: UInt256Hex | UInt256) => UInt256;
uInt256ToString: (value: UInt256 | UInt256Hex) => string;
stringToUInt256: (value: UInt256Hex | UInt256) => UInt256;
uInt256Equal: (a: UInt256, b: UInt256) => boolean;
toUInt32LE: (bytes: UInt256) => number;
ecPointToBuffer: (value: string | ECPointBase | ECPointInfinity) => Buffer;
ecPointToBuffer: (value: ECPoint | ECPointHex) => Buffer;
bufferToECPoint: (value: {}) => ECPoint;
ecPointToHex: (value: string | ECPointBase | ECPointInfinity) => string;
hexToECPoint: (value: string | ECPointBase | ECPointInfinity) => ECPoint;
ecPointToString: (value: string | ECPointBase | ECPointInfinity) => string;
ecPointCompare: (a: string | ECPointBase | ECPointInfinity, b: string | ECPointBase | ECPointInfinity) => 0 | 1 | -1;
stringToECPoint: (value: string | ECPointBase | ECPointInfinity) => ECPoint;
ecPointToHex: (value: ECPoint | ECPointHex) => ECPointHex;
hexToECPoint: (value: ECPoint | ECPointHex) => ECPoint;
ecPointToString: (value: ECPoint | ECPointHex) => string;
ecPointCompare: (a: ECPoint | ECPointHex, b: ECPoint | ECPointHex) => 0 | 1 | -1;
stringToECPoint: (value: ECPoint | ECPointHex) => ECPoint;
ecPointEqual: (a: ECPoint, b: ECPoint) => boolean;
ecPointIsInfinity: (value: ECPoint) => boolean;
privateKeyToHex: (value: string | PrivateKey) => string;
hexToPrivateKey: (value: string | PrivateKey) => PrivateKey;
privateKeyToBuffer: (value: string | PrivateKey) => Buffer;
privateKeyToHex: (value: PrivateKey | PrivateKeyHex) => PrivateKeyHex;
hexToPrivateKey: (value: PrivateKey | PrivateKeyHex) => PrivateKey;
privateKeyToBuffer: (value: PrivateKey | PrivateKeyHex) => Buffer;
bufferToPrivateKey: (value: {}) => PrivateKey;
privateKeyToString: (value: string | PrivateKey) => string;
stringToPrivateKey: (value: string | PrivateKey) => PrivateKey;
privateKeyToString: (value: PrivateKey | PrivateKeyHex) => string;
stringToPrivateKey: (value: PrivateKey | PrivateKeyHex) => PrivateKey;
isPrivateKey: (value: {}) => value is PrivateKey;
asPrivateKey: (value: {}) => PrivateKey;
fixed8FromDecimal: (value: string | number | BigNumber | BN) => BN;
fixed8FromDecimal: (value: number | string | BigNumber | BN) => BN;
fixed8ToDecimal: (bn: BN) => BigNumber;
fixedFromDecimal: (value: string | number | BigNumber | BN, decimals: number) => BN;
fixedFromDecimal: (value: number | string | BigNumber | BN, decimals: number) => BN;
fixedToDecimal: (value: BN, decimals: number) => BigNumber;
reverse: (src: Buffer) => Buffer;
};
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.common = exports.InvalidFormatError = void 0;
const tslib_1 = require("tslib");

@@ -4,0 +5,0 @@ const utils_1 = require("@neo-one/utils");

import BigNumber from 'bignumber.js';
import { AddressABI, ArrayABI, BooleanABI, BufferABI, ContractParameter, ForwardValueABI, Hash256ABI, IntegerABI, MapABI, ObjectABI, PublicKeyABI, Return, SignatureABI, StringABI, VoidABI } from './types';
import { AddressABI, AddressString, ArrayABI, BooleanABI, BufferABI, BufferString, ContractParameter, ForwardValueABI, Hash256ABI, Hash256String, IntegerABI, MapABI, ObjectABI, PublicKeyABI, PublicKeyString, Return, SignatureABI, SignatureString, StringABI, VoidABI } from './types';
export declare const contractParameters: {
String: (contractParameter: ContractParameter, parameter: StringABI) => Return;
Address: (contractParameter: ContractParameter, parameter: AddressABI) => Return;
Hash256: (contractParameter: ContractParameter, parameter: Hash256ABI) => Return;
PublicKey: (contractParameter: ContractParameter, parameter: PublicKeyABI) => Return;
Integer: (contractParameter: ContractParameter, parameter: IntegerABI) => Return;
Boolean: (contractParameter: ContractParameter, parameter: BooleanABI) => Return;
Signature: (contractParameter: ContractParameter, parameter: SignatureABI) => Return;
Buffer: (contractParameter: ContractParameter, parameter: BufferABI) => Return;
Array: (contractParameter: ContractParameter, parameter: ArrayABI) => Return;
Map: (contractParameter: ContractParameter, parameter: MapABI) => Return;
Object: (contractParameter: ContractParameter, parameter: ObjectABI) => Return;
Void: (contractParameter: ContractParameter, parameter: VoidABI) => Return;
ForwardValue: (contractParameter: ContractParameter, parameter: ForwardValueABI) => Return;
String: (contractParameter: ContractParameter, parameter: StringABI) => Return | undefined;
Address: (contractParameter: ContractParameter, parameter: AddressABI) => Return | undefined;
Hash256: (contractParameter: ContractParameter, parameter: Hash256ABI) => Return | undefined;
PublicKey: (contractParameter: ContractParameter, parameter: PublicKeyABI) => Return | undefined;
Integer: (contractParameter: ContractParameter, parameter: IntegerABI) => Return | undefined;
Boolean: (contractParameter: ContractParameter, parameter: BooleanABI) => Return | undefined;
Signature: (contractParameter: ContractParameter, parameter: SignatureABI) => Return | undefined;
Buffer: (contractParameter: ContractParameter, parameter: BufferABI) => Return | undefined;
Array: (contractParameter: ContractParameter, parameter: ArrayABI) => Return | undefined;
Map: (contractParameter: ContractParameter, parameter: MapABI) => Return | undefined;
Object: (contractParameter: ContractParameter, parameter: ObjectABI) => Return | undefined;
Void: (contractParameter: ContractParameter, parameter: VoidABI) => Return | undefined;
ForwardValue: (contractParameter: ContractParameter, parameter: ForwardValueABI) => Return | undefined;
};

@@ -21,8 +21,8 @@ export declare const smartContractConverters: {

toStringNullable: (param: ContractParameter) => string | undefined;
toAddress: (contractParameter: ContractParameter) => string;
toAddressNullable: (param: ContractParameter) => string | undefined;
toHash256: (contractParameter: ContractParameter) => string;
toHash256Nullable: (param: ContractParameter) => string | undefined;
toPublicKey: (contractParameter: ContractParameter) => string;
toPublicKeyNullable: (param: ContractParameter) => string | undefined;
toAddress: (contractParameter: ContractParameter) => AddressString;
toAddressNullable: (param: ContractParameter) => AddressString | undefined;
toHash256: (contractParameter: ContractParameter) => Hash256String;
toHash256Nullable: (param: ContractParameter) => Hash256String | undefined;
toPublicKey: (contractParameter: ContractParameter) => PublicKeyString;
toPublicKeyNullable: (param: ContractParameter) => PublicKeyString | undefined;
toInteger: (contractParameter: ContractParameter, parameter: IntegerABI) => BigNumber;

@@ -32,10 +32,10 @@ toIntegerNullable: (param: ContractParameter, abi: IntegerABI) => BigNumber | undefined;

toBooleanNullable: (param: ContractParameter) => boolean | undefined;
toSignature: (contractParameter: ContractParameter) => string;
toSignatureNullable: (param: ContractParameter) => string | undefined;
toBuffer: (contractParameter: ContractParameter) => string;
toBufferNullable: (param: ContractParameter) => string | undefined;
toSignature: (contractParameter: ContractParameter) => SignatureString;
toSignatureNullable: (param: ContractParameter) => SignatureString | undefined;
toBuffer: (contractParameter: ContractParameter) => BufferString;
toBufferNullable: (param: ContractParameter) => BufferString | undefined;
toArray: (contractParameter: ContractParameter, parameter: ArrayABI) => readonly Return[];
toArrayNullable: (param: ContractParameter, abi: ArrayABI) => readonly Return[] | undefined;
toArrayNullable: (param: ContractParameter, abi: ArrayABI) => ReadonlyArray<Return | undefined> | undefined;
toMap: (contractParameter: ContractParameter, parameter: MapABI) => ReadonlyMap<Return, Return>;
toMapNullable: (param: ContractParameter, abi: MapABI) => ReadonlyMap<Return, Return> | undefined;
toMapNullable: (param: ContractParameter, abi: MapABI) => ReadonlyMap<Return | undefined, Return | undefined> | undefined;
toObject: (contractParameter: ContractParameter, parameter: ObjectABI) => {

@@ -48,7 +48,7 @@ readonly [key: string]: Return;

toInteropInterface: (_contractParameter: ContractParameter) => undefined;
toInteropInterfaceNullable: (param: ContractParameter) => undefined;
toInteropInterfaceNullable: (param: ContractParameter) => undefined | undefined;
toVoid: (_contractParameter: ContractParameter) => undefined;
toVoidNullable: (param: ContractParameter) => undefined;
toVoidNullable: (param: ContractParameter) => undefined | undefined;
toForwardValue: (contractParameter: ContractParameter) => ContractParameter;
toForwardValueNullable: (param: ContractParameter) => undefined;
toForwardValueNullable: (param: ContractParameter) => undefined | undefined;
};
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.smartContractConverters = exports.contractParameters = void 0;
const utils_1 = require("@neo-one/utils");

@@ -147,3 +148,6 @@ const common_1 = require("./common");

const valueConverter = exports.contractParameters[value.type];
return new Map(contractParameter.value.map((val) => [keyConverter(val[0], key), valueConverter(val[1], value)]));
return new Map(contractParameter.value.map((val) => [
keyConverter(val[0], key),
valueConverter(val[1], value),
]));
};

@@ -150,0 +154,0 @@ const toObject = (contractParameter, parameter) => {

@@ -79,5 +79,5 @@ /// <reference types="node" />

parseExtendedKey: (key: string) => HDNode;
parseMasterSeed: (seedIn: string | Buffer) => HDNode;
parseMasterSeed: (seedIn: Buffer | string) => HDNode;
deriveChildKey: (node: HDNode, index: number, hardened: boolean) => HDNode;
serializeHDNode: (node: HDNode, privateNode?: boolean) => string;
};
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.crypto = void 0;
const tslib_1 = require("tslib");

@@ -4,0 +5,0 @@ const ec_key_1 = tslib_1.__importDefault(require("@neo-one/ec-key"));

@@ -16,3 +16,3 @@ /// <reference types="node" />

export declare const InvalidContractParameterError: {
new (parameter: ContractParameter, expected: readonly ("Address" | "Array" | "Boolean" | "Buffer" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface")[]): {
new (parameter: ContractParameter, expected: readonly ("Buffer" | "Address" | "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface")[]): {
readonly name: string;

@@ -19,0 +19,0 @@ readonly code: string;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.InvalidBIP32SerializePrivateNodeError = exports.InvalidBIP32HardenedError = exports.InvalidBIP32ChildIndexError = exports.InvalidBIP32ExtendedKeyError = exports.InvalidBIP32VersionError = exports.InvalidSignaturesError = exports.InvalidVMByteCodeError = exports.InvalidTransactionTypeError = exports.InvalidAttributeUsageJSONError = exports.InvalidAttributeUsageError = exports.InvalidContractParameterTypeError = exports.InvalidContractParameterTypeJSONError = exports.InvalidStateDescriptorTypeError = exports.InvalidStorageFlagsError = exports.InvalidStorageFlagsJSONError = exports.InvalidAssetTypeError = exports.InvalidAssetTypeJSONError = exports.InvalidParamError = exports.InvalidVMStateError = exports.InvalidSysCallError = exports.InvalidSignatureError = exports.InvalidPrivateKeyError = exports.InvalidNumberOfKeysError = exports.TooManyPublicKeysError = exports.InvalidAddressError = exports.Base58CheckError = exports.InvalidContractParameterError = exports.UnknownOpError = void 0;
const utils_1 = require("@neo-one/utils");

@@ -4,0 +5,0 @@ const common_1 = require("./common");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.createPrivateKey = exports.decryptNEP2 = exports.encryptNEP2 = exports.isNEP2 = exports.privateKeyToPublicKey = exports.privateKeyToAddress = exports.privateKeyToScriptHash = exports.privateKeyToWIF = exports.wifToPrivateKey = exports.addressToScriptHash = exports.scriptHashToAddress = exports.publicKeyToAddress = exports.publicKeyToScriptHash = void 0;
const common_1 = require("./common");

@@ -4,0 +5,0 @@ const crypto_1 = require("./crypto");

@@ -15,4 +15,5 @@ "use strict";

tslib_1.__exportStar(require("./ScriptBuilder"), exports);
tslib_1.__exportStar(require("./types"), exports);
tslib_1.__exportStar(require("./utils"), exports);
//# sourceMappingURL=index.js.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.IOHelper = void 0;
const bn_js_1 = require("bn.js");

@@ -4,0 +5,0 @@ const common_1 = require("./common");

/// <reference types="node" />
import BigNumber from 'bignumber.js';
import BN from 'bn.js';
import { ECPoint, UInt160, UInt256 } from './common';
import { ECPoint, ECPointHex, UInt160, UInt160Hex, UInt256, UInt256Hex } from './common';
export declare const JSONHelper: {

@@ -10,9 +10,9 @@ writeUInt64LE: (value: BN) => string;

readUInt64: (value: string) => BigNumber;
writeUInt160: (value: string | UInt160) => string;
writeUInt160: (value: UInt160 | UInt160Hex) => string;
readUInt160: (hash: string) => UInt160;
writeUInt256: (value: string | UInt256) => string;
writeUInt256: (value: UInt256 | UInt256Hex) => string;
readUInt256: (hash: string) => UInt256;
writeFixed8: (value: BN) => string;
readFixed8: (value: string) => BN;
writeECPoint: (value: string | import("./common").ECPointBase | import("./common").ECPointInfinity) => string;
writeECPoint: (value: ECPoint | ECPointHex) => string;
readECPoint: (value: string) => ECPoint;

@@ -19,0 +19,0 @@ writeBuffer: (value: Buffer) => string;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.JSONHelper = void 0;
const tslib_1 = require("tslib");

@@ -4,0 +5,0 @@ const bignumber_js_1 = tslib_1.__importDefault(require("bignumber.js"));

@@ -0,1 +1,2 @@

import { AssetTypeJSON } from './types';
export declare enum AssetTypeModel {

@@ -13,4 +14,4 @@ CreditFlag = 64,

export declare const assertAssetType: (assetType: number) => AssetTypeModel;
export declare const toJSONAssetType: (type: AssetTypeModel) => "Currency" | "Share" | "Invoice" | "Token" | "CreditFlag" | "DutyFlag" | "GoverningToken" | "UtilityToken";
export declare const assertAssetTypeJSON: (type: string) => "Currency" | "Share" | "Invoice" | "Token" | "CreditFlag" | "DutyFlag" | "GoverningToken" | "UtilityToken";
export declare const toAssetType: (type: "Currency" | "Share" | "Invoice" | "Token" | "CreditFlag" | "DutyFlag" | "GoverningToken" | "UtilityToken") => AssetTypeModel;
export declare const toJSONAssetType: (type: AssetTypeModel) => AssetTypeJSON;
export declare const assertAssetTypeJSON: (type: string) => AssetTypeJSON;
export declare const toAssetType: (type: AssetTypeJSON) => AssetTypeModel;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.toAssetType = exports.assertAssetTypeJSON = exports.toJSONAssetType = exports.assertAssetType = exports.hasFlag = exports.AssetTypeModel = void 0;
const errors_1 = require("../errors");

@@ -4,0 +5,0 @@ var AssetTypeModel;

@@ -0,1 +1,2 @@

import { ContractParameterTypeJSON } from './types';
export declare enum ContractParameterTypeModel {

@@ -17,4 +18,4 @@ Signature = 0,

export declare const assertContractParameterType: (value: number) => ContractParameterTypeModel;
export declare const toJSONContractParameterType: (type: ContractParameterTypeModel) => "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface" | "Hash160" | "ByteArray";
export declare const assertContractParameterTypeJSON: (value: string) => "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface" | "Hash160" | "ByteArray";
export declare const toContractParameterType: (value: "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface" | "Hash160" | "ByteArray") => ContractParameterTypeModel;
export declare const toJSONContractParameterType: (type: ContractParameterTypeModel) => ContractParameterTypeJSON;
export declare const assertContractParameterTypeJSON: (value: string) => ContractParameterTypeJSON;
export declare const toContractParameterType: (value: ContractParameterTypeJSON) => ContractParameterTypeModel;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.toContractParameterType = exports.assertContractParameterTypeJSON = exports.toJSONContractParameterType = exports.assertContractParameterType = exports.isContractParameterType = exports.ContractParameterTypeModel = void 0;
const errors_1 = require("../errors");

@@ -4,0 +5,0 @@ var ContractParameterTypeModel;

@@ -11,4 +11,5 @@ "use strict";

tslib_1.__exportStar(require("./transaction"), exports);
tslib_1.__exportStar(require("./types"), exports);
tslib_1.__exportStar(require("./vm"), exports);
//# sourceMappingURL=index.js.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.createSerializeWire = void 0;
const BinaryWriter_1 = require("../BinaryWriter");

@@ -4,0 +5,0 @@ exports.createSerializeWire = (serializeWireBase) => () => {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.assertStateDescriptorType = exports.StateDescriptorTypeModel = void 0;
const errors_1 = require("../errors");

@@ -4,0 +5,0 @@ var StateDescriptorTypeModel;

@@ -0,1 +1,2 @@

import { StorageFlagsJSON } from './types';
export declare enum StorageFlagsModel {

@@ -7,4 +8,4 @@ None = 0,

export declare const assertStorageFlags: (storageFlags: number) => StorageFlagsModel;
export declare const toJSONStorageFlags: (type: StorageFlagsModel) => "None" | "Constant";
export declare const assertStorageFlagsJSON: (type: string) => "None" | "Constant";
export declare const toStorageFlags: (type: "None" | "Constant") => StorageFlagsModel;
export declare const toJSONStorageFlags: (type: StorageFlagsModel) => StorageFlagsJSON;
export declare const assertStorageFlagsJSON: (type: string) => StorageFlagsJSON;
export declare const toStorageFlags: (type: StorageFlagsJSON) => StorageFlagsModel;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.toStorageFlags = exports.assertStorageFlagsJSON = exports.toJSONStorageFlags = exports.assertStorageFlags = exports.hasStorageFlag = exports.StorageFlagsModel = void 0;
const errors_1 = require("../errors");

@@ -4,0 +5,0 @@ var StorageFlagsModel;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.AttributeBaseModel = void 0;
const Serializable_1 = require("../../Serializable");

@@ -4,0 +5,0 @@ class AttributeBaseModel {

@@ -0,1 +1,2 @@

import { AttributeUsageJSON } from '../../types';
export declare enum AttributeUsageModel {

@@ -42,5 +43,5 @@ ContractHash = 0,

export declare const assertAttributeUsage: (value: number) => AttributeUsageModel;
export declare const toJSONAttributeUsage: (usage: AttributeUsageModel) => import("../../..").AttributeUsage;
export declare const toJSONAttributeUsage: (usage: AttributeUsageModel) => AttributeUsageJSON;
export declare const isAttributeUsageJSON: (usage: string) => usage is import("../../..").AttributeUsage;
export declare const assertAttributeUsageJSON: (usage: string) => import("../../..").AttributeUsage;
export declare const toAttributeUsage: (usage: import("../../..").AttributeUsage) => AttributeUsageModel;
export declare const assertAttributeUsageJSON: (usage: string) => AttributeUsageJSON;
export declare const toAttributeUsage: (usage: AttributeUsageJSON) => AttributeUsageModel;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.toAttributeUsage = exports.assertAttributeUsageJSON = exports.isAttributeUsageJSON = exports.toJSONAttributeUsage = exports.assertAttributeUsage = exports.AttributeUsageModel = void 0;
const errors_1 = require("../../../errors");

@@ -4,0 +5,0 @@ var AttributeUsageModel;

/// <reference types="node" />
import { BinaryWriter } from '../../../BinaryWriter';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type BufferAttributeUsageModel = 0x81 | 0x90 | 0xf0 | 0xf1 | 0xf2 | 0xf3 | 0xf4 | 0xf5 | 0xf6 | 0xf7 | 0xf8 | 0xf9 | 0xfa | 0xfb | 0xfc | 0xfd | 0xfe | 0xff;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type BufferAttributeUsageModel = AttributeUsageModel.DescriptionUrl | AttributeUsageModel.Description | AttributeUsageModel.Remark | AttributeUsageModel.Remark1 | AttributeUsageModel.Remark2 | AttributeUsageModel.Remark3 | AttributeUsageModel.Remark4 | AttributeUsageModel.Remark5 | AttributeUsageModel.Remark6 | AttributeUsageModel.Remark7 | AttributeUsageModel.Remark8 | AttributeUsageModel.Remark9 | AttributeUsageModel.Remark10 | AttributeUsageModel.Remark11 | AttributeUsageModel.Remark12 | AttributeUsageModel.Remark13 | AttributeUsageModel.Remark14 | AttributeUsageModel.Remark15;
export interface BufferAttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: BufferAttributeUsageModel;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.BufferAttributeModel = void 0;
const AttributeBaseModel_1 = require("./AttributeBaseModel");

@@ -4,0 +5,0 @@ const AttributeUsageModel_1 = require("./AttributeUsageModel");

import { BinaryWriter } from '../../../BinaryWriter';
import { ECPoint } from '../../../common';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type ECPointAttributeUsageModel = 0x02 | 0x03;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type ECPointAttributeUsageModel = AttributeUsageModel.ECDH02 | AttributeUsageModel.ECDH03;
export interface ECPointAttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: ECPointAttributeUsageModel;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ECPointAttributeModel = void 0;
const common_1 = require("../../../common");

@@ -4,0 +5,0 @@ const AttributeBaseModel_1 = require("./AttributeBaseModel");

@@ -5,2 +5,3 @@ "use strict";

tslib_1.__exportStar(require("./AttributeBaseModel"), exports);
tslib_1.__exportStar(require("./AttributeModel"), exports);
tslib_1.__exportStar(require("./AttributeUsageModel"), exports);

@@ -7,0 +8,0 @@ tslib_1.__exportStar(require("./BufferAttributeModel"), exports);

import { BinaryWriter } from '../../../BinaryWriter';
import { UInt160 } from '../../../common';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type UInt160AttributeUsageModel = 0x20;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type UInt160AttributeUsageModel = AttributeUsageModel.Script;
export interface UInt160AttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: UInt160AttributeUsageModel;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.UInt160AttributeModel = void 0;
const AttributeBaseModel_1 = require("./AttributeBaseModel");

@@ -4,0 +5,0 @@ class UInt160AttributeModel extends AttributeBaseModel_1.AttributeBaseModel {

import { BinaryWriter } from '../../../BinaryWriter';
import { UInt256 } from '../../../common';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type UInt256AttributeUsageModel = 0x00 | 0x30 | 0xa1 | 0xa2 | 0xa3 | 0xa4 | 0xa5 | 0xa6 | 0xa7 | 0xa8 | 0xa9 | 0xaa | 0xab | 0xac | 0xad | 0xae | 0xaf;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type UInt256AttributeUsageModel = AttributeUsageModel.ContractHash | AttributeUsageModel.Vote | AttributeUsageModel.Hash1 | AttributeUsageModel.Hash2 | AttributeUsageModel.Hash3 | AttributeUsageModel.Hash4 | AttributeUsageModel.Hash5 | AttributeUsageModel.Hash6 | AttributeUsageModel.Hash7 | AttributeUsageModel.Hash8 | AttributeUsageModel.Hash9 | AttributeUsageModel.Hash10 | AttributeUsageModel.Hash11 | AttributeUsageModel.Hash12 | AttributeUsageModel.Hash13 | AttributeUsageModel.Hash14 | AttributeUsageModel.Hash15;
export interface UInt256AttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: UInt256AttributeUsageModel;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.UInt256AttributeModel = void 0;
const AttributeBaseModel_1 = require("./AttributeBaseModel");

@@ -4,0 +5,0 @@ class UInt256AttributeModel extends AttributeBaseModel_1.AttributeBaseModel {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ClaimTransactionModel = void 0;
const common_1 = require("../../common");

@@ -4,0 +5,0 @@ const TransactionBaseModel_1 = require("./TransactionBaseModel");

@@ -10,4 +10,5 @@ "use strict";

tslib_1.__exportStar(require("./TransactionBaseModel"), exports);
tslib_1.__exportStar(require("./TransactionModel"), exports);
tslib_1.__exportStar(require("./TransactionTypeModel"), exports);
//# sourceMappingURL=index.js.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.InputModel = void 0;
const common_1 = require("../../common");

@@ -4,0 +5,0 @@ const IOHelper_1 = require("../../IOHelper");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.InvocationTransactionModel = void 0;
const utils_1 = require("@neo-one/utils");

@@ -4,0 +5,0 @@ const common_1 = require("../../common");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.OutputModel = void 0;
const IOHelper_1 = require("../../IOHelper");

@@ -4,0 +5,0 @@ const Serializable_1 = require("../Serializable");

@@ -34,5 +34,5 @@ /// <reference types="node" />

readonly serializeUnsigned: SerializeWire;
private readonly hashInternal;
private readonly hashHexInternal;
private readonly messageInternal;
readonly hashInternal: () => UInt256;
readonly hashHexInternal: () => string;
readonly messageInternal: () => Buffer;
constructor({ version, type, attributes, inputs, outputs, scripts, hash, }: TransactionBaseModelAddWithType<Type, TAttribute, TInput, TOutput, TWitness>);

@@ -39,0 +39,0 @@ abstract clone(options: {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.TransactionBaseModel = exports.MAX_TRANSACTION_ATTRIBUTES = void 0;
const common_1 = require("../../common");

@@ -4,0 +5,0 @@ const crypto_1 = require("../../crypto");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.assertTransactionType = exports.TransactionTypeModel = void 0;
const errors_1 = require("../../errors");

@@ -4,0 +5,0 @@ var TransactionTypeModel;

@@ -200,3 +200,3 @@ /// <reference types="node" />

export declare const isByteCode: (value: number) => value is Op;
export declare const assertByteCode: (value: number) => Op;
export declare const assertByteCode: (value: number) => ByteCode;
export declare enum SysCall {

@@ -203,0 +203,0 @@ 'System.Runtime.Platform' = "System.Runtime.Platform",

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.toSysCallHash = exports.sha256 = exports.assertVMState = exports.VMState = exports.assertSysCall = exports.SysCall = exports.assertByteCode = exports.isByteCode = exports.ByteBuffer = exports.Byte = exports.Op = void 0;
const tslib_1 = require("tslib");

@@ -4,0 +5,0 @@ const crypto_1 = require("crypto");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.WitnessModel = void 0;
const Serializable_1 = require("./Serializable");

@@ -4,0 +5,0 @@ class WitnessModel {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.deserializeParam = exports.serializeParam = exports.deserializeScriptBuilderParam = exports.serializeScriptBuilderParam = exports.paramTo = exports.isForwardValue = exports.scriptBuilderParamTo = void 0;
const tslib_1 = require("tslib");

@@ -4,0 +5,0 @@ const bignumber_js_1 = tslib_1.__importDefault(require("bignumber.js"));

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ScriptBuilder = void 0;
const bn_js_1 = require("bn.js");

@@ -4,0 +5,0 @@ const BinaryWriter_1 = require("./BinaryWriter");

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.utils = void 0;
const tslib_1 = require("tslib");

@@ -4,0 +5,0 @@ const bignumber_js_1 = tslib_1.__importDefault(require("bignumber.js"));

@@ -58,10 +58,10 @@ /// <reference types="node" />

GAS_ASSET_HASH: string;
uInt160ToBuffer: (value: string | UInt160) => Buffer;
uInt160ToBuffer: (value: UInt160 | UInt160Hex) => Buffer;
add0x: (value: string) => string;
strip0x: (value: string) => string;
asUInt160: (value: {}) => UInt160;
uInt160ToHex: (value: UInt160) => string;
hexToUInt160: (value: string | UInt160) => UInt160;
uInt160ToString: (value: string | UInt160) => string;
stringToUInt160: (value: string | UInt160) => UInt160;
uInt160ToHex: (value: UInt160) => UInt160Hex;
hexToUInt160: (value: UInt160Hex | UInt160) => UInt160;
uInt160ToString: (value: UInt160 | UInt160Hex) => string;
stringToUInt160: (value: UInt160Hex | UInt160) => UInt160;
uInt160Equal: (a: UInt160, b: UInt160) => boolean;

@@ -74,32 +74,32 @@ isUInt160: (value: {}) => value is UInt160;

asECPoint: (value: {}) => ECPoint;
uInt256ToBuffer: (value: string | UInt256) => Buffer;
uInt256ToBuffer: (value: UInt256 | UInt256Hex) => Buffer;
bufferToUInt256: (value: {}) => UInt256;
uInt256ToHex: (value: UInt256) => string;
hexToUInt256: (value: string | UInt256) => UInt256;
uInt256ToString: (value: string | UInt256) => string;
stringToUInt256: (value: string | UInt256) => UInt256;
uInt256ToHex: (value: UInt256) => UInt256Hex;
hexToUInt256: (value: UInt256Hex | UInt256) => UInt256;
uInt256ToString: (value: UInt256 | UInt256Hex) => string;
stringToUInt256: (value: UInt256Hex | UInt256) => UInt256;
uInt256Equal: (a: UInt256, b: UInt256) => boolean;
toUInt32LE: (bytes: UInt256) => number;
ecPointToBuffer: (value: string | ECPointBase | ECPointInfinity) => Buffer;
ecPointToBuffer: (value: ECPoint | ECPointHex) => Buffer;
bufferToECPoint: (value: {}) => ECPoint;
ecPointToHex: (value: string | ECPointBase | ECPointInfinity) => string;
hexToECPoint: (value: string | ECPointBase | ECPointInfinity) => ECPoint;
ecPointToString: (value: string | ECPointBase | ECPointInfinity) => string;
ecPointCompare: (a: string | ECPointBase | ECPointInfinity, b: string | ECPointBase | ECPointInfinity) => 0 | 1 | -1;
stringToECPoint: (value: string | ECPointBase | ECPointInfinity) => ECPoint;
ecPointToHex: (value: ECPoint | ECPointHex) => ECPointHex;
hexToECPoint: (value: ECPoint | ECPointHex) => ECPoint;
ecPointToString: (value: ECPoint | ECPointHex) => string;
ecPointCompare: (a: ECPoint | ECPointHex, b: ECPoint | ECPointHex) => 0 | 1 | -1;
stringToECPoint: (value: ECPoint | ECPointHex) => ECPoint;
ecPointEqual: (a: ECPoint, b: ECPoint) => boolean;
ecPointIsInfinity: (value: ECPoint) => boolean;
privateKeyToHex: (value: string | PrivateKey) => string;
hexToPrivateKey: (value: string | PrivateKey) => PrivateKey;
privateKeyToBuffer: (value: string | PrivateKey) => Buffer;
privateKeyToHex: (value: PrivateKey | PrivateKeyHex) => PrivateKeyHex;
hexToPrivateKey: (value: PrivateKey | PrivateKeyHex) => PrivateKey;
privateKeyToBuffer: (value: PrivateKey | PrivateKeyHex) => Buffer;
bufferToPrivateKey: (value: {}) => PrivateKey;
privateKeyToString: (value: string | PrivateKey) => string;
stringToPrivateKey: (value: string | PrivateKey) => PrivateKey;
privateKeyToString: (value: PrivateKey | PrivateKeyHex) => string;
stringToPrivateKey: (value: PrivateKey | PrivateKeyHex) => PrivateKey;
isPrivateKey: (value: {}) => value is PrivateKey;
asPrivateKey: (value: {}) => PrivateKey;
fixed8FromDecimal: (value: string | number | BigNumber | BN) => BN;
fixed8FromDecimal: (value: number | string | BigNumber | BN) => BN;
fixed8ToDecimal: (bn: BN) => BigNumber;
fixedFromDecimal: (value: string | number | BigNumber | BN, decimals: number) => BN;
fixedFromDecimal: (value: number | string | BigNumber | BN, decimals: number) => BN;
fixedToDecimal: (value: BN, decimals: number) => BigNumber;
reverse: (src: Buffer) => Buffer;
};
import BigNumber from 'bignumber.js';
import { AddressABI, ArrayABI, BooleanABI, BufferABI, ContractParameter, ForwardValueABI, Hash256ABI, IntegerABI, MapABI, ObjectABI, PublicKeyABI, Return, SignatureABI, StringABI, VoidABI } from './types';
import { AddressABI, AddressString, ArrayABI, BooleanABI, BufferABI, BufferString, ContractParameter, ForwardValueABI, Hash256ABI, Hash256String, IntegerABI, MapABI, ObjectABI, PublicKeyABI, PublicKeyString, Return, SignatureABI, SignatureString, StringABI, VoidABI } from './types';
export declare const contractParameters: {
String: (contractParameter: ContractParameter, parameter: StringABI) => Return;
Address: (contractParameter: ContractParameter, parameter: AddressABI) => Return;
Hash256: (contractParameter: ContractParameter, parameter: Hash256ABI) => Return;
PublicKey: (contractParameter: ContractParameter, parameter: PublicKeyABI) => Return;
Integer: (contractParameter: ContractParameter, parameter: IntegerABI) => Return;
Boolean: (contractParameter: ContractParameter, parameter: BooleanABI) => Return;
Signature: (contractParameter: ContractParameter, parameter: SignatureABI) => Return;
Buffer: (contractParameter: ContractParameter, parameter: BufferABI) => Return;
Array: (contractParameter: ContractParameter, parameter: ArrayABI) => Return;
Map: (contractParameter: ContractParameter, parameter: MapABI) => Return;
Object: (contractParameter: ContractParameter, parameter: ObjectABI) => Return;
Void: (contractParameter: ContractParameter, parameter: VoidABI) => Return;
ForwardValue: (contractParameter: ContractParameter, parameter: ForwardValueABI) => Return;
String: (contractParameter: ContractParameter, parameter: StringABI) => Return | undefined;
Address: (contractParameter: ContractParameter, parameter: AddressABI) => Return | undefined;
Hash256: (contractParameter: ContractParameter, parameter: Hash256ABI) => Return | undefined;
PublicKey: (contractParameter: ContractParameter, parameter: PublicKeyABI) => Return | undefined;
Integer: (contractParameter: ContractParameter, parameter: IntegerABI) => Return | undefined;
Boolean: (contractParameter: ContractParameter, parameter: BooleanABI) => Return | undefined;
Signature: (contractParameter: ContractParameter, parameter: SignatureABI) => Return | undefined;
Buffer: (contractParameter: ContractParameter, parameter: BufferABI) => Return | undefined;
Array: (contractParameter: ContractParameter, parameter: ArrayABI) => Return | undefined;
Map: (contractParameter: ContractParameter, parameter: MapABI) => Return | undefined;
Object: (contractParameter: ContractParameter, parameter: ObjectABI) => Return | undefined;
Void: (contractParameter: ContractParameter, parameter: VoidABI) => Return | undefined;
ForwardValue: (contractParameter: ContractParameter, parameter: ForwardValueABI) => Return | undefined;
};

@@ -21,8 +21,8 @@ export declare const smartContractConverters: {

toStringNullable: (param: ContractParameter) => string | undefined;
toAddress: (contractParameter: ContractParameter) => string;
toAddressNullable: (param: ContractParameter) => string | undefined;
toHash256: (contractParameter: ContractParameter) => string;
toHash256Nullable: (param: ContractParameter) => string | undefined;
toPublicKey: (contractParameter: ContractParameter) => string;
toPublicKeyNullable: (param: ContractParameter) => string | undefined;
toAddress: (contractParameter: ContractParameter) => AddressString;
toAddressNullable: (param: ContractParameter) => AddressString | undefined;
toHash256: (contractParameter: ContractParameter) => Hash256String;
toHash256Nullable: (param: ContractParameter) => Hash256String | undefined;
toPublicKey: (contractParameter: ContractParameter) => PublicKeyString;
toPublicKeyNullable: (param: ContractParameter) => PublicKeyString | undefined;
toInteger: (contractParameter: ContractParameter, parameter: IntegerABI) => BigNumber;

@@ -32,10 +32,10 @@ toIntegerNullable: (param: ContractParameter, abi: IntegerABI) => BigNumber | undefined;

toBooleanNullable: (param: ContractParameter) => boolean | undefined;
toSignature: (contractParameter: ContractParameter) => string;
toSignatureNullable: (param: ContractParameter) => string | undefined;
toBuffer: (contractParameter: ContractParameter) => string;
toBufferNullable: (param: ContractParameter) => string | undefined;
toSignature: (contractParameter: ContractParameter) => SignatureString;
toSignatureNullable: (param: ContractParameter) => SignatureString | undefined;
toBuffer: (contractParameter: ContractParameter) => BufferString;
toBufferNullable: (param: ContractParameter) => BufferString | undefined;
toArray: (contractParameter: ContractParameter, parameter: ArrayABI) => readonly Return[];
toArrayNullable: (param: ContractParameter, abi: ArrayABI) => readonly Return[] | undefined;
toArrayNullable: (param: ContractParameter, abi: ArrayABI) => ReadonlyArray<Return | undefined> | undefined;
toMap: (contractParameter: ContractParameter, parameter: MapABI) => ReadonlyMap<Return, Return>;
toMapNullable: (param: ContractParameter, abi: MapABI) => ReadonlyMap<Return, Return> | undefined;
toMapNullable: (param: ContractParameter, abi: MapABI) => ReadonlyMap<Return | undefined, Return | undefined> | undefined;
toObject: (contractParameter: ContractParameter, parameter: ObjectABI) => {

@@ -48,7 +48,7 @@ readonly [key: string]: Return;

toInteropInterface: (_contractParameter: ContractParameter) => undefined;
toInteropInterfaceNullable: (param: ContractParameter) => undefined;
toInteropInterfaceNullable: (param: ContractParameter) => undefined | undefined;
toVoid: (_contractParameter: ContractParameter) => undefined;
toVoidNullable: (param: ContractParameter) => undefined;
toVoidNullable: (param: ContractParameter) => undefined | undefined;
toForwardValue: (contractParameter: ContractParameter) => ContractParameter;
toForwardValueNullable: (param: ContractParameter) => undefined;
toForwardValueNullable: (param: ContractParameter) => undefined | undefined;
};

@@ -145,3 +145,6 @@ import { utils as commonUtils } from '@neo-one/utils';

const valueConverter = contractParameters[value.type];
return new Map(contractParameter.value.map((val) => [keyConverter(val[0], key), valueConverter(val[1], value)]));
return new Map(contractParameter.value.map((val) => [
keyConverter(val[0], key),
valueConverter(val[1], value),
]));
};

@@ -148,0 +151,0 @@ const toObject = (contractParameter, parameter) => {

@@ -79,5 +79,5 @@ /// <reference types="node" />

parseExtendedKey: (key: string) => HDNode;
parseMasterSeed: (seedIn: string | Buffer) => HDNode;
parseMasterSeed: (seedIn: Buffer | string) => HDNode;
deriveChildKey: (node: HDNode, index: number, hardened: boolean) => HDNode;
serializeHDNode: (node: HDNode, privateNode?: boolean) => string;
};

@@ -16,3 +16,3 @@ /// <reference types="node" />

export declare const InvalidContractParameterError: {
new (parameter: ContractParameter, expected: readonly ("Address" | "Array" | "Boolean" | "Buffer" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface")[]): {
new (parameter: ContractParameter, expected: readonly ("Buffer" | "Address" | "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface")[]): {
readonly name: string;

@@ -19,0 +19,0 @@ readonly code: string;

@@ -12,4 +12,5 @@ export * from './BinaryWriter';

export * from './ScriptBuilder';
export * from './types';
export * from './utils';
//# sourceMappingURL=index.js.map
/// <reference types="node" />
import BigNumber from 'bignumber.js';
import BN from 'bn.js';
import { ECPoint, UInt160, UInt256 } from './common';
import { ECPoint, ECPointHex, UInt160, UInt160Hex, UInt256, UInt256Hex } from './common';
export declare const JSONHelper: {

@@ -10,9 +10,9 @@ writeUInt64LE: (value: BN) => string;

readUInt64: (value: string) => BigNumber;
writeUInt160: (value: string | UInt160) => string;
writeUInt160: (value: UInt160 | UInt160Hex) => string;
readUInt160: (hash: string) => UInt160;
writeUInt256: (value: string | UInt256) => string;
writeUInt256: (value: UInt256 | UInt256Hex) => string;
readUInt256: (hash: string) => UInt256;
writeFixed8: (value: BN) => string;
readFixed8: (value: string) => BN;
writeECPoint: (value: string | import("./common").ECPointBase | import("./common").ECPointInfinity) => string;
writeECPoint: (value: ECPoint | ECPointHex) => string;
readECPoint: (value: string) => ECPoint;

@@ -19,0 +19,0 @@ writeBuffer: (value: Buffer) => string;

@@ -0,1 +1,2 @@

import { AssetTypeJSON } from './types';
export declare enum AssetTypeModel {

@@ -13,4 +14,4 @@ CreditFlag = 64,

export declare const assertAssetType: (assetType: number) => AssetTypeModel;
export declare const toJSONAssetType: (type: AssetTypeModel) => "Currency" | "Share" | "Invoice" | "Token" | "CreditFlag" | "DutyFlag" | "GoverningToken" | "UtilityToken";
export declare const assertAssetTypeJSON: (type: string) => "Currency" | "Share" | "Invoice" | "Token" | "CreditFlag" | "DutyFlag" | "GoverningToken" | "UtilityToken";
export declare const toAssetType: (type: "Currency" | "Share" | "Invoice" | "Token" | "CreditFlag" | "DutyFlag" | "GoverningToken" | "UtilityToken") => AssetTypeModel;
export declare const toJSONAssetType: (type: AssetTypeModel) => AssetTypeJSON;
export declare const assertAssetTypeJSON: (type: string) => AssetTypeJSON;
export declare const toAssetType: (type: AssetTypeJSON) => AssetTypeModel;

@@ -0,1 +1,2 @@

import { ContractParameterTypeJSON } from './types';
export declare enum ContractParameterTypeModel {

@@ -17,4 +18,4 @@ Signature = 0,

export declare const assertContractParameterType: (value: number) => ContractParameterTypeModel;
export declare const toJSONContractParameterType: (type: ContractParameterTypeModel) => "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface" | "Hash160" | "ByteArray";
export declare const assertContractParameterTypeJSON: (value: string) => "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface" | "Hash160" | "ByteArray";
export declare const toContractParameterType: (value: "Array" | "Boolean" | "Hash256" | "Integer" | "Map" | "PublicKey" | "Signature" | "String" | "Void" | "InteropInterface" | "Hash160" | "ByteArray") => ContractParameterTypeModel;
export declare const toJSONContractParameterType: (type: ContractParameterTypeModel) => ContractParameterTypeJSON;
export declare const assertContractParameterTypeJSON: (value: string) => ContractParameterTypeJSON;
export declare const toContractParameterType: (value: ContractParameterTypeJSON) => ContractParameterTypeModel;

@@ -8,4 +8,5 @@ export * from './AssetTypeModel';

export * from './transaction';
export * from './types';
export * from './vm';
//# sourceMappingURL=index.js.map

@@ -0,1 +1,2 @@

import { StorageFlagsJSON } from './types';
export declare enum StorageFlagsModel {

@@ -7,4 +8,4 @@ None = 0,

export declare const assertStorageFlags: (storageFlags: number) => StorageFlagsModel;
export declare const toJSONStorageFlags: (type: StorageFlagsModel) => "None" | "Constant";
export declare const assertStorageFlagsJSON: (type: string) => "None" | "Constant";
export declare const toStorageFlags: (type: "None" | "Constant") => StorageFlagsModel;
export declare const toJSONStorageFlags: (type: StorageFlagsModel) => StorageFlagsJSON;
export declare const assertStorageFlagsJSON: (type: string) => StorageFlagsJSON;
export declare const toStorageFlags: (type: StorageFlagsJSON) => StorageFlagsModel;

@@ -0,1 +1,2 @@

import { AttributeUsageJSON } from '../../types';
export declare enum AttributeUsageModel {

@@ -42,5 +43,5 @@ ContractHash = 0,

export declare const assertAttributeUsage: (value: number) => AttributeUsageModel;
export declare const toJSONAttributeUsage: (usage: AttributeUsageModel) => import("../../..").AttributeUsage;
export declare const toJSONAttributeUsage: (usage: AttributeUsageModel) => AttributeUsageJSON;
export declare const isAttributeUsageJSON: (usage: string) => usage is import("../../..").AttributeUsage;
export declare const assertAttributeUsageJSON: (usage: string) => import("../../..").AttributeUsage;
export declare const toAttributeUsage: (usage: import("../../..").AttributeUsage) => AttributeUsageModel;
export declare const assertAttributeUsageJSON: (usage: string) => AttributeUsageJSON;
export declare const toAttributeUsage: (usage: AttributeUsageJSON) => AttributeUsageModel;
/// <reference types="node" />
import { BinaryWriter } from '../../../BinaryWriter';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type BufferAttributeUsageModel = 0x81 | 0x90 | 0xf0 | 0xf1 | 0xf2 | 0xf3 | 0xf4 | 0xf5 | 0xf6 | 0xf7 | 0xf8 | 0xf9 | 0xfa | 0xfb | 0xfc | 0xfd | 0xfe | 0xff;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type BufferAttributeUsageModel = AttributeUsageModel.DescriptionUrl | AttributeUsageModel.Description | AttributeUsageModel.Remark | AttributeUsageModel.Remark1 | AttributeUsageModel.Remark2 | AttributeUsageModel.Remark3 | AttributeUsageModel.Remark4 | AttributeUsageModel.Remark5 | AttributeUsageModel.Remark6 | AttributeUsageModel.Remark7 | AttributeUsageModel.Remark8 | AttributeUsageModel.Remark9 | AttributeUsageModel.Remark10 | AttributeUsageModel.Remark11 | AttributeUsageModel.Remark12 | AttributeUsageModel.Remark13 | AttributeUsageModel.Remark14 | AttributeUsageModel.Remark15;
export interface BufferAttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: BufferAttributeUsageModel;

import { BinaryWriter } from '../../../BinaryWriter';
import { ECPoint } from '../../../common';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type ECPointAttributeUsageModel = 0x02 | 0x03;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type ECPointAttributeUsageModel = AttributeUsageModel.ECDH02 | AttributeUsageModel.ECDH03;
export interface ECPointAttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: ECPointAttributeUsageModel;

export * from './AttributeBaseModel';
export * from './AttributeModel';
export * from './AttributeUsageModel';

@@ -3,0 +4,0 @@ export * from './BufferAttributeModel';

import { BinaryWriter } from '../../../BinaryWriter';
import { UInt160 } from '../../../common';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type UInt160AttributeUsageModel = 0x20;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type UInt160AttributeUsageModel = AttributeUsageModel.Script;
export interface UInt160AttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: UInt160AttributeUsageModel;

import { BinaryWriter } from '../../../BinaryWriter';
import { UInt256 } from '../../../common';
import { AttributeBaseModel } from './AttributeBaseModel';
export declare type UInt256AttributeUsageModel = 0x00 | 0x30 | 0xa1 | 0xa2 | 0xa3 | 0xa4 | 0xa5 | 0xa6 | 0xa7 | 0xa8 | 0xa9 | 0xaa | 0xab | 0xac | 0xad | 0xae | 0xaf;
import { AttributeUsageModel } from './AttributeUsageModel';
export declare type UInt256AttributeUsageModel = AttributeUsageModel.ContractHash | AttributeUsageModel.Vote | AttributeUsageModel.Hash1 | AttributeUsageModel.Hash2 | AttributeUsageModel.Hash3 | AttributeUsageModel.Hash4 | AttributeUsageModel.Hash5 | AttributeUsageModel.Hash6 | AttributeUsageModel.Hash7 | AttributeUsageModel.Hash8 | AttributeUsageModel.Hash9 | AttributeUsageModel.Hash10 | AttributeUsageModel.Hash11 | AttributeUsageModel.Hash12 | AttributeUsageModel.Hash13 | AttributeUsageModel.Hash14 | AttributeUsageModel.Hash15;
export interface UInt256AttributeModelAdd {

@@ -6,0 +7,0 @@ readonly usage: UInt256AttributeUsageModel;

@@ -7,4 +7,5 @@ export * from './attribute';

export * from './TransactionBaseModel';
export * from './TransactionModel';
export * from './TransactionTypeModel';
//# sourceMappingURL=index.js.map

@@ -34,5 +34,5 @@ /// <reference types="node" />

readonly serializeUnsigned: SerializeWire;
private readonly hashInternal;
private readonly hashHexInternal;
private readonly messageInternal;
readonly hashInternal: () => UInt256;
readonly hashHexInternal: () => string;
readonly messageInternal: () => Buffer;
constructor({ version, type, attributes, inputs, outputs, scripts, hash, }: TransactionBaseModelAddWithType<Type, TAttribute, TInput, TOutput, TWitness>);

@@ -39,0 +39,0 @@ abstract clone(options: {

@@ -200,3 +200,3 @@ /// <reference types="node" />

export declare const isByteCode: (value: number) => value is Op;
export declare const assertByteCode: (value: number) => Op;
export declare const assertByteCode: (value: number) => ByteCode;
export declare enum SysCall {

@@ -203,0 +203,0 @@ 'System.Runtime.Platform' = "System.Runtime.Platform",

{
"name": "@neo-one/client-common",
"version": "2.6.0",
"version": "2.6.1-alpha.5",
"description": "NEO•ONE client common code.",

@@ -14,5 +14,7 @@ "main": "./dist/cjs/index",

},
"sideEffects": false,
"dependencies": {
"@neo-one/ec-key": "^0.1.0",
"@neo-one/utils": "^2.5.0",
"@neo-one/utils": "2.5.1-alpha.5",
"@types/bn.js": "^4.11.5",
"bignumber.js": "^9.0.0",

@@ -34,3 +36,2 @@ "bn.js": "^5.0.0",

"@neo-one/build-tools": "^1.0.0",
"@types/bn.js": "^4.11.5",
"@types/bs58": "^4.0.0",

@@ -45,4 +46,3 @@ "@types/buffer-xor": "^2.0.0",

"gulp": "~4.0.2"
},
"sideEffects": false
}
}

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc