Crate tree_magic [−] [src]
This is documentation for the tree_magic crate.
See the README in the repository for more information.
Structs
TYPE |
The TypeStruct autogenerated at library init, and used by the library. |
TypeStruct |
Information about currently loaded MIME types |
Functions
from_filepath |
Gets the type of a file from a filepath. |
from_filepath_node |
Gets the type of a file from a filepath, starting at a certain node in the type graph. |
from_u8_node |
Gets the type of a file from a raw bytestream, starting at a certain node in the type graph. |
from_vec_u8 |
Gets the type of a file from a byte stream. |
from_vec_u8_node |
Gets the type of a file from a vector of bytes, starting at a certain node in the type graph. |
match_filepath |
Check if the given filepath matches the given MIME type. |
match_u8 |
Checks if the given bytestream matches the given MIME type. |
match_vec_u8 |
Checks if the given vector of bytes matches the given MIME type. |