Documentation ¶
Index ¶
- type IServer
- type Service
- func (s *Service) DBConn(nameDB string) *sql.DB
- func (s *Service) ErrorLog(log string)
- func (s *Service) HTTPResponse(httpconn http.ResponseWriter, data interface{}, err messagehandle.ErrorMsg)
- func (s *Service) Launch(setting Setting)
- func (s *Service) LaunchDB(nameDB string, setting dbservice.ConnSetting) error
- func (s *Service) LaunchHTTPS(setting []restfult.Setting, cert string, key string)
- func (s *Service) LaunchRestfult(setting []restfult.Setting)
- func (s *Service) LaunchSocket(setting []socket.Setting)
- func (s *Service) Log(log string)
- type Setting
- func (s Setting) DBSetting() dbservice.ConnSetting
- func (s *Setting) MaintainTime() int64
- func (s Setting) RestfultAdderss() string
- func (s *Setting) ServerTime() int64
- func (s *Setting) SetData(data map[string]interface{})
- func (s Setting) SocketAdderss() string
- func (s *Setting) ToClient() map[string]interface{}
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IServer ¶
type IServer interface { Launch(Setting) LaunchRestfult([]restfult.Setting) LaunchSocket([]socket.Setting) LaunchDB() Log(string) ErrorLog(string) }
IServer ...
type Service ¶
type Service struct { ShotDown chan bool Setting Setting Restfult *restfult.Service Socket *socket.Service HTTPConn *myhttp.Service Transfer *transaction.Service IGame igame.IGame DBs map[string]*dbservice.DB }
Service IServr
func (*Service) HTTPResponse ¶
func (s *Service) HTTPResponse(httpconn http.ResponseWriter, data interface{}, err messagehandle.ErrorMsg)
HTTPResponse Respond to cliente
func (*Service) LaunchDB ¶
func (s *Service) LaunchDB(nameDB string, setting dbservice.ConnSetting) error
LaunchDB ...
func (*Service) LaunchHTTPS ¶ added in v1.0.1
LaunchHTTPS service start with TLS
func (*Service) LaunchRestfult ¶
LaunchRestfult service start
func (*Service) LaunchSocket ¶
LaunchSocket service start
type Setting ¶
type Setting struct { AccountEncodeStr string DBIP string DBPassword string DBPORT string DBUser string IP string PORT string SocketPort string MaintainFinishTime string MaintainStartTime string RedisURL string TransferURL string ServerMod string // contains filtered or unexported fields }
Setting ...
Click to show internal directories.
Click to hide internal directories.