SharenGo Wiki
About Sharengo
- SharenGo
- Members
- Join us
- Contact

Methodology
- Methodology

Tools
- PragMaTic
- ABS
- JsRIA

Projects
- MarcoPolo

Components Directory

Infrastructure
- HAPlatForm

Legal

Community
- Tracker
- MailingLists

Wiki
- WikiHelp
- RecentChanges
- RSS
- WikiSearch

Model2Java

Java Layout


Stereotypes :
<<class>>
<<interface>>
<<exception>>

Hibernate Layout


Stereotype : <<entity>> applied on ModelClass
Stereotype : <<PrimaryKey>> applied on Attribute
TODO used [ordered]

Gluon Framework Layout


Stereotypes :
<<servlet>>
<<ui>>
<<view>>
<<process>>
<<entitiesmgr>>
<<rsi>>

Another Configuration Mechanism.

http://www.martinfowler.com/articles/injection.html
French version : http://www.dotnetguru.org/articles/dossiers/ioc/Fowler/IoC.htm#ConstructorInjectionWithPicocontainer

Dependency with fr.openmodel.configuration.I_Configuration or fr.argia.configuration or others are an anti-pattern.

You can implement Ioc pattern like Spring, picoContainer or others.

Just an idea :

In all architectures we had a bootstrap mechanism :
- init method in servlet
- main method in Command line interface

My idea is implement Ioc mechanism in this bootstrap in order to replace configuration dependencies.

An example :

public class MyServlet{
 private MyUI ui1=null;
 public void init(){
   MutablePicoContainer pico = new DefaultPicoContainer();
   String key = "MyUI";
   String implClass=Class.forName(context.lookup("java:comp/env/factory/MyUI");
   pico.registerComponentImplementation(key,implClass);
   key = "MyProcess";
   implClass=Class.forName(context.lookup("java:comp/env/factory/MyProcess");
   pico.registerComponentImplementation(key,implClass);
   this.ui1= = (MyUI) pico.getComponentInstance("MyUI");
 }
}
public class Impl_UI1{
 private MyProcess prc1=null;
 public void setMyProcess(MyProcess process){
   this.prc1=process;
 }
 public void myUIMethod(){
   //code action here
 }
}
 
unit testing is easier

Model2Java is mentioned on: PragMaTic


VeryQuickWiki Version 2.7.1 | Admin
Contact -