@@ -17,14 +17,61 @@ import {AddressListInterfaceId} from "../rules/interfaces/library/AddressListInt
1717 */
1818interface IAddressListAllFunctions {
1919 /* ==== From IAddressList ==== */
20+
21+ /**
22+ * @notice Adds several addresses to the set.
23+ * @param targetAddresses The addresses to add.
24+ */
2025 function addAddresses (address [] calldata targetAddresses ) external ;
26+
27+ /**
28+ * @notice Removes several addresses from the set.
29+ * @param targetAddresses The addresses to remove.
30+ */
2131 function removeAddresses (address [] calldata targetAddresses ) external ;
32+
33+ /**
34+ * @notice Adds a single address to the set.
35+ * @param targetAddress The address to add.
36+ */
2237 function addAddress (address targetAddress ) external ;
38+
39+ /**
40+ * @notice Removes a single address from the set.
41+ * @param targetAddress The address to remove.
42+ */
2343 function removeAddress (address targetAddress ) external ;
44+
45+ /**
46+ * @notice Returns the number of addresses currently in the set.
47+ * @return count The number of listed addresses.
48+ */
2449 function listedAddressCount () external view returns (uint256 count );
50+
51+ /**
52+ * @notice Returns whether a single address is in the set.
53+ * @param targetAddress The address to check.
54+ * @return isListed True if the address is listed.
55+ */
2556 function isAddressListed (address targetAddress ) external view returns (bool isListed );
57+
58+ /**
59+ * @notice Returns membership for several addresses in one call.
60+ * @param targetAddresses The addresses to check.
61+ * @return results One boolean per input address, in the same order.
62+ */
2663 function areAddressesListed (address [] memory targetAddresses ) external view returns (bool [] memory results );
64+
2765 /* ==== From IIdentityRegistryContains ==== */
66+
67+ /**
68+ * @notice Returns whether an address is in the set.
69+ * @dev This is the selector that `type(IAddressList).interfaceId` OMITS, because it is
70+ * inherited rather than declared directly. Redeclaring it here is the whole point of
71+ * this flattened interface.
72+ * @param _userAddress The address to check.
73+ * @return True if the address is listed.
74+ */
2875 function contains (address _userAddress ) external view returns (bool );
2976}
3077
@@ -36,27 +83,31 @@ interface IAddressListAllFunctions {
3683contract IAddressListInterfaceIdHelper {
3784 /**
3885 * @notice Returns `type(IAddressList).interfaceId` — INCOMPLETE, omits inherited selectors.
86+ * @return The naive interface ID, which does NOT include the inherited `contains(address)`.
3987 */
4088 function getIAddressListInterfaceId () external pure returns (bytes4 ) {
4189 return type (IAddressList).interfaceId;
4290 }
4391
4492 /**
4593 * @notice Returns the XOR of ALL selectors in the {IAddressList} hierarchy (flattened).
94+ * @return The complete interface ID, including the inherited `contains(address)` selector.
4695 */
4796 function getIAddressListAllFunctionsInterfaceId () external pure returns (bytes4 ) {
4897 return type (IAddressListAllFunctions).interfaceId;
4998 }
5099
51100 /**
52101 * @notice Returns the constant defined in the {AddressListInterfaceId} library.
102+ * @return The pre-computed constant the rules actually advertise via ERC-165.
53103 */
54104 function getAddressListInterfaceIdConstant () external pure returns (bytes4 ) {
55105 return AddressListInterfaceId.IADDRESS_LIST_INTERFACE_ID;
56106 }
57107
58108 /**
59109 * @notice Returns the interface ID of the inherited parent interface.
110+ * @return The interface ID of {IIdentityRegistryContains}.
60111 */
61112 function getIIdentityRegistryContainsInterfaceId () external pure returns (bytes4 ) {
62113 return type (IIdentityRegistryContains).interfaceId;
0 commit comments