/** * Copy constructor. * @param config AbstractPlatformConfiguration */ public AbstractPlatformConfiguration(AbstractPlatformConfiguration config) { this.starterconfig = new StarterConfiguration(config.getStarterConfig()); this.rootconfig = new RootComponentConfiguration(config.getRootConfig()); }
/** * Returns a PlatformConfiguration with the default parameters but without gui. * @return */ public static PlatformConfiguration getDefaultNoGui() { PlatformConfiguration config = getDefault(); config.getRootConfig().setGui(false); return config; }
/** * Enhance this config with given other config. * Will overwrite all values that are set in the other config. * @param other */ public void enhanceWith(PlatformConfiguration other) { starterconfig.enhanceWith(other.getStarterConfig()); rootconfig.enhanceWith(other.getRootConfig()); }
/** * Constructor that creates a new Configuration based on an args object. * (which can be a Map or a String array). * Does not parse the args - no public use! * @param args */ protected AbstractPlatformConfiguration(String[] args) { starterconfig = new StarterConfiguration(); rootconfig = new RootComponentConfiguration(); rootconfig.setProgramArguments(args); }
/** * Checks this configuration for consistency errors. */ protected void checkConsistency() { starterconfig.checkConsistency(); rootconfig.checkConsistency(); }
@Override public IMonitoringService.PublishEventLevel getMonitoring() { return getStarterConfig().getMonitoring(); } }
@Override public void setComponentFactory(IComponentFactory value) { getRootConfig().setComponentFactory(value); }
@Override public boolean getLogging() { return getRootConfig().getLogging(); }
@Override public void setSimulation(boolean value) { getRootConfig().setSimulation(value); }
@Override public void setThreadpoolDefer(boolean value) { getRootConfig().setThreadpoolDefer(value); }
@Override public String getLibPath() { return getRootConfig().getLibPath(); }
@Override public void setVirtualNames(Map value) { getRootConfig().setVirtualNames(value); }
@Override public void setLocalTransport(boolean value) { getRootConfig().setLocalTransport(value); }
@Override public boolean getNioTcpTransport() { return getRootConfig().getNioTcpTransport(); }
@Override public boolean getRelayTransport() { return getRootConfig().getRelayTransport(); }
@Override public boolean getClock() { return getRootConfig().getClock(); }
@Override public boolean getFiletransfer() { return getRootConfig().getFiletransfer(); }
@Override public void setMarshal(boolean value) { getRootConfig().setMarshal(value); }
@Override public boolean getSecurity() { return getRootConfig().getSecurity(); }