xcell_types/array/
kind.rs

1use super::*;
2
3impl Default for ArrayKind {
4    fn default() -> Self {
5        Self::Vector3
6    }
7}
8impl Deref for ArrayDescription {
9    type Target = ArrayKind;
10
11    fn deref(&self) -> &Self::Target {
12        &self.kind
13    }
14}
15
16impl ArrayKind {
17    pub fn as_csharp_type(&self) -> &'static str {
18        match self {
19            ArrayKind::Vector2 => "Vector2",
20            ArrayKind::Vector3 => "Vector3",
21            ArrayKind::Vector4 => "Vector4",
22            ArrayKind::Color4 => "Color4",
23            ArrayKind::Quaternion4 => "Quaternion4",
24        }
25    }
26    // pub fn as_csharp_reader(&self) -> &'static str {
27    //     "ReadSingle"
28    // }
29}