Sha256: 7109c56c1de6f522e5b4afe7c35a7487a299d422eb559dd2206472c5f2293bfe

Contents?: true

Size: 398 Bytes

Versions: 1

Compression:

Stored size: 398 Bytes

Contents

module MoneyTree
  class Address
    attr_reader :private_key, :public_key

    def initialize(opts = {})
      private_key = opts.delete(:private_key)
      @private_key = MoneyTree::PrivateKey.new({ key: private_key }.merge(opts))
      @public_key = MoneyTree::PublicKey.new(@private_key, opts)
    end

    def to_s(network: :bitcoin)
      public_key.to_s(network: network)
    end

  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
money-tree-0.11.0 lib/money-tree/address.rb