ens

package
v0.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 23, 2024 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ListNetworks = map[string]Network{
	"MainNet": MainNet,
	"Robsten": Robsten,
}

Functions

This section is empty.

Types

type Network

type Network string
const (
	MainNet Network = "00000000000C2E074eC69A0dFb2997BA6C7d2e1e"
	Robsten Network = "00000000000C2E074eC69A0dFb2997BA6C7d2e1e"
)

These addresses hard coded in blockchain.

type Registry

type Registry struct {
	// contains filtered or unexported fields
}

Registry core contract in ENS.

func NewRegistry

func NewRegistry(eth *ethclient.Client, network Network) (*Registry, error)

NewRegistry create interface for communication with core contract in ENS.

func (*Registry) Resolver

func (r *Registry) Resolver(domain string) (*Resolver, error)

Resolver return resolver for domain.

type Resolver

type Resolver struct {
	// contains filtered or unexported fields
}

Resolver has interfaces for getting information about your domain.

func NewResolver

func NewResolver(eth *ethclient.Client, address, domain string) (*Resolver, error)

NewResolver create interface for communication with resolver. 'address' this is address to your resolver. 'domain' this is the domain that is served by the resolver from the 'address' field.

func (*Resolver) Text

func (r *Resolver) Text(key string) (string, error)

Text return string that exist in domain txt record. https://eips.ethereum.org/EIPS/eip-634

Directories

Path Synopsis
contract

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL