Overview of Grails project structure -


i'm trying find overview grails project structure, possible. see, not projects used default structure generated "grails create-app"

%project_home%     + grails-app        + conf                 ---> location of configuration artifacts             + hibernate        ---> optional hibernate config            + spring           ---> optional spring config        + controllers          ---> location of controller artifacts        + domain               ---> location of domain classes        + i18n                 ---> location of message bundles i18n        + services             ---> location of services        + taglib               ---> location of tag libraries        + util                 ---> location of special utility classes         + views                ---> location of views            + layouts          ---> location of layouts    + lib    + scripts                  ---> scripts    + src        + groovy               ---> optional; location groovy source files                                    (of types other in grails-app/*)        + java                 ---> optional; location java source files    + test                     ---> generated test classes    + web-app        + web-inf 

is there more default folder grails? (for instance, saw grails-app/jobs)

the directory structure followed part applications because artifacts defined root folder. controller class names end in 'controller', , taglibs , services have similar naming conventions, domain classes don't have name restrictions. it's location under grails-app/domain defines groovy class domain class.

grails allows applications , plugins define artifact types however, , that's you're seeing 'jobs' folder. that's created quartz plugin. similar in dynamic-controllers plugin add new controllermixins folder under grails-app controller mixin classes kept.

the benefit of creating new artifact rather keeping code under src/groovy it's simple support reloading in development mode, , groups code logically rather dumping 1 folder (src/groovy) , relying on packages keep things separate. have quick access artifacts of type. application.getdomainclasses() returns domain classes, method dynamically resolved if have quartz installed automatically support application.getjobclasses() without having register or configure beyond standard artifact registration.


Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -