# Linear Boost Controller

When a user stakes SDL in the `SDLPool`, they can choose to lock it for a certain period of time gaining a boost depending on the duration of time they locked for. `LinearBoostController` handles the boost calculations to determine how much boosted reSDL an account will receive.

## View Functions

### maxLockingDuration

Returns the maximum duration that a lock can have

```solidity
function maxLockingDuration() external view returns (uint256)
```

#### Return Values

| Name               | Type    | Description          |
| ------------------ | ------- | -------------------- |
| maxLockingDuration | uint256 | max locking duration |

### maxBoost

Returns the maximum boost multiplier that can be received for a lock

```solidity
function maxBoost() external view returns (uint256)
```

#### Return Values

| Name     | Type    | Description          |
| -------- | ------- | -------------------- |
| maxBoost | uint256 | max boost multiplier |

### getBoostAmount

Returns the amount of boosted reSDL balance received for `_amount` of SDL with `_lockingDuration`

```solidity
function getBoostAmount(uint256 _amount, uint64 _lockingDuration) external view returns (uint256)
```

#### Parameters

| Name              | Type    | Description                    |
| ----------------- | ------- | ------------------------------ |
| \_amount          | uint256 | amount of tokens to lock       |
| \_lockingDuration | uint64  | duration of the locking period |

#### Return Values

| Name        | Type    | Description                                                           |
| ----------- | ------- | --------------------------------------------------------------------- |
| boostAmount | uint256 | amount of boost balance received in addition to the unboosted balance |

## Write Functions

### setMaxLockingDuration

Sets the maximum locking duration that a lock can have

```solidity
function setMaxLockingDuration(uint64 _maxLockingDuration) external
```

#### Parameters

| Name                 | Type   | Description                     |
| -------------------- | ------ | ------------------------------- |
| \_maxLockingDuration | uint64 | max locking duration in seconds |

### setMaxBoost

Sets the maximum boost multiplier that can be received for a lock

```solidity
function setMaxBoost(uint64 _maxBoost) external
```

#### Parameters

| Name       | Type   | Description          |
| ---------- | ------ | -------------------- |
| \_maxBoost | uint64 | max boost multiplier |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.stake.link/sdl-pool-contracts/linearboostcontroller.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
