# Account

This c**omponent** holds the base implementation for a tokenbound account. All functions contained within it is compulsory to maintain compatibility with SNIP-14.

The full contract code of the `AccountComponent` can be found [**here**](https://github.com/horuslabsio/TBA/blob/v3/src/components/account/account.cairo)**.**

## Functions

### `owner`

```rust
fn owner(self: @ComponentState<TContractState>) -> ContractAddress
```

This function retrieves the owner of the associated NFT.

### `token`

```rust
fn token(self: @ComponentState<TContractState>) -> (ContractAddress, u256, felt252);
```

This function returns the contract address and token ID of the associated NFT.

### `state`

```rust
fn state(self: @ComponentState<TContractState>) -> u256
```

This function retrieves the current state of the account.

### `supports_interface`

```rust
fn supports_interface( self: @ComponentState<TContractState>, interface_id: felt252) -> bool
```

This function checks if the account supports the tokenbound interface.

#### **Parameters**

| Name      | Type           | Description                             |
| --------- | -------------- | --------------------------------------- |
| `felt252` | `interface_id` | The interface ID to be checked against. |

#### **Returns**

`bool`:  Returns `true` If the interface is supported, otherwise false.
