public class HarPostDataParam extends AbstractNameValueComment
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
TABLE_NAME
Database table name where the data is stored
|
Constructor and Description |
---|
HarPostDataParam(HarDatabaseConfig config,
long postDataParamId,
java.lang.String name,
java.lang.String value,
java.lang.String fileName,
java.lang.String contentType,
java.lang.String comment)
Creates a new
HarPostDataParam object from the database |
HarPostDataParam(org.codehaus.jackson.JsonParser jp,
java.util.List<HarWarning> warnings)
Creates a new
HarHeader object from a JsonParser already
positioned at the beginning of the element content |
HarPostDataParam(java.lang.String name,
java.lang.String value)
Creates a new
HarPostDataParam object with the mandatory
fields |
HarPostDataParam(java.lang.String name,
java.lang.String value,
java.lang.String fileName,
java.lang.String contentType,
java.lang.String comment)
Creates a new
HarPostDataParam object |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getContentType()
Returns the contentType value.
|
HarCustomFields |
getCustomFields()
Returns the customFields value.
|
java.lang.String |
getFileName()
Returns the fileName value.
|
void |
setContentType(java.lang.String contentType)
Sets the contentType value.
|
void |
setCustomFields(HarCustomFields customFields)
Sets the customFields value.
|
void |
setFileName(java.lang.String fileName)
Sets the fileName value.
|
java.lang.String |
toString() |
void |
writeHar(org.codehaus.jackson.JsonGenerator g)
Write this object on a JsonGenerator stream
|
void |
writeJDBC(HarDatabaseConfig config,
long id,
java.sql.PreparedStatement ps,
long logId)
Write this object in the given database referencing the specified id.
|
getComment, getName, getValue, setComment, setName, setValue
public static java.lang.String TABLE_NAME
public HarPostDataParam(java.lang.String name, java.lang.String value, java.lang.String fileName, java.lang.String contentType, java.lang.String comment)
HarPostDataParam
objectname
- name [string] - name of a posted parameter.value
- value [string, optional] - value of a posted parameter or
content of a posted file.fileName
- fileName [string, optional] - name of a posted file.contentType
- contentType [string, optional] - content type of a
posted file.comment
- comment [string, optional] (new in 1.2) - A comment provided
by the user or the application.public HarPostDataParam(HarDatabaseConfig config, long postDataParamId, java.lang.String name, java.lang.String value, java.lang.String fileName, java.lang.String contentType, java.lang.String comment) throws java.sql.SQLException
HarPostDataParam
object from the databaseconfig
- postDataParamId
- name
- value
- fileName
- contentType
- comment
- java.sql.SQLException
public HarPostDataParam(java.lang.String name, java.lang.String value)
HarPostDataParam
object with the mandatory
fieldsname
- name [string] - name of a posted parameter.value
- value [string, optional] - value of a posted parameter or
content of a posted file.public HarPostDataParam(org.codehaus.jackson.JsonParser jp, java.util.List<HarWarning> warnings) throws org.codehaus.jackson.JsonParseException, java.io.IOException
HarHeader
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.JsonParseException
java.io.IOException
public void writeHar(org.codehaus.jackson.JsonGenerator g) throws org.codehaus.jackson.JsonGenerationException, java.io.IOException
writeHar
in class AbstractNameValueComment
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(HarDatabaseConfig config, long id, java.sql.PreparedStatement ps, long logId) throws java.sql.SQLException
writeJDBC
in class AbstractNameValueComment
id
- the id this object refers tops
- PreparedStatement to write datajava.sql.SQLException
- if a database access error occurspublic java.lang.String getFileName()
public void setFileName(java.lang.String fileName)
fileName
- The fileName to set.public java.lang.String getContentType()
public void setContentType(java.lang.String contentType)
contentType
- The contentType to set.public HarCustomFields getCustomFields()
public void setCustomFields(HarCustomFields customFields)
customFields
- The customFields to set.public java.lang.String toString()
toString
in class AbstractNameValueComment
AbstractNameValueComment.toString()
Copyright © 2011 Emmanuel Cecchet - University of Massachusetts - All Rights Reserved.