jruby-activemq 5.5.1-java
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/History.md +6 -0
- data/LICENSE +619 -0
- data/README.md +15 -0
- data/Rakefile +34 -0
- data/apache-activemq-5.5.1/LICENSE +619 -0
- data/apache-activemq-5.5.1/NOTICE +85 -0
- data/apache-activemq-5.5.1/README.txt +63 -0
- data/apache-activemq-5.5.1/WebConsole-README.txt +42 -0
- data/apache-activemq-5.5.1/activemq-all-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/bin/activemq +653 -0
- data/apache-activemq-5.5.1/bin/activemq-admin +155 -0
- data/apache-activemq-5.5.1/bin/linux-x86-32/activemq +543 -0
- data/apache-activemq-5.5.1/bin/linux-x86-32/libwrapper.so +0 -0
- data/apache-activemq-5.5.1/bin/linux-x86-32/wrapper +0 -0
- data/apache-activemq-5.5.1/bin/linux-x86-32/wrapper.conf +139 -0
- data/apache-activemq-5.5.1/bin/linux-x86-64/activemq +543 -0
- data/apache-activemq-5.5.1/bin/linux-x86-64/libwrapper.so +0 -0
- data/apache-activemq-5.5.1/bin/linux-x86-64/wrapper +0 -0
- data/apache-activemq-5.5.1/bin/linux-x86-64/wrapper.conf +139 -0
- data/apache-activemq-5.5.1/bin/macosx/activemq +537 -0
- data/apache-activemq-5.5.1/bin/macosx/libwrapper.jnilib +0 -0
- data/apache-activemq-5.5.1/bin/macosx/wrapper +0 -0
- data/apache-activemq-5.5.1/bin/macosx/wrapper.conf +139 -0
- data/apache-activemq-5.5.1/bin/run.jar +0 -0
- data/apache-activemq-5.5.1/bin/wrapper.jar +0 -0
- data/apache-activemq-5.5.1/conf/activemq-command.xml +52 -0
- data/apache-activemq-5.5.1/conf/activemq-demo.xml +289 -0
- data/apache-activemq-5.5.1/conf/activemq-dynamic-network-broker1.xml +108 -0
- data/apache-activemq-5.5.1/conf/activemq-dynamic-network-broker2.xml +109 -0
- data/apache-activemq-5.5.1/conf/activemq-jdbc.xml +98 -0
- data/apache-activemq-5.5.1/conf/activemq-scalability.xml +77 -0
- data/apache-activemq-5.5.1/conf/activemq-security.xml +132 -0
- data/apache-activemq-5.5.1/conf/activemq-specjms.xml +118 -0
- data/apache-activemq-5.5.1/conf/activemq-static-network-broker1.xml +100 -0
- data/apache-activemq-5.5.1/conf/activemq-static-network-broker2.xml +100 -0
- data/apache-activemq-5.5.1/conf/activemq-stomp.xml +133 -0
- data/apache-activemq-5.5.1/conf/activemq-throughput.xml +82 -0
- data/apache-activemq-5.5.1/conf/activemq.xml +136 -0
- data/apache-activemq-5.5.1/conf/broker-localhost.cert +0 -0
- data/apache-activemq-5.5.1/conf/broker.ks +0 -0
- data/apache-activemq-5.5.1/conf/broker.ts +0 -0
- data/apache-activemq-5.5.1/conf/camel.xml +66 -0
- data/apache-activemq-5.5.1/conf/client.ks +0 -0
- data/apache-activemq-5.5.1/conf/client.ts +0 -0
- data/apache-activemq-5.5.1/conf/credentials-enc.properties +22 -0
- data/apache-activemq-5.5.1/conf/credentials.properties +22 -0
- data/apache-activemq-5.5.1/conf/jetty-realm.properties +20 -0
- data/apache-activemq-5.5.1/conf/jetty.xml +112 -0
- data/apache-activemq-5.5.1/conf/jmx.access +18 -0
- data/apache-activemq-5.5.1/conf/jmx.password +18 -0
- data/apache-activemq-5.5.1/conf/log4j.properties +75 -0
- data/apache-activemq-5.5.1/conf/logging.properties +25 -0
- data/apache-activemq-5.5.1/data/activemq.log +0 -0
- data/apache-activemq-5.5.1/docs/index.html +22 -0
- data/apache-activemq-5.5.1/example/build.xml +317 -0
- data/apache-activemq-5.5.1/example/conf/activemq.xml +41 -0
- data/apache-activemq-5.5.1/example/conf/log4j.properties +39 -0
- data/apache-activemq-5.5.1/example/conf/resin-web.xml +35 -0
- data/apache-activemq-5.5.1/example/conf/web.xml +40 -0
- data/apache-activemq-5.5.1/example/perfharness/perfharness-activemq.sh +49 -0
- data/apache-activemq-5.5.1/example/ruby/README.txt +27 -0
- data/apache-activemq-5.5.1/example/ruby/catstomp.rb +49 -0
- data/apache-activemq-5.5.1/example/ruby/listener.rb +51 -0
- data/apache-activemq-5.5.1/example/ruby/publisher.rb +67 -0
- data/apache-activemq-5.5.1/example/ruby/stompcat.rb +50 -0
- data/apache-activemq-5.5.1/example/src/CommandLineSupport.java +120 -0
- data/apache-activemq-5.5.1/example/src/ConsumerTool.java +353 -0
- data/apache-activemq-5.5.1/example/src/EmbeddedBroker.java +41 -0
- data/apache-activemq-5.5.1/example/src/Log4jJMSAppenderExample.java +70 -0
- data/apache-activemq-5.5.1/example/src/ProducerAndConsumerTool.java +51 -0
- data/apache-activemq-5.5.1/example/src/ProducerTool.java +247 -0
- data/apache-activemq-5.5.1/example/src/RequesterTool.java +257 -0
- data/apache-activemq-5.5.1/example/src/StompExample.java +59 -0
- data/apache-activemq-5.5.1/example/src/TopicListener.java +118 -0
- data/apache-activemq-5.5.1/example/src/TopicPublisher.java +205 -0
- data/apache-activemq-5.5.1/example/src/jndi.properties +17 -0
- data/apache-activemq-5.5.1/example/src/log4j-jms.properties +31 -0
- data/apache-activemq-5.5.1/example/transactions/README.txt +40 -0
- data/apache-activemq-5.5.1/example/transactions/build.xml +113 -0
- data/apache-activemq-5.5.1/example/transactions/src/Retailer.java +107 -0
- data/apache-activemq-5.5.1/example/transactions/src/Supplier.java +135 -0
- data/apache-activemq-5.5.1/example/transactions/src/TransactionsDemo.java +47 -0
- data/apache-activemq-5.5.1/example/transactions/src/Vendor.java +302 -0
- data/apache-activemq-5.5.1/lib/a.sh +3 -0
- data/apache-activemq-5.5.1/lib/activation-1.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/activemq-camel-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/activemq-console-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/activemq-core-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/activemq-jaas-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/activemq-protobuf-1.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/activemq-rar.txt +20 -0
- data/apache-activemq-5.5.1/lib/activemq-web-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/camel-core-2.7.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/camel-jetty-2.7.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/camel-jms-2.7.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/camel-spring-2.7.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/geronimo-j2ee-management_1.1_spec-1.0.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/geronimo-jms_1.1_spec-1.1.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/geronimo-jta_1.0.1B_spec-1.0.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/jaxb-api-2.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/jaxb-impl-2.1.6.jar +0 -0
- data/apache-activemq-5.5.1/lib/jcl-over-slf4j-1.5.11.jar +0 -0
- data/apache-activemq-5.5.1/lib/kahadb-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/activeio-core-3.1.2.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/activemq-jmdns_1.0-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/activemq-optional-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/activemq-pool-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/activemq-spring-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/activemq-xmpp-5.5.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-beanutils-1.6.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-codec-1.2.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-collections-3.2.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-dbcp-1.2.2.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-httpclient-3.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-lang-2.4.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-net-2.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/commons-pool-1.5.4.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/geronimo-j2ee-connector_1.5_spec-2.0.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/jasypt-1.7.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/jettison-1.2.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/josql-1.5.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/log4j-1.2.14.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/slf4j-log4j12-1.5.11.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-aop-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-asm-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-beans-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-context-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-core-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-expression-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-jms-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-oxm-tiger-1.5.8.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/spring-tx-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/stax2-api-3.0.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/velocity-1.6.2.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/woodstox-core-asl-4.0.7.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/xbean-spring-3.7.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/xpp3-1.1.4c.jar +0 -0
- data/apache-activemq-5.5.1/lib/optional/xstream-1.3.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/slf4j-api-1.5.11.jar +0 -0
- data/apache-activemq-5.5.1/lib/stax-1.2.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/stax-api-1.0.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/commons-management-1.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/core-3.1.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/geronimo-servlet_2.5_spec-1.2.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/jdom-1.0.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/jetty-all-server-7.1.6.v20100715.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/jetty-websocket-7.1.6.v20100715.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/jsp-2.1-glassfish-2.1.v20100127.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/jsp-api-2.1-glassfish-2.1.v20100127.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/rome-0.8.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/sitemesh-2.2.1.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/spring-web-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/lib/web/spring-webmvc-3.0.3.RELEASE.jar +0 -0
- data/apache-activemq-5.5.1/user-guide.html +119 -0
- data/apache-activemq-5.5.1/webapps/admin/404.html +137 -0
- data/apache-activemq-5.5.1/webapps/admin/500.html +138 -0
- data/apache-activemq-5.5.1/webapps/admin/META-INF/LICENSE +1026 -0
- data/apache-activemq-5.5.1/webapps/admin/META-INF/NOTICE +107 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/WebConsoleStarter.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/CopyMessage.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/CreateDestination.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/CreateSubscriber.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/DeleteDestination.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/DeleteJob.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/DeleteMessage.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/DeleteSubscriber.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/MoveMessage.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/PurgeDestination.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/controller/SendMessage.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/filter/ApplicationContextFilter$1.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/filter/ApplicationContextFilter$2.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/filter/ApplicationContextFilter.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/classes/org/apache/activemq/web/handler/BindingBeanNameUrlHandlerMapping.class +0 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/decorators.xml +30 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/dispatcher-servlet.xml +62 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/jspf/headertags.jspf +21 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/jspf/old.jspf +21 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/form/checkbox.tag +18 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/form/forEachMapEntry.tag +29 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/form/option.tag +20 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/form/short.tag +29 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/form/text.tag +30 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/form/tooltip.tag +29 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/form/uri.tag +18 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/jms/forEachConnection.tag +35 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/jms/forEachMessage.tag +34 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/jms/formatTimestamp.tag +29 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/tags/jms/persistent.tag +27 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/web.xml +187 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/webconsole-default.xml +26 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/webconsole-embedded.xml +45 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/webconsole-invm.xml +41 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/webconsole-jndi.xml +39 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/webconsole-properties.xml +39 -0
- data/apache-activemq-5.5.1/webapps/admin/WEB-INF/webconsole-query.xml +25 -0
- data/apache-activemq-5.5.1/webapps/admin/browse.jsp +64 -0
- data/apache-activemq-5.5.1/webapps/admin/connection.jsp +138 -0
- data/apache-activemq-5.5.1/webapps/admin/connections.jsp +85 -0
- data/apache-activemq-5.5.1/webapps/admin/decorators/main.jsp +165 -0
- data/apache-activemq-5.5.1/webapps/admin/decorators/panel.jsp +31 -0
- data/apache-activemq-5.5.1/webapps/admin/decorators/printable.jsp +31 -0
- data/apache-activemq-5.5.1/webapps/admin/graph.jsp +67 -0
- data/apache-activemq-5.5.1/webapps/admin/images/activemq-logo.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/asf-logo.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/big-bullet.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/black-footer-bottom.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/black-footer-left.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/black-footer-right.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/bottom-red-bar.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/checker-bg.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/content-left.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/content-right.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/feed_atom.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/feed_rss.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/left-box-bottom.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/left-box-right.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/left-box-top.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/oval-arrow.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/right-box-bottom.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/right-box-left.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/right-box-top.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/small-bullet-gray.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/small-bullet-red.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/spacer.gif +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/top-red-bar.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/white-header-left.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/white-header-right.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/images/white-header-top.png +0 -0
- data/apache-activemq-5.5.1/webapps/admin/index.jsp +65 -0
- data/apache-activemq-5.5.1/webapps/admin/js/common.js +121 -0
- data/apache-activemq-5.5.1/webapps/admin/js/css.js +145 -0
- data/apache-activemq-5.5.1/webapps/admin/js/mochi/MochiKit.js +4804 -0
- data/apache-activemq-5.5.1/webapps/admin/js/mochi/__package__.js +14 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/Base.js +332 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/Canvas.js +707 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/Layout.js +588 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/SVG.js +677 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/SweetCanvas.js +281 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/SweetSVG.js +196 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/dummy.svg +15 -0
- data/apache-activemq-5.5.1/webapps/admin/js/plotkit/iecanvas.htc +389 -0
- data/apache-activemq-5.5.1/webapps/admin/js/prettify.js +1424 -0
- data/apache-activemq-5.5.1/webapps/admin/js/standardista-table-sorting.js +434 -0
- data/apache-activemq-5.5.1/webapps/admin/message.jsp +185 -0
- data/apache-activemq-5.5.1/webapps/admin/network.jsp +52 -0
- data/apache-activemq-5.5.1/webapps/admin/queueConsumers.jsp +79 -0
- data/apache-activemq-5.5.1/webapps/admin/queueGraph.jsp +68 -0
- data/apache-activemq-5.5.1/webapps/admin/queues.jsp +78 -0
- data/apache-activemq-5.5.1/webapps/admin/scheduled.jsp +67 -0
- data/apache-activemq-5.5.1/webapps/admin/send.jsp +173 -0
- data/apache-activemq-5.5.1/webapps/admin/styles/prettify.css +44 -0
- data/apache-activemq-5.5.1/webapps/admin/styles/site.css +206 -0
- data/apache-activemq-5.5.1/webapps/admin/styles/sorttable.css +70 -0
- data/apache-activemq-5.5.1/webapps/admin/styles/type-settings.css +177 -0
- data/apache-activemq-5.5.1/webapps/admin/subscribers.jsp +158 -0
- data/apache-activemq-5.5.1/webapps/admin/test/dummy.jsp +52 -0
- data/apache-activemq-5.5.1/webapps/admin/test/index.jsp +84 -0
- data/apache-activemq-5.5.1/webapps/admin/test/systemProperties.jsp +53 -0
- data/apache-activemq-5.5.1/webapps/admin/topics.jsp +66 -0
- data/apache-activemq-5.5.1/webapps/admin/xml/queues.jsp +34 -0
- data/apache-activemq-5.5.1/webapps/admin/xml/topics.jsp +29 -0
- data/apache-activemq-5.5.1/webapps/demo/META-INF/LICENSE +494 -0
- data/apache-activemq-5.5.1/webapps/demo/META-INF/NOTICE +82 -0
- data/apache-activemq-5.5.1/webapps/demo/WEB-INF/web.xml +111 -0
- data/apache-activemq-5.5.1/webapps/demo/chat.css +76 -0
- data/apache-activemq-5.5.1/webapps/demo/chat.html +219 -0
- data/apache-activemq-5.5.1/webapps/demo/index.html +181 -0
- data/apache-activemq-5.5.1/webapps/demo/js/amq.js +307 -0
- data/apache-activemq-5.5.1/webapps/demo/js/amq_dojo_adapter.js +84 -0
- data/apache-activemq-5.5.1/webapps/demo/js/amq_jquery_adapter.js +88 -0
- data/apache-activemq-5.5.1/webapps/demo/js/amq_prototype_adapter.js +84 -0
- data/apache-activemq-5.5.1/webapps/demo/js/chat.js +209 -0
- data/apache-activemq-5.5.1/webapps/demo/js/dojo.js +16 -0
- data/apache-activemq-5.5.1/webapps/demo/js/jquery-1.4.2.min.js +154 -0
- data/apache-activemq-5.5.1/webapps/demo/js/prototype.js +4874 -0
- data/apache-activemq-5.5.1/webapps/demo/portfolio/portfolio.html +87 -0
- data/apache-activemq-5.5.1/webapps/demo/portfolio/portfolio.js +91 -0
- data/apache-activemq-5.5.1/webapps/demo/sandbox/index.html +31 -0
- data/apache-activemq-5.5.1/webapps/demo/sandbox/portfolio.html +93 -0
- data/apache-activemq-5.5.1/webapps/demo/sandbox/portfolio.js +49 -0
- data/apache-activemq-5.5.1/webapps/demo/sandbox/util.js +52 -0
- data/apache-activemq-5.5.1/webapps/demo/sandbox/webmq.js +149 -0
- data/apache-activemq-5.5.1/webapps/demo/send.html +51 -0
- data/apache-activemq-5.5.1/webapps/demo/style.css +440 -0
- data/apache-activemq-5.5.1/webapps/demo/test/amq_test.html +311 -0
- data/apache-activemq-5.5.1/webapps/demo/test/assets/README +4 -0
- data/apache-activemq-5.5.1/webapps/demo/test/assets/jsunittest.js +1017 -0
- data/apache-activemq-5.5.1/webapps/demo/test/assets/unittest.css +54 -0
- data/apache-activemq-5.5.1/webapps/favicon.ico +0 -0
- data/apache-activemq-5.5.1/webapps/fileserver/META-INF/LICENSE +203 -0
- data/apache-activemq-5.5.1/webapps/fileserver/META-INF/NOTICE +5 -0
- data/apache-activemq-5.5.1/webapps/fileserver/WEB-INF/classes/org/apache/activemq/util/FilenameGuardFilter$GuardedHttpServletRequest.class +0 -0
- data/apache-activemq-5.5.1/webapps/fileserver/WEB-INF/classes/org/apache/activemq/util/FilenameGuardFilter.class +0 -0
- data/apache-activemq-5.5.1/webapps/fileserver/WEB-INF/classes/org/apache/activemq/util/IOHelper.class +0 -0
- data/apache-activemq-5.5.1/webapps/fileserver/WEB-INF/classes/org/apache/activemq/util/RestFilter.class +0 -0
- data/apache-activemq-5.5.1/webapps/fileserver/WEB-INF/web.xml +56 -0
- data/apache-activemq-5.5.1/webapps/fileserver/index.html +30 -0
- data/apache-activemq-5.5.1/webapps/index.html +145 -0
- data/apache-activemq-5.5.1/webapps/styles/site.css +206 -0
- data/apache-activemq-5.5.1/webapps/styles/type-settings.css +177 -0
- data/lib/activemq.rb +11 -0
- metadata +382 -0
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
4
|
+
* contributor license agreements. See the NOTICE file distributed with
|
|
5
|
+
* this work for additional information regarding copyright ownership.
|
|
6
|
+
* The ASF licenses this file to You under the Apache License, Version 2.0
|
|
7
|
+
* (the "License"); you may not use this file except in compliance with
|
|
8
|
+
* the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
// AMQ Ajax Adapter for Dojo
|
|
20
|
+
// This class provides an adapter interface for the Dojo library to perform
|
|
21
|
+
// some of the library-dependent tasks...namely logging and ajax.
|
|
22
|
+
|
|
23
|
+
var org = org || {};
|
|
24
|
+
org.activemq = org.activemq || {};
|
|
25
|
+
|
|
26
|
+
org.activemq.AmqAdapter = {
|
|
27
|
+
|
|
28
|
+
init: function(options) {
|
|
29
|
+
},
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Implement this method to make an AJAX call to the AjaxServlet. An
|
|
33
|
+
* options object will accompany this class and will contain the properties
|
|
34
|
+
* that describe the details of the AJAX call. The options object will
|
|
35
|
+
* have the following properties:
|
|
36
|
+
*
|
|
37
|
+
* - method: 'get' or 'post'
|
|
38
|
+
* - data: query data to accompany the post or get.
|
|
39
|
+
* - success: A callback function that is invoked upon successful
|
|
40
|
+
* completion of the AJAX call. The parameter is:
|
|
41
|
+
* - data: The result of the AJAX call. In the case of XML
|
|
42
|
+
* data should resolve to a Document element.
|
|
43
|
+
* - error: A callback when some type of error occurs. The callback
|
|
44
|
+
* function's parameters should be:
|
|
45
|
+
* - xhr: The XmlHttpRequest object.
|
|
46
|
+
* - status: A text string of the status.
|
|
47
|
+
* - ex: The exception that caused the error.
|
|
48
|
+
* - headers: An object containing additional headers for the ajax request.
|
|
49
|
+
*/
|
|
50
|
+
ajax: function(uri, options) {
|
|
51
|
+
if (options.method == 'post') {
|
|
52
|
+
dojo.xhrPost({
|
|
53
|
+
url: uri,
|
|
54
|
+
handleAs: "xml",
|
|
55
|
+
postData: options.data,
|
|
56
|
+
headers: options.headers,
|
|
57
|
+
load : options.success ? options.success : function() {},
|
|
58
|
+
error: options.error ? function(ex, ioargs) {
|
|
59
|
+
options.error(ioargs.xhr,ioargs.xhr.status, ex);
|
|
60
|
+
} : function() {}
|
|
61
|
+
});
|
|
62
|
+
} else {
|
|
63
|
+
if (options.data)
|
|
64
|
+
{
|
|
65
|
+
uri += "?";
|
|
66
|
+
uri += options.data;
|
|
67
|
+
}
|
|
68
|
+
dojo.xhrGet({
|
|
69
|
+
url: uri,
|
|
70
|
+
handleAs: "xml",
|
|
71
|
+
headers: options.headers,
|
|
72
|
+
load : options.success ? options.success : function() {},
|
|
73
|
+
error: options.error ? function(ex, ioargs) {
|
|
74
|
+
options.error(ioargs.xhr,ioargs.xhr.status, ex);
|
|
75
|
+
} : function() {}
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
|
|
80
|
+
log: function(message, exception) {
|
|
81
|
+
if (typeof console != 'undefined' && console.log) console.log(message);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
};
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
4
|
+
* contributor license agreements. See the NOTICE file distributed with
|
|
5
|
+
* this work for additional information regarding copyright ownership.
|
|
6
|
+
* The ASF licenses this file to You under the Apache License, Version 2.0
|
|
7
|
+
* (the "License"); you may not use this file except in compliance with
|
|
8
|
+
* the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
// AMQ Ajax Adapter for jQuery
|
|
20
|
+
// This class provides an adapter interface for the jquery library to perform
|
|
21
|
+
// some of the library-dependent tasks...namely logging and ajax.
|
|
22
|
+
|
|
23
|
+
var org = org || {};
|
|
24
|
+
org.activemq = org.activemq || {};
|
|
25
|
+
|
|
26
|
+
org.activemq.AmqAdapter = {
|
|
27
|
+
|
|
28
|
+
init: function(options) {
|
|
29
|
+
},
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Implement this method to make an AJAX call to the AjaxServlet. An
|
|
33
|
+
* options object will accompany this class and will contain the properties
|
|
34
|
+
* that describe the details of the AJAX call. The options object will
|
|
35
|
+
* have the following properties:
|
|
36
|
+
*
|
|
37
|
+
* - method: 'get' or 'post'
|
|
38
|
+
* - data: query data to accompany the post or get.
|
|
39
|
+
* - success: A callback function that is invoked upon successful
|
|
40
|
+
* completion of the AJAX call. The parameter is:
|
|
41
|
+
* - data: The result of the AJAX call. In the case of XML
|
|
42
|
+
* data should resolve to a Document element.
|
|
43
|
+
* - error: A callback when some type of error occurs. The callback
|
|
44
|
+
* function's parameters should be:
|
|
45
|
+
* - xhr: The XmlHttpRequest object.
|
|
46
|
+
* - status: A text string of the status.
|
|
47
|
+
* - ex: The exception that caused the error.
|
|
48
|
+
* - headers: An object containing additional headers for the ajax request.
|
|
49
|
+
*/
|
|
50
|
+
ajax: function(uri, options) {
|
|
51
|
+
request = {
|
|
52
|
+
url: uri,
|
|
53
|
+
data: options.data,
|
|
54
|
+
success: options.success || function(){},
|
|
55
|
+
error: options.error || function(){}
|
|
56
|
+
}
|
|
57
|
+
var headers = {};
|
|
58
|
+
if( options.headers ) {
|
|
59
|
+
headers = options.headers;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
if (options.method == 'post') {
|
|
63
|
+
request.type = 'POST';
|
|
64
|
+
/* Force "Connection: close" for Mozilla browsers to work around
|
|
65
|
+
* a bug where XMLHttpReqeuest sends an incorrect Content-length
|
|
66
|
+
* header. See Mozilla Bugzilla #246651.
|
|
67
|
+
*/
|
|
68
|
+
headers[ 'Connection' ] = 'close';
|
|
69
|
+
} else {
|
|
70
|
+
request.type = 'GET';
|
|
71
|
+
request.dataType = 'xml';
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
if( headers ) {
|
|
75
|
+
request.beforeSend = function(xhr) {
|
|
76
|
+
for( h in headers ) {
|
|
77
|
+
xhr.setRequestHeader( h, headers[ h ] );
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
jQuery.ajax( request );
|
|
83
|
+
},
|
|
84
|
+
|
|
85
|
+
log: function(message, exception) {
|
|
86
|
+
if (typeof console != 'undefined' && console.log) console.log(message);
|
|
87
|
+
}
|
|
88
|
+
};
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
4
|
+
* contributor license agreements. See the NOTICE file distributed with
|
|
5
|
+
* this work for additional information regarding copyright ownership.
|
|
6
|
+
* The ASF licenses this file to You under the Apache License, Version 2.0
|
|
7
|
+
* (the "License"); you may not use this file except in compliance with
|
|
8
|
+
* the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
// AMQ Ajax Adapter for Prototype
|
|
20
|
+
// This class provides an adapter interface for the prototype library to perform
|
|
21
|
+
// some of the library-dependent tasks...namely logging and ajax.
|
|
22
|
+
|
|
23
|
+
var org = org || {};
|
|
24
|
+
org.activemq = org.activemq || {};
|
|
25
|
+
|
|
26
|
+
org.activemq.AmqAdapter = {
|
|
27
|
+
|
|
28
|
+
init: function(options) {
|
|
29
|
+
},
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Implement this method to make an AJAX call to the AjaxServlet. An
|
|
33
|
+
* options object will accompany this class and will contain the properties
|
|
34
|
+
* that describe the details of the AJAX call. The options object will
|
|
35
|
+
* have the following properties:
|
|
36
|
+
*
|
|
37
|
+
* - method: 'get' or 'post'
|
|
38
|
+
* - data: query data to accompany the post or get.
|
|
39
|
+
* - success: A callback function that is invoked upon successful
|
|
40
|
+
* completion of the AJAX call. The parameter is:
|
|
41
|
+
* - data: The result of the AJAX call. In the case of XML
|
|
42
|
+
* data should resolve to a Document element.
|
|
43
|
+
* - error: A callback when some type of error occurs. The callback
|
|
44
|
+
* function's parameters should be:
|
|
45
|
+
* - xhr: The XmlHttpRequest object.
|
|
46
|
+
* - status: A text string of the status.
|
|
47
|
+
* - ex: The exception that caused the error.
|
|
48
|
+
* - headers: An object containing additional headers for the ajax request.
|
|
49
|
+
*/
|
|
50
|
+
ajax: function(uri, options) {
|
|
51
|
+
request = {
|
|
52
|
+
onSuccess: options.success ? function(xhr, header) {
|
|
53
|
+
if (options.success) {
|
|
54
|
+
var ct = xhr.getResponseHeader("content-type");
|
|
55
|
+
var xml = ct && ct.indexOf("xml") >= 0;
|
|
56
|
+
var data = xml ? xhr.responseXML : xhr.responseText;
|
|
57
|
+
options.success(data);
|
|
58
|
+
}
|
|
59
|
+
} : function() {},
|
|
60
|
+
onFailure: options.error || function() {
|
|
61
|
+
},
|
|
62
|
+
onException: options.error || function() {
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
if( options.headers ) {
|
|
67
|
+
request.requestHeaders = options.headers;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
if (options.method == 'post') {
|
|
71
|
+
request.postBody = options.data;
|
|
72
|
+
} else {
|
|
73
|
+
request.parameters = options.data;
|
|
74
|
+
request.method = 'get';
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
new Ajax.Request( uri, request );
|
|
78
|
+
},
|
|
79
|
+
|
|
80
|
+
log: function(message, exception) {
|
|
81
|
+
if (typeof console != 'undefined' && console.log) console.log(message);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
};
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
4
|
+
* contributor license agreements. See the NOTICE file distributed with
|
|
5
|
+
* this work for additional information regarding copyright ownership.
|
|
6
|
+
* The ASF licenses this file to You under the Apache License, Version 2.0
|
|
7
|
+
* (the 'License'); you may not use this file except in compliance with
|
|
8
|
+
* the License. You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an 'AS IS' BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
var amq = org.activemq.Amq;
|
|
20
|
+
|
|
21
|
+
org.activemq.Chat = function() {
|
|
22
|
+
var last = '';
|
|
23
|
+
|
|
24
|
+
var user = null;
|
|
25
|
+
|
|
26
|
+
var chatTopic = 'topic://CHAT.DEMO';
|
|
27
|
+
|
|
28
|
+
var chat, join, joined, phrase, members, username = null;
|
|
29
|
+
|
|
30
|
+
var chatHandler = function(message) {
|
|
31
|
+
var type = message.getAttribute('type');
|
|
32
|
+
var from = message.getAttribute('from');
|
|
33
|
+
|
|
34
|
+
switch (type) {
|
|
35
|
+
// Incoming chat message
|
|
36
|
+
case 'chat' : {
|
|
37
|
+
var text = message.childNodes[0].data;
|
|
38
|
+
|
|
39
|
+
if (from == last) from = '...';
|
|
40
|
+
else {
|
|
41
|
+
last = from;
|
|
42
|
+
from += ':';
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
chat.innerHTML += '<span class=\'from\'>' + from + ' </span><span class=\'text\'>' + text + '</span><br/>';
|
|
46
|
+
break;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
// Incoming ping request, add the person's name to your list.
|
|
50
|
+
case 'ping' : {
|
|
51
|
+
members.innerHTML += '<span class="member">' + from + '</span><br/>';
|
|
52
|
+
break;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
// someone new joined the chatroom, clear your list and
|
|
56
|
+
// broadcast your name to all users.
|
|
57
|
+
case 'join' : {
|
|
58
|
+
members.innerHTML = '';
|
|
59
|
+
if (user != null)
|
|
60
|
+
amq.sendMessage(chatTopic, '<message type="ping" from="' + user + '"/>');
|
|
61
|
+
chat.innerHTML += '<span class="alert"><span class="from">' + from + ' </span><span class="text">has joined the room!</span></span><br/>';
|
|
62
|
+
break;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
// Screw you guys, I'm going home...
|
|
66
|
+
// When I (and everyone else) receive a leave message, we broadcast
|
|
67
|
+
// our own names in a ping in order to update everyone's list.
|
|
68
|
+
// todo: Make this more efficient by simply removing the person's name from the list.
|
|
69
|
+
case 'leave': {
|
|
70
|
+
members.innerHTML = '';
|
|
71
|
+
chat.innerHTML += '<span class="alert"><span class="from">' + from + ' </span><span class="text">has left the room!</span></span><br/>';
|
|
72
|
+
|
|
73
|
+
// If we are the one that is leaving...
|
|
74
|
+
if (from == user) {
|
|
75
|
+
// switch the input form
|
|
76
|
+
join.className = '';
|
|
77
|
+
joined.className = 'hidden';
|
|
78
|
+
username.focus();
|
|
79
|
+
|
|
80
|
+
user = null;
|
|
81
|
+
amq.removeListener('chat', chatTopic);
|
|
82
|
+
}
|
|
83
|
+
if (user != null)
|
|
84
|
+
amq.sendMessage(chatTopic, '<message type="ping" from="' + user + '"/>');
|
|
85
|
+
break;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
chat.scrollTop = chat.scrollHeight - chat.clientHeight;
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
var getKeyCode = function (ev) {
|
|
93
|
+
var keyc;
|
|
94
|
+
if (window.event) keyc = window.event.keyCode;
|
|
95
|
+
else keyc = ev.keyCode;
|
|
96
|
+
return keyc;
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
var addEvent = function(obj, type, fn) {
|
|
100
|
+
if (obj.addEventListener)
|
|
101
|
+
obj.addEventListener(type, fn, false);
|
|
102
|
+
else if (obj.attachEvent) {
|
|
103
|
+
obj["e"+type+fn] = fn;
|
|
104
|
+
obj[type+fn] = function() { obj["e"+type+fn]( window.event ); }
|
|
105
|
+
obj.attachEvent( "on"+type, obj[type+fn] );
|
|
106
|
+
}
|
|
107
|
+
};
|
|
108
|
+
|
|
109
|
+
var initEventHandlers = function() {
|
|
110
|
+
addEvent(username, 'keyup', function(ev) {
|
|
111
|
+
var keyc = getKeyCode(ev);
|
|
112
|
+
if (keyc == 13 || keyc == 10) {
|
|
113
|
+
org.activemq.Chat.join();
|
|
114
|
+
return false;
|
|
115
|
+
}
|
|
116
|
+
return true;
|
|
117
|
+
});
|
|
118
|
+
|
|
119
|
+
addEvent(document.getElementById('joinB'), 'click', function() {
|
|
120
|
+
org.activemq.Chat.join();
|
|
121
|
+
return true;
|
|
122
|
+
});
|
|
123
|
+
|
|
124
|
+
addEvent(phrase, 'keyup', function(ev) {
|
|
125
|
+
var keyc = getKeyCode(ev);
|
|
126
|
+
|
|
127
|
+
if (keyc == 13 || keyc == 10) {
|
|
128
|
+
var text = phrase.value;
|
|
129
|
+
phrase.value = '';
|
|
130
|
+
org.activemq.Chat.chat(text);
|
|
131
|
+
return false;
|
|
132
|
+
}
|
|
133
|
+
return true;
|
|
134
|
+
});
|
|
135
|
+
|
|
136
|
+
addEvent(document.getElementById('sendB'), 'click', function() {
|
|
137
|
+
var text = phrase.value;
|
|
138
|
+
phrase.value = '';
|
|
139
|
+
org.activemq.Chat.chat(text);
|
|
140
|
+
});
|
|
141
|
+
|
|
142
|
+
addEvent(document.getElementById('leaveB'), 'click', function() {
|
|
143
|
+
org.activemq.Chat.leave();
|
|
144
|
+
return false;
|
|
145
|
+
});
|
|
146
|
+
};
|
|
147
|
+
|
|
148
|
+
return {
|
|
149
|
+
join: function() {
|
|
150
|
+
var name = username.value;
|
|
151
|
+
if (name == null || name.length == 0) {
|
|
152
|
+
alert('Please enter a username!');
|
|
153
|
+
} else {
|
|
154
|
+
user = name;
|
|
155
|
+
|
|
156
|
+
amq.addListener('chat', chatTopic, chatHandler);
|
|
157
|
+
join.className = 'hidden';
|
|
158
|
+
joined.className = '';
|
|
159
|
+
phrase.focus();
|
|
160
|
+
|
|
161
|
+
amq.sendMessage(chatTopic, '<message type="join" from="' + user + '"/>');
|
|
162
|
+
}
|
|
163
|
+
},
|
|
164
|
+
|
|
165
|
+
leave: function() {
|
|
166
|
+
amq.sendMessage(chatTopic, '<message type="leave" from="' + user + '"/>');
|
|
167
|
+
},
|
|
168
|
+
|
|
169
|
+
chat: function(text) {
|
|
170
|
+
if (text != null && text.length > 0) {
|
|
171
|
+
// TODO more encoding?
|
|
172
|
+
text = text.replace('<', '<');
|
|
173
|
+
text = text.replace('>', '>');
|
|
174
|
+
|
|
175
|
+
amq.sendMessage(chatTopic, '<message type="chat" from="' + user + '">' + text + '</message>');
|
|
176
|
+
}
|
|
177
|
+
},
|
|
178
|
+
|
|
179
|
+
init: function() {
|
|
180
|
+
join = document.getElementById('join');
|
|
181
|
+
joined = document.getElementById('joined');
|
|
182
|
+
chat = document.getElementById('chat');
|
|
183
|
+
members = document.getElementById('members');
|
|
184
|
+
username = document.getElementById('username');
|
|
185
|
+
phrase = document.getElementById('phrase');
|
|
186
|
+
|
|
187
|
+
if (join.className == 'hidden' && joined.className == 'hidden') {
|
|
188
|
+
join.className = '';
|
|
189
|
+
joined.className = 'hidden';
|
|
190
|
+
username.focus();
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
initEventHandlers();
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
}();
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
|
|
202
|
+
|
|
203
|
+
|
|
204
|
+
|
|
205
|
+
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
|
|
209
|
+
|