> For the complete documentation index, see [llms.txt](https://docs.rigoblock.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.rigoblock.com/api/protocol/libraries/storagelib.md).

# StorageLib

## Overview

#### License: Apache-2.0-or-later

```solidity
library StorageLib
```

A library for extensions to access proxy pre-assigned storage slots.

## Constants info

### APPLICATIONS\_SLOT (0x6cfa4b91)

```solidity
bytes32 constant APPLICATIONS_SLOT = 0xdc487a67cca3fd0341a90d1b8834103014d2a61e6a212e57883f8680b8f9c831
```

persistent storage slots, used to read from proxy storage without having to update implementation

### DELEGATION\_SLOT (0x71a9550b)

```solidity
bytes32 constant DELEGATION_SLOT = 0x1de728329845ca9693f4e251833e4fd20a461e4f39179bee6e55171aedb6dc19
```

### POOL\_INIT\_SLOT (0x4a3979e3)

```solidity
bytes32 constant POOL_INIT_SLOT = 0xe48b9bb119adfc3bccddcc581484cc6725fe8d292ebfcec7d67b1f93138d8bd8
```

### POOL\_TOKENS\_SLOT (0x56d208e1)

```solidity
bytes32 constant POOL_TOKENS_SLOT = 0xf46fb7ff9ff9a406787c810524417c818e45ab2f1997f38c2555c845d23bb9f6
```

### TOKEN\_REGISTRY\_SLOT (0xa26ea087)

```solidity
bytes32 constant TOKEN_REGISTRY_SLOT = 0x3dcde6752c7421366e48f002bbf8d6493462e0e43af349bebb99f0470a12300d
```

### UNIV4\_TOKEN\_IDS\_SLOT (0xe0668072)

```solidity
bytes32 constant UNIV4_TOKEN_IDS_SLOT = 0xd87266b00c1e82928c0b0200ad56e2ee648a35d4e9b273d2ac9533471e3b5d3c
```

### HYPERLIQUID\_DATA\_SLOT (0xd0331a58)

```solidity
bytes32 constant HYPERLIQUID_DATA_SLOT = 0x4afbc3162e1589b633acdf6b7c00223a8c67447dd0ad462eaa13272955dff2a1
```

## Functions info

### pool

```solidity
function pool() internal pure returns (Pool storage s)
```

### delegation

```solidity
function delegation() internal pure returns (DelegationData storage s)
```

### activeTokensSet

```solidity
function activeTokensSet() internal pure returns (AddressSet storage s)
```

### uniV4TokenIdsSlot

```solidity
function uniV4TokenIdsSlot() internal pure returns (TokenIdsSlot storage s)
```

### activeApplications

```solidity
function activeApplications()
    internal
    pure
    returns (ApplicationsSlot storage s)
```

### hyperliquidData

```solidity
function hyperliquidData() internal pure returns (HyperliquidData storage s)
```

### isOwnedToken

```solidity
function isOwnedToken(address token) internal view returns (bool)
```

Checks if a token is owned by the pool (base token or active token)

Parameters:

| Name  | Type    | Description            |
| ----- | ------- | ---------------------- |
| token | address | Token address to check |

Return values:

| Name | Type | Description                                         |
| ---- | ---- | --------------------------------------------------- |
| \[0] | bool | True if token is base token or in active tokens set |
