pub struct Melter { /* private fields */ }
Expand description
Convert ironman data to plaintext
Implementations
sourceimpl Melter
impl Melter
sourcepub fn with_extraction(self, extraction: Extraction) -> Self
pub fn with_extraction(self, extraction: Extraction) -> Self
Set the memory allocation extraction behavior for when a zip is encountered
sourcepub fn with_on_failed_resolve(self, strategy: FailedResolveStrategy) -> Self
pub fn with_on_failed_resolve(self, strategy: FailedResolveStrategy) -> Self
Set the behavior for when an unresolved binary token is encountered
sourcepub fn with_rewrite(self, rewrite: bool) -> Self
pub fn with_rewrite(self, rewrite: bool) -> Self
Set if the melter should rewrite properties to better match the plaintext format
Setting to false will preserve binary fields and values even if they don’t make any sense in the plaintext output.
sourcepub fn melt_with_tokens<Q>(
&self,
data: &[u8],
resolver: &Q
) -> Result<(Vec<u8>, HashSet<u16>), Eu4Error> where
Q: TokenResolver,
pub fn melt_with_tokens<Q>(
&self,
data: &[u8],
resolver: &Q
) -> Result<(Vec<u8>, HashSet<u16>), Eu4Error> where
Q: TokenResolver,
Convert ironman data to plaintext
sourcepub fn melt(&self, data: &[u8]) -> Result<(Vec<u8>, HashSet<u16>), Eu4Error>
pub fn melt(&self, data: &[u8]) -> Result<(Vec<u8>, HashSet<u16>), Eu4Error>
Convert ironman data to plaintext
pub fn melt_entries(
&self,
metadata: &[u8],
gamestate: &[u8],
ai: &[u8]
) -> Result<(Vec<u8>, HashSet<u16>), Eu4Error>
pub fn melt_entries_with_tokens<Q>(
&self,
metadata: &[u8],
gamestate: &[u8],
ai: &[u8],
resolver: &Q
) -> Result<(Vec<u8>, HashSet<u16>), Eu4Error> where
Q: TokenResolver,
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Melter
impl Send for Melter
impl Sync for Melter
impl Unpin for Melter
impl UnwindSafe for Melter
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more