1: <?php
2: /**
3: * XOOPS Kernel Class
4: *
5: * You may not change or alter any portion of this comment or credits
6: * of supporting developers from this source code or any supporting source code
7: * which is considered copyrighted (c) material of the original comment or credit authors.
8: * This program is distributed in the hope that it will be useful,
9: * but WITHOUT ANY WARRANTY; without even the implied warranty of
10: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11: *
12: * @copyright XOOPS Project (http://xoops.org)
13: * @license GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
14: * @package kernel
15: * @since 2.0.0
16: * @author Kazumi Ono (AKA onokazu) http://www.myweb.ne.jp/, http://jp.xoops.org/
17: * @version $Id$
18: */
19:
20: namespace Xoops\Core\Kernel\Handlers;
21:
22: use Xoops\Core\Kernel\Dtype;
23: use Xoops\Core\Kernel\XoopsObject;
24:
25: /**
26: * a group of users
27: *
28: * @category Xoops\Core\Kernel\Handlers\XoopsGroup
29: * @package Xoops\Core\Kernel
30: * @author Kazumi Ono <onokazu@xoops.org>
31: * @copyright 2000-2015 XOOPS Project (http://xoops.org)
32: * @license GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
33: * @link http://xoops.org
34: */
35: class XoopsGroup extends XoopsObject
36: {
37: /**
38: * Constructor
39: */
40: public function __construct()
41: {
42: $this->initVar('groupid', Dtype::TYPE_INTEGER, null, false);
43: $this->initVar('name', Dtype::TYPE_TEXT_BOX, null, true, 100);
44: $this->initVar('description', Dtype::TYPE_TEXT_AREA, null, false);
45: $this->initVar('group_type', Dtype::TYPE_OTHER, null, false);
46: }
47:
48: /**
49: * getter
50: *
51: * @param string $format Dtype::FORMAT_xxxx constant
52: *
53: * @return mixed
54: */
55: public function id($format = Dtype::FORMAT_NONE)
56: {
57: return $this->getVar('groupid', $format);
58: }
59:
60: /**
61: * getter
62: *
63: * @param string $format Dtype::FORMAT_xxxx constant
64: *
65: * @return mixed
66: */
67: public function groupid($format = '')
68: {
69: return $this->getVar('groupid', $format);
70: }
71:
72: /**
73: * getter
74: *
75: * @param string $format Dtype::FORMAT_xxxx constant
76: *
77: * @return mixed
78: */
79: public function name($format = '')
80: {
81: return $this->getVar('name', $format);
82: }
83:
84: /**
85: * getter
86: *
87: * @param string $format Dtype::FORMAT_xxxx constant
88: *
89: * @return mixed
90: */
91: public function description($format = '')
92: {
93: return $this->getVar('description', $format);
94: }
95:
96: /**
97: * getter
98: *
99: * @param string $format Dtype::FORMAT_xxxx constant
100: *
101: * @return mixed
102: */
103: public function group_type($format = '')
104: {
105: return $this->getVar('group_type', $format);
106: }
107: }
108: