Logo Search packages:      
Sourcecode: xulrunner-1.9 version File versions  Download package

nsIContent Class Reference

#include <nsIContent.h>

Inheritance diagram for nsIContent:

nsINode nsISupports nsGenericElement nsTextNode nsAttributeTextNode nsGenConImageContent nsGenericHTMLElement nsGenericHTMLFormElement nsGenericHTMLFrameElement nsHTMLOptGroupElement nsHTMLOptionElement nsHTMLSelectElement

List of all members.


Detailed Description

A node of content in a document's content model. This interface is supported by all content objects.

Definition at line 72 of file nsIContent.h.


Public Types

enum  { ATTR_MISSING = -1, ATTR_VALUE_NO_MATCH = -2 }
enum  {
  IME_STATUS_NONE = 0x0000, IME_STATUS_ENABLE = 0x0001, IME_STATUS_DISABLE = 0x0002, IME_STATUS_PASSWORD = 0x0004,
  IME_STATUS_OPEN = 0x0008, IME_STATUS_CLOSE = 0x0010
}
enum  { IME_STATUS_MASK_ENABLED, IME_STATUS_MASK_OPENED = IME_STATUS_OPEN | IME_STATUS_CLOSE }
enum  {
  eCONTENT = 1 << 0, eDOCUMENT = 1 << 1, eATTRIBUTE = 1 << 2, eELEMENT = 1 << 3,
  eTEXT = 1 << 4, ePROCESSING_INSTRUCTION = 1 << 5, eCOMMENT = 1 << 6, eHTML = 1 << 7,
  eHTML_FORM_CONTROL = 1 << 8, eXUL = 1 << 9, eSVG = 1 << 10, eDOCUMENT_FRAGMENT = 1 << 11,
  eDATA_NODE = 1 << 12, eMATHML = 1 << 13
}
typedef nsIAtom *const *const AttrValuesArray
enum  ETabFocusType { eTabFocus_formElementsMask = (1<<1), eTabFocus_linksMask = (1<<2), eTabFocus_any = 1 + (1<<1) + (1<<2) }

Public Member Functions

