Source for file Ethna_Plugin_Generator_AppObject.php
Documentation is available at Ethna_Plugin_Generator_AppObject.php
// vim: foldmethod=marker
* Ethna_Plugin_Generator_AppObject.php
* @author Masaki Fujimoto <fujimoto@php.net>
* @license http://www.opensource.org/licenses/bsd-license.php The BSD License
// {{{ Ethna_Plugin_Generator_AppObject
* @author Masaki Fujimoto <fujimoto@php.net>
* アプリケーションオブジェクトのスケルトンを生成する
* @param string $table_name テーブル名
* @return bool true:成功 false:失敗
$app_dir =
$this->ctl->getDirectory('app');
$app_path =
ucfirst($this->ctl->getAppId()) .
'_' .
$table_id .
'.php';
$macro['project_id'] =
$this->ctl->getAppId();
$macro['app_path'] =
$app_path;
$macro['app_object'] =
ucfirst($this->ctl->getAppId()) .
'_' .
$table_id;
$user_macro =
$this->_getUserMacro();
$path =
"$app_dir/$app_path";
printf("file [%s] already exists -> skip\n", $path);
} else if ($this->_generateFile("skel.app_object.php", $path, $macro) ==
false) {
printf("[warning] file creation failed [%s]\n", $path);
printf("app-object script(s) successfully created [%s]\n", $path);
Documentation generated on Fri, 11 Nov 2011 04:00:13 +0900 by phpDocumentor 1.4.3