Hash128

Struct Hash128 

Source
pub struct Hash128 {
Show 16 fields pub bytes_0_: Option<u8>, pub bytes_10_: Option<u8>, pub bytes_11_: Option<u8>, pub bytes_12_: Option<u8>, pub bytes_13_: Option<u8>, pub bytes_14_: Option<u8>, pub bytes_15_: Option<u8>, pub bytes_1_: Option<u8>, pub bytes_2_: Option<u8>, pub bytes_3_: Option<u8>, pub bytes_4_: Option<u8>, pub bytes_5_: Option<u8>, pub bytes_6_: Option<u8>, pub bytes_7_: Option<u8>, pub bytes_8_: Option<u8>, pub bytes_9_: Option<u8>,
}
Expand description

Hash128 is a sub class of the Unity engine since version 4.1.0. Exert from Unity’s scripting documentation: Represents a 128-bit hash value. Use Hash128 to uniquely identify a piece of data. A 128-bit hash value has an extremely low probability of hash collisions, so you can assume that if the hash values of two pieces of data are identical, then the data is identical too. For example, to quickly determine whether texture pixel contents have changed, or if they are identical between several textures, you can use Texture.imageContentsHash.To compute the hash values for some data, use the Hash128.Compute function. To compute the hash values incrementally for several pieces of data, use Hash128.Append. The hash algorithm used to compute Hash128 values is SpookyHash V2. Note that while this hash algorithm is quite fast to compute and has good hash distribution qualities, it is not a cryptographic hash function.

Fields§

§bytes_0_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_10_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_11_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_12_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_13_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_14_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_15_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_1_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_2_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_3_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_4_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_5_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_6_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_7_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_8_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

§bytes_9_: Option<u8>

u8: (4.1.0 - 2022.3.2f1)

Trait Implementations§

Source§

impl Debug for Hash128

Source§

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

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

impl<'de> Deserialize<'de> for Hash128

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 Serialize for Hash128

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

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, U> TryFrom<U> for T
where U: Into<T>,

Source§

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>,

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.
Source§

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