Publication Date: 2014-Mar-26
The IP.com Prior Art Database
Disclosed is a method to provide more compact Java* code at runtime by implementing a novel application for stripping the unused portions of the code.
Page 01 of 1
The Java* object code encompasses all code for the application and maintains references to all the libraries that are specified in the code. At runtime, the Java classloader loads any classes that are referenced in the code. All the methods in
the class are loaded, which can result in loading a lot more code into memory than
may be needed. This may not be desirable for environments where memory is a premium.
The novel contribution is an application that strips the unused portions of the Java object code.
The application modifies the existing Java class loader to exclude any unused methods in the class being loaded. By excluding un-referenced methods, the new class loader reduces the size of the object code. This provides a more compact code at runtime.
*Java is a registered trademark. Oracle and Java are registered trademarks of Oracle and/or its affiliates.