MCPcopy Create free account
hub / github.com/buggins/coolreader / ~tinyNodeCollection

Method ~tinyNodeCollection

crengine/src/lvtinydom.cpp:1875–1904  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1873}
1874
1875tinyNodeCollection::~tinyNodeCollection()
1876{
1877#if BUILD_LITE!=1
1878 if ( _cacheFile )
1879 delete _cacheFile;
1880#endif
1881 // clear all elem parts
1882 for ( int partindex = 0; partindex<=(_elemCount>>TNC_PART_SHIFT); partindex++ ) {
1883 ldomNode * part = _elemList[partindex];
1884 if ( part ) {
1885 int n0 = TNC_PART_LEN * partindex;
1886 for ( int i=0; i<TNC_PART_LEN && n0+i<=_elemCount; i++ )
1887 part[i].onCollectionDestroy();
1888 free(part);
1889 _elemList[partindex] = NULL;
1890 }
1891 }
1892 // clear all text parts
1893 for ( int partindex = 0; partindex<=(_textCount>>TNC_PART_SHIFT); partindex++ ) {
1894 ldomNode * part = _textList[partindex];
1895 if ( part ) {
1896 int n0 = TNC_PART_LEN * partindex;
1897 for ( int i=0; i<TNC_PART_LEN && n0+i<=_textCount; i++ )
1898 part[i].onCollectionDestroy();
1899 free(part);
1900 _textList[partindex] = NULL;
1901 }
1902 }
1903 ldomNode::unregisterDocument((ldomDocument*)this);
1904}
1905
1906#if BUILD_LITE!=1
1907/// put all objects into persistent storage

Callers

nothing calls this directly

Calls 1

onCollectionDestroyMethod · 0.80

Tested by

no test coverage detected