diff --git a/README.md b/README.md index 81ac71c..bb67766 100644 --- a/README.md +++ b/README.md @@ -182,10 +182,6 @@ foreach ($protocol->getResponses() as $response) { Directory `src` contains autoload file which accepts only Bolt library namespaces. Main Bolt namespace points to this directory. If you have installed this project with composer, you have to load `vendor/autoload.php`. -## :vertical_traffic_light: Server state - -Server state is not reported by server but it is evaluated by received response. You can access current state through property `$protocol->serverState`. This property is updated with every call `getResponse(s)`. - ## :chains: Connection Bolt class constructor accepts connection argument. This argument has to be instance of class which implements IConnection interface. Library offers few options. @@ -253,6 +249,10 @@ timeout for establishing socket connection itself you have to set ini directive _Setting up ini directive isn't part of connection class because function `ini_set` can be disabled on production environments for security reasons._ +## :vertical_traffic_light: Server state + +Server state is not reported by server but it is evaluated by received response. You can access current state through property `$protocol->serverState`. This property is updated with every call `getResponse(s)`. + ## :pushpin: More solutions If you need simple class to cover basic functionality you can diff --git a/src/enum/Signature.php b/src/enum/Signature.php index 426b4dc..bdaa09e 100644 --- a/src/enum/Signature.php +++ b/src/enum/Signature.php @@ -11,8 +11,25 @@ enum Signature: int { case NONE = 0; - case SUCCESS = 0x70; //112 - case FAILURE = 0x7F; //127 - case IGNORED = 0x7E; //126 - case RECORD = 0x71; //113 + /** + * The SUCCESS message indicates that the corresponding request has succeeded as intended. It may contain metadata relating to the outcome. Metadata keys are described in the section of this document relating to the message that began the exchange. + * @internal 112 + */ + case SUCCESS = 0x70; + /** + * A FAILURE message response indicates that the client is not permitted to exchange further messages. Servers may choose to include metadata describing the nature of the failure. + * @internal 127 + */ + case FAILURE = 0x7F; + /** + * The IGNORED message indicates that the corresponding request has not been carried out. + * @internal 126 + */ + case IGNORED = 0x7E; + /** + * A RECORD message carries a sequence of values corresponding to a single entry in a result. + * These messages are currently only ever received in response to a PULL (PULL_ALL in v1, v2, and v3) message and will always be followed by a summary message. + * @internal 113 + */ + case RECORD = 0x71; }