ãã¼ã¿ãã¼ã¹ã¨ Doctrine (âThe Modelâ)¶ ç¾å®ãèªããããã©ããªã¢ããªã±ã¼ã·ã§ã³ã«ã¨ã£ã¦ãããã¼ã¿ãã¼ã¹ã¸ã®æ å ±ã®æ°¸ç¶åããã¼ã¿ãã¼ã¹ããã®æ å ±ã®åå¾ã¯ãæããã使ãããããã¦ãã£ã¬ã³ã¸ãããã®ããã¿ã¹ã¯ã§ãããã®ã¿ã¹ã¯ãç°¡åã«ããªããã¨ãã§ããå¼·åãªãã¼ã«ãæä¾ãããã¨ãããã ä¸ç¹ã®ç®çã ãã«ç¹åãã Doctrine ã¨ããã©ã¤ãã©ãªãã幸éãªãã¨ã«ã Symfony ã¯çµ±åãã¦ãã¾ãããã®ç« ã§ã¯ãDoctrine ã®åºæ¬çãªãã£ãã½ãã£ã¨ãã©ãã ãç°¡åã«ãã¼ã¿ãã¼ã¹ã使ããã¨ãã§ããããã¨ããç¹ãè¦ã¦ããã¾ãã Note Doctrine èªä½ã¯ãSymfony ã¨ã¯å®å ¨ã«ç¬ç«ãã¦ãã¦ãSymfony ã§ä½¿ç¨ãããã¨ã¯ãªãã·ã§ã³ã§ãããã®ç« ã¯ããªãã¸ã§ã¯ãã¨ãªã¬ã¼ã·ã§ãã«ãã¼ã¿ãã¼ã¹(MySQL ã PostgreSQLãMicrosoft SQL)ãããããã
Doctrine2ã¯PHPã®ORMã§PHP5.3.0以éã«å¯¾å¿ãã¦ããã©ã¤ãã©ãªã§ãã Doctrine1ããã§ã«åå¨ãã¦ãã¾ãããæ§ã ãªä¾¿å©ãªæ©è½ã追å ããããã«å¼·åã«ãªã£ã¦ãã¾ãã ãã ããè²ã ã§ããã¨ãããã¨ã¯è¦ãããã¨ãå¤ãã¨ãããã¨ã§å®éã«Doctrine2ã触ã£ã¦ã¿ã¦ãã®ä¸çã«è§¦ãã¦ã¿ããã¨æãã¾ãã ä»åã¯ã¤ã³ã¹ãã¼ã«ããORMã使ã£ã¦ãã¼ã¿ãã¼ã¹ã¨ä¼è©±ãã¦ã¿ã¦ãã®ç¹å¾´ãè¦ã¦ã¿ããã¨æãã¾ãã å¿ é æ¡ä»¶ Doctrine2ã¯å¤§ãã3ã¤ã®ããã±ã¼ã¸ããæ§æããã¦ãã¾ãã Commonããã±ã¼ã¸ ä»ã®ã©ã¤ãã©ãªã«ä¾åãã¦ããªãåå©ç¨æ§ã®ããã©ã¤ãã©ãªãã¾ã¨ããããã±ã¼ã¸ãã³ã¬ã¯ã·ã§ã³ã®ã©ã¤ãã©ãªãªã©ãå«ã¾ãã¦ãã¾ãã DBALããã±ã¼ã¸ PDOã®èãä¸çªä¸ã®ã©ããã¼ã«ãªãã¾ããèãã¨ããã®ã¯DBã®æ¹è¨ã®éããå¸åãããã¨ã ããç®çããã®ããã±ã¼ã¸ã¯Commonããã±ã¼ã¸ãå«ã
FuelPHP Advent Calendar 2012ã®19æ¥ç®æ å½ã®@ttikittã§ãã æ¨æ¥ã¯@tmd45ããã®ããããã®ã¬ã³ã¿ã«ãµã¼ã㧠FuelPHP ã使ã£ã¦ã¯ã¦ãªãã¤ã¯ããã°ãä½ãï¼ViewModel ã使ã£ã¦ã¿ãç·¨ãã§ããã æ¬æ¥ã®ãã¼ãã¯ãå¤é¨ã©ã¤ãã©ãªã®çµã¿è¾¼ã¿ãã§ãã fuelphpã¯æ¡å¼µæ§ã«å¯ãã ãã¬ã¼ã ã¯ã¼ã¯ã§ãå¤é¨ã©ã¤ãã©ãªãåãè¾¼ãã§ã容æã«æ¡å¼µããäºãã§ãã¾ãã ã¨ã¯ãããã®ã®å ·ä½çã«è§¦ãããã¦ããæ©ä¼ããã¾ããªãã®ã§ãORMã©ã¤ãã©ãªã®çµã¿è¾¼ã¿ã«ã¤ãã¦ç´¹ä»ãã¾ãã å 人ãå± ãã¾ããããããã¡ãã®ãªãã¸ããªãå ã«è§£èª¬ã»èª¿æ´ãã¾ãã aspendigital/fuel-doctrine2 çµã¿è¾¼ãã©ã¤ãã©ãªã«ã¤ãã¦ã¯ãã¡ãã Doctrine2 ORMï¼doctrine projectï¼ ãªããfuelphpã®ormããã±ã¼ã¸ãè²ã ãªæ©è½ãæã£ã¦ãã¾ãã ã©
åãã¾ãã¦ã社å ã«ããã»ã¨ãã©ã®ããã°ã©ãã¼ãpropelã®ä¸ãããªãdoctrineãå¦ãã ããããå¹³æçã¾ã(20æ³)ãæ°åã®itaniã§ãã symfonyãå¦ãã ã¨ãã«ããããªè¨äºããã£ãããããªãã¨æã£ãã®ã§æ¸ããã¨ã«ãã¾ããã ã¨ããããã§ãsymfonyã触ã£ã¦ã¾ã éããªãåããä»åã¯doctrineã使ã£ã¦DBã®åºæ¬æä½ãç´¹ä»ãã¾ãã â»symfonyã®versionã¯1.4ã使ç¨ãã¾ãã DBã®æºå ã¾ãã¯DBã®æºåããã¾ãã symfonyã使ã£ã¦DBãä½ãã«ã¯ã¾ãã¹ãã¼ããä½ããªããã°ããã¾ããã ã¹ãã¼ããä½ãæ¹æ³ã¯ï¼ã¤ããã¾ãã ï¼ãèªåã§schema.ymlãæ¸ã config/doctrine/schema.ymlã«ãã¼ãã«ã®æ§é ãYAMLãã©ã¼ãããã§æ¸ãã¾ãã //ä»å使ãDBã®schema.yml User: columns: name: { type:
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}