1. An electronic device comprising a hardware system, said electronic device comprising: a virtual machine implemented in said hardware system, wherein said virtual machine is configured to interpret an application file comprising a platform-independent portion that is independent of said hardware system and a native portion that is functionally dependent upon the hardware system, wherein the virtual machine is configurable to search the application file for the native portion in response to detecting a request for a native method in the platform-independent portion and to copy the native portion to storage to be accessible by the virtual machine for subsequent servicing of said request if the native portion corresponds to the requested native method, said native portion being invisible to the virtual machine at runtime.