com.HttpPart methods

Methods for the com.HttpPart class.

Table 1. Class methods of com.HttpPart
Name Description
CreateAttachment(
   filename STRING )
  RETURNS com.HttpPart
Creates a new HttpPart object based on a given filename located on disk.
CreateFromData(
   b BYTE )
  RETURNS com.HttpPart
Creates a new HttpPart object based on given BYTE located in memory.
CreateFromDomDocument(
   doc xml.DomDocument )
  RETURNS com.HttpPart
Creates a new HttpPart object based on given XML document.
CreateFromString(
   str STRING )
  RETURNS com.HttpPart
Creates a new HttpPart object based on given string.
Table 2. Object methods of com.HttpPart
Name Description
clearHeaders()
Remove all headers from the HTTP part.
getAttachment()
  RETURNS STRING
Returns the absolute path to the HTTP part.
getContentAsData(
   b BYTE )
Returns the HTTP part as a BYTE.
getContentAsDomDocument()
  RETURNS xml.DomDocument
Returns the HTTP part as an XML document.
getHeader(
   name STRING )
  RETURNS STRING
Returns a named HTTP multipart header as a string.
getHeaderCount()
  RETURNS INTEGER
Retrieve the number of headers for the current HTTP part.
getHeaderName(
   pos INTEGER )
  RETURNS STRING
Retrieve the name of an HTTP multipart header as a string, where the multipart header is specified by its position.
getHeaderValue(
   pos INTEGER )
  RETURNS STRING
Retrieve the value of an HTTP multipart header as a string, where the multipart header is specified by its position.
getContentAsString()
  RETURNS STRING
Returns the HTTP part as a string.
removeHeader(
   name STRING )
Remove the header of given name from the current HttpPart object.
setHeader(
   name STRING,
   value STRING )
Sets a named HTTP multipart header using a string value.