MCPcopy Create free account
hub / github.com/Tencent/TAD_Sim / initialize

Method initialize

common/map_sdk/mapdb/src/sqlite_operation.cpp:113–137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

111}
112
113bool sqliteOperation::initialize() {
114 if (NULL == dbPtr) {
115 std::cerr << "Create connection first" << std::endl;
116 return false;
117 }
118
119 // create spatial metadata
120 if (!sqlitePackage::initSpatialMeta(dbPtr)) return false;
121
122 // create temp table
123 // attention mutil process situation
124 /*
125 if ( !sqlitePackage::isTableExists( dbPtr, TEMP_TABLE ) )
126 {
127 if ( !sqlitePackage::execSql( dbPtr, SQL_CREATE_TEMP_TABLE ) )
128 {
129 if ( !sqlitePackage::isTableExists( dbPtr, TEMP_TABLE ) ){
130 return false;}
131 }
132 }
133 */
134
135 bool ret = initializeTables();
136 return ret;
137}
138
139bool sqliteOperation::initializeTables() {
140 // check division table

Callers 2

LocalSearchMethod · 0.45
saveMapMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected