Trait roles_rpc::RolesApi[][src]

pub trait RolesApi<BlockHash, AccountId>: Sized + Send + Sync + 'static {
    fn get_space_permissions_by_account(
        &self,
        at: Option<BlockHash>,
        account: AccountId,
        space_id: SpaceId
    ) -> Result<Vec<SpacePermission>>;
fn get_accounts_with_any_role_in_space(
        &self,
        at: Option<BlockHash>,
        space_id: SpaceId
    ) -> Result<Vec<AccountId>>;
fn get_space_ids_for_account_with_any_role(
        &self,
        at: Option<BlockHash>,
        account_id: AccountId
    ) -> Result<Vec<SpaceId>>; fn to_delegate<M: Metadata>(self) -> IoDelegate<Self, M>
    where
        BlockHash: Send + Sync + 'static + DeserializeOwned,
        AccountId: Send + Sync + 'static + Serialize + DeserializeOwned
, { ... } }

Required methods

fn get_space_permissions_by_account(
    &self,
    at: Option<BlockHash>,
    account: AccountId,
    space_id: SpaceId
) -> Result<Vec<SpacePermission>>
[src]

fn get_accounts_with_any_role_in_space(
    &self,
    at: Option<BlockHash>,
    space_id: SpaceId
) -> Result<Vec<AccountId>>
[src]

fn get_space_ids_for_account_with_any_role(
    &self,
    at: Option<BlockHash>,
    account_id: AccountId
) -> Result<Vec<SpaceId>>
[src]

Loading content...

Provided methods

fn to_delegate<M: Metadata>(self) -> IoDelegate<Self, M> where
    BlockHash: Send + Sync + 'static + DeserializeOwned,
    AccountId: Send + Sync + 'static + Serialize + DeserializeOwned
[src]

Create an IoDelegate, wiring rpc calls to the trait methods.

Loading content...

Implementors

impl<C, Block, AccountId> RolesApi<<Block as Block>::Hash, AccountId> for Roles<C, Block> where
    Block: BlockT,
    AccountId: Codec,
    C: Send + Sync + 'static + ProvideRuntimeApi<Block> + HeaderBackend<Block>,
    C::Api: RolesRuntimeApi<Block, AccountId>, 
[src]

Loading content...