Skip to main content

JBProjectHandles

Manages reverse records that point from JB project IDs to ENS nodes. If the reverse record of a project ID is pointed to an ENS node with a TXT record matching the ID of that project, then the ENS node will be considered the "handle" for that project.

Code

https://github.com/jbx-protocol/juice-project-handles/blob/main/contracts/JBProjectHandles.sol

Addresses

Ethereum mainnet: 0xD75d2EeF7Fe65Bf9f46D7ef0b21EdED98cB0a3A4

Goerli testnet: 0xAD6F7c8052F806F83AD5F51b33cE4E547CC00f3d

Interfaces

NameDescription
IJBProjectHandlesGeneral interface for the methods in this contract that interact with the blockchain's state according to the protocol's rules.

Inheritance

ContractDescription
JBOperatableIncludes convenience functionality for checking a message sender's permissions before executing certain transactions.

Constructor

/**
@param _projects A contract which mints ERC-721's that represent project ownership and transfers.
@param _operatorStore A contract storing operator assignments.
@param _textResolver The ENS text resolver contract address.
*/
constructor(
IJBProjects _projects,
IJBOperatorStore _operatorStore,
ITextResolver _textResolver
) JBOperatable(_jbOperatorStore) {
projects = _projects;
textResolver = _textResolver;
}
  • _projects is a contract which mints ERC-721's that represent project ownership and transfers.
  • _operatorStore is a contract storing operator assignments.
  • _textResolver is the ENS text resolver contract address.

Events

NameData
SetEnsNameParts
  • uint256 indexed projectId
  • string indexed handle
  • string[] parts
  • address caller

Properties

NameDefinition
projects

Returns

textResolver

Returns

TEXT_KEY

Returns

  • string

Read

FunctionDefinition
handleOf

Params

  • uint256 _projectId

Returns

  • string memory
ensNamePartsOf

Params

  • uint256 _projectId

Returns

  • string[] memory

Write

FunctionDefinition
setEnsNamePartsFor

Traits

Params

  • uint256 _projectId
  • string[] memory _parts