From 232693b73a3bc2156fc15ca8a3cada8f23ec6dcc Mon Sep 17 00:00:00 2001 From: Radu Ioan Fericean Date: Wed, 16 May 2012 18:15:12 +0300 Subject: [PATCH] session manager and event interfaces --- sessionmanager/event.go | 36 ++++++++++++++++++++++++++++++++ sessionmanager/sessionmanager.go | 24 +++++++++++++++++++++ 2 files changed, 60 insertions(+) create mode 100644 sessionmanager/event.go create mode 100644 sessionmanager/sessionmanager.go diff --git a/sessionmanager/event.go b/sessionmanager/event.go new file mode 100644 index 000000000..443bb2244 --- /dev/null +++ b/sessionmanager/event.go @@ -0,0 +1,36 @@ +/* +Rating system designed to be used in VoIP Carriers World +Copyright (C) 2012 Radu Ioan Fericean + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see +*/ + +package sessionmanager + +import ( + "time" +) + +type Event interface { + New(string) Event + GetName() string + GetDirection() string + GetOrigId() string + GetSubject() string + GetDestination() string + GetTOR() string + GetUUID() string + GetCstmId() string + GetStartTime() (time.Time, error) +} diff --git a/sessionmanager/sessionmanager.go b/sessionmanager/sessionmanager.go new file mode 100644 index 000000000..0b8f54183 --- /dev/null +++ b/sessionmanager/sessionmanager.go @@ -0,0 +1,24 @@ +/* +Rating system designed to be used in VoIP Carriers World +Copyright (C) 2012 Radu Ioan Fericean + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see +*/ + +package sessionmanager + +type SessionManager interface { + DisconnectSession(*Session) + GetSessionDelegate() SessionDelegate +}