View Javadoc
1 /* 2 * @(#)Interceptor.java 3 * 4 * JFoxMQ the open source JMS MOM. 5 * 6 * Corpyright 2002-2003 Huihoo Power, Inc. All Rights Reserved. This software 7 * is licensed under LGPL license. 8 * 9 * For more information, please visit: http://www.huihoo.org 10 */ 11 12 package org.huihoo.jfox.ms.crb; 13 14 import javax.jms.Destination; 15 import javax.jms.Message; 16 import javax.jms.Queue; 17 import javax.jms.TemporaryQueue; 18 import javax.jms.TemporaryTopic; 19 import javax.jms.Topic; 20 21 /*** 22 * Defines the interceptor interface.Among object on 23 * server,JMSDestinationManager is implements this interface. 24 * 25 * @author Liang.Zhao (zlushangnwpu@sina.com) 26 * @version 1.0 @created July 23th 2003 27 */ 28 public interface Interceptor { 29 30 /*** 31 * Get a clientID from the server. 32 * 33 * @return an internally generated clientID. 34 * @exception Exception 35 */ 36 public String getID() throws Exception; 37 38 /*** 39 * Gets the TemporaryTopic 40 * 41 * @param void 42 * @return TemporaryTopic 43 * @exception Exception 44 */ 45 public TemporaryTopic createTemporaryTopic() throws Exception; 46 47 /*** 48 * Gets the TemporaryQueue 49 * 50 * @param void 51 * @return TemporaryQueue 52 * @exception Exception 53 */ 54 public TemporaryQueue createTemporaryQueue() throws Exception; 55 56 /*** 57 * The client close the connection. 58 * 59 * @param void 60 * @exception Exception 61 */ 62 public void closeConnection() throws Exception; 63 64 /*** 65 * Check if clientID is a valid ID 66 * 67 * @param String 68 * ID 69 * @exception Exception 70 */ 71 public void checkID(String ID) throws Exception; 72 73 /*** 74 * Send a message to the destination specifyed in the message. 75 * 76 * @param Message 77 * @exception Exception 78 */ 79 public void sendMessage(Message message) throws Exception; 80 81 /*** 82 * Create a queue identity 83 * 84 * @param String 85 * destination 86 * @return Queue 87 * @exception Exception 88 */ 89 public Queue createQueue(String destination) throws Exception; 90 91 /*** 92 * Create a topic identity 93 * 94 * @param destination 95 * @return Topic 96 * @exception Exception 97 */ 98 public Topic createTopic(String destination) throws Exception; 99 100 /*** 101 * Delete a temporary destination from server 102 * 103 * @param Destination 104 * destination 105 * @exception Exception 106 */ 107 public void deleteTemporaryDestination(Destination destination) 108 throws Exception; 109 110 /*** 111 * Commit a transaction 112 * 113 * @param TransactionRequest 114 * t 115 * @exception Exception 116 */ 117 //public void CommitTransaction()//TransactionRequest t 118 // throws Exception; 119 120 /*** 121 * Send a acknowledge to server 122 * 123 * @param AcknowledgementRequest 124 * ack 125 * @exception Exception 126 */ 127 //public void sendAcknowledge(AcknowledgementRequest ack) 128 // throws Exception; 129 130 /*** 131 * Browse message on given destination 132 * 133 * @param Destination 134 * destination 135 * @param String 136 * selector 137 * @return Message[] 138 * @exception Exception 139 */ 140 public Message[] browse(Destination destination, String selector) 141 throws Exception; 142 143 /*** 144 * Receive a message synchronously. 145 * 146 * @param Destination 147 * destination 148 * @param long 149 * wait 150 * @return Message 151 * @exception Exception 152 */ 153 public Message receiveMessage(Destination destination, long wait) 154 throws Exception; 155 156 /*** 157 * Remove a subcriber. 158 * 159 * @param 160 * @exception Exception 161 * Description of Exception 162 */ 163 public void removeSubscriber() throws Exception; 164 165 /*** 166 * Authenticate the user. 167 * 168 * @param String 169 * userName 170 * @param String 171 * password 172 * @return boolean 173 * @exception Exception 174 */ 175 public boolean authenticate(String userName, String password) 176 throws Exception; 177 178 /*** 179 * @param 180 * @exception java.lang.Exception 181 * The exception description. 182 */ 183 public void addSubscriber() throws java.lang.Exception; 184 185 }

This page was automatically generated by Maven