Packages

package web3j

This project is an idiomatic Scala wrapper around Web3J for Ethereum. This project is built with Scala 2.12, and requires the Java 8 runtime; it is not yet compatible with Java 9.

This project promotes idiomatic Scala in the following ways:

  • Variables and no-argument methods are actually names of properties, so set and get prefixes are not used. This means some properties do not have exactly the same name as their Web3J counterpart.
  • Zero-argument methods only require parentheses if they perform side effects.
  • Scala data types are used to the maximum extent that makes sense. For example, scala.concurrent.Future.
  • A functional programming style is encouraged by always returning immutable data types from methods. For example, scala.collection.immutable.List

The Ethereum JSON-RPC documentation was the source of many the comments incorporated into this Scaladoc.

The JSON-RPC default block parameter can represent a QUANTITY or a TAG. Quantities are expressed as integer block numbers, and tags are strings with one of the values "latest", "earliest" or "pending". The Java implementation performs the same function as the underlying JSON-RPC implementation.

Whisper is an experimental communication protocol of the Ethereum P2P protocol suite that allows for messaging between users' DApps (Ethereum Distributed Applications). Whisper uses the same network that the blockchain runs on. The protocol is separate from the blockchain, so smart contracts do not have access to whispered messages.

EthBlock and its internal types such as Block, TransactionObject and TransactionResult are returned by the following methods of com.micronautics.web3j.EthereumSynchronous and com.micronautics.web3j.EthereumASynchronous: blockByHash, blockByNumber, uncleByBlockHashAndIndex, uncleByBlockNumberAndIndex.

Source
package.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. web3j
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. final case class Address(value: String) extends AnyVal with Product with Serializable
  2. final case class BlockHash(value: String) extends AnyVal with Product with Serializable
  3. class Cmd extends AnyRef
  4. final case class Compiler(value: String) extends AnyVal with Product with Serializable
  5. final case class Digest(value: String) extends AnyVal with Product with Serializable
  6. final case class EtHash(value: String) extends AnyVal with Product with Serializable
  7. class Ether extends Ordered[Ether]

    Wei are the smallest unit of currency and are always integers, never fractional quantities

  8. class EthereumASynchronous extends AnyRef

    All of the methods in this class return a scala.concurrent.Future and do not block.

  9. class EthereumSynchronous extends AnyRef

    All of the methods in this class block until a value is ready to be returned to the caller.

  10. final case class FilterId(value: BigInteger) extends AnyVal with Product with Serializable
  11. sealed abstract final class InfuraNetwork extends Enum[InfuraNetwork]

    From the web3j testnet docs: For development, its recommended you use the Rinkeby (geth only) or Kovan (Parity only) test networks.

    From the web3j testnet docs: For development, its recommended you use the Rinkeby (geth only) or Kovan (Parity only) test networks. This is because they use a Proof of Authority (PoA) consensus mechanism, ensuring transactions and blocks are created in a consistent and timely manner. The Ropsten testnet, although closest to the Mainnet as it uses Proof of Work (PoW) consensus, has been subject to attacks in the past and tends to be more problematic for developers.

  12. final case class Keccak256Hash(value: String) extends AnyVal with Product with Serializable

    The SHA3 hash is more properly referred to as Keccak-256

  13. final case class LLLCompiled(value: String) extends AnyVal with Product with Serializable
  14. final case class LLLSource(value: String) extends AnyVal with Product with Serializable
  15. final case class Nonce(value: BigInt) extends AnyVal with Product with Serializable

    An account nonce is a transaction counter, provided by Ethereum for each Account.

    An account nonce is a transaction counter, provided by Ethereum for each Account. Nonces prevent replay attacks wherein a transaction sending Ether from A to B can be replayed by B over and over to continually drain A's balance.

    See also

    See Glossary

  16. implicit class RichBlock extends AnyRef

    Enriches response.EthBlock.Block with convenience methods

  17. final case class SerpentCompiled(value: String) extends AnyVal with Product with Serializable
  18. final case class SerpentSource(value: String) extends AnyVal with Product with Serializable
  19. final case class Signature(value: String) extends AnyVal with Product with Serializable
  20. final case class SignedData(value: String) extends AnyVal with Product with Serializable
  21. final case class SoliditySource(value: String) extends AnyVal with Product with Serializable

    Web3J already has EthCompileSolidity.Code to represent Solidity compiled code

  22. final case class TransactionHash(value: String) extends AnyVal with Product with Serializable
  23. class Web3JScala extends AnyRef

    Wrapper for Web3J

Value Members

  1. object Cmd

    Command-line invocation / process control

  2. object Ether
  3. object Web3JScala

    Web3J builders and stateless methods.

Inherited from AnyRef

Inherited from Any

Ungrouped