summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2008-06-03 23:15:16 +0000
committerJo-Philipp Wich <jow@openwrt.org>2008-06-03 23:15:16 +0000
commit6071119f2e205dc2d58b27c990e12b306b755026 (patch)
tree399b89554e71d103ec0e3d19e3b5e1f3db1009d2
parent7557c5bcef137e7e27c4dd56325a633231d91cc8 (diff)
* luc/statistics: add file/license headers
-rw-r--r--applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua22
-rw-r--r--applications/luci-statistics/luasrc/statistics/datatree.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/i18n.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/colors.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/cpu/cpu.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/df/df.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/interface.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/iptables/ipt_packets.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/irq/irq.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/ping/ping.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes/ps_state.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/tcpconns/tcp_connections.lua15
-rw-r--r--applications/luci-statistics/luasrc/statistics/rrdtool/definitions/wireless.lua15
17 files changed, 256 insertions, 6 deletions
diff --git a/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua b/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua
index 3b1bb99d7..ae1679bee 100644
--- a/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua
+++ b/applications/luci-statistics/luasrc/controller/luci_statistics/luci_statistics.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - statistics controller module
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.controller.luci_statistics.luci_statistics", package.seeall)
function index()
@@ -20,11 +35,6 @@ function index()
end
end
- -- override call(): call requested action function with supplied parameters
- function _call( func, tree, plugin )
- return function() getfenv()[func]( tree, plugin ) end
- end
-
-- override i18n(): try to translate stat_<str> or fall back to <str>
function _i18n( str )
return luci.i18n.translate( "stat_" .. str, str )
@@ -124,7 +134,7 @@ function statistics_networkplugins()
end
-function statistics_render( tree )
+function statistics_render()
require("luci.statistics.rrdtool")
require("luci.template")
diff --git a/applications/luci-statistics/luasrc/statistics/datatree.lua b/applications/luci-statistics/luasrc/statistics/datatree.lua
index 327b8ef36..03608b10b 100644
--- a/applications/luci-statistics/luasrc/statistics/datatree.lua
+++ b/applications/luci-statistics/luasrc/statistics/datatree.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - rrd data tree builder
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.datatree", package.seeall)
local util = require("luci.util")
diff --git a/applications/luci-statistics/luasrc/statistics/i18n.lua b/applications/luci-statistics/luasrc/statistics/i18n.lua
index a31d12667..865839524 100644
--- a/applications/luci-statistics/luasrc/statistics/i18n.lua
+++ b/applications/luci-statistics/luasrc/statistics/i18n.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - diagram i18n helper
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.i18n", package.seeall)
require("luci.util")
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool.lua b/applications/luci-statistics/luasrc/statistics/rrdtool.lua
index 5f07a41ff..b6f6d44ba 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - rrdtool interface library / diagram model interpreter
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool", package.seeall)
require("luci.statistics.datatree")
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/colors.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/colors.lua
index cdd6f7105..8f28524aa 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/colors.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/colors.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - diagram color helper class
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.colors", package.seeall)
require("luci.util")
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions.lua
index add69e4b6..68468c0cf 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - data definition database (obsolete)
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions", package.seeall)
require("luci.util")
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/cpu/cpu.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/cpu/cpu.lua
index bd002e12f..d6053a5e7 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/cpu/cpu.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/cpu/cpu.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - cpu plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.cpu.cpu",package.seeall)
function rrdargs( graph, host, plugin, plugin_instance, dtype )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/df/df.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/df/df.lua
index a6045b720..1d29800b3 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/df/df.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/df/df.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - df plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.df.df", package.seeall)
function rrdargs( graph, plugin, plugin_instance, dtype )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/interface.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/interface.lua
index 0d812d6ec..029ffe323 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/interface.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/interface.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - interface plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.interface", package.seeall)
function rrdargs( graph, host, plugin, plugin_instance )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/iptables/ipt_packets.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/iptables/ipt_packets.lua
index 2ab57e862..e1dd50753 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/iptables/ipt_packets.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/iptables/ipt_packets.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - iptables plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.iptables.ipt_packets", package.seeall)
function rrdargs( graph, plugin, plugin_instance, dtype )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/irq/irq.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/irq/irq.lua
index a68227bf5..270e06fe6 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/irq/irq.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/irq/irq.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - irq plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id: stat-genconfig 2272 2008-06-03 22:42:01Z nbd $
+
+]]--
+
module("luci.statistics.rrdtool.definitions.irq.irq", package.seeall)
function rrdargs( graph, plugin, plugin_instance, dtype )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua
index 8f32ab3d1..daff584b5 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/netlink.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - netlink plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.netlink", package.seeall)
function rrdargs( graph, plugin, plugin_instance )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/ping/ping.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/ping/ping.lua
index a7bf2956c..6a3bd5e14 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/ping/ping.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/ping/ping.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - ping plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.ping.ping", package.seeall)
function rrdargs( graph, plugin, plugin_instance, dtype )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes.lua
index 17f1e2b99..f2ca2c68a 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - processes plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id: stat-genconfig 2272 2008-06-03 22:42:01Z nbd $
+
+]]--
+
module("luci.statistics.rrdtool.definitions.processes", package.seeall)
function rrdargs( graph, plugin, plugin_instance )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes/ps_state.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes/ps_state.lua
index 5dd446f31..c95152ee4 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes/ps_state.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/processes/ps_state.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - processes plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.processes.ps_state", package.seeall)
function rrdargs( graph, plugin, plugin_instance, dtype )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/tcpconns/tcp_connections.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/tcpconns/tcp_connections.lua
index 7f54c1091..9f62541b3 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/tcpconns/tcp_connections.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/tcpconns/tcp_connections.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - tcpconns plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.tcpconns.tcp_connections", package.seeall)
function rrdargs( graph, plugin, plugin_instance, dtype )
diff --git a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/wireless.lua b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/wireless.lua
index 7c0888558..9bcbc0690 100644
--- a/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/wireless.lua
+++ b/applications/luci-statistics/luasrc/statistics/rrdtool/definitions/wireless.lua
@@ -1,3 +1,18 @@
+--[[
+
+Luci statistics - wireless plugin diagram definition
+(c) 2008 Freifunk Leipzig / Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+]]--
+
module("luci.statistics.rrdtool.definitions.wireless", package.seeall)
function rrdargs( graph, host, plugin, plugin_instance )