PageRenderTime 60ms CodeModel.GetById 24ms RepoModel.GetById 1ms app.codeStats 0ms

/jboss-as-7.1.1.Final/ejb3/src/main/java/org/jboss/as/ejb3/subsystem/IIOPSettingsService.java

#
Java | 55 lines | 37 code | 14 blank | 4 comment | 0 complexity | bceb385f77e680d2ba83f890ab03b86c MD5 | raw file
Possible License(s): LGPL-2.1, Apache-2.0
  1. package org.jboss.as.ejb3.subsystem;
  2. import org.jboss.msc.service.Service;
  3. import org.jboss.msc.service.ServiceName;
  4. import org.jboss.msc.service.StartContext;
  5. import org.jboss.msc.service.StartException;
  6. import org.jboss.msc.service.StopContext;
  7. /**
  8. * Services that manages IIOP settings
  9. * @author Stuart Douglas
  10. */
  11. public class IIOPSettingsService implements Service<IIOPSettingsService> {
  12. public static final ServiceName SERVICE_NAME = ServiceName.JBOSS.append("ejb3", "iiop", "settingsService");
  13. private volatile boolean enabledByDefault = false;
  14. private volatile boolean useQualifiedName = false;
  15. public IIOPSettingsService(final boolean enabledByDefault, final boolean useQualifiedName) {
  16. this.enabledByDefault = enabledByDefault;
  17. this.useQualifiedName = useQualifiedName;
  18. }
  19. @Override
  20. public void start(final StartContext context) throws StartException {
  21. }
  22. @Override
  23. public void stop(final StopContext context) {
  24. }
  25. @Override
  26. public IIOPSettingsService getValue() throws IllegalStateException, IllegalArgumentException {
  27. return this;
  28. }
  29. public boolean isEnabledByDefault() {
  30. return enabledByDefault;
  31. }
  32. public void setEnabledByDefault(final boolean enabledByDefault) {
  33. this.enabledByDefault = enabledByDefault;
  34. }
  35. public boolean isUseQualifiedName() {
  36. return useQualifiedName;
  37. }
  38. public void setUseQualifiedName(final boolean useQualifiedName) {
  39. this.useQualifiedName = useQualifiedName;
  40. }
  41. }