The Stomp class

(PECL stomp >= 0.1.0)

소개

Represents a connection between PHP and a Stomp compliant Message Broker.

클래스 개요

Stomp {
/* 메소드 */
public bool abort ( string $transaction_id [, array $headers ] )
public bool ack ( mixed $msg [, array $headers ] )
public bool begin ( string $transaction_id [, array $headers ] )
public bool commit ( string $transaction_id [, array $headers ] )
public __construct ([ string $broker = ini_get("stomp.default_broker_uri") [, string $username [, string $password [, array $headers ]]]] )
public bool __destruct ( void )
public string error ( void )
public array getReadTimeout ( void )
public string getSessionId ( void )
public bool hasFrame ( void )
public stompframe readFrame ([ string $class_name = "stompFrame" ] )
public bool send ( string $destination , mixed $msg [, array $headers ] )
public void setReadTimeout ( int $seconds [, int $microseconds ] )
public bool subscribe ( string $destination [, array $headers ] )
public bool unsubscribe ( string $destination [, array $headers ] )
}

Table of Contents

add a note add a note

User Contributed Notes 1 note

up
1
guilherme dot geronimo at gmail dot com
7 years ago
In some cases (E.g. ActiveMQ), when you have many consumers you need to identify your "client-id" during the connection process, otherwise the server can misunderstand your connection and create new topics/queues:

<?php
$stomp
= new Stomp($url, $user, $password, array('client-id'=> $clientId ));
?>
To Top