Documentation ¶
Overview ¶
Go binding for libGammu (library to work with different cell phones)
Index ¶
- type EncodeError
- type Error
- type SMS
- type StateMachine
- func (sm *StateMachine) Connect() error
- func (sm *StateMachine) Disconnect() error
- func (sm *StateMachine) GetSMS() (sms SMS, err error)
- func (sm *StateMachine) HardReset() error
- func (sm *StateMachine) IsConnected() bool
- func (sm *StateMachine) Reset() error
- func (sm *StateMachine) SendLongSMS(number, text string, report bool) error
- func (sm *StateMachine) SendSMS(number, text string, report bool) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EncodeError ¶
type EncodeError struct {
// contains filtered or unexported fields
}
func (EncodeError) Error ¶
func (e EncodeError) Error() string
type StateMachine ¶
type StateMachine struct { Timeout time.Duration // Default 15s // contains filtered or unexported fields }
StateMachine
func NewStateMachine ¶
func NewStateMachine(cf string) (*StateMachine, error)
Creates new state maschine using cf configuration file or default configuration file if cf == "".
func (*StateMachine) Connect ¶
func (sm *StateMachine) Connect() error
func (*StateMachine) Disconnect ¶
func (sm *StateMachine) Disconnect() error
func (*StateMachine) GetSMS ¶
func (sm *StateMachine) GetSMS() (sms SMS, err error)
Read and deletes first avaliable message. Returns io.EOF if there is no more messages to read
func (*StateMachine) HardReset ¶
func (sm *StateMachine) HardReset() error
func (*StateMachine) IsConnected ¶
func (sm *StateMachine) IsConnected() bool
func (*StateMachine) Reset ¶
func (sm *StateMachine) Reset() error
func (*StateMachine) SendLongSMS ¶
func (sm *StateMachine) SendLongSMS(number, text string, report bool) error
Click to show internal directories.
Click to hide internal directories.