apidoc
[ class tree: apidoc ] [ index: apidoc ] [ all elements ]

Class: System_Socket_Debugger

Source Location: /System_Socket-0.4.0/Socket/Debugger.php

Class Overview

System_Socket_Observer
   |
   --System_Socket_Debugger

System_Socket_Debugger


Author(s):

Version:

  • $Revision: 1.9 $

Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 70]
System_Socket_Debugger

The System_Socket_Debugger class aims to provide a simple and versatile option to debug socket implementations in various ways.

Example 1:

  1.  require_once 'System/Socket.php';
  2.  require_once 'System/Socket/Debugger.php';
  3.  $conn &System_Socket::createConnection(
  4.    array('address'=>'pear.php.net''port'=>80));
  5.  $conn->attach(new System_Socket_Debugger(SYSTEM_SOCKET_DEBUG_ECHO));

Example 2:

  1.  // no need to explicitly create a System_Socket_Debugger object
  2.  require_once 'System/Socket.php';
  3.  require_once 'System/Socket/Debugger.php';
  4.  define('SYSTEM_SOCKET_DEBUG'SYSTEM_SOCKET_DEBUG_ECHO);
  5.  $conn &System_Socket::createConnection(
  6.    array('address'=>'pear.php.net''port'=>80));
  7.  // a debugger object gets attached automagically

  • Author: Michael Wallner <mike@php.net>
  • Version: $Revision: 1.9 $
  • Access: public


[ Top ]


Class Variables

$dateFormat =  'Y-m-d H:i:s'

[line 126]

Echoed dates format
  • Access: public

Type:   string


[ Top ]

$echoDate =  true

[line 118]

Whether to echo a date
  • Access: public

Type:   bool


[ Top ]

$hasPearLog =  false

[line 144]

Whether a PEAR::Log object is attached
  • Access: public

Type:   bool


[ Top ]

$LF =  "\n"

[line 78]

Linefeed character(s)
  • Access: public

Type:   string


[ Top ]

$PearLog =  null

[line 135]

PEAR::Log object
  • Access: public

Type:   object


[ Top ]

$stack = array()

[line 152]

Note stack
  • Access: protected

Type:   array


[ Top ]

$type =  SYSTEM_SOCKET_DEBUG_NONE

[line 86]

Type
  • Access: public

Type:   int


[ Top ]

$verboseArgs =  true

[line 102]

Whether to log methods arguments
  • Access: public

Type:   bool


[ Top ]

$verboseCalls =  true

[line 94]

Whether to log all method calls
  • Access: public

Type:   bool


[ Top ]

$verboseResults =  true

[line 110]

Whether to log methods results
  • Access: public

Type:   bool


[ Top ]



Method Detail

System_Socket_Debugger (Constructor)   [line 160]

object System_Socket_Debugger System_Socket_Debugger( [ $type = null])

Constructor
  • Access: public

Parameters:

   $type   — 

[ Top ]

arg2string   [line 291]

string arg2string( mixed $arg)

arg2string

Attempts to convert any argument to a representive string.

  • Access: public

Parameters:

mixed   $arg   — 

[ Top ]

getStack   [line 276]

array getStack( [int $num = null])

Get (part of) note stack

Each received note gets stored in the notes stack of the debugger. With this method you can get the whole stack or the $numth part.

  • Access: public

Parameters:

int   $num   — 

[ Top ]

notify   [line 203]

void notify( array $note)

Notify
  • Access: public

Overrides System_Socket_Observer::notify() (Notify)

Parameters:

array   $note   — 

[ Top ]

setPearLog   [line 187]

bool setPearLog( &$log, object Log $log)

Set a configured PEAR_Log object
  • Access: public

Parameters:

object Log   $log   — 
   &$log   — 

[ Top ]


Documentation generated on Mon, 11 Mar 2019 10:15:56 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.