novax-account 0.2.12

The `novax-account` crate offers utilities for retrieving account information from the blockchain, such as address balance, nonce, code or code hash.
use serde::{Deserialize, Serialize};
use novax::errors::NovaXError;

#[derive(Serialize, Deserialize, Clone, PartialEq, Debug)]
pub enum AccountError {
    AccountNotFound { address: String },
    CannotDecodeCodeMetadata { metadata: String},
    UnknownErrorWhileGettingInfosOfAccount { address: String},
    CannotParseAccountInfo { address: String},
    CannotParseAccountBalance { address: String, balance: String},
    CannotParseAccountDeveloperReward { address: String, reward: String},
    CannotParseAccountOwnerAddress { address: String, owner: String},
    NestedAppError(NovaXError)
}

impl From<NovaXError> for AccountError {
    fn from(value: NovaXError) -> Self {
        AccountError::NestedAppError(value)
    }
}