Struct toornament::Discipline
[−]
[src]
pub struct Discipline { pub id: DisciplineId, pub name: String, pub short_name: String, pub full_name: String, pub copyrights: String, pub team_size: Option<TeamSize>, pub additional_fields: Option<AdditionalFields>, }
A game discipline object.
Fields
id: DisciplineId
An identifier for a discipline, can be used in others APIs. Example: "counterstrike_go"
name: String
The official name of the discipline. Example: "Counter-Strike: GO"
short_name: String
The short name of the discipline. Example: "CS:GO"
full_name: String
The complete name of the discipline. Example: "Counter-Strike: Global Offensive"
copyrights: String
The name of the publisher of the discipline or any other right related information about the owner of the discipline. Example: "Valve Software"
team_size: Option<TeamSize>
(Optional) Sets the minimum and maximum of players in a team.
Example: (4, 8), where 4
is minimal size of a team in the tournament
and 8
is maximal size of a team in the tournament.
additional_fields: Option<AdditionalFields>
(Optional) Additional fields concerning the discipline. Note about the special fields in this API: if the field is mentioned, you must use one of the following values.
Methods
impl Discipline
[src]
fn new<S: Into<String>>(
id: DisciplineId,
name: S,
short_name: S,
full_name: S,
copyrights: S
) -> Discipline
id: DisciplineId,
name: S,
short_name: S,
full_name: S,
copyrights: S
) -> Discipline
Creates new Discipline
object.
fn id<'a>(&'a mut self, id: DisciplineId) -> &'a mut Self
A builder method for $field with $field_type
type.
fn name<'a, S: Into<String>>(&'a mut self, name: S) -> &'a mut Self
A builder method for $field with String
type.
fn short_name<'a, S: Into<String>>(&'a mut self, short_name: S) -> &'a mut Self
A builder method for $field with String
type.
fn full_name<'a, S: Into<String>>(&'a mut self, full_name: S) -> &'a mut Self
A builder method for $field with String
type.
fn copyrights<'a, S: Into<String>>(&'a mut self, copyrights: S) -> &'a mut Self
A builder method for $field with String
type.
fn team_size<'a>(&'a mut self, team_size: Option<TeamSize>) -> &'a mut Self
A builder method for $field with $field_type
type.
fn additional_fields<'a>(
&'a mut self,
additional_fields: Option<AdditionalFields>
) -> &'a mut Self
&'a mut self,
additional_fields: Option<AdditionalFields>
) -> &'a mut Self
A builder method for $field with $field_type
type.
Trait Implementations
impl Clone for Discipline
[src]
fn clone(&self) -> Discipline
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Debug for Discipline
[src]
impl Default for Discipline
[src]
fn default() -> Discipline
Returns the "default value" for a type. Read more