pub(crate) enum ItemType {
Show 26 variants
Module,
ExternCrate,
Import,
Struct,
Enum,
Function,
Typedef,
Static,
Trait,
Impl,
TyMethod,
Method,
StructField,
Variant,
Macro,
Primitive,
AssocType,
Constant,
AssocConst,
Union,
ForeignType,
Keyword,
OpaqueTy,
ProcAttribute,
ProcDerive,
TraitAlias,
}Expand description
Item type. Corresponds to clean::ItemEnum variants.
The search index uses item types encoded as smaller numbers which equal to
discriminants. JavaScript then is used to decode them into the original value.
Consequently, every change to this type should be synchronized to
the itemTypes mapping table in html/static/js/search.js.
In addition, code in html::render uses this enum to generate CSS classes, page prefixes, and
module headings. If you are adding to this enum and want to ensure that the sidebar also prints
a heading, edit the listing in html/render.rs, function sidebar_module. This uses an
ordering based on a helper function inside item_module, in the same file.
Variants
Module
ExternCrate
Import
Struct
Enum
Function
Typedef
Static
Trait
Impl
TyMethod
Method
StructField
Variant
Macro
Primitive
AssocType
Constant
AssocConst
Union
ForeignType
Keyword
OpaqueTy
ProcAttribute
ProcDerive
TraitAlias
Implementations
Trait Implementations
sourceimpl FromWithTcx<ItemType> for ItemKind
impl FromWithTcx<ItemType> for ItemKind
sourceimpl Ord for ItemType
impl Ord for ItemType
sourceimpl PartialOrd<ItemType> for ItemType
impl PartialOrd<ItemType> for ItemType
sourcefn partial_cmp(&self, other: &ItemType) -> Option<Ordering>
fn partial_cmp(&self, other: &ItemType) -> Option<Ordering>
This method returns an ordering between self and other values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
impl Copy for ItemType
impl Eq for ItemType
impl StructuralEq for ItemType
impl StructuralPartialEq for ItemType
Auto Trait Implementations
impl RefUnwindSafe for ItemType
impl Send for ItemType
impl Sync for ItemType
impl Unpin for ItemType
impl UnwindSafe for ItemType
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more
impl<'a, T> Captures<'a> for T where
T: ?Sized,
Layout
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference’s “Type Layout” chapter for details on type layout guarantees.
Size: 1 byte
Size for each variant:
Module: 0 bytesExternCrate: 0 bytesImport: 0 bytesStruct: 0 bytesEnum: 0 bytesFunction: 0 bytesTypedef: 0 bytesStatic: 0 bytesTrait: 0 bytesImpl: 0 bytesTyMethod: 0 bytesMethod: 0 bytesStructField: 0 bytesVariant: 0 bytesMacro: 0 bytesPrimitive: 0 bytesAssocType: 0 bytesConstant: 0 bytesAssocConst: 0 bytesUnion: 0 bytesForeignType: 0 bytesKeyword: 0 bytesOpaqueTy: 0 bytesProcAttribute: 0 bytesProcDerive: 0 bytesTraitAlias: 0 bytes