public class EventRecord
extends java.lang.Object
Constructor and Description |
---|
EventRecord()
Create the EventRecord with no fields other than "invalid" as
the hostname.
|
EventRecord(java.lang.String _hostname,
java.lang.Object[] _ips,
java.util.Calendar _timestamp,
java.lang.String _type,
java.lang.String _logLevel,
java.lang.String _source,
java.lang.String _message)
Create the EventRecord given the most common properties
among different metric types.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
get(java.lang.String fieldName)
Get the value of a property of the EventRecord.
|
java.util.HashMap<java.lang.String,java.lang.Object> |
getMap()
Return the HashMap of properties of the EventRecord.
|
boolean |
isValid()
Check if the EventRecord is a valid one, i.e., whether
it represents meaningful metric values.
|
void |
set(java.lang.String fieldName,
java.lang.Object fieldValue)
Set the value of a property of the EventRecord.
|
java.lang.String |
toString()
Creates and returns a string representation of the object.
|
public EventRecord(java.lang.String _hostname, java.lang.Object[] _ips, java.util.Calendar _timestamp, java.lang.String _type, java.lang.String _logLevel, java.lang.String _source, java.lang.String _message)
public EventRecord()
public final java.util.HashMap<java.lang.String,java.lang.Object> getMap()
public void set(java.lang.String fieldName, java.lang.Object fieldValue)
fieldName
- the name of the property to setfieldValue
- the value of the property to setpublic java.lang.Object get(java.lang.String fieldName)
fieldName
- the name of the property to get.public boolean isValid()
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2009 The Apache Software Foundation