Versions in this module Expand all Collapse all v0 v0.4.0 Dec 10, 2018 Changes in this version + var ErrIllegalUID = errors.New("illegal uid") + var Lifetime = &lifetime + type LifetimeHandler func(*Session) + type NetworkEntity interface + Close func() error + MID func() uint + Push func(route string, v interface{}) error + RemoteAddr func() net.Addr + Response func(v interface{}) error + ResponseMID func(mid uint, v interface{}) error + type Session struct + func New(entity NetworkEntity) *Session + func (s *Session) Bind(uid int64) error + func (s *Session) Clear() + func (s *Session) Close() + func (s *Session) Float32(key string) float32 + func (s *Session) Float64(key string) float64 + func (s *Session) HasKey(key string) bool + func (s *Session) ID() int64 + func (s *Session) Int(key string) int + func (s *Session) Int16(key string) int16 + func (s *Session) Int32(key string) int32 + func (s *Session) Int64(key string) int64 + func (s *Session) Int8(key string) int8 + func (s *Session) MID() uint + func (s *Session) Push(route string, v interface{}) error + func (s *Session) RemoteAddr() net.Addr + func (s *Session) Remove(key string) + func (s *Session) Response(v interface{}) error + func (s *Session) ResponseMID(mid uint, v interface{}) error + func (s *Session) Restore(data map[string]interface{}) + func (s *Session) Set(key string, value interface{}) + func (s *Session) State() map[string]interface{} + func (s *Session) String(key string) string + func (s *Session) UID() int64 + func (s *Session) Uint(key string) uint + func (s *Session) Uint16(key string) uint16 + func (s *Session) Uint32(key string) uint32 + func (s *Session) Uint64(key string) uint64 + func (s *Session) Uint8(key string) uint8 + func (s *Session) Value(key string) interface{}