Module: Ethlite
- Defined in:
- lib/ethlite.rb,
lib/ethlite/utils.rb,
lib/ethlite/version.rb,
lib/ethlite/abi/type.rb,
lib/ethlite/constant.rb,
lib/ethlite/contract.rb,
lib/ethlite/abi/codec.rb
Defined Under Namespace
Modules: Abi, UtilHelper, Utils
Classes: Configuration, ContractMethod
Constant Summary
collapse
- MAJOR =
0
- MINOR =
3
- PATCH =
2
- VERSION =
[MAJOR,MINOR,PATCH].join('.')
- BYTE_EMPTY =
todo/check: use auto-freeze string literals magic comment - why? why not?
"".b.freeze
- BYTE_ZERO =
"\x00".b.freeze
- BYTE_ONE =
"\x01".b.freeze
- TT32 =
2**32
- TT40 =
2**40
- TT160 =
2**160
- TT256 =
2**256
- TT64M1 =
2**64 - 1
- UINT_MAX =
2**256 - 1
- UINT_MIN =
0
- INT_MAX =
2**255 - 1
- INT_MIN =
-2**255
- HASH_ZERO =
("\x00"*32).b.freeze
- PUBKEY_ZERO =
("\x00"*32).b.freeze
- PRIVKEY_ZERO =
("\x00"*32).b.freeze
- PRIVKEY_ZERO_HEX =
('0'*64).freeze
- CONTRACT_CODE_SIZE_LIMIT =
0x6000
Class Method Summary
collapse
Class Method Details
.banner ⇒ Object
13
14
15
|
# File 'lib/ethlite/version.rb', line 13
def self.banner
"ethlite/#{VERSION} on Ruby #{RUBY_VERSION} (#{RUBY_RELEASE_DATE}) [#{RUBY_PLATFORM}] in (#{root})"
end
|
.config ⇒ Object
54
|
# File 'lib/ethlite.rb', line 54
def self.config() @config ||= Configuration.new; end
|
lets you use
Ethlite.configure do |config|
config.rpc = Ethlite::Rpc.new( ENV['INFURA_URI'] )
end
53
|
# File 'lib/ethlite.rb', line 53
def self.configure() yield( config ); end
|
.root ⇒ Object
17
18
19
|
# File 'lib/ethlite/version.rb', line 17
def self.root
File.expand_path( File.dirname(File.dirname(File.dirname(__FILE__))) )
end
|
.version ⇒ Object
9
10
11
|
# File 'lib/ethlite/version.rb', line 9
def self.version
VERSION
end
|