|
PHP5中文手册
SAMConnection->send()(No version information available, might be only in CVS) SAMConnection->send() — Send a message to a queue or publish an item to a topic. 说明SAMConnection
string send
( string $target
, SAMMessage $msg
[, array $properties
] )
The "send" method is used to send a message to a specific queue or to publish to a specific topic. The method returns a correlation id that can be used as a selector to identify reply or response messages when these are requested. 参数
返回值A correlation id string that can be used in a subsequent receive call as a selector to obtain any reply or response that has been requested or FALSE if an error occurred.
范例
Example#1 Send a message to a queue
<?php
Example#2 Publish a message to a topic
<?php Example#3 Send a request and receive a response
<?php |