MCPcopy Create free account
hub / github.com/acl-dev/acl / on_message

Method on_message

lib_acl_cpp/src/db/db_service.cpp:133–155  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

131 }
132
133 virtual void on_message(int nMsg, void* data, int dlen acl_unused)
134 {
135 DB_IPC_DAT* dat = (DB_IPC_DAT*) data;
136 db_query* query = dat->query;
137
138 switch (nMsg) {
139 case DB_OK:
140 query->on_ok(dat->rows, dat->affected_rows);
141 break;
142 case DB_ERR_OPEN:
143 query->on_error(DB_ERR_OPEN);
144 break;
145 case DB_ERR_EXEC_SQL:
146 query->on_error(DB_ERR_EXEC_SQL);
147 break;
148 default:
149 break;
150 }
151
152 dat->db->free_result();
153 dbservice_->push_back(dat->db);
154 query->destroy();
155 }
156protected:
157 virtual void on_close(void)
158 {

Callers

nothing calls this directly

Calls 5

free_resultMethod · 0.80
on_okMethod · 0.45
on_errorMethod · 0.45
push_backMethod · 0.45
destroyMethod · 0.45

Tested by

no test coverage detected