WebCore/generated/MathMLNames.cpp
changeset 0 4f2f89ce4247
equal deleted inserted replaced
-1:000000000000 0:4f2f89ce4247
       
     1 /*
       
     2  * THIS FILE WAS AUTOMATICALLY GENERATED, DO NOT EDIT.
       
     3  *
       
     4  * This file was generated by the dom/make_names.pl script.
       
     5  *
       
     6  * Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc.  All rights reserved.
       
     7  *
       
     8  * Redistribution and use in source and binary forms, with or without
       
     9  * modification, are permitted provided that the following conditions
       
    10  * are met:
       
    11  * 1. Redistributions of source code must retain the above copyright
       
    12  *    notice, this list of conditions and the following disclaimer.
       
    13  * 2. Redistributions in binary form must reproduce the above copyright
       
    14  *    notice, this list of conditions and the following disclaimer in the
       
    15  *    documentation and/or other materials provided with the distribution.
       
    16  *
       
    17  * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY
       
    18  * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
       
    19  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
       
    20  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE COMPUTER, INC. OR
       
    21  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
       
    22  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
       
    23  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
       
    24  * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
       
    25  * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
       
    26  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
       
    27  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
       
    28  */
       
    29 
       
    30 #include "config.h"
       
    31 #ifdef SKIP_STATIC_CONSTRUCTORS_ON_GCC
       
    32 #define DOM_MathMLNAMES_HIDE_GLOBALS 1
       
    33 #else
       
    34 #define QNAME_DEFAULT_CONSTRUCTOR 1
       
    35 #endif
       
    36 
       
    37 #include "MathMLNames.h"
       
    38 
       
    39 #include <wtf/StaticConstructors.h>
       
    40 namespace WebCore {
       
    41 
       
    42  namespace MathMLNames {
       
    43 
       
    44 using namespace WebCore;
       
    45 
       
    46 DEFINE_GLOBAL(AtomicString, mathmlNamespaceURI, "http://www.w3.org/1998/Math/MathML")
       
    47 // Tags
       
    48 DEFINE_GLOBAL(QualifiedName, annotation_xmlTag, nullAtom, "annotation_xml", mathmlNamespaceURI);
       
    49 DEFINE_GLOBAL(QualifiedName, malignmarkTag, nullAtom, "malignmark", mathmlNamespaceURI);
       
    50 DEFINE_GLOBAL(QualifiedName, mathTag, nullAtom, "math", mathmlNamespaceURI);
       
    51 DEFINE_GLOBAL(QualifiedName, mfencedTag, nullAtom, "mfenced", mathmlNamespaceURI);
       
    52 DEFINE_GLOBAL(QualifiedName, mfracTag, nullAtom, "mfrac", mathmlNamespaceURI);
       
    53 DEFINE_GLOBAL(QualifiedName, mglyphTag, nullAtom, "mglyph", mathmlNamespaceURI);
       
    54 DEFINE_GLOBAL(QualifiedName, miTag, nullAtom, "mi", mathmlNamespaceURI);
       
    55 DEFINE_GLOBAL(QualifiedName, mnTag, nullAtom, "mn", mathmlNamespaceURI);
       
    56 DEFINE_GLOBAL(QualifiedName, moTag, nullAtom, "mo", mathmlNamespaceURI);
       
    57 DEFINE_GLOBAL(QualifiedName, moverTag, nullAtom, "mover", mathmlNamespaceURI);
       
    58 DEFINE_GLOBAL(QualifiedName, mrootTag, nullAtom, "mroot", mathmlNamespaceURI);
       
    59 DEFINE_GLOBAL(QualifiedName, mrowTag, nullAtom, "mrow", mathmlNamespaceURI);
       
    60 DEFINE_GLOBAL(QualifiedName, msTag, nullAtom, "ms", mathmlNamespaceURI);
       
    61 DEFINE_GLOBAL(QualifiedName, msqrtTag, nullAtom, "msqrt", mathmlNamespaceURI);
       
    62 DEFINE_GLOBAL(QualifiedName, msubTag, nullAtom, "msub", mathmlNamespaceURI);
       
    63 DEFINE_GLOBAL(QualifiedName, msubsupTag, nullAtom, "msubsup", mathmlNamespaceURI);
       
    64 DEFINE_GLOBAL(QualifiedName, msupTag, nullAtom, "msup", mathmlNamespaceURI);
       
    65 DEFINE_GLOBAL(QualifiedName, mtextTag, nullAtom, "mtext", mathmlNamespaceURI);
       
    66 DEFINE_GLOBAL(QualifiedName, munderTag, nullAtom, "munder", mathmlNamespaceURI);
       
    67 DEFINE_GLOBAL(QualifiedName, munderoverTag, nullAtom, "munderover", mathmlNamespaceURI);
       
    68 
       
    69 
       
    70 WebCore::QualifiedName** getMathMLTags(size_t* size)
       
    71 {
       
    72     static WebCore::QualifiedName* MathMLTags[] = {
       
    73         (WebCore::QualifiedName*)&annotation_xmlTag,
       
    74         (WebCore::QualifiedName*)&malignmarkTag,
       
    75         (WebCore::QualifiedName*)&mathTag,
       
    76         (WebCore::QualifiedName*)&mfencedTag,
       
    77         (WebCore::QualifiedName*)&mfracTag,
       
    78         (WebCore::QualifiedName*)&mglyphTag,
       
    79         (WebCore::QualifiedName*)&miTag,
       
    80         (WebCore::QualifiedName*)&mnTag,
       
    81         (WebCore::QualifiedName*)&moTag,
       
    82         (WebCore::QualifiedName*)&moverTag,
       
    83         (WebCore::QualifiedName*)&mrootTag,
       
    84         (WebCore::QualifiedName*)&mrowTag,
       
    85         (WebCore::QualifiedName*)&msTag,
       
    86         (WebCore::QualifiedName*)&msqrtTag,
       
    87         (WebCore::QualifiedName*)&msubTag,
       
    88         (WebCore::QualifiedName*)&msubsupTag,
       
    89         (WebCore::QualifiedName*)&msupTag,
       
    90         (WebCore::QualifiedName*)&mtextTag,
       
    91         (WebCore::QualifiedName*)&munderTag,
       
    92         (WebCore::QualifiedName*)&munderoverTag,
       
    93     };
       
    94     *size = 20;
       
    95     return MathMLTags;
       
    96 }
       
    97 
       
    98 // Attributes
       
    99 DEFINE_GLOBAL(QualifiedName, closeAttr, nullAtom, "close", mathmlNamespaceURI);
       
   100 DEFINE_GLOBAL(QualifiedName, denomalignAttr, nullAtom, "denomalign", mathmlNamespaceURI);
       
   101 DEFINE_GLOBAL(QualifiedName, linethicknessAttr, nullAtom, "linethickness", mathmlNamespaceURI);
       
   102 DEFINE_GLOBAL(QualifiedName, mathbackgroundAttr, nullAtom, "mathbackground", mathmlNamespaceURI);
       
   103 DEFINE_GLOBAL(QualifiedName, mathcolorAttr, nullAtom, "mathcolor", mathmlNamespaceURI);
       
   104 DEFINE_GLOBAL(QualifiedName, mathsizeAttr, nullAtom, "mathsize", mathmlNamespaceURI);
       
   105 DEFINE_GLOBAL(QualifiedName, numalignAttr, nullAtom, "numalign", mathmlNamespaceURI);
       
   106 DEFINE_GLOBAL(QualifiedName, openAttr, nullAtom, "open", mathmlNamespaceURI);
       
   107 DEFINE_GLOBAL(QualifiedName, separatorsAttr, nullAtom, "separators", mathmlNamespaceURI);
       
   108 DEFINE_GLOBAL(QualifiedName, stretchyAttr, nullAtom, "stretchy", mathmlNamespaceURI);
       
   109 
       
   110 
       
   111 WebCore::QualifiedName** getMathMLAttrs(size_t* size)
       
   112 {
       
   113     static WebCore::QualifiedName* MathMLAttr[] = {
       
   114         (WebCore::QualifiedName*)&closeAttr,
       
   115         (WebCore::QualifiedName*)&denomalignAttr,
       
   116         (WebCore::QualifiedName*)&linethicknessAttr,
       
   117         (WebCore::QualifiedName*)&mathbackgroundAttr,
       
   118         (WebCore::QualifiedName*)&mathcolorAttr,
       
   119         (WebCore::QualifiedName*)&mathsizeAttr,
       
   120         (WebCore::QualifiedName*)&numalignAttr,
       
   121         (WebCore::QualifiedName*)&openAttr,
       
   122         (WebCore::QualifiedName*)&separatorsAttr,
       
   123         (WebCore::QualifiedName*)&stretchyAttr,
       
   124     };
       
   125     *size = 10;
       
   126     return MathMLAttr;
       
   127 }
       
   128 
       
   129 void init()
       
   130 {
       
   131     static bool initialized = false;
       
   132     if (initialized)
       
   133         return;
       
   134     initialized = true;
       
   135     
       
   136     // Use placement new to initialize the globals.
       
   137     
       
   138     AtomicString::init();
       
   139     AtomicString mathmlNS("http://www.w3.org/1998/Math/MathML");
       
   140 
       
   141     // Namespace
       
   142     new ((void*)&mathmlNamespaceURI) AtomicString(mathmlNS);
       
   143 
       
   144     // Tags
       
   145     new ((void*)&annotation_xmlTag) QualifiedName(nullAtom, "annotation-xml", mathmlNS);
       
   146     new ((void*)&malignmarkTag) QualifiedName(nullAtom, "malignmark", mathmlNS);
       
   147     new ((void*)&mathTag) QualifiedName(nullAtom, "math", mathmlNS);
       
   148     new ((void*)&mfencedTag) QualifiedName(nullAtom, "mfenced", mathmlNS);
       
   149     new ((void*)&mfracTag) QualifiedName(nullAtom, "mfrac", mathmlNS);
       
   150     new ((void*)&mglyphTag) QualifiedName(nullAtom, "mglyph", mathmlNS);
       
   151     new ((void*)&miTag) QualifiedName(nullAtom, "mi", mathmlNS);
       
   152     new ((void*)&mnTag) QualifiedName(nullAtom, "mn", mathmlNS);
       
   153     new ((void*)&moTag) QualifiedName(nullAtom, "mo", mathmlNS);
       
   154     new ((void*)&moverTag) QualifiedName(nullAtom, "mover", mathmlNS);
       
   155     new ((void*)&mrootTag) QualifiedName(nullAtom, "mroot", mathmlNS);
       
   156     new ((void*)&mrowTag) QualifiedName(nullAtom, "mrow", mathmlNS);
       
   157     new ((void*)&msTag) QualifiedName(nullAtom, "ms", mathmlNS);
       
   158     new ((void*)&msqrtTag) QualifiedName(nullAtom, "msqrt", mathmlNS);
       
   159     new ((void*)&msubTag) QualifiedName(nullAtom, "msub", mathmlNS);
       
   160     new ((void*)&msubsupTag) QualifiedName(nullAtom, "msubsup", mathmlNS);
       
   161     new ((void*)&msupTag) QualifiedName(nullAtom, "msup", mathmlNS);
       
   162     new ((void*)&mtextTag) QualifiedName(nullAtom, "mtext", mathmlNS);
       
   163     new ((void*)&munderTag) QualifiedName(nullAtom, "munder", mathmlNS);
       
   164     new ((void*)&munderoverTag) QualifiedName(nullAtom, "munderover", mathmlNS);
       
   165     // Attributes
       
   166     new ((void*)&closeAttr) QualifiedName(nullAtom, "close", nullAtom);
       
   167     new ((void*)&denomalignAttr) QualifiedName(nullAtom, "denomalign", nullAtom);
       
   168     new ((void*)&linethicknessAttr) QualifiedName(nullAtom, "linethickness", nullAtom);
       
   169     new ((void*)&mathbackgroundAttr) QualifiedName(nullAtom, "mathbackground", nullAtom);
       
   170     new ((void*)&mathcolorAttr) QualifiedName(nullAtom, "mathcolor", nullAtom);
       
   171     new ((void*)&mathsizeAttr) QualifiedName(nullAtom, "mathsize", nullAtom);
       
   172     new ((void*)&numalignAttr) QualifiedName(nullAtom, "numalign", nullAtom);
       
   173     new ((void*)&openAttr) QualifiedName(nullAtom, "open", nullAtom);
       
   174     new ((void*)&separatorsAttr) QualifiedName(nullAtom, "separators", nullAtom);
       
   175     new ((void*)&stretchyAttr) QualifiedName(nullAtom, "stretchy", nullAtom);
       
   176 }
       
   177 
       
   178 } }
       
   179