add example
[mdref/mdref-pq] / pq / Connection / trace.md
1 # bool pq\Connection::trace([resource $stream])
2
3 Trace protocol communication with the server.
4
5 > ***NOTE:***
6 Calling pq\Connection::trace() without argument or NULL stops tracing.
7
8 ## Params:
9
10 * Optional resource $stream = NULL
11 The resource to which the protocol trace will be output.
12 (The stream must be castable to STDIO).
13
14 ## Returns:
15
16 * bool, success.
17
18 ## Throws:
19
20 * pq\Exception\BadMethodCallException