com.almende.eve.agent.log
Class LogAgent

java.lang.Object
  extended by com.almende.eve.agent.Agent
      extended by com.almende.eve.agent.log.LogAgent
All Implemented Interfaces:
AgentInterface

public class LogAgent
extends Agent


Constructor Summary
LogAgent()
           
 
Method Summary
 void cancelTimeToLive()
          Remove existing time to live
 String getDescription()
          Retrieve a description of the agents functionality
 List<Log> getLogs(Long since)
           
 String getVersion()
          Retrieve the agents version number
 void killMe()
          Delete the log agent.
 void log(Log log)
           
 void setTimeToLive(long interval)
          Set a time-to-live for the LogAgent.
 
Methods inherited from class com.almende.eve.agent.Agent
clear, create, createAgentProxy, delete, destroy, finalize, getAgentFactory, getContext, getId, getMethods, getScheduler, getState, getType, getUrls, init, onSubscribe, onTrigger, onUnsubscribe, send, send, send, send, sendAsync, sendAsync, setAgentFactory, setState, subscribe, toString, trigger, unsubscribe, unsubscribe
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LogAgent

public LogAgent()
Method Detail

log

public void log(Log log)

getLogs

public List<Log> getLogs(Long since)
                  throws Exception
Throws:
Exception

cancelTimeToLive

public void cancelTimeToLive()
Remove existing time to live


setTimeToLive

public void setTimeToLive(long interval)
                   throws Exception
Set a time-to-live for the LogAgent. After this timeout, it will delete itself. This is useful for a temporary LogAgent used for a single session in a browser.

Parameters:
interval - interval in milliseconds
Throws:
Exception

killMe

public void killMe()
            throws Exception
Delete the log agent.

Throws:
Exception

getDescription

public String getDescription()
Description copied from interface: AgentInterface
Retrieve a description of the agents functionality

Specified by:
getDescription in interface AgentInterface
Specified by:
getDescription in class Agent
Returns:
description

getVersion

public String getVersion()
Description copied from interface: AgentInterface
Retrieve the agents version number

Specified by:
getVersion in interface AgentInterface
Specified by:
getVersion in class Agent
Returns:
version


Copyright © 2013 Almende BV. All Rights Reserved.