Struct napchart::RemoteNapchart[][src]

pub struct RemoteNapchart {
    pub chartid: String,
    pub title: Option<String>,
    pub description: Option<String>,
    pub username: Option<String>,
    pub last_updated: DateTime<Utc>,
    pub is_snapshot: bool,
    pub public_link: Option<String>,
    pub chart: Napchart,
}

A napchart downloaded from https://napchart.com. Includes extra metadata around the internal Napchart, such as the chart’s ID, title, author, update time, etc.

Fields

chartid: String

The chart’s ID code. Chartids are unique. Should be in one of the following formats:

  • 5 chars (napchart.com/xxxxx) (deprecated)
  • 6 chars (napchart.com/xxxxxx) (deprecated)
  • 9 chars snapshot (napchart.com/snapshot/xxxxxxxxx)
  • 9 chars user chart (napchart.com/:user/xxxxxxxxx)
  • 9 chars user chart with title (napchart.com/:user/Some-title-here-xxxxxxxxx)
title: Option<String>

The title of the napchart, or None if empty

description: Option<String>

The description of the napchart, or None if empty

username: Option<String>

The user that saved this napchart, or None if anonymous

last_updated: DateTime<Utc>

The time that this chart was last saved

is_snapshot: bool

True if this napchart was saved as a snapshot

public_link: Option<String>

The public link to this napchart. (Note: We should be able to generate this from the other metadata)

chart: Napchart

The chart itself

Implementations

impl RemoteNapchart[src]

pub fn semantic_eq(&self, other: &Self) -> bool[src]

True if both RemoteNapcharts are the same, ignoring chartid, last_updated, and public_link. Used by the api tests to make sure BlockingClient and AsyncClient are doing the same thing.

Trait Implementations

impl Debug for RemoteNapchart[src]

Auto Trait Implementations

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> Instrument for T[src]

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

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,