pub struct Instance {
Show 23 fields pub active: bool, pub can_request_invite: bool, pub capacity: i32, pub client_number: String, pub full: bool, pub id: String, pub instance_id: String, pub location: String, pub n_users: i32, pub name: String, pub owner_id: Option<String>, pub permanent: bool, pub photon_region: Region, pub platforms: Box<InstancePlatforms>, pub region: Region, pub secure_name: String, pub short_name: Option<String>, pub tags: Vec<String>, pub type: InstanceType, pub world_id: String, pub hidden: Option<String>, pub friends: Option<String>, pub private: Option<String>,
}
Expand description

Instance : * hidden field is only present if InstanceType is hidden aka "Friends+", and is instance creator. * friends field is only present if InstanceType is friends aka "Friends", and is instance creator. * private field is only present if InstanceType is private aka "Invite" or "Invite+", and is instance creator.

Fields§

§active: bool§can_request_invite: bool§capacity: i32§client_number: String

Always returns "unknown".

§full: bool§id: String

InstanceID can be "offline" on User profiles if you are not friends with that user and "private" if you are friends and user is in private instance.

§instance_id: String§location: String

InstanceID can be "offline" on User profiles if you are not friends with that user and "private" if you are friends and user is in private instance.

§n_users: i32§name: String§owner_id: Option<String>

A users unique ID, usually in the form of usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469. Legacy players can have old IDs in the form of 8JoV9XEdpo. The ID can never be changed.

§permanent: bool§photon_region: Region§platforms: Box<InstancePlatforms>§region: Region§secure_name: String§short_name: Option<String>§tags: Vec<String>

The tags array on Instances usually contain the language tags of the people in the instance.

§type: InstanceType§world_id: String

WorldID be "offline" on User profiles if you are not friends with that user.

§hidden: Option<String>

A users unique ID, usually in the form of usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469. Legacy players can have old IDs in the form of 8JoV9XEdpo. The ID can never be changed.

§friends: Option<String>

A users unique ID, usually in the form of usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469. Legacy players can have old IDs in the form of 8JoV9XEdpo. The ID can never be changed.

§private: Option<String>

A users unique ID, usually in the form of usr_c1644b5b-3ca4-45b4-97c6-a2a0de70d469. Legacy players can have old IDs in the form of 8JoV9XEdpo. The ID can never be changed.

Implementations§

source§

impl Instance

source

pub fn new( active: bool, can_request_invite: bool, capacity: i32, client_number: String, full: bool, id: String, instance_id: String, location: String, n_users: i32, name: String, permanent: bool, photon_region: Region, platforms: InstancePlatforms, region: Region, secure_name: String, tags: Vec<String>, type: InstanceType, world_id: String ) -> Instance

  • hidden field is only present if InstanceType is hidden aka "Friends+", and is instance creator. * friends field is only present if InstanceType is friends aka "Friends", and is instance creator. * private field is only present if InstanceType is private aka "Invite" or "Invite+", and is instance creator.

Trait Implementations§

source§

impl Clone for Instance

source§

fn clone(&self) -> Instance

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Instance

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for Instance

source§

fn default() -> Instance

Returns the “default value” for a type. Read more
source§

impl<'de> Deserialize<'de> for Instance

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl PartialEq for Instance

source§

fn eq(&self, other: &Instance) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for Instance

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl StructuralPartialEq for Instance

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Err>

source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,