nxt.tools

## Class ContractManager

- java.lang.Object
- - nxt.tools.ContractManager

-     public class ContractManager
      extends java.lang.Object

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `ContractManager.ContractData`
    `static class` | `ContractManager.OPTION`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ContractManager()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `delete(java.lang.String contractName)`
    `void` | `init(java.lang.String contractName)`
    `void` | `list(java.lang.String account, java.lang.String name)`
    `JO` | `listImpl(java.lang.String account, java.lang.String name)`
    `static void` | `main(java.lang.String[] args)`
    `void` | `reference(ContractManager.ContractData contractData, byte[] contractFullHash)`
    `JO` | `reference(ContractManager.ContractData contractData, byte[] fullHash, JO uploaderParams)`
    `ContractManager.ContractData` | `upload(java.lang.String contractName, java.lang.String packageName)`
    `ContractManager.ContractData` | `uploadImpl(java.lang.String contractName, java.lang.String packageName)`
    `boolean` | `verify(java.lang.String hash, java.lang.String sourceFile)` We assume that the contract is composed of a single source file which is deployed to the blockchain either as a single class file or as a Jar file containing all its inner classes.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ContractManager

          public ContractManager()

  - ### Method Detail

    - #### main

          public static void main(java.lang.String[] args)

    - #### init

          public void init(java.lang.String contractName)

    - #### list

          public void list(java.lang.String account,
                           java.lang.String name)

    - #### listImpl

          public JO listImpl(java.lang.String account,
                             java.lang.String name)

    - #### upload

          public ContractManager.ContractData upload(java.lang.String contractName,
                                                     java.lang.String packageName)

    - #### uploadImpl

          public ContractManager.ContractData uploadImpl(java.lang.String contractName,
                                                         java.lang.String packageName)

    - #### reference

          public void reference(ContractManager.ContractData contractData,
                                byte[] contractFullHash)

    - #### reference

          public JO reference(ContractManager.ContractData contractData,
                              byte[] fullHash,
                              JO uploaderParams)

    - #### delete

          public void delete(java.lang.String contractName)

    - #### verify

          public boolean verify(java.lang.String hash,
                                java.lang.String sourceFile)

      We assume that the contract is composed of a single source file which is deployed to the blockchain either as a single class file or as a Jar file containing all its inner classes. This compiled contract is identified by the provided transaction hash on the Ignis chain.
      Parameters:
        `hash` - hash of the cloud data transaction which stores the contract file
        `sourceFile` - path to the source file to compile
      Returns:
        true if the compiled source code is identical to the code deployed to the blockchain, false otherwise