/parser/html/nsHtml5StackNode.h

http://github.com/zpao/v8monkey · C Header · 103 lines · 65 code · 12 blank · 26 comment · 0 complexity · 81c922323a81daa6d3b797593efed880 MD5 · raw file

  1. /*
  2. * Copyright (c) 2007 Henri Sivonen
  3. * Copyright (c) 2007-2011 Mozilla Foundation
  4. *
  5. * Permission is hereby granted, free of charge, to any person obtaining a
  6. * copy of this software and associated documentation files (the "Software"),
  7. * to deal in the Software without restriction, including without limitation
  8. * the rights to use, copy, modify, merge, publish, distribute, sublicense,
  9. * and/or sell copies of the Software, and to permit persons to whom the
  10. * Software is furnished to do so, subject to the following conditions:
  11. *
  12. * The above copyright notice and this permission notice shall be included in
  13. * all copies or substantial portions of the Software.
  14. *
  15. * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  16. * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  17. * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
  18. * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  19. * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
  20. * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
  21. * DEALINGS IN THE SOFTWARE.
  22. */
  23. /*
  24. * THIS IS A GENERATED FILE. PLEASE DO NOT EDIT.
  25. * Please edit StackNode.java instead and regenerate.
  26. */
  27. #ifndef nsHtml5StackNode_h__
  28. #define nsHtml5StackNode_h__
  29. #include "prtypes.h"
  30. #include "nsIAtom.h"
  31. #include "nsHtml5AtomTable.h"
  32. #include "nsString.h"
  33. #include "nsINameSpaceManager.h"
  34. #include "nsIContent.h"
  35. #include "nsTraceRefcnt.h"
  36. #include "jArray.h"
  37. #include "nsHtml5ArrayCopy.h"
  38. #include "nsAHtml5TreeBuilderState.h"
  39. #include "nsHtml5Atoms.h"
  40. #include "nsHtml5ByteReadable.h"
  41. #include "nsIUnicodeDecoder.h"
  42. #include "nsHtml5Macros.h"
  43. class nsHtml5StreamParser;
  44. class nsHtml5Tokenizer;
  45. class nsHtml5TreeBuilder;
  46. class nsHtml5MetaScanner;
  47. class nsHtml5AttributeName;
  48. class nsHtml5ElementName;
  49. class nsHtml5HtmlAttributes;
  50. class nsHtml5UTF16Buffer;
  51. class nsHtml5StateSnapshot;
  52. class nsHtml5Portability;
  53. class nsHtml5StackNode
  54. {
  55. public:
  56. PRInt32 flags;
  57. nsIAtom* name;
  58. nsIAtom* popName;
  59. PRInt32 ns;
  60. nsIContent** node;
  61. nsHtml5HtmlAttributes* attributes;
  62. private:
  63. PRInt32 refcount;
  64. public:
  65. inline PRInt32 getFlags()
  66. {
  67. return flags;
  68. }
  69. PRInt32 getGroup();
  70. bool isScoping();
  71. bool isSpecial();
  72. bool isFosterParenting();
  73. bool isHtmlIntegrationPoint();
  74. nsHtml5StackNode(PRInt32 flags, PRInt32 ns, nsIAtom* name, nsIContent** node, nsIAtom* popName, nsHtml5HtmlAttributes* attributes);
  75. nsHtml5StackNode(nsHtml5ElementName* elementName, nsIContent** node);
  76. nsHtml5StackNode(nsHtml5ElementName* elementName, nsIContent** node, nsHtml5HtmlAttributes* attributes);
  77. nsHtml5StackNode(nsHtml5ElementName* elementName, nsIContent** node, nsIAtom* popName);
  78. nsHtml5StackNode(nsHtml5ElementName* elementName, nsIAtom* popName, nsIContent** node);
  79. nsHtml5StackNode(nsHtml5ElementName* elementName, nsIContent** node, nsIAtom* popName, bool markAsIntegrationPoint);
  80. private:
  81. static PRInt32 prepareSvgFlags(PRInt32 flags);
  82. static PRInt32 prepareMathFlags(PRInt32 flags, bool markAsIntegrationPoint);
  83. public:
  84. ~nsHtml5StackNode();
  85. void dropAttributes();
  86. void retain();
  87. void release();
  88. static void initializeStatics();
  89. static void releaseStatics();
  90. };
  91. #endif