[xoops-cvslog 1895] CVS update: xoops2jp/html/kernel

Zurück zum Archiv-Index

Minahito minah****@users*****
2006年 1月 24日 (火) 20:25:05 JST


Index: xoops2jp/html/kernel/subjecticon.php
diff -u /dev/null xoops2jp/html/kernel/subjecticon.php:1.1.2.1
--- /dev/null	Tue Jan 24 20:25:05 2006
+++ xoops2jp/html/kernel/subjecticon.php	Tue Jan 24 20:25:05 2006
@@ -0,0 +1,70 @@
+<?php
+
+class XoopsSubjecticon extends XoopsObject
+{
+	function XoopsSubjecticon()
+	{
+        $this->initVar('filename', XOBJ_DTYPE_TXTBOX, null, true, 255);
+	}
+}
+
+class XoopsSubjecticonHandler extends XoopsObjectHandler
+{
+	var $_mResult;
+	
+	function XoopsSubjecticonHandler(&$db)
+	{
+		require_once XOOPS_ROOT_PATH . "/class/xoopslists.php";
+		$this->_mResult =& XoopsLists::getSubjectsList();
+	}
+	
+	function &create()
+	{
+		$ret =& new XoopsSubjecticon();
+		return $ret;
+	}
+	
+	function &get($filename)
+	{
+		if (isset($this->_mResult[$filename])) {
+			$obj =& new XoopsSubjecticon();
+			$obj->setVar('filename', $this->_mResult[$filename]);
+
+			return $obj;
+		}
+		
+		$ret = null;
+		return $ret;
+	}
+
+	function &getObjects($criteria = null, $key_as_id = false)
+	{
+		$ret = array();
+		
+		foreach ($this->_mResult as $filename => $value) {
+			$obj =& new XoopsSubjecticon();
+			$obj->setVar('filename', $filename);
+			if ($key_as_id) {
+				$ret[$filename] =& $obj;
+			}
+			else {
+				$ret[] =& $obj;
+			}
+			unset($obj);
+		}
+		
+		return $ret;
+	}
+	
+	function insert(&$obj)
+	{
+		return false;
+	}
+
+	function delete(&$obj)
+	{
+		return false;
+	}
+}
+
+?>
\ No newline at end of file


xoops-cvslog メーリングリストの案内
Zurück zum Archiv-Index