SAMConnection::unsubscribe

(PECL sam >= 0.1.0)

SAMConnection::unsubscribe Cancel a subscription to a specified topic

说明

SAMConnection::unsubscribe ( string $subscriptionId [, string $targetTopic ] ) : bool

The "unsubscribe" method is used to delete an existing subscription to a specified topic.

参数

subscriptionId

The identifier of an existing subscription as returned by a call to the subscribe method.

返回值

This method returns FALSE if an error occurs.

范例

Example #1 Delete a subscription

<?php
if (!$conn->unsubscribe($subid)) {
    
// The unsubscribe failed!
    
echo "Unsubscribe failed ($conn->errno$conn->error";
}
?>

相关文章
php dba 函数 fetch data specified by keyphp mcve 函数 delete specified transaction from mcve conn structurephp ncurses 函数 move position and add attributed string with specified lengthphp ncurses 函数 move position and add string with specified lengthphp odbc 函数 lists the column names in specified tablesphp sqlsrv 函数 returns information about the client and specified connectionphp sqlsrv 函数 indicates whether the specified statement has rowsphp sqlsrv 函数 makes the next result of the specified statement activephp stream 函数 runs the equivalent of the select system call on the given arrays of streams with a timeout specified by tv sec and tv usecphp tidy 函数 returns the number of tidy accessibility warnings encountered for specified documentphp tidy 函数 returns the number of tidy configuration errors encountered for specified documentphp tidy 函数 returns the number of tidy errors encountered for specified documentphp sam 函数 contains the text description of the last failed sam operationphp sam 函数 queries whether a connection is established to a messaging serverphp sam 函数 read a message from a queue without removing it from the queuephp sam 函数 receive a message from a queue or subscriptionphp sam 函数 send a message to a queue or publish an item to a topicphp sam 函数 create a subscription to a specified topicphp sam 函数 cancel a subscription to a specified topicphp sdo 函数 return the property for the specified sequence index
关注编程学问公众号