ISrsHttpServeMux

ISrsHttpServeMux();

virtual ~ISrsHttpServeMux();

virtual int serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r) = 0;

SrsHttpServeMux

std::map<std::string, SrsHttpMuxEntry*> entries;

std::map<std::string, ISrsHttpHandler*> vhosts;

std::vector<ISrsHttpMatchHijacker*> hijackers;

SrsHttpServeMux();

virtual ~SrsHttpServeMux();


virtual int initialize();

virtual void hijack(ISrsHttpMatchHijacker* h);

virtual void unhijack(ISrsHttpMatchHijacker* h);

virtual int handle(std::string pattern, ISrsHttpHandler* handler);

virtual bool can_serve(ISrsHttpMessage* r);

virtual int serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r);

virtual int find_handler(ISrsHttpMessage* r, ISrsHttpHandler** ph);

virtual int match(ISrsHttpMessage* r, ISrsHttpHandler** ph);

virtual bool path_match(std::string pattern, std::string path);

继承

SrsHttpServer

SrsServer* server;

SrsHttpStaticServer* http_static;

SrsHttpStreamServer* http_stream;

SrsHttpServer(SrsServer* svr);

virtual ~SrsHttpServer();

virtual int initialize();

virtual int serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r);

virtual int http_mount(SrsSource* s, SrsRequest* r);

virtual void http_unmount(SrsSource* s, SrsRequest* r);

ISrsHttpHandler

SrsHttpMuxEntry* entry;

ISrsHttpHandler();

virtual ~ISrsHttpHandler();

virtual bool is_not_found();

virtual int serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r) = 0;

SrsHttpFileServer

std::string dir;

SrsHttpFileServer(std::string root_dir);

virtual ~SrsHttpFileServer();

void bitStreamExtractor(std::string path,std::string extractorFile,std::string layerNumber);

virtual int serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r);

virtual int serve_file(ISrsHttpResponseWriter* w, ISrsHttpMessage* r, std::string fullpath)

virtual int serve_file(ISrsHttpResponseWriter* w, ISrsHttpMessage* r, std::string fullpath, int64_t startNum,int64_t endNum);

virtual int serve_file(ISrsHttpResponseWriter* w, ISrsHttpMessage* r, std::string fullpath, int64_t startNum, int64_t endNum, std::string layer);

virtual int serve_flv_file(ISrsHttpResponseWriter* w, ISrsHttpMessage* r, std::string fullpath);

virtual int serve_mp4_file(ISrsHttpResponseWriter* w, ISrsHttpMessage* r, std::string fullpath);

virtual int serve_flv_stream(ISrsHttpResponseWriter* w, ISrsHttpMessage* r, std::string fullpath, int offset);

virtual int serve_mp4_stream(ISrsHttpResponseWriter* w, ISrsHttpMessage* r, std::string fullpath, int start, int end);

virtual int copy(ISrsHttpResponseWriter* w, SrsFileReader* fs, ISrsHttpMessage* r, int size);

继承

qwe

qwe

2019-10-08 11:49:52 0 10
这里是评论

相关推荐