[][src]Struct osu_db::listing::Listing

pub struct Listing {
    pub version: u32,
    pub folder_count: u32,
    pub unban_date: Option<DateTime<Utc>>,
    pub player_name: Option<String>,
    pub beatmaps: Vec<Beatmap>,
    pub user_permissions: u32,
}

A structure representing the osu!.db binary database. This database contains pre-processed data and settings for all available osu! beatmaps.

Fields

version: u32

The osu!.db version number. This is a decimal number in the form YYYYMMDD (eg. 20150203).

folder_count: u32

The amount of folders within the "Songs" directory. Probably for quick checking of changes within the directory.

unban_date: Option<DateTime<Utc>>

Whether the account is locked/banned, and when will be it be unbanned.

player_name: Option<String>

Self-explanatory.

beatmaps: Vec<Beatmap>

All stored beatmaps and the information stored about them. The main bulk of information.

user_permissions: u32

User permissions (0 = None, 1 = Normal, 2 = Moderator, 4 = Supporter, 8 = Friend, 16 = peppy, 32 = World Cup staff)

Implementations

impl Listing[src]

pub fn from_bytes(bytes: &[u8]) -> Result<Listing, Error>[src]

pub fn from_file<P: AsRef<Path>>(path: P) -> Result<Listing, Error>[src]

Parse a listing from the osu!.db database file.

pub fn to_writer<W: Write>(&self, out: W) -> Result<()>[src]

Write the listing to an arbitrary writer.

pub fn save<P: AsRef<Path>>(&self, path: P) -> Result<()>[src]

Similar to to_writer but writes the listing to a file (ie. osu!.db).

Trait Implementations

impl Clone for Listing[src]

impl Debug for Listing[src]

impl PartialEq<Listing> for Listing[src]

impl StructuralPartialEq for Listing[src]

Auto Trait Implementations

impl RefUnwindSafe for Listing

impl Send for Listing

impl Sync for Listing

impl Unpin for Listing

impl UnwindSafe for Listing

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.