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

Method updateLaneBoundary

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

Source from the content-addressed store, hash-verified

1754}
1755
1756bool sqliteOperation::updateLaneBoundary(const hadmap::tx_laneboundary_t& boundary) {
1757 char sql[512];
1758
1759 sprintf(sql,
1760 "UPDATE " LANE_BOUNDARY_TABLE
1761 " SET srs = ?, lane_mark = ?, geom = ? "
1762 "WHERE pkid = %llu",
1763 boundary.pkid);
1764
1765 sqliteStmtPtr stmt(dbPtr, sql);
1766
1767 sqlite3_bind_int(stmt, 1, boundary.srs);
1768 sqlite3_bind_int(stmt, 2, boundary.lane_mark);
1769
1770 sqlite3_blob_data blob;
1771 createBlob(boundary.geom, boundary.srs, blob);
1772 sqlite3_bind_blob(stmt, 3, blob.data, blob.size, SQLITE_TRANSIENT);
1773
1774 int r = sqlite3_step(stmt);
1775 if (SQLITE_DONE != r) std::cerr << "Update Boundary Error, Code " << r << std::endl;
1776 sqlite3_reset(stmt);
1777
1778 return r == SQLITE_DONE;
1779}
1780
1781bool sqliteOperation::updateLaneLink(const hadmap::tx_lanelink_t& lanelink) {
1782 char sql[512];

Callers 1

updateRoadsMethod · 0.80

Calls 1

createBlobFunction · 0.85

Tested by

no test coverage detected