virtual nsresult AddEventListenerByIID (nsIDOMEventListener *aListener, const nsIID &aIID)=0
virtual void AddMutationObserver (nsIMutationObserver *aMutationObserver)
nsresult AppendChildTo (nsIContent *aKid, PRBool aNotify)
virtual nsresult AppendText (const PRUnichar *aBuffer, PRUint32 aLength, PRBool aNotify)=0
virtual void AppendTextTo (nsAString &aResult)=0
virtual PRBool AttrValueIs (PRInt32 aNameSpaceID, nsIAtom *aName, nsIAtom *aValue, nsCaseTreatment aCaseSensitive) const
virtual PRBool AttrValueIs (PRInt32 aNameSpaceID, nsIAtom *aName, const nsAString &aValue, nsCaseTreatment aCaseSensitive) const
virtual void BeginAddingChildren ()
virtual nsresult BindToTree (nsIDocument *aDocument, nsIContent *aParent, nsIContent *aBindingParent, PRBool aCompileEventHandlers)=0
virtual nsresult Clone (nsINodeInfo *aNodeInfo, nsINode **aResult) const =0
virtual nsresult DeleteProperty (PRUint16 aCategory, nsIAtom *aPropertyName)
nsresult DeleteProperty (nsIAtom *aPropertyName)
virtual void DestroyContent ()=0
virtual nsresult DispatchDOMEvent (nsEvent *aEvent, nsIDOMEvent *aDOMEvent, nsPresContext *aPresContext, nsEventStatus *aEventStatus)=0
virtual nsresult DoneAddingChildren (PRBool aHaveNotified)
virtual void DoneCreatingElement ()
virtual PRInt32 FindAttrValueIn (PRInt32 aNameSpaceID, nsIAtom *aName, AttrValuesArray *aValues, nsCaseTreatment aCaseSensitive) const
virtual nsIContentFindFirstNonNativeAnonymous () const
virtual PRBool GetAttr (PRInt32 aNameSpaceID, nsIAtom *aName, nsAString &aResult) const =0
virtual PRUint32 GetAttrCount () const =0
virtual nsChangeHint GetAttributeChangeHint (const nsIAtom *aAttribute, PRInt32 aModType) const =0
virtual const nsAttrName * GetAttrNameAt (PRUint32 aIndex) const =0
virtual already_AddRefed< nsIURI > GetBaseURI () const =0
virtual nsIContentGetBindingParent () const =0
virtual nsIContentGetChildAt (PRUint32 aIndex) const =0
virtual PRUint32 GetChildCount () const =0
virtual nsIAtom * GetClassAttributeName () const =0
virtual const nsAttrValue * GetClasses () const =0
nsIDocument * GetCurrentDoc () const
virtual PRUint32 GetDesiredIMEState ()
nsIDocument * GetDocument () const
virtual already_AddRefed
< nsINodeInfo > 
GetExistingAttrNameFromQName (const nsAString &aStr) const =0
PtrBits GetFlags () const
virtual nsIAtom * GetID () const =0
virtual nsIAtom * GetIDAttributeName () const =0
virtual nsICSSStyleRule * GetInlineStyleRule ()=0
virtual nsresult GetListenerManager (PRBool aCreateIfNotFound, nsIEventListenerManager **aResult)=0
PRInt32 GetNameSpaceID () const
nsINodeGetNodeParent () const
nsIDocument * GetOwnerDoc () const
nsIContentGetParent () const
virtual void * GetProperty (PRUint16 aCategory, nsIAtom *aPropertyName, nsresult *aStatus=nsnull) const
void * GetProperty (nsIAtom *aPropertyName, nsresult *aStatus=nsnull) const
virtual PRUint32 GetScriptTypeID () const
nsIContentGetSelectionRootContent (nsIPresShell *aPresShell)
virtual nsresult GetSystemEventGroup (nsIDOMEventGroup **aGroup)=0
virtual nsPIDOMEventTarget * GetTargetForDOMEvent ()
virtual nsPIDOMEventTarget * GetTargetForEventTargetChain ()
virtual const nsTextFragmentGetText ()=0
nsIContentGetTextEditorRootContent (nsIEditor **aEditor=nsnull)
virtual PRBool HasAttr (PRInt32 aNameSpaceID, nsIAtom *aName) const =0
PRBool HasFlag (PtrBits aFlag) const
PRBool HasProperties () const
PRBool HasSameOwnerDoc (nsINode *aOther)
virtual PRInt32 IndexOf (nsINode *aPossibleChild) const =0
virtual nsresult InsertChildAt (nsIContent *aKid, PRUint32 aIndex, PRBool aNotify)=0
virtual PRInt32 IntrinsicState () const
virtual PRBool IsDoneAddingChildren ()
PRBool IsEditable () const
virtual PRBool IsFocusable (PRInt32 *aTabIndex=nsnull)
PRBool IsInDoc () const
PRBool IsInNativeAnonymousSubtree () const
virtual PRBool IsLink (nsIURI **aURI) const =0
PRBool IsNativeAnonymous () const
virtual PRBool IsNodeOfType (PRUint32 aFlags) const =0
virtual nsresult MaybeTriggerAutoLink (nsIDocShell *aShell)
virtual PRBool MayHaveFrame () const
nsINodeInfo * NodeInfo () const
nsIPrincipalNodePrincipal () const
 NS_IMETHOD_ (PRBool) IsAttributeMapped(const nsIAtom *aAttribute) const =0
