IRoyaltyEngineV1.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/// @author: manifold.xyz
import "@openzeppelin/contracts/utils/introspection/IERC165Upgradeable.sol";
/**
* @dev Lookup engine interface
*/
interface IRoyaltyEngineV1 is IERC165Upgradeable {
/**
* Get the royalty for a given token (address, id) and value amount. Does not cache the bps/amounts. Caches the spec for a given token address
*
* @param tokenAddress - The address of the token
* @param tokenId - The id of the token
* @param value - The value you wish to get the royalty of
*
* returns Two arrays of equal length, royalty recipients and the corresponding amount each recipient should get
*/
function getRoyalty(
address tokenAddress,
uint256 tokenId,
uint256 value
) external returns (address payable[] memory recipients, uint256[] memory amounts);
/**
* View only version of getRoyalty
*
* @param tokenAddress - The address of the token
* @param tokenId - The id of the token
* @param value - The value you wish to get the royalty of
*
* returns Two arrays of equal length, royalty recipients and the corresponding amount each recipient should get
*/
function getRoyaltyView(
address tokenAddress,
uint256 tokenId,
uint256 value
) external view returns (address payable[] memory recipients, uint256[] memory amounts);
}
Updated over 1 year ago