您的位置:首页 > 编程语言 > PHP开发

【CakePHP1.3】_文件名、类名约定

2013-02-19 09:08 351 查看

文件名、类名约定

通常,文件名匹配类名,类名采用驼峰命名法。

例:假如有一个类MyNiftyClass,那么它一定在 MyNiftyClass.php文件中

The Controller class KissesAndHugsController would be found in a file named KissesAnd-
HugsController.php
• The Component class MyHandyComponent would be found in a file named MyHandyComponent.
php
• The Model class OptionValue would be found in a file named OptionValue.php
• The Behavior class EspeciallyFunkableBehavior would be found in a file named EspeciallyFunkableBehavior.
php
• The View class SuperSimpleView would be found in a file named SuperSimpleView.php
• The Helper class BestEverHelper would be found in a file named BestEverHelper.php
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: