Hey Fiorenzo!
I've FINALLY had a chance to take a look at this. It looks great! One
comment about your tests though :)
You do a lot of this:
`assertTrue(content.contains("javax.ejb.TransactionAttributeType"));`
Instead, however, you should probably call:
`javaSource.hasImport("javax.ejb.TransactionAttributeType")`
and
javaSource.hasAnnotation("javax.ejb.TransactionAttribute");
instead of doing string comparisons.
Otherwise, though, this looks awesome! Does your plugin help with
configuring @MessageDriven beans to actually connect to a JMS queue? Just a
thought maybe for the next version :)
~Lincoln
On Wed, Sep 12, 2012 at 7:25 PM, JFlower <fiorenzino(a)gmail.com> wrote:
Hi Lincoln,
my ejb plugin is ready to meet your eyes:
https://github.com/fiorenzino/core/tree/FORGE-610/javaee-impl/src/main/ja...
initial test:
https://github.com/fiorenzino/core/blob/FORGE-610/javaee-impl/src/test/ja...
i need to do some works before close:
- add more tests (for all functionality)
- add more parameters on mdb configuration
- add clusterable annotation
- add transaction on methods
- permit undo/change (revert/change configuration)
*I'm waiting for your comments on my slow work (..unfortunately my free
time is limited...)*
*
*
bye
fiorenzo
PS: the fucked Mdb annotation at end was:
javaClass.addImport(ActivationConfigProperty.class);
javaClass.addImport(MessageDriven.class);
javaClass.addImport(Message.class);
javaClass.addInterface(MessageListener.class);
javaClass.addMethod("public void onMessage(Message message) {}");
javaClass.addAnnotation(javaClassType.MESSAGEDRIVEN.getAnnotation())
.setLiteralValue("name", "\"" + name + "\"")
.setLiteralValue("activationConfig",
"{@ActivationConfigProperty(propertyName = \"destinationType\",
propertyValue = \""+ destinationType+ "\"), " +
"@ActivationConfigProperty(propertyName = \"destination\", propertyValue
= \""+ destinationName + "\")" + "}");
_______________________________________________
forge-dev mailing list
forge-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/forge-dev
--
Lincoln Baxter, III
http://ocpsoft.org
"Simpler is better."