OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CSSParserToken_h | 5 #ifndef CSSParserToken_h |
6 #define CSSParserToken_h | 6 #define CSSParserToken_h |
7 | 7 |
8 #include "core/CoreExport.h" | 8 #include "core/CoreExport.h" |
9 #include "core/css/CSSPrimitiveValue.h" | 9 #include "core/css/CSSPrimitiveValue.h" |
10 #include "core/css/parser/CSSParserString.h" | 10 #include "core/css/parser/CSSParserString.h" |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 } | 97 } |
98 bool valueEqualsIgnoringCase(const char* str) const { return value().equalIg
noringCase(str); } | 98 bool valueEqualsIgnoringCase(const char* str) const { return value().equalIg
noringCase(str); } |
99 | 99 |
100 UChar delimiter() const; | 100 UChar delimiter() const; |
101 NumericSign numericSign() const; | 101 NumericSign numericSign() const; |
102 NumericValueType numericValueType() const; | 102 NumericValueType numericValueType() const; |
103 double numericValue() const; | 103 double numericValue() const; |
104 HashTokenType hashTokenType() const { ASSERT(m_type == HashToken); return m_
hashTokenType; } | 104 HashTokenType hashTokenType() const { ASSERT(m_type == HashToken); return m_
hashTokenType; } |
105 BlockType blockType() const { return static_cast<BlockType>(m_blockType); } | 105 BlockType blockType() const { return static_cast<BlockType>(m_blockType); } |
106 CSSPrimitiveValue::UnitType unitType() const { return static_cast<CSSPrimiti
veValue::UnitType>(m_unit); } | 106 CSSPrimitiveValue::UnitType unitType() const { return static_cast<CSSPrimiti
veValue::UnitType>(m_unit); } |
| 107 void setUnitType(CSSPrimitiveValue::UnitType unitType) { m_unit = static_cas
t<int>(unitType); } |
107 UChar32 unicodeRangeStart() const { ASSERT(m_type == UnicodeRangeToken); ret
urn m_unicodeRange.start; } | 108 UChar32 unicodeRangeStart() const { ASSERT(m_type == UnicodeRangeToken); ret
urn m_unicodeRange.start; } |
108 UChar32 unicodeRangeEnd() const { ASSERT(m_type == UnicodeRangeToken); retur
n m_unicodeRange.end; } | 109 UChar32 unicodeRangeEnd() const { ASSERT(m_type == UnicodeRangeToken); retur
n m_unicodeRange.end; } |
109 CSSValueID id() const; | 110 CSSValueID id() const; |
110 CSSValueID functionId() const; | 111 CSSValueID functionId() const; |
111 | 112 |
112 CSSPropertyID parseAsUnresolvedCSSPropertyID() const; | 113 CSSPropertyID parseAsUnresolvedCSSPropertyID() const; |
113 | 114 |
114 void serialize(StringBuilder&) const; | 115 void serialize(StringBuilder&) const; |
115 | 116 |
116 private: | 117 private: |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
149 | 150 |
150 namespace WTF { | 151 namespace WTF { |
151 template <> | 152 template <> |
152 struct IsTriviallyMoveAssignable<blink::CSSParserToken> { | 153 struct IsTriviallyMoveAssignable<blink::CSSParserToken> { |
153 STATIC_ONLY(IsTriviallyMoveAssignable); | 154 STATIC_ONLY(IsTriviallyMoveAssignable); |
154 static const bool value = true; | 155 static const bool value = true; |
155 }; | 156 }; |
156 } | 157 } |
157 | 158 |
158 #endif // CSSSParserToken_h | 159 #endif // CSSSParserToken_h |
OLD | NEW |