Definition at line 190 of file SkDOM.cpp.
◆ SkDOMParser()
Definition at line 192 of file SkDOM.cpp.
194 fRoot = nullptr;
195 fLevel = 0;
196 fNeedToFlush = true;
197 }
SkXMLParserError fParserError
SkXMLParser(SkXMLParserError *parserError=nullptr)
◆ flushAttributes()
void SkDOMParser::flushAttributes |
( |
| ) |
|
|
inlineprotected |
Definition at line 202 of file SkDOM.cpp.
202 {
204
205 int attrCount = fAttrs.size();
206
209
210 node->
fName = fElemName;
211 node->fFirstChild = nullptr;
212 node->fAttrCount =
SkToU16(attrCount);
213 node->fAttrs = attrs;
214 node->fType = fElemType;
215
216 if (fRoot == nullptr) {
217 node->fNextSibling = nullptr;
218 fRoot = node;
219 } else {
224 }
225 *fParentStack.append() = node;
226
228 fAttrs.reset();
229 }
static void * sk_careful_memcpy(void *dst, const void *src, size_t len)
constexpr uint16_t SkToU16(S x)
T * makeArrayDefault(size_t count)
auto make(Ctor &&ctor) -> decltype(ctor(nullptr))
◆ getRoot()
◆ onAddAttribute()
bool SkDOMParser::onAddAttribute |
( |
const char |
name[], |
|
|
const char |
value[] |
|
) |
| |
|
inlineoverrideprotectedvirtual |
Reimplemented from SkXMLParser.
Definition at line 236 of file SkDOM.cpp.
236 {
240 return false;
241 }
static char * dupstr(SkArenaAlloc *chunk, const char src[], size_t srcLen)
DEF_SWITCHES_START aot vmservice shared library name
◆ onEndElement()
bool SkDOMParser::onEndElement |
( |
const char |
elem[] | ) |
|
|
inlineoverrideprotectedvirtual |
Reimplemented from SkXMLParser.
Definition at line 243 of file SkDOM.cpp.
243 {
244 if (fNeedToFlush)
246 fNeedToFlush = false;
247 --fLevel;
248
250 fParentStack.pop_back();
251
254 while (child) {
259 }
261 return false;
262 }
static float next(float f)
static float prev(float f)
◆ onStartElement()
bool SkDOMParser::onStartElement |
( |
const char |
elem[] | ) |
|
|
inlineoverrideprotectedvirtual |
◆ onText()
bool SkDOMParser::onText |
( |
const char |
text[], |
|
|
int |
len |
|
) |
| |
|
inlineoverrideprotectedvirtual |
Reimplemented from SkXMLParser.
Definition at line 264 of file SkDOM.cpp.
264 {
267
268 return false;
269 }
bool onEndElement(const char elem[]) override
bool text(const char text[], int len)
◆ fParserError
The documentation for this class was generated from the following file: