Home >Backend Development >PHP Tutorial >LotusPhp framework directory_PHP tutorial
The order is a bit messy. In fact, the introduction should be followed by the introduction of the program directory. I was busy in those days, so I wrote some simple ones. Today I am back on track and will finish writing all Lotusphp in order. Documentation
│ Config.php ConfigExpression / Configuration expression class
│ Lotus.php Glue code
│ shortcut.php � 到 到到 到 到 suit: Store.php LtStoreFile / File storage class
│ StoreMemory.php LtStoreMemory / Memory storage class, used in general test mode Automatic Loading
│ CacheAdapterFactory.php CacheAdapterFactory / Cache Adapter Factory Class
│ │ CacheConfigBuilder.php CacheConfigBuilder / Cache Configuration Class
│ │ CacheConnectionManager.php ConnectionManager / Cache connection manager class
│ │ CacheHandle.php │ CacheAdapter / Cache Adapter Interface
│ │ CacheAdapterApc.php CacheAdapterApc / Apc Cache Adapter Class
│ │ CacheAdapterEAccelerator.php CacheAdapterEAccelerator / EAccelerator cache adapter class
│ │ CacheAdapterFile.php CacheAdapterFile / File Cache Adapter Class
│ │ CacheAdapterMemcache.php AdapterMemcache / Memcache Cache Adapter Class
│ │ CacheAdapterMemcached.php CacheAdapterMemcached / Memcached Cache Adapter Class
│ │ CacheAdapterXcache.php CacheAdapterXcache /│ b─TableDataGateway TableDataGateway / Table data gateway
│ CacheTableDataGateway.php CacheTabledataGateway / cache table data gate A> │ │ Captcha.php Captcha / Verification Code
│ │ CaptChaimagengine.php Captchaimagengine / Verification Code Picture Generation Class
│ │
│ ─fonts FONTS / font folder
│ Ding-DongDaddyO.ttf
│ Duality.ttf
│ Jura.ttf
│ StayPuft.ttf
│ TimesNewRomanBold.ttf
│ VeraSansBold.ttf
│
├─ Cookie Cookie / Cookie operation class
│
├─DB PHP DBADAPTERFACTORY / Database Adapter Factory Class
│ │ Dbconfigbuilder.php Dbconfigbuilder / Database Configuration Class
│ │ DBConnectionManager.php DbConnectionManager / Database Connection Manager
│ │ │ dbhandle.php dbhandle / database operating handle
│ │ DBSQLESSION.PHP DBSQLEXPRESSION / Database SQL expression class
│ │
│ ├ ─ ADapter Adapter / Adapter
│ │ │ dbconnectionadapter. PHP qli.php DbConnectionAdapterMysqli / Mysqli connection adapter class
│ │ │ DbConnectionAdapterPdo.php DbConnectionAdapterPdo / Pdo connection adapter Class
│ │ │ DbConnectionAdapterPgsql.php DbConnectionAdapterPgsql /
PostgreSQL connection adapter class
│ │ │ DbConnectionAdapterSqlite.php DbConnectionAdapterSqlite / Sqlite connection adapter class
│ │ │ │ └─SqlAdapter SqlAdapter / Sql adapter
│ │ DbSqlAdapter.php DbSqlAdapter / Sql adapter class
│ │ DbSqlAdapterMys ql. PHP DBSQLADAPTERMYSQL /MySQL SQL adapter class
│ │ dbsqladapterpgsql.php dbsqladapterpgsql /PostgreSql SQL adapter class
│ │ DBSQLADAPTERTERTERITE.PHP DB DB SQLADAPTERSQLITE / SQLITE SQL adapter class
│ │
│ └ - Queryngine Queryngine / Database Query Engine
│ ├─SqlMap │ │ │ │ │ │ Object.php AbstractDbSqlMapFilterObject / SqlMap Processing Factory Abstract Class
│ │ DbSqlMapClient.php │ │ │ DbSqlMapResultFactory.php DbSqlMapResultFactory / SqlMap record factory class
│ │ │TableDataGateway DbTableDataGateway / Table data gateway class
│ DbTableRelation.php DbTableRelation / Empty
│ DbWhereCondition. php Inflector.php
│
├─Logger
├ - MVC MVC / MVC
│ Action.php Action / Action abstract class, under the MVC mode, all running programs must inherit it or its subclasses
│ Component.php Component / and Action Similarly, there is verification under Action, such as identity, form verification, and Component without verification
│ Context.php Context.php Context/Context processing class handles some common operations of clients and servers, such as form variable judgment, etc.
│ Dispatcher.php Dispatcher / Dispatching class. From it to call the relevant class │ TemplateView.php Template / Template
│ View.php Template / Class
│
├ - ObjectIl ObjectItil.php ObjectUtil / Declare the singleton mode of various classes
│
├─Pagination Pagination Rbac.php RBAC / RBAC Authentication Class
│
├─Router Router / Routing class. Parse url's
│
├─Session . SessionStoreFiles.php SessionStoreFiles / Session file Storage class
│ SessionStoreMemcache.php SessionStoreMemcache/Session MemcacheStorage class
│ SessionStoreMysql.php SessionStoreMy sql / Session Mysql storage class, temporarily empty
│ SessionStoreSqlite.php SessionStoreSqlite / Session Sqlite storage class
│ u─ Url url
│ url.php url / url generated class
│
├ - Validator value / form verification
│ validator.php value / form verification class
│ ValidatorDtd.php
This is a file directory printed with dos. Each file and folder has annotations listed. You can see the directory structure and mutual functions. Even without looking at the code, you can understand the general architecture and the functions of each class. , helpful for understanding Lotusphp
Each folder represents a component. There may be multiple classes or subclasses under each component.
The several files in the root directory of the folder are the basic classes of Lotusphp and are indispensable. Even if you transplant the components to other frameworks in the future, these basic classes must be transplanted together. If you want to transform other classes to suit Lotusphp's framework calls, you must fully understand these basic classes.
Lotus.php is the glue code, used to glue all components and set related parameters. It is also the only page that needs to be referenced in the framework. The others are automatically loaded by Autoloader
Config.php and ConfigExpression.php are configuration classes that are specially designed to read configuration files. Many function definitions in Lotusphp need to be implemented through configuration files. Programs can be quickly changed through configuration file classes. Settings, such as some properties of database connection, some settings of paging, etc.
Store.php, StoreFile.php, and StoreMemory.php are the basic classes used for file storage operations. Configuration, templates, Autoloader, etc. are all implemented through file caching
In future chapters we will have a detailed usage introduction for all components
www.bkjia.com