|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
java.lang.Objectorg.apache.log4j.AppenderSkeleton
org.apache.log4j.net.MulticastAppender
public class MulticastAppender
Multicast-based Appender. Works in conjunction with the MulticastReceiver, which expects a LoggingEvent encoded using XMLLayout. Sends log information as a multicast datagrams.
Messages are not sent as LoggingEvent objects but as text after applying XMLLayout.
The port and remoteHost properties can be set in configuration properties. By setting the remoteHost to a broadcast address any number of clients can listen for log messages.
This was inspired and really extended/copied from SocketAppender
. Please
see the docs for the proper credit to the authors of that class.
フィールドの概要 | |
---|---|
static java.lang.String |
ZONE
The MulticastDNS zone advertised by a MulticastAppender the MulticastAppender also adds a 'multicastAddress' property with the multicast address value as a string |
クラス org.apache.log4j.AppenderSkeleton から継承されたフィールド |
---|
closed, errorHandler, headFilter, layout, name, tailFilter, threshold |
コンストラクタの概要 | |
---|---|
MulticastAppender()
|
メソッドの概要 | |
---|---|
void |
activateOptions()
Open the multicast sender for the RemoteHost and Port. |
void |
append(org.apache.log4j.spi.LoggingEvent event)
|
void |
cleanUp()
Close the Socket and release the underlying connector thread if it has been created |
void |
close()
Close this appender. |
java.lang.String |
getApplication()
Returns value of the App option. |
java.lang.String |
getEncoding()
Returns value of the Encoding option. |
boolean |
getLocationInfo()
Returns value of the LocationInfo option. |
int |
getPort()
Returns value of the Port option. |
java.lang.String |
getRemoteHost()
Returns value of the RemoteHost option. |
int |
getTimeToLive()
Returns value of the Time to Live option. |
boolean |
isActive()
Get if item is active. |
boolean |
isAdvertiseViaMulticastDNS()
|
boolean |
requiresLayout()
Gets whether appender requires a layout. |
void |
setAdvertiseViaMulticastDNS(boolean advertiseViaMulticastDNS)
|
void |
setApplication(java.lang.String app)
The App option takes a string value which should be the name of the application getting logged. |
void |
setEncoding(java.lang.String encoding)
The Encoding option specifies how the bytes are encoded. |
void |
setLocationInfo(boolean locationInfo)
The LocationInfo option takes a boolean value. |
void |
setPort(int port)
The Port option takes a positive integer representing the port where multicast packets will be sent. |
void |
setRemoteHost(java.lang.String host)
The RemoteHost option takes a string value which should be the host name or ipaddress to send the multicast packets. |
void |
setTimeToLive(int timeToLive)
The Time to live option takes a positive integer representing the time to live value. |
クラス org.apache.log4j.AppenderSkeleton から継承されたメソッド |
---|
addFilter, clearFilters, doAppend, finalize, getErrorHandler, getFilter, getFirstFilter, getLayout, getName, getThreshold, isAsSevereAsThreshold, setErrorHandler, setLayout, setName, setThreshold |
クラス java.lang.Object から継承されたメソッド |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
インタフェース org.apache.log4j.net.NetworkBased から継承されたメソッド |
---|
getName |
フィールドの詳細 |
---|
public static final java.lang.String ZONE
コンストラクタの詳細 |
---|
public MulticastAppender()
メソッドの詳細 |
---|
public void activateOptions()
org.apache.log4j.spi.OptionHandler
内の activateOptions
org.apache.log4j.AppenderSkeleton
内の activateOptions
public void close()
This will mark the appender as closed and
call then cleanUp()
method.
org.apache.log4j.Appender
内の close
public void cleanUp()
public void append(org.apache.log4j.spi.LoggingEvent event)
org.apache.log4j.AppenderSkeleton
内の append
public void setRemoteHost(java.lang.String host)
public java.lang.String getRemoteHost()
public void setLocationInfo(boolean locationInfo)
public boolean getLocationInfo()
public void setEncoding(java.lang.String encoding)
public java.lang.String getEncoding()
public void setApplication(java.lang.String app)
public java.lang.String getApplication()
public void setTimeToLive(int timeToLive)
public int getTimeToLive()
public void setPort(int port)
public int getPort()
PortBased
内の getPort
public boolean isActive()
NetworkBased
の記述:
NetworkBased
内の isActive
public boolean requiresLayout()
org.apache.log4j.Appender
内の requiresLayout
public boolean isAdvertiseViaMulticastDNS()
public void setAdvertiseViaMulticastDNS(boolean advertiseViaMulticastDNS)
|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |