User Tools

Site Tools


en:dev:284:registry

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
en:dev:284:registry [12.08.2015 20:41] – finished translation and remove fixme mrbasemanen:dev:284:registry [26.09.2023 04:21] – [Overview] Manuela v.d.Decken
Line 8: Line 8:
 Global constants (as well as global variables), used within classes, break up their clear encapsulation and can prevent the reusability of the code. See 'Basics of object-oriented programming'. Global constants (as well as global variables), used within classes, break up their clear encapsulation and can prevent the reusability of the code. See 'Basics of object-oriented programming'.
  
-Global constants are, as has long been stated, from this version on deprecated, that is undesirable. See: [[en:dev:284:deprecated|Deprecated-List Entry 10 from 12.2013]].+Global constants are, as has long been stated, from this version on deprecated, that is undesirable. See: [[dev:284:deprecated|Deprecated-List Entry 10 from 12.2013]].
  
 Of course, discarding all previous constants without any replacement is clearly not a feasible approach. That's simply impossible. At least in the first step, the class '**WbAdaptor**' makes properties available that are similar to the previous constants. Of course, discarding all previous constants without any replacement is clearly not a feasible approach. That's simply impossible. At least in the first step, the class '**WbAdaptor**' makes properties available that are similar to the previous constants.
Line 27: Line 27:
  
 ^old constant   ^new key    ^content (example)  ^ ^old constant   ^new key    ^content (example)  ^
-|{introduced}      |Db              |the current object for accessing the database +|NEW               |Db              |the current object for accessing the database 
-|{introduced}      |Trans           |the current translation object                 | +|NEW               |Trans           |the current translation object                 | 
-|{introduced}      |App             |the current application/core object            |  +|NEW               |App             |the current application/core object            |  
-|{introduced}      |PageId          |the ID of the current page                     | +|NEW               |PageId          |the ID of the current page                     | 
-|{introduced}      |BlockId         |the ID of the current block                    | +|NEW               |BlockId         |the ID of the current block                    | 
-|{introduced}      |SectionId       |the ID of the current section                  |+|NEW               |SectionId       |the ID of the current section                  |
 |WB_URL            |AppUrl          |http: ⁄⁄ example.com/wb/                                                     | |WB_URL            |AppUrl          |http: ⁄⁄ example.com/wb/                                                     |
-|WB_REL            |AppRel          |/wb/                                                                         |+|WB_REL            |AppRel          |/wb/  (absolute path from DOCUMENT_ROOT, for use as a relative URL)                                                                      |
 |WB_PATH           |AppPath         |/var/www/httpdocs/wb/ \\ alternatively, in Windows  ('c:/var/www/httpdocs/wb/' | |WB_PATH           |AppPath         |/var/www/httpdocs/wb/ \\ alternatively, in Windows  ('c:/var/www/httpdocs/wb/' |
 |ADMIN_URL         |AcpUrl          |http: ⁄⁄ example.com/wb/admin/                                               | |ADMIN_URL         |AcpUrl          |http: ⁄⁄ example.com/wb/admin/                                               |
Line 42: Line 42:
 |TEMPLATE          |Template        |MyTemplate             | |TEMPLATE          |Template        |MyTemplate             |
 |TEMPLATE_DIR      |TemplateDir     |templates/MyTemplate/  | |TEMPLATE_DIR      |TemplateDir     |templates/MyTemplate/  |
-|{introduced}      |TemplateUrl     |http: ⁄⁄ example.com/wb/templates/MyTemplate/ +|NEW               |TemplateUrl     |http: ⁄⁄ example.com/wb/templates/MyTemplate/ 
-|{introduced}      |TemplateRel     |/wb/templates/MyTemplate/ +|NEW               |TemplateRel     |/wb/templates/MyTemplate/ 
-|{introduced}      |TemplatePath    |/var/www/httpdocs/wb/templates/MyTemplate/  |+|NEW               |TemplatePath    |/var/www/httpdocs/wb/templates/MyTemplate/  |
 |ADMIN_DIRECTORY   |AcpDir          |admin/                                                                       | |ADMIN_DIRECTORY   |AcpDir          |admin/                                                                       |
 |PAGES_DIRECTORY   |PagesDir        |pages/                                                                       | |PAGES_DIRECTORY   |PagesDir        |pages/                                                                       |
Line 51: Line 51:
 |WB_REVISION       |AppRevision     |2060                                                                         | |WB_REVISION       |AppRevision     |2060                                                                         |
 |WB_SP             |AppServicePack  |SP1                                                                          | |WB_SP             |AppServicePack  |SP1                                                                          |
-|{introduced}  |AppName         |WebsiteBaker                                                                 |+|NEW               |AppName         |WebsiteBaker                                                                 |
 |STRING_DIR_MODE   |DirModeString   | %%rwxrwxr-x%%   (textual representation, corresponds to 0775 octal)                                                           | |STRING_DIR_MODE   |DirModeString   | %%rwxrwxr-x%%   (textual representation, corresponds to 0775 octal)                                                           |
 |OCTAL_DIR_MODE    |DirModeOctal    | %%509%% (stored integer, corresponds to 0775 written in octal)  | |OCTAL_DIR_MODE    |DirModeOctal    | %%509%% (stored integer, corresponds to 0775 written in octal)  |
Line 86: Line 86:
  
 ===== Application of WbAdaptor ===== ===== Application of WbAdaptor =====
-This class can be reached from anywhere. It is sufficient to import that only existing active instance of the class with\\ <php> $oReg = WbAdaptor::getInstance(); </php> to import into the current scope. +This class can be reached from anywhere. It is sufficient to import that only existing active instance of the class with\\ <php> $oReg = \bin\WbAdaptor::getInstance(); </php> to import into the current scope. 
 But even better is the use of dependency injection, i.e. the transfer of the instance from outside to the function or class. But even better is the use of dependency injection, i.e. the transfer of the instance from outside to the function or class.
  
en/dev/284/registry.txt · Last modified: 26.09.2023 07:14 by Manuela v.d.Decken