資源簡介
ActiveMQ Demo程序,包括發送和接收程序
ActiveMQ是個好東東,不必多說。ActiveMQ提供多種語言支持,如Java, C, C , C#, Ruby, Perl, Python, PHP等。由于我在windows下開發GUI,比較關心C 和C#,其中C#的ActiveMQ很簡單,Apache提供NMS(.Net Messaging Service)支持.Net開發,只需如下幾個步驟即能建立簡單的實現
ActiveMQ是個好東東,不必多說。ActiveMQ提供多種語言支持,如Java, C, C , C#, Ruby, Perl, Python, PHP等。由于我在windows下開發GUI,比較關心C 和C#,其中C#的ActiveMQ很簡單,Apache提供NMS(.Net Messaging Service)支持.Net開發,只需如下幾個步驟即能建立簡單的實現
代碼片段和文件信息
using?System;
using?System.Collections.Generic;
using?System.ComponentModel;
using?System.Data;
using?System.Drawing;
using?System.Text;
using?System.Windows.Forms;
using?Apache.NMS;
using?Apache.NMS.ActiveMQ;
namespace?MQDemoSubscriber
{
????public?partial?class?Form1?:?Form
????{
????????private?MQ?m_mq;
????????private?IMessageConsumer?m_consumer;
????????private?delegate?void?ShowNoteMsgDelegate(string?msg);
????????public?Form1()
????????{
????????????InitializeComponent();
????????}
????????private?void?btnConnect_Click(object?sender?EventArgs?e)
????????{
????????????try
????????????{
????????????????if?(!GlobalFunction.CheckControlInput(txtURI?“URI“?0?false))?return;
????????????????m_mq?=?new?MQ();
????????????????m_mq.uri?=?txtURI.Text;
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2012-08-14?10:15??MQDemo\
?????目錄???????????0??2012-08-14?10:15??MQDemo\MQDemo\
?????文件????????1404??2011-04-28?16:36??MQDemo\MQDemo.sln
?????文件???????30192??2012-08-14?10:15??MQDemo\MQDemo.suo
?????目錄???????????0??2012-08-14?10:14??MQDemo\MQDemo\bin\
?????目錄???????????0??2012-08-14?10:14??MQDemo\MQDemo\bin\Release\
?????文件??????421888??2010-05-07?12:31??MQDemo\MQDemo\bin\Release\Apache.NMS.ActiveMQ.dll
?????文件???????65536??2010-01-11?09:09??MQDemo\MQDemo\bin\Release\Apache.NMS.dll
?????文件???????19456??2012-08-14?10:13??MQDemo\MQDemo\bin\Release\MQDemoSubscriber.exe
?????文件???????14328??2012-08-14?10:13??MQDemo\MQDemo\bin\Release\MQDemoSubscriber.vshost.exe
?????文件????????3590??2012-08-14?10:12??MQDemo\MQDemo\Form1.cs
?????文件???????17023??2012-08-14?10:12??MQDemo\MQDemo\Form1.Designer.cs
?????文件????????6014??2012-08-14?10:12??MQDemo\MQDemo\Form1.resx
?????文件????????5415??2011-04-28?17:18??MQDemo\MQDemo\GlobalFunction.cs
?????文件????????4976??2011-04-28?17:18??MQDemo\MQDemo\MQ.cs
?????文件????????4117??2011-04-28?17:17??MQDemo\MQDemo\MQDemo.csproj
?????文件?????????477??2011-04-28?17:18??MQDemo\MQDemo\Program.cs
?????目錄???????????0??2012-08-14?10:10??MQDemo\MQDemo\Properties\
?????文件????????1368??2011-04-28?17:19??MQDemo\MQDemo\Properties\AssemblyInfo.cs
?????文件????????2856??2011-04-28?17:17??MQDemo\MQDemo\Properties\Resources.Designer.cs
?????文件????????5612??2011-04-28?14:20??MQDemo\MQDemo\Properties\Resources.resx
?????文件????????1114??2011-04-28?17:17??MQDemo\MQDemo\Properties\Settings.Designer.cs
?????文件?????????249??2011-04-28?14:20??MQDemo\MQDemo\Properties\Settings.settings
?????目錄???????????0??2012-08-14?10:14??MQDemo\MQProducerDemo\
?????目錄???????????0??2012-08-14?10:22??MQDemo\MQProducerDemo\bin\
?????目錄???????????0??2012-08-14?10:15??MQDemo\MQProducerDemo\bin\Release\
?????文件??????421888??2010-05-07?12:31??MQDemo\MQProducerDemo\bin\Release\Apache.NMS.ActiveMQ.dll
?????文件???????65536??2010-01-11?09:09??MQDemo\MQProducerDemo\bin\Release\Apache.NMS.dll
?????文件???????26624??2012-08-14?10:14??MQDemo\MQProducerDemo\bin\Release\MQDemoProducer.exe
?????文件?????????887??2011-04-28?16:29??MQDemo\MQProducerDemo\Debug.cs
?????文件????????4594??2012-08-14?10:09??MQDemo\MQProducerDemo\Form1.cs
............此處省略14個文件信息
評論
共有 條評論