| 113 | } |
| 114 | |
| 115 | std::string |
| 116 | Url::getScheme() const |
| 117 | { |
| 118 | std::string ret_str; |
| 119 | if (isInitialized()) { |
| 120 | int length; |
| 121 | const char *memptr = TSUrlSchemeGet(state_->hdr_buf_, state_->url_loc_, &length); |
| 122 | if (memptr && length) { |
| 123 | ret_str.assign(memptr, length); |
| 124 | } |
| 125 | LOG_DEBUG("Using scheme [%s]", ret_str.c_str()); |
| 126 | } |
| 127 | return ret_str; |
| 128 | } |
| 129 | |
| 130 | std::string |
| 131 | Url::getHost() const |
no test coverage detected