목표
Solana Core concepts - 2
내용
Solana Account Model
On Solana, all data is contained in what we call "accounts".
Accounts can store up to 10MiB of data, which contain either executable program code or program state.
Account require a rent deposit in lamports that is proportional to the amount of data stored.
Every account has a program owner. Only the program that owns an account can modify its data.
Programs(smart contracts) are stateless accounts that store executable code.
Data accounts are created by programs to store and manage program state.
Accounts
Every account on Solana is identifiable by a unique 32byte address, which is generally displayed as a base58 encoded string.
The relationship between the account and its address can be thought of as a key-value pair.
Accounts have a max size of 10MiB and every account on Solana has the same base Account type.
pub struct Account {
pub lamports: u64,
#[cfg_attr(feature = "serde", serde(with = "serde_bytes"))]
pub data: Vec<u8>,
pub owner: Pubkey,
pub executable: bool,
pub rent_epoch: Epoch,
}
Every Account on Solana has the following fields:
- data
- executable
- lamports
- owner
- rent_epoch
'2024 동계 모각코' 카테고리의 다른 글
2024 동계 모각코 5회차 - 목표 및 결과 (0) | 2025.02.14 |
---|---|
2024 동계 모각코 4회차 - 목표 및 결과 (0) | 2025.02.05 |
2024 동계 모각코 3회차 - 목표 및 결과 (0) | 2025.01.27 |
2024 동계 모각코 2주차 - 목표 및 결과 (0) | 2025.01.20 |
2024 동계 모각코 1주차 - 목표 및 결과 (0) | 2025.01.12 |
목표
Solana Core concepts - 2
내용
Solana Account Model
On Solana, all data is contained in what we call "accounts".
Accounts can store up to 10MiB of data, which contain either executable program code or program state.
Account require a rent deposit in lamports that is proportional to the amount of data stored.
Every account has a program owner. Only the program that owns an account can modify its data.
Programs(smart contracts) are stateless accounts that store executable code.
Data accounts are created by programs to store and manage program state.
Accounts
Every account on Solana is identifiable by a unique 32byte address, which is generally displayed as a base58 encoded string.
The relationship between the account and its address can be thought of as a key-value pair.
Accounts have a max size of 10MiB and every account on Solana has the same base Account type.
pub struct Account {
pub lamports: u64,
#[cfg_attr(feature = "serde", serde(with = "serde_bytes"))]
pub data: Vec<u8>,
pub owner: Pubkey,
pub executable: bool,
pub rent_epoch: Epoch,
}
Every Account on Solana has the following fields:
- data
- executable
- lamports
- owner
- rent_epoch
'2024 동계 모각코' 카테고리의 다른 글
2024 동계 모각코 5회차 - 목표 및 결과 (0) | 2025.02.14 |
---|---|
2024 동계 모각코 4회차 - 목표 및 결과 (0) | 2025.02.05 |
2024 동계 모각코 3회차 - 목표 및 결과 (0) | 2025.01.27 |
2024 동계 모각코 2주차 - 목표 및 결과 (0) | 2025.01.20 |
2024 동계 모각코 1주차 - 목표 및 결과 (0) | 2025.01.12 |