[][src]Struct schemeguardian::DestructureToken

pub struct DestructureToken(_);

Struct that splits a token at the pattern :::

Struct structure

use redactedsecret::SecretString;

pub struct DestructureToken(SecretString);

Example

use schemeguardian::DestructureToken;
use redactedsecret::SecretString;

DestructureToken::new()
    .token(SecretString::new("Foo".to_owned()))
    .build();

Methods

impl DestructureToken[src]

Usage

use schemeguardian::DestructureToken;

pub fn new() -> Self[src]

Initialize a new DestructureToken struct returning a Self value

Example

use schemeguardian::DestructureToken;
use redactedsecret::SecretString;

DestructureToken::new()
    .token(SecretString::new("Foo".to_owned()))
    .build();

pub fn token(self, value: SecretString) -> Self[src]

Replace the default field with user specified field

Example

use schemeguardian::DestructureToken;
use redactedsecret::SecretString;

DestructureToken::new()
    .token(SecretString::new("Foo".to_owned()));

pub fn identifier(&self) -> Option<SecretString>[src]

Takes the branca decoded key from the client and splits it into a Identifier keys

Example

use schemeguardian::DestructureToken;
use redactedsecret::SecretString;

DestructureToken::new()
    .token(SecretString::new("Foo".to_owned()))
    .identifier();

pub fn rac(&self) -> Option<SecretString>[src]

Takes the branca decoded key from the client and splits it into a RandomAccessCode keys

Example

use schemeguardian::DestructureToken;
use redactedsecret::SecretString;

DestructureToken::new()
    .token(SecretString::new("Foo".to_owned()))
    .rac();

pub fn build(&self) -> Option<(SecretString, SecretString)>[src]

Takes the branca decoded key from the client and splits it into a identifier and RandomAccessCode keys Returns (Identifier, RandomAccessCode) as (SecretString, SecretString)

Example

use schemeguardian::DestructureToken;
use redactedsecret::SecretString;

DestructureToken::new()
    .token(SecretString::new("Foo".to_owned()))
    .build();

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,