geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gdam...@apache.org
Subject svn commit: r158582 - geronimo/trunk/modules/jetty/src/java/org/apache/geronimo/jetty/connector/JettyConnector.java
Date Tue, 22 Mar 2005 09:17:10 GMT
Author: gdamour
Date: Tue Mar 22 01:17:09 2005
New Revision: 158582

URL: http://svn.apache.org/viewcvs?view=rev&rev=158582
Log:
Expose default scheme and port as GBean attributes. Also add an empty
constructor such that JettyConnector can be used as a GBean reference.

Modified:
    geronimo/trunk/modules/jetty/src/java/org/apache/geronimo/jetty/connector/JettyConnector.java

Modified: geronimo/trunk/modules/jetty/src/java/org/apache/geronimo/jetty/connector/JettyConnector.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/modules/jetty/src/java/org/apache/geronimo/jetty/connector/JettyConnector.java?view=diff&r1=158581&r2=158582
==============================================================================
--- geronimo/trunk/modules/jetty/src/java/org/apache/geronimo/jetty/connector/JettyConnector.java
(original)
+++ geronimo/trunk/modules/jetty/src/java/org/apache/geronimo/jetty/connector/JettyConnector.java
Tue Mar 22 01:17:09 2005
@@ -32,6 +32,14 @@
     private final JettyContainer container;
     protected final HttpListener listener;
 
+    /**
+     * Only used to allow declaration as a reference.
+     */
+    public JettyConnector() {
+        container = null;
+        listener = null;
+    }
+
     public JettyConnector(JettyContainer container) {
         this.container = container;
         this.listener = null;
@@ -42,6 +50,14 @@
         this.listener = listener;
     }
 
+    public String getDefaultScheme() {
+        return listener.getDefaultScheme();
+    }
+
+    public String getHost() {
+        return listener.getHost();
+    }
+    
     public int getPort() {
         return listener.getPort();
     }
@@ -79,11 +95,12 @@
             }
         }
     }
-
     public static final GBeanInfo GBEAN_INFO;
 
     static {
         GBeanInfoBuilder infoFactory = new GBeanInfoBuilder("Jetty HTTP Connector", JettyConnector.class);
+        infoFactory.addAttribute("defaultScheme", String.class, false);
+        infoFactory.addAttribute("host", String.class, false);
         infoFactory.addAttribute("port", int.class, true);
         infoFactory.addReference("JettyContainer", JettyContainer.class, NameFactory.GERONIMO_SERVICE);
         infoFactory.setConstructor(new String[] {"JettyContainer"});



Mime
View raw message