# Class LoggerAppenderSocket

LoggerAppenderSocket appends to a network socket.

# Configurable parameters:

- remoteHost - Target remote host.
- port - Target port (optional, defaults to 4446).
- timeout - Connection timeout in seconds (optional, defaults to 'default_socket_timeout' from php.ini)

The socket will by default be opened in blocking mode.

  LoggerConfigurable
  LoggerAppender
  LoggerAppenderSocket

Package: log4php\appenders
License: Apache License, Version 2.0
Version: $Revision: 1337820 $
Link: Appender documentation
Located at appenders/LoggerAppenderSocket.php

Methods summary
`public `LoggerLayout`` | # `getDefaultLayout( )` Override the default layout to use serialized. Override the default layout to use serialized. #### Returns ``LoggerLayout`` #### Overrides `LoggerAppender::getDefaultLayout()`
`public` | # `activateOptions( )` Prepares the appender for logging. Prepares the appender for logging. Derived appenders should override this method if option structure requires it. #### Overrides `LoggerAppender::activateOptions()`
`public` | # `append( `LoggerLoggingEvent` $event )` Forwards the logging event to the destination. Forwards the logging event to the destination. Derived appenders should implement this method to perform actual logging. #### Parameters $event ``LoggerLoggingEvent`` $event
`public` | # `setRemoteHost( mixed $hostname )` Sets the target host. Sets the target host.
`public` | # `setPort( mixed $port )` Sets the target port Sets the target port
`public` | # `setTimeout( mixed $timeout )` Sets the timeout. Sets the timeout.
`public` | # `getRemoteHost( )` Returns the target host. Returns the target host.
`public` | # `getPort( )` Returns the target port. Returns the target port.
`public` | # `getTimeout( )` Returns the timeout Returns the timeout

Methods inherited from LoggerAppender
`__construct(), __destruct(), addFilter(), clearFilters(), close(), doAppend(), getFilter(), getFirstFilter(), getLayout(), getName(), getThreshold(), isAsSevereAsThreshold(), requiresLayout(), setLayout(), setName(), setThreshold(), warn()`

Methods inherited from LoggerConfigurable
`setBoolean(), setFileSize(), setInteger(), setLevel(), setNumeric(), setPositiveInteger(), setString()`

Properties summary
`protected mixed` | $remoteHost | `` | # Target host. Target host. #### See http://php.net/manual/en/function.fsockopen.php
`protected integer` | $port | `4446` | # Target port Target port
`protected mixed` | $timeout | `` | # Connection timeout in ms. Connection timeout in ms.

Properties inherited from LoggerAppender
`$closed, $filter, $layout, $name, $requiresLayout, $threshold`