mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-06-16 04:55:58 +08:00
单例接口放置在cpp文件中
This commit is contained in:
@@ -32,6 +32,14 @@ using namespace ZL::Util;
|
||||
namespace ZL {
|
||||
namespace Rtsp {
|
||||
|
||||
UDPServer &UDPServer::Instance() {
|
||||
static UDPServer *instance(new UDPServer());
|
||||
return *instance;
|
||||
}
|
||||
void UDPServer::Destory() {
|
||||
delete &UDPServer::Instance();
|
||||
}
|
||||
|
||||
UDPServer::UDPServer() {
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user