virtual void PerformAccesskey (PRBool aKeyCausesActivation, PRBool aIsTrustedEvent)
virtual nsresult PostHandleEvent (nsEventChainPostVisitor &aVisitor)=0
virtual nsresult PreHandleEvent (nsEventChainPreVisitor &aVisitor)=0
virtual nsresult RemoveChildAt (PRUint32 aIndex, PRBool aNotify)=0
virtual nsresult RemoveEventListenerByIID (nsIDOMEventListener *aListener, const nsIID &aIID)=0
virtual void RemoveFocus (nsPresContext *aPresContext)
virtual void RemoveMutationObserver (nsIMutationObserver *aMutationObserver)
virtual void SaveSubtreeState ()=0
virtual nsresult SetAttr (PRInt32 aNameSpaceID, nsIAtom *aName, nsIAtom *aPrefix, const nsAString &aValue, PRBool aNotify)=0
nsresult SetAttr (PRInt32 aNameSpaceID, nsIAtom *aName, const nsAString &aValue, PRBool aNotify)
void SetEditableFlag (PRBool aEditable)
void SetFlags (PtrBits aFlagsToSet)
virtual void SetFocus (nsPresContext *aPresContext)
NS_IMETHOD SetInlineStyleRule (nsICSSStyleRule *aStyleRule, PRBool aNotify)=0
virtual void SetMayHaveFrame (PRBool aMayHaveFrame)
void SetNativeAnonymous ()
virtual nsresult SetProperty (PRUint16 aCategory, nsIAtom *aPropertyName, void *aValue, NSPropertyDtorFunc aDtor=nsnull, PRBool aTransfer=PR_FALSE, void **aOldValue=nsnull)
nsresult SetProperty (nsIAtom *aPropertyName, void *aValue, NSPropertyDtorFunc aDtor=nsnull, PRBool aTransfer=PR_FALSE)
virtual nsresult SetScriptTypeID (PRUint32 aLang)
nsresult SetText (const nsAString &aStr, PRBool aNotify)
virtual nsresult SetText (const PRUnichar *aBuffer, PRUint32 aLength, PRBool aNotify)=0
nsIAtom * Tag () const
virtual PRBool TextIsOnlyWhitespace ()=0
virtual PRUint32 TextLength ()=0
virtual void UnbindFromTree (PRBool aDeep=PR_TRUE, PRBool aNullParent=PR_TRUE)=0
virtual nsresult UnsetAttr (PRInt32 aNameSpaceID, nsIAtom *aAttr, PRBool aNotify)=0
void UnsetFlags (PtrBits aFlagsToUnset)
virtual void * UnsetProperty (PRUint16 aCategory, nsIAtom *aPropertyName, nsresult *aStatus=nsnull)
void * UnsetProperty (nsIAtom *aPropertyName, nsresult *aStatus=nsnull)
virtual void UpdateEditableState ()
NS_IMETHOD WalkContentStyleRules (nsRuleWalker *aRuleWalker)=0
virtual nsresult WillHandleEvent (nsEventChainPostVisitor &aVisitor)
Methods
 NS_IMETHOD_ (nsrefcnt) AddRef(void)=0
NS_IMETHOD QueryInterface (REFNSIID aIID, void **aInstancePtr)=0

Static Public Attributes

static PRInt32 sTabFocusModel = eTabFocus_any
static PRBool sTabFocusModelAppliesToXUL = PR_FALSE

Protected Types

enum  { PARENT_BIT_INDOCUMENT = 1 << 0, PARENT_BIT_PARENT_IS_CONTENT = 1 << 1 }
enum  { kParentBitMask = 0x3 }

Protected Member Functions

virtual nsINode::nsSlots * CreateSlots ()
nsSlots * FlagsAsSlots () const
nsSlots * GetExistingSlots () const
nsTObserverArray
< nsIMutationObserver * > * 
GetMutationObservers ()
nsSlots * GetSlots ()
PRBool HasSlots () const
virtual PRBool IsEditableExternal () const
PRBool IsEditableInternal () const

Protected Attributes

PtrBits mFlagsOrSlots
nsCOMPtr< nsINodeInfo > mNodeInfo
PtrBits mParentPtrBits

Friends

class nsNodeSupportsWeakRefTearoff
class nsNodeUtils
class nsNodeWeakReference

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

Generated by  Doxygen 1.6.0   Back to index