pub struct HostToolAuthority {
workspace_root: PathBuf,
capabilities: Vec<Capability>,
paths: Vec<PathBuf>,
sources: Vec<String>,
}Expand description
Host-issued authority. Resource declarations can only narrow these grants.
Fields§
§workspace_root: PathBuf§capabilities: Vec<Capability>§paths: Vec<PathBuf>§sources: Vec<String>Implementations§
Source§impl HostToolAuthority
impl HostToolAuthority
pub fn new(workspace_root: &Path, capabilities: Vec<Capability>) -> Result<Self>
pub fn enroll_path(&mut self, path: &Path) -> Result<()>
pub fn enroll_source(&mut self, source: String) -> Result<()>
pub fn workspace_root(&self) -> &Path
pub fn capabilities(&self) -> &[Capability]
pub fn paths(&self) -> &[PathBuf]
pub fn sources(&self) -> &[String]
Trait Implementations§
Source§impl Clone for HostToolAuthority
impl Clone for HostToolAuthority
Source§fn clone(&self) -> HostToolAuthority
fn clone(&self) -> HostToolAuthority
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for HostToolAuthority
impl RefUnwindSafe for HostToolAuthority
impl Send for HostToolAuthority
impl Sync for HostToolAuthority
impl Unpin for HostToolAuthority
impl UnsafeUnpin for HostToolAuthority
impl UnwindSafe for HostToolAuthority
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more