[jboss-dev-forums] [Embedded JBoss Development] - Re: ShrinkWrap - Descriptors

epbernard do-not-reply at jboss.com
Mon Sep 28 09:46:08 EDT 2009


"aslak" wrote : 
  | They all 'share' the same base Archive impl as a backing, so there is no problem having code like this:
  | 
  | 
  |   | WebArchive war = new WebArchiveImpl(new MemoryMapArchiveImpl());
  |   | EnterpriseArchive ear = new EnterpriseArchiveImpl(war.getInternalArchive());
  |   | 
  | 

well this code is fugly, that's a huge problem :)

anonymous wrote : 
  | 
  |   | EnterpriseArchive ear = new EnterpriseArchiveImpl(new MemoryMapArchiveImpl());
  |   | WebArchive war = ear.getWebModule("my.war");
  |   | 
  | 
That's a different scenario here, you are creating a new archive so a dedicated method makes sense.

anonymous wrote : 
  | This should of course be hidden away in some 'specializes' like api, but the point is the same.
  | 
Still it seems to me that delegation is less heavy on the specializer implementation and subclassing the core archive impl does not give you much.

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4257372#4257372

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4257372



More information about the jboss-dev-forums mailing list