001    /** 
002     * 
003     * Copyright 2004 Protique Ltd
004     * 
005     * Licensed under the Apache License, Version 2.0 (the "License"); 
006     * you may not use this file except in compliance with the License. 
007     * You may obtain a copy of the License at 
008     * 
009     * http://www.apache.org/licenses/LICENSE-2.0
010     * 
011     * Unless required by applicable law or agreed to in writing, software
012     * distributed under the License is distributed on an "AS IS" BASIS, 
013     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
014     * See the License for the specific language governing permissions and 
015     * limitations under the License. 
016     * 
017     **/
018    package org.activemq.ra.jms;
019    
020    import javax.jms.ConnectionMetaData;
021    import java.util.Enumeration;
022    import java.util.Hashtable;
023    
024    /**
025     * A <CODE>ConnectionMetaData</CODE> object provides information describing
026     * the <CODE>Connection</CODE> object.
027     *
028     * @version $Revision: 1.1.1.1 $
029     */
030    public class ConnectionProxyMetaData implements ConnectionMetaData {
031    
032        /**
033         * Gets the JMS API version.
034         *
035         * @return the JMS API version
036         */
037        public String getJMSVersion() {
038            return "1.1";
039        }
040    
041        /**
042         * Gets the JMS major version number.
043         *
044         * @return the JMS API major version number
045         */
046        public int getJMSMajorVersion() {
047            return 1;
048        }
049    
050        /**
051         * Gets the JMS minor version number.
052         *
053         * @return the JMS API minor version number
054         */
055        public int getJMSMinorVersion() {
056            return 1;
057        }
058    
059        /**
060         * Gets the JMS provider name.
061         *
062         * @return the JMS provider name
063         */
064        public String getJMSProviderName() {
065            return "Protique";
066        }
067    
068        /**
069         * Gets the JMS provider version.
070         *
071         * @return the JMS provider version
072         */
073    
074        public String getProviderVersion() {
075            return "1.1";
076        }
077    
078        /**
079         * Gets the JMS provider major version number.
080         *
081         * @return the JMS provider major version number
082         */
083    
084        public int getProviderMajorVersion() {
085            return 1;
086        }
087    
088        /**
089         * Gets the JMS provider minor version number.
090         *
091         * @return the JMS provider minor version number
092         */
093    
094        public int getProviderMinorVersion() {
095            return 1;
096        }
097    
098        /**
099         * Gets an enumeration of the JMSX property names.
100         *
101         * @return an Enumeration of JMSX property names
102         */
103    
104        public Enumeration getJMSXPropertyNames() {
105            Hashtable jmxProperties = new Hashtable();
106            jmxProperties.put("JMSXGroupID", "1");
107            jmxProperties.put("JMSXGroupSeq", "1");
108            return jmxProperties.keys();
109        }
110    }