pub struct ARSC { /* private fields */ }Expand description
Represents an Android Resource Table (ARSC) file.
This struct holds the parsed global string pool and resource packages. It provides methods to query resources by ID or by name.
Implementations§
Source§impl ARSC
impl ARSC
Sourcepub fn new(input: &mut &[u8]) -> Result<ARSC, ARCSError>
pub fn new(input: &mut &[u8]) -> Result<ARSC, ARCSError>
Parses raw ARSC bytes into an ARSC structure.
Sourcepub fn get_resource_value(&self, id: u32) -> Option<String>
pub fn get_resource_value(&self, id: u32) -> Option<String>
Retrieves a resource value by its numeric ID.
Recursively resolves references if the value is a reference type.
Sourcepub fn get_resource_value_by_name(&self, name: &str) -> Option<String>
pub fn get_resource_value_by_name(&self, name: &str) -> Option<String>
Retrieves a resource value by its resolved name.
Sourcepub fn get_resource_name(&self, id: u32) -> Option<String>
pub fn get_resource_name(&self, id: u32) -> Option<String>
Returns the full resource name for a given resource ID.
Uses a cache to speed up repeated lookups.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for ARSC
impl !RefUnwindSafe for ARSC
impl Send for ARSC
impl !Sync for ARSC
impl Unpin for ARSC
impl UnsafeUnpin for ARSC
impl UnwindSafe for ARSC
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
Mutably borrows from an owned value. Read more