[−][src]Struct scryfall::set::Set
A Set object containing all fields that scryfall
provides.
For documentation on each field please refer to their documentation
Fields
id: Uuid
code: SetCode
mtgo_code: Option<String>
tcgplayer_id: Option<u64>
name: String
set_type: SetType
released_at: Option<NaiveDate>
block_code: Option<String>
block: Option<String>
parent_set_code: Option<String>
card_count: usize
digital: bool
foil_only: bool
scryfall_uri: String
uri: URI<Set>
icon_svg_uri: String
search_uri: PaginatedURI<Card>
Methods
impl Set
[src]
ⓘImportant traits for PaginatedURI<T>pub fn all() -> PaginatedURI<Set>
[src]
ⓘImportant traits for PaginatedURI<T>
Returns a PaginatedURI
of all the sets in the scryfall
database.
Examples
use scryfall::set::Set; match Set::all().next().unwrap() { Ok(sets) => assert_ne!(sets.len(), 0), Err(e) => eprintln!("{:?}", e) }
pub fn code(code: &str) -> Result<Set>
[src]
Returns a Set
with the given set code.
The code can be either the code
or the mtgo_code
for the set.
Examples
use scryfall::set::Set; assert_eq!(Set::code("mmq").unwrap().name, "Mercadian Masques")
pub fn tcgplayer<T: Display>(code: T) -> Result<Set>
[src]
Returns a Set
with the given tcgplayer_id
.
Also known as the groupId
on TCGplayer’s API.
Examples
use scryfall::set::Set; assert_eq!(Set::tcgplayer(1909).unwrap().name, "Amonkhet Invocations")
pub fn uuid(uuid: Uuid) -> Result<Set>
[src]
Returns a Set with the given Scryfall uuid
.
Examples
use scryfall::set::Set; assert_eq!( Set::uuid("2ec77b94-6d47-4891-a480-5d0b4e5c9372".to_string()).unwrap().name, "Ultimate Masters")
ⓘImportant traits for PaginatedURI<T>pub fn cards(&self) -> &PaginatedURI<Card>
[src]
ⓘImportant traits for PaginatedURI<T>
Returns an iterartor over the cards of the set.
Trait Implementations
impl PartialEq<Set> for Set
[src]
impl Clone for Set
[src]
fn clone(&self) -> Set
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for Set
[src]
impl Serialize for Set
[src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl<'de> Deserialize<'de> for Set
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
Auto Trait Implementations
Blanket Implementations
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,
impl<T> Erased for T
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
U: TryFrom<T>,