Sage Intacct SDK for PHP
XMLWriter Class Reference
Inheritance diagram for XMLWriter:

Public Member Functions

 startElement ($name)
 
 writeElement ($name, $content=null, $writeNull=false)
 
 writeElementDate ($name, $date=null, $format=self::IA_DATE_FORMAT, $writeNull=false)
 
 writeElementDateTime ($name, $date=null, $format=self::IA_DATETIME_FORMAT, $writeNull=false)
 
 writeDateSplitElements (\DateTime $date, $writeNull=true)
 
 writeAttribute ($name, $value, $writeNull=true)
 

Data Fields

const IA_DATE_FORMAT = 'm/d/Y'
 
const IA_DATETIME_FORMAT = 'm/d/Y H:i:s'
 
const IA_MULTI_SELECT_GLUE = '#~#'
 

Protected Member Functions

 isValidXmlName (string $name)
 

Member Function Documentation

◆ isValidXmlName()

isValidXmlName ( string  $name)
protected
Parameters
string$name
Returns
bool

◆ startElement()

startElement (   $name)

◆ writeAttribute()

writeAttribute (   $name,
  $value,
  $writeNull = true 
)

Write full attribute

Parameters
string$name
string$value
bool$writeNull
Returns
bool

◆ writeDateSplitElements()

writeDateSplitElements ( \DateTime  $date,
  $writeNull = true 
)

Write full element date tags

Parameters
\DateTime$date
bool$writeNull
Returns
bool

◆ writeElement()

writeElement (   $name,
  $content = null,
  $writeNull = false 
)

Write full element tag

Parameters
string$name
mixed$content
bool$writeNull
Returns
bool

◆ writeElementDate()

writeElementDate (   $name,
  $date = null,
  $format = self::IA_DATE_FORMAT,
  $writeNull = false 
)

◆ writeElementDateTime()

writeElementDateTime (   $name,
  $date = null,
  $format = self::IA_DATETIME_FORMAT,
  $writeNull = false 
)

Field Documentation

◆ IA_DATE_FORMAT

const IA_DATE_FORMAT = 'm/d/Y'

◆ IA_DATETIME_FORMAT

const IA_DATETIME_FORMAT = 'm/d/Y H:i:s'

◆ IA_MULTI_SELECT_GLUE

const IA_MULTI_SELECT_GLUE = '#~#'