diff options
author | Ted Ross <tross@apache.org> | 2011-02-18 19:16:35 +0000 |
---|---|---|
committer | Ted Ross <tross@apache.org> | 2011-02-18 19:16:35 +0000 |
commit | 6838b02ab50b49718ac3108c678fbc80c930e3ee (patch) | |
tree | fd620c96f5b496c9258c71c8545744bfcf114c06 | |
parent | 5d4c9f6c2ea66540a9c140e5da27a15d95ca7c43 (diff) | |
download | qpid-python-6838b02ab50b49718ac3108c678fbc80c930e3ee.tar.gz |
QPID-3009 - Renamed module to cqpid_perl to distinguish it from other language bindings.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1072105 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/client.pl | 8 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/drain.pl | 12 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/hello_world.pl | 10 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/hello_xml.pl | 6 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/map_receiver.pl | 8 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/map_sender.pl | 8 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/server.pl | 6 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/examples/perl/spout.pl | 10 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/perl/Makefile.am | 20 | ||||
-rw-r--r-- | qpid/cpp/bindings/qpid/perl/perl.i | 2 |
10 files changed, 45 insertions, 45 deletions
diff --git a/qpid/cpp/bindings/qpid/examples/perl/client.pl b/qpid/cpp/bindings/qpid/examples/perl/client.pl index 93eec88e07..19d9d3f14f 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/client.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/client.pl @@ -20,13 +20,13 @@ use strict; use warnings; -use cqpid; +use cqpid_perl; my $url = ( @ARGV == 1 ) ? $ARGV[0] : "amqp:tcp:127.0.0.1:5672"; my $connectionOptions = ( @ARGV > 1 ) ? $ARGV[1] : ""; -my $connection = new cqpid::Connection($url, $connectionOptions); +my $connection = new cqpid_perl::Connection($url, $connectionOptions); eval { $connection->open(); @@ -35,7 +35,7 @@ my $session = $connection->createSession(); my $sender = $session->createSender("service_queue"); #create temp queue & receiver... -my $responseQueue = new cqpid::Address("#response-queue; {create:always, delete:always}"); +my $responseQueue = new cqpid_perl::Address("#response-queue; {create:always, delete:always}"); my $receiver = $session->createReceiver($responseQueue); #Now send some messages... @@ -47,7 +47,7 @@ my @s = ( "And the mome raths outgrabe." ); -my $request = new cqpid::Message(); +my $request = new cqpid_perl::Message(); $request->setReplyTo($responseQueue); for (my $i=0; $i<4; $i++) { $request->setContent($s[$i]); diff --git a/qpid/cpp/bindings/qpid/examples/perl/drain.pl b/qpid/cpp/bindings/qpid/examples/perl/drain.pl index 8010b7c95b..60ac0c50ed 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/drain.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/drain.pl @@ -20,7 +20,7 @@ use strict; use warnings; -use cqpid; +use cqpid_perl; use Getopt::Long; my $url = "127.0.0.1"; @@ -47,11 +47,11 @@ if ($#ARGV ge 0) { } sub getTimeout { - return ($forever) ? $cqpid::Duration::FOREVER : new cqpid::Duration($timeout*1000); + return ($forever) ? $cqpid_perl::Duration::FOREVER : new cqpid_perl::Duration($timeout*1000); } -my $connection = new cqpid::Connection($url, $connectionOptions); +my $connection = new cqpid_perl::Connection($url, $connectionOptions); eval { $connection->open(); @@ -59,13 +59,13 @@ eval { my $receiver = $session->createReceiver($address); my $timeout = getTimeout(); - my $message = new cqpid::Message(); + my $message = new cqpid_perl::Message(); my $i = 0; while($receiver->fetch($message, $timeout)) { print "Message(properties=" . $message->getProperties() . ",content='"; if ($message->getContentType() eq "amqp/map") { - my $content = cqpid::decodeMap($message); + my $content = cqpid_perl::decodeMap($message); map{ print "\n$_ => $content->{$_}"; } keys %{$content}; } else { @@ -77,7 +77,7 @@ eval { if ($replyto->getName()) { print "Replying to " . $message->getReplyTo()->str() . "...\n"; my $sender = $session->createSender($replyto); - my $response = new cqpid::Message("received by the server."); + my $response = new cqpid_perl::Message("received by the server."); $sender->send($response); } $session->acknowledge(); diff --git a/qpid/cpp/bindings/qpid/examples/perl/hello_world.pl b/qpid/cpp/bindings/qpid/examples/perl/hello_world.pl index cf2f05f8b7..a96b98a002 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/hello_world.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/hello_world.pl @@ -21,13 +21,13 @@ use strict; use warnings; use Data::Dumper; -use cqpid; +use cqpid_perl; my $broker = ( @ARGV > 0 ) ? $ARGV[0] : "localhost:5672"; my $address = ( @ARGV > 1 ) ? $ARGV[0] : "amq.topic"; my $connectionOptions = ( @ARGV > 2 ) ? $ARGV[1] : ""; -my $connection = new cqpid::Connection($broker, $connectionOptions); +my $connection = new cqpid_perl::Connection($broker, $connectionOptions); eval { $connection->open(); @@ -36,12 +36,12 @@ eval { my $receiver = $session->createReceiver($address); my $sender = $session->createSender($address); - $sender->send(new cqpid::Message("Hello world!")); + $sender->send(new cqpid_perl::Message("Hello world!")); - #my $duration = new cqpid::Duration(1000); + #my $duration = new cqpid_perl::Duration(1000); #print ">>>" . $duration->getMilliseconds() . "\n"; - my $message = $receiver->fetch($cqpid::Duration::SECOND); + my $message = $receiver->fetch($cqpid_perl::Duration::SECOND); #$message->setDurable(1); #print "Durable: " . $message->getDurable() . "\n"; diff --git a/qpid/cpp/bindings/qpid/examples/perl/hello_xml.pl b/qpid/cpp/bindings/qpid/examples/perl/hello_xml.pl index c48a5225c2..cebf2ceee6 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/hello_xml.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/hello_xml.pl @@ -20,7 +20,7 @@ use strict; use warnings; -use cqpid; +use cqpid_perl; my $broker = ( @ARGV > 0 ) ? $ARGV[0] : "localhost:5672"; my $connectionOptions = ( @ARGV > 1 ) ? $ARGV[1] : ""; @@ -44,7 +44,7 @@ x-bindings: [{ exchange: xml-exchange, key: weather, arguments: { xquery:" $quer END -my $connection = new cqpid::Connection($broker, $connectionOptions); +my $connection = new cqpid_perl::Connection($broker, $connectionOptions); eval { $connection->open(); @@ -52,7 +52,7 @@ eval { my $receiver = $session->createReceiver($address); - my $message = new cqpid::Message(); + my $message = new cqpid_perl::Message(); my $content = <<END; <weather> diff --git a/qpid/cpp/bindings/qpid/examples/perl/map_receiver.pl b/qpid/cpp/bindings/qpid/examples/perl/map_receiver.pl index e3e8a201dd..2e2611e38f 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/map_receiver.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/map_receiver.pl @@ -21,21 +21,21 @@ use strict; use warnings; use Data::Dumper; -use cqpid; +use cqpid_perl; my $url = ( @ARGV > 0 ) ? $ARGV[0] : "amqp:tcp:127.0.0.1:5672"; my $address = ( @ARGV > 1 ) ? $ARGV[0] : "message_queue; {create: always}"; my $connectionOptions = ( @ARGV > 2 ) ? $ARGV[1] : ""; -my $connection = new cqpid::Connection($url, $connectionOptions); +my $connection = new cqpid_perl::Connection($url, $connectionOptions); eval { $connection->open(); my $session = $connection->createSession(); my $receiver = $session->createReceiver($address); - my $content = cqpid::decodeMap($receiver->fetch()); - #my $content = cqpid::decodeList($receiver->fetch()); + my $content = cqpid_perl::decodeMap($receiver->fetch()); + #my $content = cqpid_perl::decodeList($receiver->fetch()); print Dumper($content); diff --git a/qpid/cpp/bindings/qpid/examples/perl/map_sender.pl b/qpid/cpp/bindings/qpid/examples/perl/map_sender.pl index 095acce0ab..4107cd48b9 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/map_sender.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/map_sender.pl @@ -21,13 +21,13 @@ use strict; use warnings; use Data::Dumper; -use cqpid; +use cqpid_perl; my $url = ( @ARGV > 0 ) ? $ARGV[0] : "amqp:tcp:127.0.0.1:5672"; my $address = ( @ARGV > 1 ) ? $ARGV[1] : "message_queue; {create: always}"; my $connectionOptions = ( @ARGV > 2 ) ? $ARGV[2] : ""; -my $connection = new cqpid::Connection($url, $connectionOptions); +my $connection = new cqpid_perl::Connection($url, $connectionOptions); eval { $connection->open(); @@ -35,13 +35,13 @@ eval { my $session = $connection->createSession(); my $sender = $session->createSender($address); - my $message = new cqpid::Message(); + my $message = new cqpid_perl::Message(); my $content = { id => 987654321, name => "Widget", percent => sprintf("%.2f", 0.99), colours => [ qw (red green white) ], }; - cqpid::encode($content, $message); + cqpid_perl::encode($content, $message); $sender->send($message, 1); $connection->close(); diff --git a/qpid/cpp/bindings/qpid/examples/perl/server.pl b/qpid/cpp/bindings/qpid/examples/perl/server.pl index 0c64f15c66..b14da565b9 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/server.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/server.pl @@ -20,13 +20,13 @@ use strict; use warnings; -use cqpid; +use cqpid_perl; my $url = ( @ARGV == 1 ) ? $ARGV[0] : "amqp:tcp:127.0.0.1:5672"; my $connectionOptions = ( @ARGV > 1 ) ? $ARGV[1] : ""; -my $connection = new cqpid::Connection($url, $connectionOptions); +my $connection = new cqpid_perl::Connection($url, $connectionOptions); eval { $connection->open(); @@ -41,7 +41,7 @@ eval { my $sender = $session->createSender($address); my $s = $request->getContent(); $s = uc($s); - my $response = new cqpid::Message($s); + my $response = new cqpid_perl::Message($s); $sender->send($response); print "Processed request: " . $request->getContent() . " -> " . $response->getContent() . "\n"; $session->acknowledge(); diff --git a/qpid/cpp/bindings/qpid/examples/perl/spout.pl b/qpid/cpp/bindings/qpid/examples/perl/spout.pl index 50773a4fe2..7365e732bf 100644 --- a/qpid/cpp/bindings/qpid/examples/perl/spout.pl +++ b/qpid/cpp/bindings/qpid/examples/perl/spout.pl @@ -20,7 +20,7 @@ use strict; use warnings; -use cqpid; +use cqpid_perl; use Getopt::Long; use Time::Local; @@ -77,19 +77,19 @@ sub setProperties { } } -my $connection = new cqpid::Connection($url, $connectionOptions); +my $connection = new cqpid_perl::Connection($url, $connectionOptions); eval { $connection->open(); my $session = $connection->createSession(); my $sender = $session->createSender($address); - my $message = new cqpid::Message(); + my $message = new cqpid_perl::Message(); setProperties($message) if (@properties); if (@entries) { my $content = {}; setEntries($content); - cqpid::encode($content, $message); + cqpid_perl::encode($content, $message); } elsif ($content) { $message->setContent($content); @@ -98,7 +98,7 @@ eval { my $receiver; if ($replyto) { - my $responseQueue = new cqpid::Address($replyto); + my $responseQueue = new cqpid_perl::Address($replyto); $receiver = $session->createReceiver($responseQueue); $message->setReplyTo($responseQueue); } diff --git a/qpid/cpp/bindings/qpid/perl/Makefile.am b/qpid/cpp/bindings/qpid/perl/Makefile.am index 982d493ba0..13ab66f032 100644 --- a/qpid/cpp/bindings/qpid/perl/Makefile.am +++ b/qpid/cpp/bindings/qpid/perl/Makefile.am @@ -22,21 +22,21 @@ if HAVE_PERL_DEVEL INCLUDES = -I$(top_srcdir)/include -I$(top_builddir)/include -I$(top_srcdir)/src -I$(top_builddir)/src -I$(PERL_INC) EXTRA_DIST = perl.i -BUILT_SOURCES = cqpid.cpp +BUILT_SOURCES = cqpid_perl.cpp SWIG_FLAGS = -w362,401 -cqpid.cpp: $(srcdir)/perl.i $(srcdir)/../qpid.i $(srcdir)/../../swig_perl_typemaps.i - $(SWIG) -perl -c++ $(SWIG_FLAGS) $(INCLUDES) $(QPID_CXXFLAGS) -I/usr/include -o cqpid.cpp $(srcdir)/perl.i +cqpid_perl.cpp: $(srcdir)/perl.i $(srcdir)/../qpid.i $(srcdir)/../../swig_perl_typemaps.i + $(SWIG) -perl -c++ $(SWIG_FLAGS) $(INCLUDES) $(QPID_CXXFLAGS) -I/usr/include -o cqpid_perl.cpp $(srcdir)/perl.i -lib_LTLIBRARIES = cqpid.la -cqpid_PERL = cqpid.pm +lib_LTLIBRARIES = libcqpid_perl.la +cqpid_perl_PERL = cqpid_perl.pm -cqpid_la_LDFLAGS = -avoid-version -module -shared -cqpid_la_LIBADD = -L$(top_builddir)/src/.libs -lqpidmessaging -lqpidtypes \ +libcqpid_perl_la_LDFLAGS = -avoid-version -shared +libcqpid_perl_la_LIBADD = -L$(top_builddir)/src/.libs -lqpidmessaging -lqpidtypes \ $(top_builddir)/src/libqpidmessaging.la $(top_builddir)/src/libqpidtypes.la -cqpid_la_CXXFLAGS = $(INCLUDES) -nodist_cqpid_la_SOURCES = cqpid.cpp +libcqpid_perl_la_CXXFLAGS = $(INCLUDES) +nodist_libcqpid_perl_la_SOURCES = cqpid_perl.cpp -CLEANFILES = cqpid.cpp cqpid.pm +CLEANFILES = cqpid_perl.cpp cqpid_perl.pm endif # HAVE_PERL_DEVEL diff --git a/qpid/cpp/bindings/qpid/perl/perl.i b/qpid/cpp/bindings/qpid/perl/perl.i index b7ae0568b6..38ac91761f 100644 --- a/qpid/cpp/bindings/qpid/perl/perl.i +++ b/qpid/cpp/bindings/qpid/perl/perl.i @@ -17,7 +17,7 @@ * under the License. */ -%module cqpid +%module cqpid_perl %include "std_string.i" %include "../../swig_perl_typemaps.i" |