/** * Loads the default module description from the file "module.properties". This file * must be in the same package as the implementing class. * * @throws ModuleInitializeException if an error occurs. */ protected void loadModuleInfo() throws ModuleInitializeException { final InputStream in = ObjectUtilities.getResourceRelativeAsStream ("module.properties", getClass()); if (in == null) { throw new ModuleInitializeException ("File 'module.properties' not found in module package."); } loadModuleInfo(in); }
/** * Loads the default module description from the file "module.properties". This file * must be in the same package as the implementing class. * * @throws ModuleInitializeException if an error occurs. */ protected void loadModuleInfo() throws ModuleInitializeException { final InputStream in = ObjectUtilities.getResourceRelativeAsStream ("module.properties", getClass()); if (in == null) { throw new ModuleInitializeException ("File 'module.properties' not found in module package."); } loadModuleInfo(in); }
/** * Loads the default module description from the file "module.properties". This file * must be in the same package as the implementing class. * * @throws ModuleInitializeException if an error occurs. */ protected void loadModuleInfo() throws ModuleInitializeException { final InputStream in = ObjectUtilities.getResourceRelativeAsStream ("module.properties", getClass()); if (in == null) { throw new ModuleInitializeException ("File 'module.properties' not found in module package."); } loadModuleInfo(in); }
final InputStream in = ObjectUtilities.getResourceRelativeAsStream (resourceName, resourceSource); if (in != null)
final InputStream in = ObjectUtilities.getResourceRelativeAsStream (resourceName, resourceSource); if (in != null)
final InputStream in = ObjectUtilities.getResourceRelativeAsStream (resourceName, resourceSource); if (in != null)
/** * Configures the module by loading the configuration properties and * adding them to the package configuration. * * @param subSystem the subsystem. */ public void configure(final SubSystem subSystem) { final InputStream in = ObjectUtilities.getResourceRelativeAsStream ("configuration.properties", getClass()); if (in == null) { return; } try { subSystem.getPackageManager().getPackageConfiguration().load(in); } finally { try { in.close(); } catch (IOException e) { // can be ignored ... } } }
/** * Configures the module by loading the configuration properties and * adding them to the package configuration. * * @param subSystem the subsystem. */ public void configure(final SubSystem subSystem) { final InputStream in = ObjectUtilities.getResourceRelativeAsStream ("configuration.properties", getClass()); if (in == null) { return; } try { subSystem.getPackageManager().getPackageConfiguration().load(in); } finally { try { in.close(); } catch (IOException e) { // can be ignored ... } } }
/** * Configures the module by loading the configuration properties and * adding them to the package configuration. * * @param subSystem the subsystem. */ public void configure(final SubSystem subSystem) { final InputStream in = ObjectUtilities.getResourceRelativeAsStream ("configuration.properties", getClass()); if (in == null) { return; } try { subSystem.getPackageManager().getPackageConfiguration().load(in); } finally { try { in.close(); } catch (IOException e) { // can be ignored ... } } }