(w http.ResponseWriter, r *http.Request)
| 63 | } |
| 64 | |
| 65 | func (conf *GlobalConfig) API_closeStream(w http.ResponseWriter, r *http.Request) { |
| 66 | if streamPath := r.URL.Query().Get("streamPath"); streamPath != "" { |
| 67 | if s := Streams.Get(streamPath); s != nil { |
| 68 | s.Close() |
| 69 | util.ReturnOK(w, r) |
| 70 | } else { |
| 71 | util.ReturnError(util.APIErrorNoStream, NO_SUCH_STREAM, w, r) |
| 72 | } |
| 73 | } else { |
| 74 | util.ReturnError(util.APIErrorNoStream, "no streamPath", w, r) |
| 75 | } |
| 76 | } |
| 77 | |
| 78 | // API_getConfig 获取指定的配置信息 |
| 79 | func (conf *GlobalConfig) API_getConfig(w http.ResponseWriter, r *http.Request) { |
nothing calls this directly
no test coverage detected