SmppSession

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 9, 2018 License: MIT, Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	STATE_UNBIND = 0
	STATE_BIND   = 1
)

Variables

This section is empty.

Functions

func InitializeSmppSessionInstance

func InitializeSmppSessionInstance(gw *config.SmsGateway, pduConf *config.PDUConfigs)

InitializeSmppSessionInstance ...

Types

type ISmppSessionManager

type ISmppSessionManager interface {
	Bind() error
	Rebind() error
	Destroy()
	SendSMS(data *models.SendSMS) bool
	Unbind() (unbindResp *PDU.UnbindResp, err *Exception.Exception)
}

ISmppSessionManager smpp session manager interface

var Instance ISmppSessionManager

Instance instance of SmppSessionManager

type SmppSessionManager

type SmppSessionManager struct {
	// contains filtered or unexported fields
}

SmppSessionManager default smpp session manager

func (*SmppSessionManager) Bind

func (c *SmppSessionManager) Bind() error

Bind safe binding

func (*SmppSessionManager) Destroy

func (c *SmppSessionManager) Destroy()

Destroy session

func (*SmppSessionManager) HandleEvent

func (c *SmppSessionManager) HandleEvent(event *gosmpp.ServerPDUEvent) (ex *Exception.Exception)

HandleEvent handle server pdu events

func (*SmppSessionManager) Rebind

func (c *SmppSessionManager) Rebind() error

Rebind ...

func (*SmppSessionManager) SendSMS

func (c *SmppSessionManager) SendSMS(data *models.SendSMS) (subRes bool)

SendSMS do send sms

func (*SmppSessionManager) Unbind

func (c *SmppSessionManager) Unbind() (unbindResp *PDU.UnbindResp, err *Exception.Exception)

Unbind unbinding connections

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL