Struct FileTypeDef

struct FileTypeDef { ... }

A single file type definition.

File type definitions can be retrieved in aggregate from a file type matcher. File type definitions are also reported when its responsible for a match.

Implementations

impl FileTypeDef

fn name(self: &Self) -> &str

Return the name of this file type.

fn globs(self: &Self) -> &[String]

Return the globs used to recognize this file type.

impl Clone for FileTypeDef

fn clone(self: &Self) -> FileTypeDef

impl Debug for FileTypeDef

fn fmt(self: &Self, f: &mut $crate::fmt::Formatter<'_>) -> $crate::fmt::Result

impl Eq for FileTypeDef

impl Freeze for FileTypeDef

impl PartialEq for FileTypeDef

fn eq(self: &Self, other: &FileTypeDef) -> bool

impl RefUnwindSafe for FileTypeDef

impl Send for FileTypeDef

impl StructuralPartialEq for FileTypeDef

impl Sync for FileTypeDef

impl Unpin for FileTypeDef

impl UnwindSafe for FileTypeDef

impl<T> Any for FileTypeDef

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for FileTypeDef

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for FileTypeDef

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> CloneToUninit for FileTypeDef

unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)

impl<T> From for FileTypeDef

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Pointable for FileTypeDef

unsafe fn init(init: <T as Pointable>::Init) -> usize
unsafe fn deref<'a>(ptr: usize) -> &'a T
unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
unsafe fn drop(ptr: usize)

impl<T> ToOwned for FileTypeDef

fn to_owned(self: &Self) -> T
fn clone_into(self: &Self, target: &mut T)

impl<T, U> Into for FileTypeDef

fn into(self: Self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom for FileTypeDef

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for FileTypeDef

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>