Index: branches/dev/html/test/adachi/LLReader/LLReader/Feed.php
===================================================================
--- branches/dev/html/test/adachi/LLReader/LLReader/Feed.php	(revision 14611)
+++ branches/dev/html/test/adachi/LLReader/LLReader/Feed.php	(revision 14611)
@@ -0,0 +1,9 @@
+<?php
+
+require_once('XML/Feed/Parser.php');
+ 
+class LLReader_Feed extends XML_Feed_Parser {
+
+}
+
+?>
Index: branches/dev/html/test/adachi/LLReader/LLReader/Plugin/Subscription/Simple.php
===================================================================
--- branches/dev/html/test/adachi/LLReader/LLReader/Plugin/Subscription/Simple.php	(revision 14611)
+++ branches/dev/html/test/adachi/LLReader/LLReader/Plugin/Subscription/Simple.php	(revision 14611)
@@ -0,0 +1,12 @@
+<?php
+
+require_once('LLReader/Plugin.php');
+
+class LLReader_Plugin_Subscription_Simple extends LLReader_Plugin {
+    function execute ($llr) {
+        $config = $this->get_config();
+        $llr->p($config);
+    }
+}
+
+?>
Index: branches/dev/html/test/adachi/LLReader/LLReader/Util.php
===================================================================
--- branches/dev/html/test/adachi/LLReader/LLReader/Util.php	(revision 14611)
+++ branches/dev/html/test/adachi/LLReader/LLReader/Util.php	(revision 14611)
@@ -0,0 +1,23 @@
+<?php
+
+class LLReader_Util {
+    public static function log ($msg) {
+        echo $msg . "\n";
+    }
+
+    public static function p ($var, $var_dump = true) {
+        echo "++++++++ debug start ++++++++\n";
+
+        if ($var_dump) {
+            var_dump($var);
+        }
+        else {
+            print_r($var);
+        }
+
+        echo "++++++++ debug end ++++++++\n";
+    }
+
+}
+
+?>
Index: branches/dev/html/test/adachi/LLReader/LLReader/Plugin.php
===================================================================
--- branches/dev/html/test/adachi/LLReader/LLReader/Plugin.php	(revision 14611)
+++ branches/dev/html/test/adachi/LLReader/LLReader/Plugin.php	(revision 14611)
@@ -0,0 +1,18 @@
+<?php
+
+abstract class LLReader_Plugin {
+    protected $config;
+    
+    public function __construct ($llr, $config) {
+        $this->config = $config;
+    }
+    
+    abstract public function execute ($llr);
+    
+    protected function get_config () {
+        return $this->config;
+    }
+    
+}
+
+?>
Index: branches/dev/html/test/adachi/LLReader/pless_release.php
===================================================================
--- branches/dev/html/test/adachi/LLReader/pless_release.php	(revision 14611)
+++ branches/dev/html/test/adachi/LLReader/pless_release.php	(revision 14611)
@@ -0,0 +1,28 @@
+<?php
+
+ini_set('include_path', ini_get('include_path') . ';./;./Lib');
+
+require_once('LLReader.php');
+
+$config = array(
+    'plugins' => array(
+        'Subscription_Simple' => array(
+            'urls' => array(
+                '',
+                ''
+            ),
+        )/*,
+        'Publish_Mail'=> array(
+            'to' => array(
+                '',
+                '',
+            ),
+            'from' => ''
+        )*/
+    )
+);
+ 
+$LLR = new LLReader($config);
+$LLR->run();
+
+?>
Index: branches/dev/html/test/adachi/LLReader/LLReader.php
===================================================================
--- branches/dev/html/test/adachi/LLReader/LLReader.php	(revision 14611)
+++ branches/dev/html/test/adachi/LLReader/LLReader.php	(revision 14611)
@@ -0,0 +1,83 @@
+<?php
+require_once('LLReader/Util.php');
+require_once('LLReader/Feed.php');
+//require_once('LLReader/Constant.php');
+
+class LLReader {
+    private $config;
+    private $plugins;
+    private $feeds;
+
+    public function __construct($config){
+        $this->config = $config;
+    }
+
+    public function run () {
+        $this->load_plugins();
+
+        $phases = array(
+            'Subscription',
+            'Filter',
+            'Publish'
+        );
+        
+        foreach ( $phases as $phase ) {
+            $plugins = $this->get_plugins($phase);
+            
+            foreach ( $plugins as $plugin ) {
+                $plugin->execute($this);
+            }
+        }
+    }
+
+    private function load_plugins () {
+        foreach ($this->config['plugins'] as $name => $config) {
+            $class   = 'LLReader_Plugin_' . $name;
+            $include = preg_replace('/_/', '/', $class) . '.php';
+            $ret     = include_once($include);
+
+            $err = 0;
+
+            if ($ret) {
+                if ( preg_match("/^(.+?)_/", $name, $matches) ) {
+                    $phase = $matches[1];
+                    $this->plugins[$phase][] = new $class($this, $config);
+                    $this->log('[OK] ' . $class . ' loaded');
+                }
+                else {
+                    $this->log('[ERR] ' . 'class name is invalid: ' . $class);
+                    $err++;
+                }
+            }
+            else {
+                $this->log('[ERR] ' . $class . " not found");
+                $err++;
+            }
+        }
+
+        if ($err) {
+            $this->log('[Die] ' . 'function load_plugins()');
+            exit();
+        }
+    }
+
+    public function log ($msg) {
+        LLReader_Util::log($msg);
+    }
+
+    public function p ($var) {
+        LLReader_Util::p($var);
+    }
+
+    private function get_plugins ($phase) {
+        if ( empty($this->plugins[$phase]) ) {
+        	return array();
+        }
+        return $this->plugins[$phase];
+    }
+
+    public function get_feeds () {
+        return $this->feeds;
+    }
+}
+?>
