downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

SAMConnection->isConnected> <SAMConnection->errno
Last updated: Fri, 13 Nov 2009

view this page in

SAMConnection->error

(PECL sam >= 0.1.0)

SAMConnection->error最後に実行した SAM 操作のエラーの説明を含む

説明

SAMConnection
string $error;

この接続で最後に実行された SAM 操作のテキストによる説明が含まれます。 直近の操作が正常に終了した場合は、このプロパティには空の文字列が含まれます。

返り値

この接続で発生した最後のエラーの内容を表すテキストを返します。 空の文字列は、この接続の直近の操作が正常に終了したことを表します。

例1 エラー番号および説明の取得法

<?php
$conn 
= new SAMConnection();
$conn->connect(SAM_WMQ, array(SAM_HOST => 'localhost'SAM_PORT => 1506));
$msg = new SAMMessage('This is a simple text item');
if (!
$conn->send('topic://test'$msg)) {
    
// 送信に失敗しました!
    
echo "Send failed ($conn->errno$conn->error";
}
?>



add a note add a note User Contributed Notes
SAMConnection->error
There are no user contributed notes for this page.

SAMConnection->isConnected> <SAMConnection->errno
Last updated: Fri, 13 Nov 2009
 
 
show source | credits | stats | sitemap | contact | advertising | mirror sites