opnet 1.0.2 → 1.0.11
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.
- package/.babelrc +7 -0
- package/.idea/{OPNet.iml → opnet.iml} +1 -0
- package/browser/block/Block.d.ts +27 -0
- package/browser/index.d.ts +15 -0
- package/browser/index.js +2 -0
- package/browser/index.js.LICENSE.txt +14 -0
- package/browser/interfaces/blocks/IBlock.d.ts +28 -0
- package/browser/interfaces/opnet/OPNetTransactionTypes.d.ts +5 -0
- package/browser/interfaces/transactions/ITransaction.d.ts +31 -0
- package/browser/providers/JSONRpcProvider.d.ts +12 -0
- package/browser/scripts/test.d.ts +1 -0
- package/browser/transactions/DeploymentTransaction.d.ts +6 -0
- package/browser/transactions/GenericTransaction.d.ts +6 -0
- package/browser/transactions/InteractionTransaction.d.ts +17 -0
- package/browser/transactions/Transaction.d.ts +17 -0
- package/browser/transactions/TransactionInput.d.ts +16 -0
- package/browser/transactions/TransactionOutput.d.ts +19 -0
- package/build/providers/JSONRpcProvider.d.ts +1 -1
- package/build/transactions/InteractionTransaction.d.ts +1 -0
- package/build/transactions/InteractionTransaction.js +1 -0
- package/cjs/block/Block.d.ts +27 -0
- package/cjs/block/Block.js +72 -0
- package/cjs/index.d.ts +11 -0
- package/cjs/index.js +26 -0
- package/cjs/interfaces/blocks/IBlock.d.ts +28 -0
- package/cjs/interfaces/blocks/IBlock.js +2 -0
- package/cjs/interfaces/opnet/OPNetTransactionTypes.d.ts +5 -0
- package/cjs/interfaces/opnet/OPNetTransactionTypes.js +9 -0
- package/cjs/interfaces/transactions/ITransaction.d.ts +31 -0
- package/cjs/interfaces/transactions/ITransaction.js +2 -0
- package/cjs/providers/JSONRpcProvider.d.ts +12 -0
- package/cjs/providers/JSONRpcProvider.js +52 -0
- package/cjs/scripts/test.d.ts +1 -0
- package/cjs/scripts/test.js +10 -0
- package/cjs/transactions/DeploymentTransaction.d.ts +6 -0
- package/cjs/transactions/DeploymentTransaction.js +10 -0
- package/cjs/transactions/GenericTransaction.d.ts +6 -0
- package/cjs/transactions/GenericTransaction.js +10 -0
- package/cjs/transactions/InteractionTransaction.d.ts +17 -0
- package/cjs/transactions/InteractionTransaction.js +29 -0
- package/cjs/transactions/Transaction.d.ts +17 -0
- package/cjs/transactions/Transaction.js +28 -0
- package/cjs/transactions/TransactionInput.d.ts +16 -0
- package/cjs/transactions/TransactionInput.js +18 -0
- package/cjs/transactions/TransactionOutput.d.ts +19 -0
- package/cjs/transactions/TransactionOutput.js +20 -0
- package/gulpfile.js +152 -152
- package/package.json +94 -71
- package/src/index.ts +4 -0
- package/src/providers/JSONRpcProvider.ts +66 -67
- package/src/transactions/InteractionTransaction.ts +1 -0
- package/tsconfig.base.json +10 -2
- package/tsconfig.webpack.json +11 -0
- package/webpack.config.js +58 -0
package/.babelrc
ADDED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
<excludeFolder url="file://$MODULE_DIR$/build" />
|
|
9
9
|
<excludeFolder url="file://$MODULE_DIR$/packages" />
|
|
10
10
|
<excludeFolder url="file://$MODULE_DIR$/cjs" />
|
|
11
|
+
<excludeFolder url="file://$MODULE_DIR$/browser" />
|
|
11
12
|
</content>
|
|
12
13
|
<orderEntry type="inheritedJdk" />
|
|
13
14
|
<orderEntry type="sourceFolder" forTests="false" />
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { BigNumberish } from 'ethers';
|
|
2
|
+
import { BlockHeaderChecksumProof, IBlock } from '../interfaces/blocks/IBlock.js';
|
|
3
|
+
import { OPNetTransactionTypes } from '../interfaces/opnet/OPNetTransactionTypes.js';
|
|
4
|
+
import { TransactionBase } from '../transactions/Transaction.js';
|
|
5
|
+
export declare class Block implements IBlock {
|
|
6
|
+
readonly height: BigNumberish;
|
|
7
|
+
readonly hash: string;
|
|
8
|
+
readonly previousBlockHash: string;
|
|
9
|
+
readonly previousBlockChecksum: string;
|
|
10
|
+
readonly bits: string;
|
|
11
|
+
readonly nonce: number;
|
|
12
|
+
readonly version: number;
|
|
13
|
+
readonly size: number;
|
|
14
|
+
readonly txCount: number;
|
|
15
|
+
readonly weight: number;
|
|
16
|
+
readonly strippedSize: number;
|
|
17
|
+
readonly time: number;
|
|
18
|
+
readonly medianTime: number;
|
|
19
|
+
readonly checksumRoot: string;
|
|
20
|
+
readonly merkleRoot: string;
|
|
21
|
+
readonly storageRoot: string;
|
|
22
|
+
readonly receiptRoot: string;
|
|
23
|
+
readonly checksumProofs: BlockHeaderChecksumProof;
|
|
24
|
+
readonly transactions?: TransactionBase<OPNetTransactionTypes>[];
|
|
25
|
+
constructor(block: IBlock);
|
|
26
|
+
private getTransactions;
|
|
27
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export * from './interfaces/opnet/OPNetTransactionTypes.js';
|
|
2
|
+
export * from './interfaces/transactions/ITransaction.js';
|
|
3
|
+
export * from './transactions/DeploymentTransaction.js';
|
|
4
|
+
export * from './transactions/GenericTransaction.js';
|
|
5
|
+
export * from './transactions/InteractionTransaction.js';
|
|
6
|
+
export * from './transactions/Transaction.js';
|
|
7
|
+
export * from './transactions/TransactionInput.js';
|
|
8
|
+
export * from './transactions/TransactionOutput.js';
|
|
9
|
+
export * from './providers/JSONRpcProvider.js';
|
|
10
|
+
export * from './block/Block.js';
|
|
11
|
+
export * from './interfaces/blocks/IBlock.js';
|
|
12
|
+
declare const _default: {
|
|
13
|
+
version: string;
|
|
14
|
+
};
|
|
15
|
+
export default _default;
|