pub struct RawTableField {
pub field_name: String,
pub field_data: String,
pub state: Option<String>,
}Expand description
Individual field value within a table row.
This is the raw equivalent to RPFM’s DecodedData. Each field has a name,
a string value, and optionally a “state” flag marking localisable fields.
§XML Representation
In the original Assembly Kit XML, fields appear as:
<field_name>value</field_name>
<other_field some_attribute="...">value with attributes</other_field>During parsing, these are normalized to:
<datafield field_name="field_name">value</datafield>
<datafield field_name="other_field" state="1">value with attributes</datafield>§State Attribute for Localisable Fields
The state attribute is set to "1" when the original XML field tag had any
attributes. In Assembly Kit files, fields with attributes are localisable fields
(fields containing translatable text). These fields are filtered out when extracting
non-localisable field definitions, ensuring that regular data fields and translation
fields are processed separately.
Fields§
§field_name: StringName of the field (column name).
field_data: StringString representation of the field value.
All values are stored as strings in XML and must be parsed to their actual types during conversion.
state: Option<String>State flag marking localisable (translatable) fields.
Set to "1" when the original Assembly Kit XML field tag had any attributes,
which indicates the field is localisable (contains translatable text).
Such fields are filtered out during non-localisable field extraction to ensure
translation fields are handled separately from regular data fields.
Trait Implementations§
Source§impl Debug for RawTableField
impl Debug for RawTableField
Source§impl Default for RawTableField
impl Default for RawTableField
Source§fn default() -> RawTableField
fn default() -> RawTableField
Source§impl<'de> Deserialize<'de> for RawTableField
impl<'de> Deserialize<'de> for RawTableField
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for RawTableField
impl RefUnwindSafe for RawTableField
impl Send for RawTableField
impl Sync for RawTableField
impl Unpin for RawTableField
impl UnsafeUnpin for RawTableField
impl UnwindSafe for RawTableField
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.