pub struct ClassLoader { /* private fields */ }Expand description
Implementation of a Java class loader.
See: https://docs.oracle.com/javase/specs/jvms/se24/html/jvms-5.html
Implementations§
Source§impl ClassLoader
impl ClassLoader
Sourcepub fn new<S: AsRef<str>>(name: S, class_path: ClassPath) -> Self
pub fn new<S: AsRef<str>>(name: S, class_path: ClassPath) -> Self
Create a new class loader with the given name and parent.
Sourcepub fn class_path(&self) -> &ClassPath
pub fn class_path(&self) -> &ClassPath
Get the class path.
Sourcepub fn parent(&self) -> Option<&ClassLoader>
pub fn parent(&self) -> Option<&ClassLoader>
Get the parent class loader.
Sourcepub fn set_parent(&mut self, parent: Option<ClassLoader>)
pub fn set_parent(&mut self, parent: Option<ClassLoader>)
Set the parent class loader.
Trait Implementations§
Source§impl Clone for ClassLoader
impl Clone for ClassLoader
Source§impl Debug for ClassLoader
impl Debug for ClassLoader
Source§impl Display for ClassLoader
impl Display for ClassLoader
Source§impl PartialEq for ClassLoader
Implement equality for class loaders.
impl PartialEq for ClassLoader
Implement equality for class loaders.
Auto Trait Implementations§
impl Freeze for ClassLoader
impl !RefUnwindSafe for ClassLoader
impl Send for ClassLoader
impl Sync for ClassLoader
impl Unpin for ClassLoader
impl !UnwindSafe for ClassLoader
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