Author: fhanik Date: Thu May 10 08:24:51 2007 New Revision: 536888 URL: http://svn.apache.org/viewvc?view=rev&rev=536888 Log: Add in getters Also change name from pluralis to CometOperation
Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/CometEvent.java tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/CometEvent.java URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/CometEvent.java?view=diff&rev=536888&r1=536887&r2=536888 ============================================================================== --- tomcat/tc6.0.x/trunk/java/org/apache/catalina/CometEvent.java (original) +++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/CometEvent.java Thu May 10 08:24:51 2007 @@ -184,12 +184,19 @@ throws IOException, IllegalStateException; /** + * Returns the configuration for this Comet connection + * @return CometConfiguration[] + * @see #configure(CometConfiguration...) + */ + public CometConfiguration[] getConfiguration(); + + /** * OP_CALLBACK - receive a CALLBACK event from the container * OP_READ - receive a READ event when the connection has data to be read * OP_WRITE - receive a WRITE event when the connection is able to receive data to be written * @see #register(CometOperations) */ - public enum CometOperations {OP_CALLBACK, OP_READ, OP_WRITE}; + public enum CometOperation {OP_CALLBACK, OP_READ, OP_WRITE}; /** * Registers the Comet connection with the container for IO notifications. @@ -199,8 +206,16 @@ * @throws IllegalStateException - if you are trying to register with a socket that already is registered * or if the operation you are trying to register is invalid. */ - public void register(CometOperations... operations) + public void register(CometOperation... operations) throws IOException, IllegalStateException; + + /** + * Returns what the current IO notifications that the Comet + * connection is registered for. + * @return CometOperations[] + * @see #register(CometOperations...) + */ + public CometOperation[] getRegisteredOps(); /** * Returns true if the Comet connection is blocking or non blocking and you can write Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java?view=diff&rev=536888&r1=536887&r2=536888 ============================================================================== --- tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java (original) +++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CometEventImpl.java Thu May 10 08:24:51 2007 @@ -134,9 +134,17 @@ throw new UnsupportedOperationException(); } - public void register(CometEvent.CometOperations... operations) + public void register(CometEvent.CometOperation... operations) throws IOException, IllegalStateException { throw new UnsupportedOperationException(); + } + + public CometConfiguration[] getConfiguration() { + throw new UnsupportedOperationException(); + } + + public CometOperation[] getRegisteredOps() { + throw new UnsupportedOperationException(); } } --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]