Skip to content

Commit

Permalink
Improved readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Toomas Romer committed Mar 27, 2017
1 parent 6080875 commit 42efe09
Showing 1 changed file with 11 additions and 15 deletions.
26 changes: 11 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,25 @@ Java Fundamentals - Classloaders Homework
Description
----------

Here we've implemented a very simple plugin system. We have a *Plugin* interface
that defines that every plugin has a *name*, *URL* and a *logo*. The plugins are defined
in the folder *plugins* in the project. Each plugin has a README.properties
(that defines plugin information) and the corresponding class file in that folder.
Our custom class loader picks that class up and instantiates. We call these plugins
our *local plugins*.
Here we've implemented a very simple plugin system. We have a *Plugin* interface that defines that every plugin has a *name*, *URL* and a *logo*. The plugins are defined
in the folder *plugins* in the project.

Each plugin has a `README.properties` (that defines the plugin information) and the corresponding class file in that folder.

Our custom class loader picks that class up and instantiates. We call these plugins our *local plugins*.

Your task
----------

Write a custom classloader and all necessary logic to support *remote plugins*. Remote plugins
adhere to the same interface but they are accessible from the interwebs.
Write a custom classloader and all necessary logic to support *remote plugins*. Remote plugins adhere to the same interface but they are accessible from the interwebs.

The plugins are hosted at https://github.com/zeroturnaround/jf-hw-classloaders/tree/master/plugins-remote
I have hardcoded the locations of the 3 plugins into the homework.
The plugins are hosted at https://github.com/zeroturnaround/jf-hw-classloaders/tree/master/plugins-remote I have hardcoded the locations of the 3 plugins into the homework.

The plugin meta information is in the README.properties file of each plugin. The plugin class files are hidden inside PNG files in the same folder and your task is to find, extract and define classes
from those very same images.
The plugin meta information is in the README.properties file of each plugin. The plugin class files are hidden inside PNG files in the same folder and your task is to find, extract and define classes from those very same images.

Just to reiterate. The bytes of the classes that define the plugins are somewhere in the PNG files. Once
you've implemented your solution the *org.zeroturnaround.jf.hw.classloaders.Main* program should run without any errors and print out all remote plugins (currently only prints names and null values). We've also provided empty implementations of RemotePluginManager and RemotePluginLoader.
Just to reiterate. The bytes of the classes that define the plugins are somewhere in the PNG files. Once you've implemented your solution the *org.zeroturnaround.jf.hw.classloaders.Main* program should run without any errors and print out all remote plugins (currently only prints names and null values). We've also provided empty implementations of RemotePluginManager and RemotePluginLoader. There is also a unit test that will start to pass after you've implemented the methods correctly. I will evaluate the correctness of the homework based on the output of the `Main` method.

Make sure that your program reads the PNG files from the network and not from local disk. For example you can use the java.util.Properties to load properties from a remote properties file by using streams (java.net.URL can also help here).
I've also implemented a helper method `RemotePluginManager.loadPropertiesFile(URL url)`. You can use this to load remote properties files.

Happy hacking!

Expand Down

0 comments on commit 42efe09

Please sign in to comment.