123456789101112131415161718192021 |
- package http_client
- var clientInstance *Client
- func InitInstance() {
- if clientInstance == nil {
- clientInstance = New()
- }
- }
- func DestroyInstance() {
- if clientInstance == nil {
- return
- }
- Destroy(clientInstance)
- }
- func GetInstance() *Client {
- return clientInstance
- }
|