OpenAPI 1.0

com.aquafold.openapi.io
Interface AQHttpLogReader

All Superinterfaces:
AQDataReader, Closeable

public interface AQHttpLogReader
extends AQDataReader

An object implementing this interface, available via aqua.io.newHttpLogReader(), facilitates reading of Apache web server access log files.

This helper interface makes no assumptions as to the log format (which depends on the specific server configuration). A AQDataSet produced by this interface contains the data present in the log, minus square brackets and quotes found in the original log.


Method Summary
 AQDataSet read()
          Sequentially reads the input log into an in-memory data set.
 void setFile(String filename)
          Sets the input file name
 void setFirstLineContainsColumnNames(boolean contains)
          Determines whether first call to AQDataReader.readNextRow() should return column names set previously by setLogFormat(String).
 void setLogFormat(String format)
          Sets column structure according to Apache Log Format specification.
 
Methods inherited from interface com.aquafold.openapi.io.AQDataReader
close, getColumnStructure, readNextRow
 

Method Detail

setFile

void setFile(String filename)
Sets the input file name

Parameters:
filename -

setLogFormat

void setLogFormat(String format)
Sets column structure according to Apache Log Format specification.

Parameters:
format -

setFirstLineContainsColumnNames

void setFirstLineContainsColumnNames(boolean contains)
Determines whether first call to AQDataReader.readNextRow() should return column names set previously by setLogFormat(String). This call has no effect on subsequent calls to AQDataReader.readNextRow().

Parameters:
contains -

read

AQDataSet read()
               throws Exception
Sequentially reads the input log into an in-memory data set. Unless the column structure has been set earlier by calling setLogFormat(String) method, a new column structure is created with text columns named C1, C2, C3, ...

Specified by:
read in interface AQDataReader
Throws:
Exception - On Error.

OpenAPI 1.0


Copyright © 2010 AquaFold, Inc. All Rights Reserved. Use is subject to license terms.