MCPcopy Create free account
hub / github.com/apache/trafficserver / setPath

Method setPath

src/tscpp/api/Url.cc:156–169  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

154}
155
156void
157Url::setPath(const std::string &path)
158{
159 if (!isInitialized()) {
160 LOG_ERROR("Url %p not initialized", this);
161 return;
162 }
163
164 if (TSUrlPathSet(state_->hdr_buf_, state_->url_loc_, path.c_str(), path.length()) == TS_SUCCESS) {
165 LOG_DEBUG("Set path to [%s]", path.c_str());
166 } else {
167 LOG_ERROR("Could not set path; hdr_buf %p, url_loc %p", state_->hdr_buf_, state_->url_loc_);
168 }
169}
170
171void
172Url::setQuery(const std::string &query)

Callers

nothing calls this directly

Calls 3

TSUrlPathSetFunction · 0.85
c_strMethod · 0.45
lengthMethod · 0.45

Tested by

no test coverage detected