Documentation ¶
Index ¶
- Variables
- func ContenthashToString(bytes []byte) (string, error)
- func CreateRegistrySession(chainID *big.Int, wallet *accounts.Wallet, account *accounts.Account, ...) *registry.ContractSession
- func DNSWireFormat(domain string) []byte
- func DNSWireFormatDomainHash(domain string) (hash [32]byte)
- func Domain(domain string) string
- func DomainLevel(name string) (level int)
- func DomainPart(domain string, part int) (string, error)
- func Format(backend bind.ContractBackend, address common.Address) string
- func LabelHash(label string) (hash [32]byte, err error)
- func NameHash(name string) (hash [32]byte, err error)
- func NormaliseDomain(domain string) (string, error)
- func NormaliseDomainStrict(domain string) (string, error)
- func Normalize(input string) (output string, err error)
- func PublicResolverAddress(backend bind.ContractBackend) (common.Address, error)
- func RegistrarContractAddress(backend bind.ContractBackend, domain string) (common.Address, error)
- func RegistryContractAddress(backend bind.ContractBackend) (common.Address, error)
- func RegistryContractFromRegistrar(backend bind.ContractBackend, registrar *auctionregistrar.Contract) (*registry.Contract, error)
- func Resolve(backend bind.ContractBackend, input string) (address common.Address, err error)
- func ReverseResolve(backend bind.ContractBackend, address common.Address) (string, error)
- func SetResolver(session *registry.ContractSession, name string, resolverAddr *common.Address) (*types.Transaction, error)
- func SetSubdomainOwner(session *registry.ContractSession, name string, subdomain string, ...) (*types.Transaction, error)
- func StringToContenthash(text string) ([]byte, error)
- func Tld(domain string) string
- func UnqualifiedName(domain string, root string) (string, error)
- type AuctionEntry
- type AuctionRegistrar
- func (r *AuctionRegistrar) Entry(domain string) (*AuctionEntry, error)
- func (r *AuctionRegistrar) Migrate(opts *bind.TransactOpts, domain string) (*types.Transaction, error)
- func (r *AuctionRegistrar) Owner(domain string) (common.Address, error)
- func (r *AuctionRegistrar) Release(opts *bind.TransactOpts, domain string) (*types.Transaction, error)
- func (r *AuctionRegistrar) SetOwner(opts *bind.TransactOpts, domain string, address common.Address) (*types.Transaction, error)
- func (r *AuctionRegistrar) ShaBid(hash [32]byte, address common.Address, value *big.Int, salt [32]byte) ([32]byte, error)
- func (r *AuctionRegistrar) State(name string) (string, error)
- type BaseRegistrar
- func (r *BaseRegistrar) Expiry(domain string) (*big.Int, error)
- func (r *BaseRegistrar) Owner(domain string) (common.Address, error)
- func (r *BaseRegistrar) PriorAuctionContract() (*AuctionRegistrar, error)
- func (r *BaseRegistrar) Reclaim(opts *bind.TransactOpts, domain string, newOwner common.Address) (*types.Transaction, error)
- func (r *BaseRegistrar) RegisteredWith(domain string) (string, error)
- func (r *BaseRegistrar) SetOwner(opts *bind.TransactOpts, domain string, newOwner common.Address) (*types.Transaction, error)
- type DNSRegistrar
- type DNSResolver
- func (r *DNSResolver) ClearDNSZone(opts *bind.TransactOpts) (*types.Transaction, error)
- func (r *DNSResolver) HasRecords(name string) (bool, error)
- func (r *DNSResolver) Record(name string, rrType uint16) ([]byte, error)
- func (r *DNSResolver) SetRecords(opts *bind.TransactOpts, data []byte) (*types.Transaction, error)
- func (r *DNSResolver) SetZonehash(opts *bind.TransactOpts, zonehash []byte) (*types.Transaction, error)
- func (r *DNSResolver) Zonehash() ([]byte, error)
- type DNSSECOracle
- type Deed
- type ETHController
- func (c *ETHController) Commit(opts *bind.TransactOpts, domain string, owner common.Address, secret [32]byte) (*types.Transaction, error)
- func (c *ETHController) CommitmentHash(domain string, owner common.Address, secret [32]byte) (common.Hash, error)
- func (c *ETHController) CommitmentTime(domain string, owner common.Address, secret [32]byte) (*big.Int, error)
- func (c *ETHController) IsAvailable(domain string) (bool, error)
- func (c *ETHController) IsValid(domain string) (bool, error)
- func (c *ETHController) MaxCommitmentInterval() (*big.Int, error)
- func (c *ETHController) MinCommitmentInterval() (*big.Int, error)
- func (c *ETHController) MinRegistrationDuration() (time.Duration, error)
- func (c *ETHController) Renew(opts *bind.TransactOpts, domain string) (*types.Transaction, error)
- func (c *ETHController) RentCost(domain string) (*big.Int, error)
- func (c *ETHController) Reveal(opts *bind.TransactOpts, domain string, owner common.Address, secret [32]byte) (*types.Transaction, error)
- type Name
- func (n *Name) Address(coinType uint64) ([]byte, error)
- func (n *Name) Controller() (common.Address, error)
- func (n *Name) CreateSubdomain(label string, controller common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
- func (n *Name) Expires() (time.Time, error)
- func (n *Name) ExtendRegistration(opts *bind.TransactOpts) (*types.Transaction, error)
- func (n *Name) IsRegistered() (bool, error)
- func (n *Name) Reclaim(opts *bind.TransactOpts) (*types.Transaction, error)
- func (n *Name) RegisterStageOne(registrant common.Address, opts *bind.TransactOpts) (*types.Transaction, [32]byte, error)
- func (n *Name) RegisterStageTwo(registrant common.Address, secret [32]byte, opts *bind.TransactOpts) (*types.Transaction, error)
- func (n *Name) Registrant() (common.Address, error)
- func (n *Name) RegistrationInterval() (time.Duration, error)
- func (n *Name) RentCost() (*big.Int, error)
- func (n *Name) ResolverAddress() (common.Address, error)
- func (n *Name) SetAddress(coinType uint64, address []byte, opts *bind.TransactOpts) (*types.Transaction, error)
- func (n *Name) SetController(controller common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
- func (n *Name) SetResolverAddress(address common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
- func (n *Name) Transfer(registrant common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
- type Registry
- func (r *Registry) Owner(name string) (common.Address, error)
- func (r *Registry) Resolver(name string) (*Resolver, error)
- func (r *Registry) ResolverAddress(name string) (common.Address, error)
- func (r *Registry) SetOwner(opts *bind.TransactOpts, name string, address common.Address) (*types.Transaction, error)
- func (r *Registry) SetResolver(opts *bind.TransactOpts, name string, address common.Address) (*types.Transaction, error)
- func (r *Registry) SetSubdomainOwner(opts *bind.TransactOpts, name string, subname string, address common.Address) (*types.Transaction, error)
- type Resolver
- func (r *Resolver) ABI(name string) (string, error)
- func (r *Resolver) Address() (common.Address, error)
- func (r *Resolver) Contenthash() ([]byte, error)
- func (r *Resolver) InterfaceImplementer(interfaceID [4]byte) (common.Address, error)
- func (r *Resolver) MultiAddress(coinType uint64) ([]byte, error)
- func (r *Resolver) PubKey() ([32]byte, [32]byte, error)
- func (r *Resolver) SetABI(opts *bind.TransactOpts, name string, abi string, contentType *big.Int) (*types.Transaction, error)
- func (r *Resolver) SetAddress(opts *bind.TransactOpts, address common.Address) (*types.Transaction, error)
- func (r *Resolver) SetContenthash(opts *bind.TransactOpts, contenthash []byte) (*types.Transaction, error)
- func (r *Resolver) SetMultiAddress(opts *bind.TransactOpts, coinType uint64, address []byte) (*types.Transaction, error)
- func (r *Resolver) SetPubKey(opts *bind.TransactOpts, x [32]byte, y [32]byte) (*types.Transaction, error)
- func (r *Resolver) SetText(opts *bind.TransactOpts, name string, value string) (*types.Transaction, error)
- func (r *Resolver) Text(name string) (string, error)
- type ReverseRegistrar
- type ReverseResolver
Constants ¶
This section is empty.
Variables ¶
var UnknownAddress = common.HexToAddress("00")
UnknownAddress is the address to which unknown entries resolve
Functions ¶
func ContenthashToString ¶
ContenthashToString turns EIP-1577 binary format in to EIP-1577 text format
func CreateRegistrySession ¶
func CreateRegistrySession(chainID *big.Int, wallet *accounts.Wallet, account *accounts.Account, passphrase string, contract *registry.Contract, gasPrice *big.Int) *registry.ContractSession
CreateRegistrySession creates a session suitable for multiple calls
func DNSWireFormat ¶
DNSWireFormat turns a domain name in to wire format
func DNSWireFormatDomainHash ¶
DNSWireFormatDomainHash hashes a domain name in wire format
func Domain ¶
Domain obtains the domain of an ENS name, including subdomains. It does this by removing everything up to and including the first period. For example, 'eth' will return ”
'foo.eth' will return 'eth' 'bar.foo.eth' will return 'foo.eth'
func DomainLevel ¶
DomainLevel calculates the level of the domain presented. A top-level domain (e.g. 'eth') will be 0, a domain (e.g. 'foo.eth') will be 1, a subdomain (e.g. 'bar.foo.eth' will be 2, etc.
func DomainPart ¶
DomainPart obtains a part of a name Positive parts start at the lowest-level of the domain and work towards the top-level domain. Negative parts start at the top-level domain and work towards the lowest-level domain. For example, with a domain bar.foo.com the following parts will be returned: Number | part
1 | bar 2 | foo 3 | com -1 | com -2 | foo -3 | bar
func Format ¶
func Format(backend bind.ContractBackend, address common.Address) string
Format provides a string version of an address, reverse resolving it if possible
func NormaliseDomain ¶
NormaliseDomain turns ENS domain in to normal form
func NormaliseDomainStrict ¶ added in v3.0.2
NormaliseDomainStrict turns ENS domain in to normal form, using strict DNS rules (e.g. no underscores)
func PublicResolverAddress ¶
func PublicResolverAddress(backend bind.ContractBackend) (common.Address, error)
PublicResolverAddress obtains the address of the public resolver for a chain
func RegistrarContractAddress ¶
RegistrarContractAddress obtains the registrar contract address for a given domain
func RegistryContractAddress ¶
func RegistryContractAddress(backend bind.ContractBackend) (common.Address, error)
RegistryContractAddress obtains the address of the registry contract for a chain. This is (currently) the same for all chains.
func RegistryContractFromRegistrar ¶
func RegistryContractFromRegistrar(backend bind.ContractBackend, registrar *auctionregistrar.Contract) (*registry.Contract, error)
RegistryContractFromRegistrar obtains the registry contract given an existing registrar contract
func Resolve ¶
Resolve resolves an ENS name in to an Etheruem address This will return an error if the name is not found or otherwise 0
func ReverseResolve ¶
ReverseResolve resolves an address in to an ENS name This will return an error if the name is not found or otherwise 0
func SetResolver ¶
func SetResolver(session *registry.ContractSession, name string, resolverAddr *common.Address) (*types.Transaction, error)
SetResolver sets the resolver for a name
func SetSubdomainOwner ¶
func SetSubdomainOwner(session *registry.ContractSession, name string, subdomain string, ownerAddr *common.Address) (*types.Transaction, error)
SetSubdomainOwner sets the owner for a subdomain of a name
func StringToContenthash ¶
StringToContenthash turns EIP-1577 text format in to EIP-1577 binary format
Types ¶
type AuctionEntry ¶
type AuctionEntry struct { State string Deed common.Address Registration time.Time Value *big.Int HighestBid *big.Int }
AuctionEntry is an auction entry
type AuctionRegistrar ¶
type AuctionRegistrar struct { Contract *auctionregistrar.Contract ContractAddr common.Address // contains filtered or unexported fields }
AuctionRegistrar is the structure for the auction registrar contract
func NewAuctionRegistrar ¶
func NewAuctionRegistrar(backend bind.ContractBackend, domain string) (*AuctionRegistrar, error)
NewAuctionRegistrar creates a new auction registrar for a given domain
func NewAuctionRegistrarAt ¶
func NewAuctionRegistrarAt(backend bind.ContractBackend, domain string, address common.Address) (*AuctionRegistrar, error)
NewAuctionRegistrarAt creates an auction registrar for a given domain at a given address
func (*AuctionRegistrar) Entry ¶
func (r *AuctionRegistrar) Entry(domain string) (*AuctionEntry, error)
Entry obtains a registrar entry for a name
func (*AuctionRegistrar) Migrate ¶
func (r *AuctionRegistrar) Migrate(opts *bind.TransactOpts, domain string) (*types.Transaction, error)
Migrate migrates a domain to the permanent registrar
func (*AuctionRegistrar) Owner ¶
func (r *AuctionRegistrar) Owner(domain string) (common.Address, error)
Owner obtains the owner of the deed that represents the name.
func (*AuctionRegistrar) Release ¶
func (r *AuctionRegistrar) Release(opts *bind.TransactOpts, domain string) (*types.Transaction, error)
Release releases a domain
func (*AuctionRegistrar) SetOwner ¶
func (r *AuctionRegistrar) SetOwner(opts *bind.TransactOpts, domain string, address common.Address) (*types.Transaction, error)
SetOwner sets the owner of the deed that represents the name.
type BaseRegistrar ¶
type BaseRegistrar struct { Contract *baseregistrar.Contract ContractAddr common.Address // contains filtered or unexported fields }
BaseRegistrar is the structure for the registrar
func NewBaseRegistrar ¶
func NewBaseRegistrar(backend bind.ContractBackend, domain string) (*BaseRegistrar, error)
NewBaseRegistrar obtains the registrar contract for a given domain
func (*BaseRegistrar) Expiry ¶
func (r *BaseRegistrar) Expiry(domain string) (*big.Int, error)
Expiry obtains the unix timestamp at which the registration expires.
func (*BaseRegistrar) Owner ¶
func (r *BaseRegistrar) Owner(domain string) (common.Address, error)
Owner obtains the owner of the underlying token that represents the name.
func (*BaseRegistrar) PriorAuctionContract ¶
func (r *BaseRegistrar) PriorAuctionContract() (*AuctionRegistrar, error)
PriorAuctionContract obtains the previous (auction) registrar contract
func (*BaseRegistrar) Reclaim ¶
func (r *BaseRegistrar) Reclaim(opts *bind.TransactOpts, domain string, newOwner common.Address) (*types.Transaction, error)
Reclaim reclaims a domain by the owner
func (*BaseRegistrar) RegisteredWith ¶
func (r *BaseRegistrar) RegisteredWith(domain string) (string, error)
RegisteredWith returns one of "temporary", "permanent" or "none" for the registrar on which this name is registered
func (*BaseRegistrar) SetOwner ¶
func (r *BaseRegistrar) SetOwner(opts *bind.TransactOpts, domain string, newOwner common.Address) (*types.Transaction, error)
SetOwner sets the owner of the token holding the name
type DNSRegistrar ¶
type DNSRegistrar struct { Contract *dnsregistrar.Contract ContractAddr common.Address // contains filtered or unexported fields }
DNSRegistrar is the structure for the registrar
func NewDNSRegistrar ¶
func NewDNSRegistrar(backend bind.ContractBackend, domain string) (*DNSRegistrar, error)
NewDNSRegistrar obtains the registrar contract for a given domain
type DNSResolver ¶
type DNSResolver struct { Contract *dnsresolver.Contract ContractAddr common.Address // contains filtered or unexported fields }
DNSResolver is the structure for the DNS resolver contract
func NewDNSResolver ¶
func NewDNSResolver(backend bind.ContractBackend, domain string) (*DNSResolver, error)
NewDNSResolver creates a new DNS resolver for a given domain
func NewDNSResolverAt ¶
func NewDNSResolverAt(backend bind.ContractBackend, domain string, address common.Address) (*DNSResolver, error)
NewDNSResolverAt creates a new DNS resolver for a given domain at a given address
func (*DNSResolver) ClearDNSZone ¶
func (r *DNSResolver) ClearDNSZone(opts *bind.TransactOpts) (*types.Transaction, error)
ClearDNSZone clears all records in the zone
func (*DNSResolver) HasRecords ¶
func (r *DNSResolver) HasRecords(name string) (bool, error)
HasRecords returns true if the given name has any RRsets
func (*DNSResolver) Record ¶
func (r *DNSResolver) Record(name string, rrType uint16) ([]byte, error)
Record obtains an RRSet for a name
func (*DNSResolver) SetRecords ¶
func (r *DNSResolver) SetRecords(opts *bind.TransactOpts, data []byte) (*types.Transaction, error)
SetRecords sets one or more RRSets
func (*DNSResolver) SetZonehash ¶ added in v3.1.0
func (r *DNSResolver) SetZonehash(opts *bind.TransactOpts, zonehash []byte) (*types.Transaction, error)
SetZonehash sets the zone hash of the domain
func (*DNSResolver) Zonehash ¶ added in v3.1.0
func (r *DNSResolver) Zonehash() ([]byte, error)
Zonehash returns the zone hash of the domain
type DNSSECOracle ¶
type DNSSECOracle struct { Contract *dnssecoracle.Contract ContractAddr common.Address // contains filtered or unexported fields }
DNSSECOracle is the structure for the DNSSEC oracle
func NewDNSSECOracle ¶
func NewDNSSECOracle(backend bind.ContractBackend, domain string) (*DNSSECOracle, error)
NewDNSSECOracle obtains the DNSSEC oracle contract for a given domain
type Deed ¶
Deed is the structure for the deed
func NewDeed ¶
func NewDeed(backend bind.ContractBackend, domain string) (*Deed, error)
NewDeed obtains the deed contract for a given domain
func (*Deed) PreviousOwner ¶
PreviousOwner obtains the previous owner of the deed
func (*Deed) SetOwner ¶
func (c *Deed) SetOwner(opts *bind.TransactOpts, address common.Address) (*types.Transaction, error)
SetOwner sets the owner of the deed
type ETHController ¶
type ETHController struct { Contract *ethcontroller.Contract ContractAddr common.Address // contains filtered or unexported fields }
ETHController is the structure for the .eth controller contract
func NewETHController ¶
func NewETHController(backend bind.ContractBackend, domain string) (*ETHController, error)
NewETHController creates a new controller for a given domain
func NewETHControllerAt ¶
func NewETHControllerAt(backend bind.ContractBackend, domain string, address common.Address) (*ETHController, error)
NewETHControllerAt creates a .eth controller at a given address
func (*ETHController) Commit ¶
func (c *ETHController) Commit(opts *bind.TransactOpts, domain string, owner common.Address, secret [32]byte) (*types.Transaction, error)
Commit sends a commitment to register a domain.
func (*ETHController) CommitmentHash ¶
func (c *ETHController) CommitmentHash(domain string, owner common.Address, secret [32]byte) (common.Hash, error)
CommitmentHash returns the commitment hash for a label/owner/secret tuple
func (*ETHController) CommitmentTime ¶
func (c *ETHController) CommitmentTime(domain string, owner common.Address, secret [32]byte) (*big.Int, error)
CommitmentTime states the time at which a commitment was registered on the blockchain.
func (*ETHController) IsAvailable ¶
func (c *ETHController) IsAvailable(domain string) (bool, error)
IsAvailable returns true if the domain is available for registration.
func (*ETHController) IsValid ¶
func (c *ETHController) IsValid(domain string) (bool, error)
IsValid returns true if the domain is considered valid by the controller.
func (*ETHController) MaxCommitmentInterval ¶
func (c *ETHController) MaxCommitmentInterval() (*big.Int, error)
MaxCommitmentInterval returns the maximum time that has to pass between a commit and reveal
func (*ETHController) MinCommitmentInterval ¶
func (c *ETHController) MinCommitmentInterval() (*big.Int, error)
MinCommitmentInterval returns the minimum time that has to pass between a commit and reveal
func (*ETHController) MinRegistrationDuration ¶
func (c *ETHController) MinRegistrationDuration() (time.Duration, error)
MinRegistrationDuration returns the minimum duration for which a name can be registered
func (*ETHController) Renew ¶
func (c *ETHController) Renew(opts *bind.TransactOpts, domain string) (*types.Transaction, error)
Renew renews a registered domain.
func (*ETHController) RentCost ¶
func (c *ETHController) RentCost(domain string) (*big.Int, error)
RentCost returns the cost of rent in wei-per-second.
func (*ETHController) Reveal ¶
func (c *ETHController) Reveal(opts *bind.TransactOpts, domain string, owner common.Address, secret [32]byte) (*types.Transaction, error)
Reveal reveals a commitment to register a domain.
type Name ¶
type Name struct { // Name is the fully-qualified name of an ENS domain e.g. foo.bar.eth Name string // Domain is the domain of an ENS domain e.g. bar.eth Domain string // Label is the name part of an ENS domain e.g. foo Label string // contains filtered or unexported fields }
Name represents an ENS name, for example 'foo.bar.eth'.
func NewName ¶
func NewName(backend bind.ContractBackend, name string) (*Name, error)
NewName creates an ENS name structure. Note that this does not create the name on-chain.
func (*Name) Address ¶ added in v3.0.9
Address fetches the address of the name for a given coin type. Coin types are defined at https://github.com/satoshilabs/slips/blob/master/slip-0044.md
func (*Name) Controller ¶
Controller obtains the controller for this name. The controller can carry out operations on the name such as setting records, but cannot transfer ultimate ownership of the name.
func (*Name) CreateSubdomain ¶
func (n *Name) CreateSubdomain(label string, controller common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
CreateSubdomain creates a subdomain on the name.
func (*Name) ExtendRegistration ¶
func (n *Name) ExtendRegistration(opts *bind.TransactOpts) (*types.Transaction, error)
ExtendRegistration sends a transaction that extends the registration of the name.
func (*Name) IsRegistered ¶
IsRegistered returns true if the name is registered in the registrar
func (*Name) Reclaim ¶
func (n *Name) Reclaim(opts *bind.TransactOpts) (*types.Transaction, error)
Reclaim reclaims controller rights by the registrant
func (*Name) RegisterStageOne ¶
func (n *Name) RegisterStageOne(registrant common.Address, opts *bind.TransactOpts) (*types.Transaction, [32]byte, error)
RegisterStageOne sends a transaction that starts the registration process.
func (*Name) RegisterStageTwo ¶
func (n *Name) RegisterStageTwo(registrant common.Address, secret [32]byte, opts *bind.TransactOpts) (*types.Transaction, error)
RegisterStageTwo sends a transaction that completes the registration process. The registrant must be the same as supplied in RegisterStageOne. The secret is that returned by RegisterStageOne. At least RegistrationInterval() time must have passed since the stage one transaction was mined for this to work.
func (*Name) Registrant ¶
Registrant obtains the registrant for this name.
func (*Name) RegistrationInterval ¶
RegistrationInterval obtains the minimum interval between commit and reveal when registering this name.
func (*Name) ResolverAddress ¶
ResolverAddress fetches the address of the resolver contract for the name.
func (*Name) SetAddress ¶ added in v3.0.9
func (n *Name) SetAddress(coinType uint64, address []byte, opts *bind.TransactOpts) (*types.Transaction, error)
SetAddress sets the address of the name for a given coin type. Coin types are defined at https://github.com/satoshilabs/slips/blob/master/slip-0044.md
func (*Name) SetController ¶
func (n *Name) SetController(controller common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
SetController sets the controller for this name. The controller can carry out operations on the name such as setting records, but cannot transfer ultimate ownership of the name.
func (*Name) SetResolverAddress ¶
func (n *Name) SetResolverAddress(address common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
SetResolverAddress sets the resolver contract address for the name.
func (*Name) Transfer ¶
func (n *Name) Transfer(registrant common.Address, opts *bind.TransactOpts) (*types.Transaction, error)
Transfer transfers the registration of this name to a new registrant.
type Registry ¶
type Registry struct { Contract *registry.Contract ContractAddr common.Address // contains filtered or unexported fields }
Registry is the structure for the registry contract
func NewRegistry ¶
func NewRegistry(backend bind.ContractBackend) (*Registry, error)
NewRegistry obtains the ENS registry
func NewRegistryAt ¶
NewRegistryAt obtains the ENS registry at a given address
func (*Registry) ResolverAddress ¶
ResolverAddress returns the address of the resolver for a name
func (*Registry) SetOwner ¶
func (r *Registry) SetOwner(opts *bind.TransactOpts, name string, address common.Address) (*types.Transaction, error)
SetOwner sets the ownership of a domain
func (*Registry) SetResolver ¶
func (r *Registry) SetResolver(opts *bind.TransactOpts, name string, address common.Address) (*types.Transaction, error)
SetResolver sets the resolver for a name
func (*Registry) SetSubdomainOwner ¶
func (r *Registry) SetSubdomainOwner(opts *bind.TransactOpts, name string, subname string, address common.Address) (*types.Transaction, error)
SetSubdomainOwner sets the ownership of a subdomain, potentially creating it in the process
type Resolver ¶
type Resolver struct { Contract *resolver.Contract ContractAddr common.Address // contains filtered or unexported fields }
Resolver is the structure for the resolver contract
func NewResolver ¶
func NewResolver(backend bind.ContractBackend, domain string) (*Resolver, error)
NewResolver obtains an ENS resolver for a given domain
func NewResolverAt ¶
func NewResolverAt(backend bind.ContractBackend, domain string, address common.Address) (*Resolver, error)
NewResolverAt obtains an ENS resolver at a given address
func (*Resolver) Contenthash ¶
Contenthash returns the content hash of the domain
func (*Resolver) InterfaceImplementer ¶
InterfaceImplementer returns the address of the contract that implements the given interface for the given domain
func (*Resolver) MultiAddress ¶ added in v3.0.9
MultiAddress returns the address of the domain for a given coin type. The coin type is as per https://github.com/satoshilabs/slips/blob/master/slip-0044.md
func (*Resolver) SetABI ¶
func (r *Resolver) SetABI(opts *bind.TransactOpts, name string, abi string, contentType *big.Int) (*types.Transaction, error)
SetABI sets the ABI associated with a name
func (*Resolver) SetAddress ¶
func (r *Resolver) SetAddress(opts *bind.TransactOpts, address common.Address) (*types.Transaction, error)
SetAddress sets the Ethereum address of the domain
func (*Resolver) SetContenthash ¶
func (r *Resolver) SetContenthash(opts *bind.TransactOpts, contenthash []byte) (*types.Transaction, error)
SetContenthash sets the content hash of the domain
func (*Resolver) SetMultiAddress ¶ added in v3.0.9
func (r *Resolver) SetMultiAddress(opts *bind.TransactOpts, coinType uint64, address []byte) (*types.Transaction, error)
SetMultiAddress sets the iaddress of the domain for a given coin type. The coin type is as per https://github.com/satoshilabs/slips/blob/master/slip-0044.md
func (*Resolver) SetPubKey ¶ added in v3.0.6
func (r *Resolver) SetPubKey(opts *bind.TransactOpts, x [32]byte, y [32]byte) (*types.Transaction, error)
SetPubKey sets the public key of the domain
func (*Resolver) SetText ¶
func (r *Resolver) SetText(opts *bind.TransactOpts, name string, value string) (*types.Transaction, error)
SetText sets the text associated with a name
type ReverseRegistrar ¶
type ReverseRegistrar struct { Contract *reverseregistrar.Contract ContractAddr common.Address }
ReverseRegistrar is the structure for the reverse registrar
func NewReverseRegistrar ¶
func NewReverseRegistrar(backend bind.ContractBackend) (*ReverseRegistrar, error)
NewReverseRegistrar obtains the reverse registrar
func NewReverseRegistrarAt ¶
func NewReverseRegistrarAt(backend bind.ContractBackend, address common.Address) (*ReverseRegistrar, error)
NewReverseRegistrarAt obtains the reverse registrar at a given address
func (*ReverseRegistrar) DefaultResolverAddress ¶
func (r *ReverseRegistrar) DefaultResolverAddress() (common.Address, error)
DefaultResolverAddress obtains the default resolver address
func (*ReverseRegistrar) SetName ¶
func (r *ReverseRegistrar) SetName(opts *bind.TransactOpts, name string) (tx *types.Transaction, err error)
SetName sets the name
type ReverseResolver ¶
type ReverseResolver struct { Contract *reverseresolver.Contract ContractAddr common.Address }
ReverseResolver is the structure for the reverse resolver contract
func NewReverseResolver ¶
func NewReverseResolver(backend bind.ContractBackend) (*ReverseResolver, error)
NewReverseResolver obtains the reverse resolver
func NewReverseResolverAt ¶
func NewReverseResolverAt(backend bind.ContractBackend, address common.Address) (*ReverseResolver, error)
NewReverseResolverAt obtains the reverse resolver at a given address
func NewReverseResolverFor ¶ added in v3.4.0
func NewReverseResolverFor(backend bind.ContractBackend, address common.Address) (*ReverseResolver, error)
NewReverseResolverFor creates a reverse resolver contract for the given address.