org.tranche.server.logs
Class LogEntries

java.lang.Object
  extended by org.tranche.server.logs.LogEntries

public class LogEntries
extends java.lang.Object

Keeps track of size. A simple class.

Author:
Bryan E. Smith - bryanesmith@gmail.com

Constructor Summary
LogEntries()
          Create and initialize structures to track log entries.
 
Method Summary
 void add(LogEntry entry)
          Add a log entry for tracking.
 void clear()
          Clear the entire list of log entries being tracked.
 java.util.Iterator<LogEntry> iterator()
          Return an iterator pointing to the beginning of list of entries being tracked.
 long lengthInBytes()
          Length in bytes of entries being tracked.
 int size()
          Number of entries being tracked.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LogEntries

public LogEntries()
Create and initialize structures to track log entries.

Method Detail

add

public void add(LogEntry entry)
Add a log entry for tracking.

Parameters:
entry -

size

public int size()
Number of entries being tracked.

Returns:

lengthInBytes

public long lengthInBytes()
Length in bytes of entries being tracked.

Returns:

iterator

public java.util.Iterator<LogEntry> iterator()
Return an iterator pointing to the beginning of list of entries being tracked.

Returns:

clear

public void clear()
Clear the entire list of log entries being tracked.



This code is free for use both commercially and non-commercially as stated in the project's license