Plugin dependencies

Refactor code so dependencies can be declared in configuration file.
See https://trac.openmicroscopy.org.uk/ome/ticket/10038