From 3142bc1bcec3ab55677cdb2cdadf5cf23d15f4b4 Mon Sep 17 00:00:00 2001 From: Natanael Copa Date: Thu, 27 Mar 2008 13:54:16 +0000 Subject: added ipsec-tools git-svn-id: svn://svn.alpinelinux.org/acf/ipsec-tools/trunk@845 ab2d0c66-481e-0410-8bed-d214d4d58bed --- ipsec-tools-controller.lua | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 ipsec-tools-controller.lua (limited to 'ipsec-tools-controller.lua') diff --git a/ipsec-tools-controller.lua b/ipsec-tools-controller.lua new file mode 100644 index 0000000..2a31dd6 --- /dev/null +++ b/ipsec-tools-controller.lua @@ -0,0 +1,25 @@ +module(..., package.seeall) + +-- This is the object/text used when we want to add a new record + +require("format") + +local list_redir = function (self) + self.conf.action = "status" + self.conf.type = "redir" + error (self.conf) +end + +mvc = {} +mvc.on_load = function(self, parent) + if (self.worker[self.conf.action] == nil ) or ( self.conf.action == "init" ) then + self.worker[self.conf.action] = list_redir(self) + end +end + +-- ################################################################################ +-- PUBLIC FUNCTIONS +function status(self) + return { status=self.model.getstatus() } +end + -- cgit v1.2.3