Skip to main content

NetPropError

Enum NetPropError 

Source
pub enum NetPropError {
Show 15 variants NoTable { class: String, }, NoStandardProxies, NotFound { table: String, name: String, }, Relocated { name: String, table: String, }, InvalidOffset { name: String, offset: c_int, }, NotAHandle { name: String, }, HandleOutOfRange { name: String, handle: EntityHandle, }, NotAValue { name: String, kind: PropKind, }, NotAnArray { name: String, kind: PropKind, }, ElementOutOfRange { name: String, index: usize, len: usize, }, TypeMismatch { name: String, storage: Storage, requested: &'static str, }, UnknownStorage { name: String, }, NoProxy { name: String, }, NotNetworked { class_name: String, }, ClassMismatch { name: String, expected: String, class_name: String, found: String, },
}
Expand description

Why a networked variable could not be found or accessed.

Variants§

§

NoTable

The server class has no table of networked variables.

Fields

§class: String

The class’s network name, such as CTFPlayer.

§

NoStandardProxies

ServerGameDll::standard_send_proxies found none, so how variables are stored cannot be recognized.

§

NotFound

No variable has the name in the table or the tables nested within it.

Fields

§table: String

The name of the table searched.

§name: String

The name looked up.

§

Relocated

The variable is inside a nested table whose proxy relocates its data, so where it lives in the entity is unknown.

Fields

§name: String

The variable’s name.

§table: String

The name of the PropKind::DataTable property whose proxy relocates the data.

§

InvalidOffset

The variable’s offset, or its array’s stride, is negative, or its position in the entity overflows.

Fields

§name: String

The variable’s name.

§offset: c_int

The offset the property gives, in bytes.

§

NotAHandle

NetProp::get_handle or NetProp::set_handle was called on a property that is not declared as an entity handle.

Fields

§name: String

The property’s name.

§

HandleOutOfRange

NetProp::set_handle was given a handle whose slot lies past the entity list.

Fields

§name: String

The variable’s name.

§handle: EntityHandle

The handle refused.

§

NotAValue

The property is an array, a nested table, or of a type this crate does not know, so it has no single value to access.

Fields

§name: String

The property’s name.

§kind: PropKind

The type the property is networked as.

§

NotAnArray

NetProp::element was called on a property that is neither an array nor a nested table.

Fields

§name: String

The property’s name.

§kind: PropKind

The type the property is networked as.

§

ElementOutOfRange

NetProp::element was given an index past the last element.

Fields

§name: String

The name of the array or nested table property.

§index: usize

The index requested.

§len: usize

The number of elements.

§

TypeMismatch

The variable is not stored compatibly with the type requested.

Fields

§name: String

The variable’s name.

§storage: Storage

How the variable is stored.

§requested: &'static str

The name of the type requested, from type_name.

§

UnknownStorage

The variable’s send proxy is missing or is not one of the standard proxies this crate recognizes, so how it is stored is unknown. NetProp::value can still read it if it has a proxy.

Fields

§name: String

The variable’s name.

§

NoProxy

The property has no send proxy to read its value with.

Fields

§name: String

The property’s name.

§

NotNetworked

The entity has no edict, server class, or send table.

Fields

§class_name: String

The entity’s classname.

§

ClassMismatch

The entity’s class does not derive from the one the variable was resolved in, so the variable’s offset does not hold for it.

Fields

§name: String

The variable’s name.

§expected: String

The name of the table the variable was resolved in.

§class_name: String

The entity’s classname.

§found: String

The name of the entity’s send table.

Trait Implementations§

Source§

impl Clone for NetPropError

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for NetPropError

Source§

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

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

impl Display for NetPropError

Source§

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

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

impl Eq for NetPropError

Source§

impl Error for NetPropError

1.30.0 · Source§

fn source(&self) -> Option<&(dyn Error + 'static)>

Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§

fn description(&self) -> &str

👎Deprecated since 1.42.0:

use the Display impl or to_string()

1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more
Source§

impl From<NetPropError> for SoundscapeError

Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for AmmoError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for BossError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for BuildingError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for DominationError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for EffectError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for GameRulesError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for MvmError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for ObjectiveError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for ObserverError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for PlayerError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for ProjectileError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for RagdollError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for TfRagdollError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for ScoreError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for WeaponError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl From<NetPropError> for WearableError

Available on crate feature tf2 only.
Source§

fn from(source: NetPropError) -> Self

Converts to this type from the input type.
Source§

impl PartialEq for NetPropError

Source§

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

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

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

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for NetPropError

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. 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,

Source§

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> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

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

Source§

type Error = !

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

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

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

Source§

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.