#[non_exhaustive]pub enum DeclarationErrorKind {
Show 42 variants
MissingDb,
MissingAuthModels {
models: Vec<&'static str>,
},
ShellAssetsWithoutBundle,
InvalidSegment {
item: &'static str,
segment: String,
fault: SegmentFault,
},
PrefixOverlapsRuntime {
prefix: String,
},
PrefixOverlapsPanel {
other: String,
},
ServeDirWithoutCatchAll {
path: String,
},
ServeDirTwice {
path: String,
},
ServeDirTaken {
path: String,
panel: String,
},
SecondHome,
DuplicateResource,
NotMounted,
ReservedSlug {
slug: String,
},
DuplicateSlug {
slug: String,
},
DuplicateAction {
name: &'static str,
},
DuplicateRelation,
UnregisteredRelation,
UnregisteredOptionSource {
field: String,
source: &'static str,
},
TraversalLens {
steps: usize,
},
UnresolvedLens {
model: &'static str,
steps: Vec<usize>,
},
TenancyColumnNotAField,
TenancyViaOwnColumn,
TenancyViaWithoutBelongsTo,
UnguardedForeignKey {
relation: String,
keys: Vec<String>,
},
NoColumns,
ZeroPageSize,
DuplicateColumn {
name: String,
},
DuplicateFilter {
name: String,
},
DuplicateField {
name: String,
},
EmptyFormOverride,
FormWithoutRecordForm,
CreateWithoutForm,
UnboundControl {
control: String,
},
ControlBoundTwice {
control: String,
},
MissingControl {
field: String,
key: String,
},
NoBlankAnswer {
control: String,
field: String,
in_repeater: bool,
},
FormClaimsTenantColumn {
field: String,
column: String,
},
CompositeKeyChoice {
field: String,
},
UniqueWithoutIndex {
field: String,
},
CreateColumnsNameTenant {
column: String,
},
UnknownCreateColumn {
column: &'static str,
},
UnwrittenColumn {
column: String,
},
}Expand description
What is wrong with a declaration.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
MissingDb
The router holds no toasty::Db.
MissingAuthModels
Auth is on, but the Db does not register the shipped models it needs.
ShellAssetsWithoutBundle
Panel::shell_assets is set, but the router has no asset bundle.
InvalidSegment
A path segment the panel routes cannot be a literal URL segment.
Fields
fault: SegmentFaultWhy it is refused.
PrefixOverlapsRuntime
The prefix overlaps Topcoat’s runtime endpoints.
PrefixOverlapsPanel
The prefix overlaps another panel’s.
ServeDirWithoutCatchAll
A Panel::serve_dir pattern that does not end in a catch-all.
ServeDirTwice
The panel serves the same directory pattern twice.
ServeDirTaken
Another panel already serves the directory pattern.
SecondHome
A second Panel::home page.
DuplicateResource
The resource is registered on the panel twice.
NotMounted
The resource is not mounted on the request’s panel.
ReservedSlug
A slug naming a route the panel serves itself.
DuplicateSlug
A slug another resource or page already mounts at.
DuplicateAction
Two actions share a NAME.
DuplicateRelation
Two relations to the same resource.
UnregisteredRelation
A relation to a resource the panel does not register.
UnregisteredOptionSource
A relationship field whose options come from a resource the panel does not register.
TraversalLens
A lens with more than one step where a single field of the model is needed.
UnresolvedLens
A multi-step lens that resolves to no single column.
Fields
TenancyColumnNotAField
A Tenancy::column lens that names no field of the model.
TenancyViaOwnColumn
A Tenancy::via lens that names one field of the model.
TenancyViaWithoutBelongsTo
A Tenancy::via lens whose first step is no belongs_to relation.
UnguardedForeignKey
A Tenancy::via resource whose form writes the parent’s foreign key other than through a
relationship field over a tenant-scoped resource of the parent’s model.
Fields
NoColumns
A table with no column.
ZeroPageSize
Table::paginate(0).
DuplicateColumn
Two table columns share a name.
DuplicateFilter
Two table filters share a name.
DuplicateField
Two schema fields share a name.
EmptyFormOverride
A form() override that declares no control over a record form with fields.
FormWithoutRecordForm
A form schema on a resource whose Form serves no form.
CreateWithoutForm
A resource whose policy allows create but that has no form.
UnboundControl
A form control no record-form field binds, so its input is never written.
ControlBoundTwice
A form control more than one record-form field binds.
MissingControl
A record-form field binding a key the form declares no control for.
NoBlankAnswer
A control that may be posted empty over a record-form field with no blank answer.
Fields
FormClaimsTenantColumn
A tenant-scoped resource’s record form claims the tenant column.
CompositeKeyChoice
A relationship field over a model with a composite primary key.
UniqueWithoutIndex
A field marked unique over a column no unique index covers.
CreateColumnsNameTenant
create_columns names the tenant column.
UnknownCreateColumn
create_columns names a field the model does not have.
UnwrittenColumn
A non-nullable column nothing writes on create.
Trait Implementations§
Source§impl Clone for DeclarationErrorKind
impl Clone for DeclarationErrorKind
Source§impl Debug for DeclarationErrorKind
impl Debug for DeclarationErrorKind
Source§impl Display for DeclarationErrorKind
impl Display for DeclarationErrorKind
impl Eq for DeclarationErrorKind
Source§impl PartialEq for DeclarationErrorKind
impl PartialEq for DeclarationErrorKind
impl StructuralPartialEq for DeclarationErrorKind
Auto Trait Implementations§
impl Freeze for DeclarationErrorKind
impl RefUnwindSafe for DeclarationErrorKind
impl Send for DeclarationErrorKind
impl Sync for DeclarationErrorKind
impl Unpin for DeclarationErrorKind
impl UnsafeUnpin for DeclarationErrorKind
impl UnwindSafe for DeclarationErrorKind
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> CloneAny for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.