public AbstractUnitSelector(double threshold) throws InstantiationException { this.threshold = threshold; try { this.selectedObjectRegistry = new SynchronizableRegistryImpl<>(); } catch (InstantiationException ex) { throw new InstantiationException(this, ex); } }
@Override public void init() throws InitializationException, InterruptedException { if (!initialized) { try { registryTransformerRegistry = new SynchronizableRegistryImpl<>(); registryTransformerRegistry.setName("registryTransformers"); handleJPArguments(); rsbConnection.init(); initialized = true; } catch (JPValidationException | JPNotAvailableException | CouldNotPerformException ex) { throw new InitializationException(SkeletonMergingController.class, ex); } } }
/** * {@inheritDoc} * * @throws InitializationException {@inheritDoc} * @throws InterruptedException {@inheritDoc} */ @Override public void init() throws InitializationException, InterruptedException { if (!initialized) { try { LOGGER.info("Initializing ControlController."); controllableObjectRegistry = new SynchronizableRegistryImpl<>(); registryFlags = JPService.getProperty(JPPscUnitFilterList.class).getValue(); LOGGER.info("Selected Control Registry flags: " + registryFlags.toString()); threshold = JPService.getProperty(JPControlThreshold.class).getValue(); LOGGER.info("Selected Control threshold: " + threshold); initializeRegistryConnection(); rsbConnection = new RSBConnection(this); rsbConnection.init(); initialized = true; } catch (JPNotAvailableException | CouldNotPerformException ex) { throw new InitializationException(ControlController.class, ex); } } }