Setting Options for the XML Class : Comments and Processing Instructions « XML « Flash / Flex / ActionScript






Setting Options for the XML Class

 

//ignoreWhitespace 
//ignoreComments 
//ignoreProcessingInstructions 
//prettyPrinting 
//prettyIndent 
//ignoreWhitespace


package{
  import flash.display.Sprite;
  
  public class Main extends Sprite{
    public function Main(){

        trace(XML.settings().ignoreProcessingInstructions); // Displays: true
        XML.ignoreProcessingInstructions = false;
        trace(XML.settings().ignoreProcessingInstructions); // Displays: false

    }
  }
}

        








Related examples in the same category

1.Accessing Comments and Processing Instructions
2.To obtain an XMLList representing all comments and processing instructions within an entire XML tree
3.Search for elements only while ignoring text nodes, comments, and processing directives, use elements()
4.Finding Node Types: element, attribute, text, comment, processing-instruction
5.Converting Comments and Processing-Instructions to Strings
6.use the comments() method or the processingInstructions() method to get XMLLists