public class HarEntryTimings
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
TABLE_NAME
Database table name where the data is stored
|
| Constructor and Description |
|---|
HarEntryTimings(HarDatabaseConfig config,
long entryId)
Creates a new
HarEntryTimings object from a database. |
HarEntryTimings(org.codehaus.jackson.JsonParser jp,
java.util.List<HarWarning> warnings)
Creates a new
HarEntryTimings object from a JsonParser already
positioned at the beginning of the element content |
HarEntryTimings(long send,
long wait,
long receive)
Creates a new
HarEntryTimings object with mandatory fields |
HarEntryTimings(long blocked,
long dns,
long connect,
long send,
long wait,
long receive,
long ssl,
java.lang.String comment)
Creates a new
HarEntryTimings object |
| Modifier and Type | Method and Description |
|---|---|
void |
deleteFromJDBC(HarDatabaseConfig config,
long logId)
Delete objects in the database referencing the specified logId.
|
long |
getBlocked()
Returns the blocked value.
|
java.lang.String |
getComment()
Returns the comment value.
|
long |
getConnect()
Returns the connect value.
|
HarCustomFields |
getCustomFields()
Returns the customFields value.
|
long |
getDns()
Returns the dns value.
|
long |
getReceive()
Returns the receive value.
|
long |
getSend()
Returns the send value.
|
long |
getSsl()
Returns the ssl value.
|
long |
getWait()
Returns the wait value.
|
void |
setBlocked(long blocked)
Sets the blocked value.
|
void |
setComment(java.lang.String comment)
Sets the comment value.
|
void |
setConnect(long connect)
Sets the connect value.
|
void |
setCustomFields(HarCustomFields customFields)
Sets the customFields value.
|
void |
setDns(long dns)
Sets the dns value.
|
void |
setReceive(long receive)
Sets the receive value.
|
void |
setSend(long send)
Sets the send value.
|
void |
setSsl(long ssl)
Sets the ssl value.
|
void |
setWait(long wait)
Sets the wait value.
|
java.lang.String |
toString() |
void |
writeHar(org.codehaus.jackson.JsonGenerator g)
Write this object on a JsonGenerator stream
|
void |
writeJDBC(long entryId,
HarDatabaseConfig config,
long logId)
Write this object to a database according to the given configuration
|
public static java.lang.String TABLE_NAME
public HarEntryTimings(long blocked,
long dns,
long connect,
long send,
long wait,
long receive,
long ssl,
java.lang.String comment)
HarEntryTimings objectblocked - blocked [number, optional] - Time spent in a queue waiting
for a network connection. Use -1 if the timing does not apply to
the current request.dns - dns [number, optional] - DNS resolution time. The time required
to resolve a host name. Use -1 if the timing does not apply to the
current request.connect - connect [number, optional] - Time required to create TCP
connection. Use -1 if the timing does not apply to the current
request.send - send [number] - Time required to send HTTP request to the
server.wait - wait [number] - Waiting for a response from the server.receive - receive [number] - Time required to read entire response
from the server (or cache).ssl - ssl [number, optional] (new in 1.2) - Time required for SSL/TLS
negotiation. If this field is defined then the time is also
included in the connect field (to ensure backward compatibility
with HAR 1.1). Use -1 if the timing does not apply to the current
request.comment - comment [string, optional] (new in 1.2) - A comment provided
by the user or the application.public HarEntryTimings(long send,
long wait,
long receive)
HarEntryTimings object with mandatory fieldssend - send [number] - Time required to send HTTP request to the
server.wait - wait [number] - Waiting for a response from the server.receive - receive [number] - Time required to read entire response
from the server (or cache).public HarEntryTimings(org.codehaus.jackson.JsonParser jp,
java.util.List<HarWarning> warnings)
throws org.codehaus.jackson.JsonParseException,
java.io.IOException
HarEntryTimings object from a JsonParser already
positioned at the beginning of the element contentjp - a JsonParser already positioned at the beginning of the element
contentwarnings - null if parser should fail on first error, pointer to
warning list if warnings can be issued for missing fieldsorg.codehaus.jackson.JsonParseExceptionjava.io.IOExceptionpublic HarEntryTimings(HarDatabaseConfig config, long entryId) throws java.sql.SQLException
HarEntryTimings object from a database.
Retrieves the HarEntryTimings objects that corresponds to the specified
entry id.config - the database configuration to useentryId - the entry id to readjava.sql.SQLException - if a database error occurspublic void writeHar(org.codehaus.jackson.JsonGenerator g)
throws org.codehaus.jackson.JsonGenerationException,
java.io.IOException
g - a JsonGeneratorjava.io.IOException - if an IO error occursorg.codehaus.jackson.JsonGenerationException - if the generator failsHarFileWriter.writeHarFile(HarLog, java.io.File)public void writeJDBC(long entryId,
HarDatabaseConfig config,
long logId)
throws java.sql.SQLException
entryId - the entry id this object refers toconfig - the database configuration to usejava.sql.SQLException - if a database error occurspublic void deleteFromJDBC(HarDatabaseConfig config, long logId) throws java.sql.SQLException
logId - the logId this object refers toconfig - the database configurationjava.sql.SQLException - if a database access error occurspublic long getBlocked()
public void setBlocked(long blocked)
blocked - The blocked to set.public long getDns()
public void setDns(long dns)
dns - The dns to set.public long getConnect()
public void setConnect(long connect)
connect - The connect to set.public long getSend()
public void setSend(long send)
send - The send to set.public long getWait()
public void setWait(long wait)
wait - The wait to set.public long getReceive()
public void setReceive(long receive)
receive - The receive to set.public long getSsl()
public void setSsl(long ssl)
ssl - The ssl to set.public java.lang.String getComment()
public void setComment(java.lang.String comment)
comment - The comment to set.public HarCustomFields getCustomFields()
public void setCustomFields(HarCustomFields customFields)
customFields - The customFields to set.public java.lang.String toString()
toString in class java.lang.ObjectObject.toString()Copyright © 2011 Emmanuel Cecchet - University of Massachusetts - All Rights Reserved.