Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions
nsIParserNode Class Reference

Parser nodes are the unit of exchange between the parser and the content sink. More...

#include <nsIParserNode.h>

Inheritance diagram for nsIParserNode:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual const nsAString & GetTagName () const =0
 Retrieve the name of the node gess5/11/98.
virtual const nsAString & GetText () const =0
 Retrieve the text from the given node gess5/11/98.
virtual PRInt32 GetNodeType () const =0
 Retrieve the type of the parser node.
virtual PRInt32 GetTokenType () const =0
 Retrieve token type of parser node gess5/11/98.
virtual PRInt32 GetAttributeCount (PRBool askToken=PR_FALSE) const =0
 Retrieve the number of attributes in this node.
virtual const nsAString & GetKeyAt (PRUint32 anIndex) const =0
 Retrieve the key (of key/value pair) at given index gess5/11/98.
virtual const nsAString & GetValueAt (PRUint32 anIndex) const =0
 Retrieve the value (of key/value pair) at given index gess5/11/98.
virtual PRInt32 TranslateToUnicodeStr (nsString &aString) const =0
 NOTE: When the node is an entity, this will translate the entity to it's unicode value, and store it in aString.
virtual void AddAttribute (CToken *aToken)=0
virtual PRInt32 GetSourceLineNumber (void) const =0
 This getter retrieves the line number from the input source where the token occured.
virtual PRBool GetGenericState (void) const =0
 This pair of methods allows us to set a generic bit (for arbitrary use) on each node stored in the context.
virtual void SetGenericState (PRBool aState)=0
virtual void GetSource (nsString &aString)=0
 Retrieve a string containing the tag and its attributes in "source" form rickg 06June2000.
virtual nsresult ReleaseAll ()=0
 Release all the objects you're holding harishd 08/02/00.

Detailed Description

Parser nodes are the unit of exchange between the parser and the content sink.

Nodes offer access to the current token, its attributes, and its skipped- content if applicable.

gess 3/25/98

Definition at line 82 of file nsIParserNode.h.


Member Function Documentation

virtual void nsIParserNode::AddAttribute ( CToken aToken) [pure virtual]

Implemented in nsCParserStartNode, and nsCParserNode.

Here is the caller graph for this function:

virtual PRInt32 nsIParserNode::GetAttributeCount ( PRBool  askToken = PR_FALSE) const [pure virtual]

Retrieve the number of attributes in this node.

gess5/11/98

Returns:
count of attributes (may be 0)

Implemented in nsCParserStartNode, and nsCParserNode.

Here is the caller graph for this function:

virtual PRBool nsIParserNode::GetGenericState ( void  ) const [pure virtual]

This pair of methods allows us to set a generic bit (for arbitrary use) on each node stored in the context.

gess 11May2000

Implemented in nsCParserNode.

Here is the caller graph for this function:

virtual const nsAString& nsIParserNode::GetKeyAt ( PRUint32  anIndex) const [pure virtual]

Retrieve the key (of key/value pair) at given index gess5/11/98.

Parameters:
anIndexis the index of the key you want
Returns:
string containing key.

Implemented in nsCParserStartNode, and nsCParserNode.

Here is the caller graph for this function:

virtual PRInt32 nsIParserNode::GetNodeType ( ) const [pure virtual]

Retrieve the type of the parser node.

gess5/11/98

Returns:
node type.

Implemented in nsCParserNode.

Here is the caller graph for this function:

virtual void nsIParserNode::GetSource ( nsString aString) [pure virtual]

Retrieve a string containing the tag and its attributes in "source" form rickg 06June2000.

Returns:
void

Implemented in nsCParserStartNode, and nsCParserNode.

virtual PRInt32 nsIParserNode::GetSourceLineNumber ( void  ) const [pure virtual]

This getter retrieves the line number from the input source where the token occured.

Lines are interpreted as occuring between
characters. gess7/24/98

Returns:
int containing the line number the token was found on

Implemented in nsCParserNode.

virtual const nsAString& nsIParserNode::GetTagName ( ) const [pure virtual]

Retrieve the name of the node gess5/11/98.

Returns:
string containing node name

Implemented in nsCParserNode.

virtual const nsAString& nsIParserNode::GetText ( ) const [pure virtual]

Retrieve the text from the given node gess5/11/98.

Returns:
string containing node text

Implemented in nsCParserNode.

Here is the caller graph for this function:

virtual PRInt32 nsIParserNode::GetTokenType ( ) const [pure virtual]

Retrieve token type of parser node gess5/11/98.

Returns:
token type

Implemented in nsCParserNode.

Here is the caller graph for this function:

virtual const nsAString& nsIParserNode::GetValueAt ( PRUint32  anIndex) const [pure virtual]

Retrieve the value (of key/value pair) at given index gess5/11/98.

Parameters:
anIndexis the index of the value you want
Returns:
string containing value.

Implemented in nsCParserStartNode, and nsCParserNode.

Here is the caller graph for this function:

virtual nsresult nsIParserNode::ReleaseAll ( ) [pure virtual]

Release all the objects you're holding harishd 08/02/00.

Returns:
void

Implemented in nsCParserStartNode, and nsCParserNode.

virtual void nsIParserNode::SetGenericState ( PRBool  aState) [pure virtual]

Implemented in nsCParserNode.

Here is the caller graph for this function:

virtual PRInt32 nsIParserNode::TranslateToUnicodeStr ( nsString aString) const [pure virtual]

NOTE: When the node is an entity, this will translate the entity to it's unicode value, and store it in aString.

gess5/11/98

Parameters:
aStringwill contain the resulting unicode string value
Returns:
int (unicode char or unicode index from table)

Implemented in nsCParserNode.

Here is the caller graph for this function:


The documentation for this class was generated from the following file: