MCPcopy Create free account
hub / github.com/bytedance/Fastbot_Android / InsertEndChild

Method InsertEndChild

native/thirdpart/tinyxml2/tinyxml2.cpp:895–922  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

893
894
895XMLNode* XMLNode::InsertEndChild( XMLNode* addThis )
896{
897 TIXMLASSERT( addThis );
898 if ( addThis->_document != _document ) {
899 TIXMLASSERT( false );
900 return 0;
901 }
902 InsertChildPreamble( addThis );
903
904 if ( _lastChild ) {
905 TIXMLASSERT( _firstChild );
906 TIXMLASSERT( _lastChild->_next == 0 );
907 _lastChild->_next = addThis;
908 addThis->_prev = _lastChild;
909 _lastChild = addThis;
910
911 addThis->_next = 0;
912 }
913 else {
914 TIXMLASSERT( _firstChild == 0 );
915 _firstChild = _lastChild = addThis;
916
917 addThis->_prev = 0;
918 addThis->_next = 0;
919 }
920 addThis->_parent = this;
921 return addThis;
922}
923
924
925XMLNode* XMLNode::InsertFirstChild( XMLNode* addThis )

Callers 2

DeepCloneMethod · 0.80
DeepCopyMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected