pub struct NamespaceTable {
pub tap: Option<String>,
pub uri: Option<String>,
pub rev: Option<String>,
pub subdir: Option<String>,
pub via: Option<Via>,
}Fields§
§tap: Option<String>Tap-prefix shorthand. tap = "acme" expands to
github:acme/lex-labels.
uri: Option<String>Explicit URI (github:, gitlab:, https:, path:,
git+ssh:).
rev: Option<String>Branch / tag / SHA pin. Mutable refs (branches) honour the resolver’s 24-hour cache TTL; tags and SHAs are cached indefinitely.
subdir: Option<String>Subdirectory inside the resolved repo containing the schema files. Defaults to repo root.
via: Option<Via>Transport selector for github: / gitlab: URL templates.
"https" (default) uses the forge’s tarball/archive API over
public HTTPS; "git" uses a git clone, inheriting the user’s
git credential setup for private repos (SSH agent, OS keychain,
gh CLI, etc.). Only valid when the spec resolves to a template
scheme (tap, or uri starting with github: / gitlab:);
declaring it on a non-template URI is a load-time error.
Implementations§
Source§impl NamespaceTable
impl NamespaceTable
Sourcepub fn validate(&self) -> Result<(), LabelsConfigError>
pub fn validate(&self) -> Result<(), LabelsConfigError>
Validate mutual-exclusion + non-emptiness, plus that via is
only declared on URL-template-shaped specs (tap, or uri
using github: / gitlab:). via on a path: / https: /
git+ssh: / git: URI is meaningless — the transport is
already fully determined — so reject it at load time rather
than letting it silently no-op.
Trait Implementations§
Source§impl Clone for NamespaceTable
impl Clone for NamespaceTable
Source§fn clone(&self) -> NamespaceTable
fn clone(&self) -> NamespaceTable
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for NamespaceTable
impl Debug for NamespaceTable
Source§impl Default for NamespaceTable
impl Default for NamespaceTable
Source§fn default() -> NamespaceTable
fn default() -> NamespaceTable
Source§impl<'de> Deserialize<'de> for NamespaceTable
impl<'de> Deserialize<'de> for NamespaceTable
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for NamespaceTable
impl RefUnwindSafe for NamespaceTable
impl Send for NamespaceTable
impl Sync for NamespaceTable
impl Unpin for NamespaceTable
impl UnsafeUnpin for NamespaceTable
impl UnwindSafe for NamespaceTable
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> 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>
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>
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