[Yanel-dev] shared library

Paul Bakker p.bakker at sourcesense.com
Thu Oct 14 10:56:39 CEST 2010


Dear Cedric,

Thanks a lot. I'll try your approach.

Best,
Paul

2010/10/14 Cedric Staub <cedric.staub at wyona.com>

> Hi
>
> On Wed, Oct 13, 2010 at 05:35:12PM +0100, Paul Bakker wrote:
> > Can you recommend an approach for where to put utility classes that
> contain
> > methods that could be used by several resource types?
>
> Personally, I like to do it this way:
>
> 1. I create a new resource type, e.g. my-shared-resource.
>
> 2. I let the resource type be packaged into a jar file by creating a
> pom.xml file within src/build. Here's an example from our newly released
> konakart-yanel-realm's shared resource:
>
> <?xml version=3D"1.0"?>
> <project>
>  <modelVersion>4.0.0</modelVersion>
>  <groupId>wyona-org-yanel</groupId>
>  <artifactId>yanel-resource- at NAME@</artifactId>
>  <version>@VERSION@</version>
> </project>
>
> 3. Then you'll need to add that resource to the dependencies of your
> other resources by writing it into src/build/dependencies.xml:
>
> <dependency groupId=3D"wyona-org-yanel"
> artifactId=3D"yanel-resource-konakart-shared" version=3D"0.0.1-dev-rXXX"/>
>
> 4. And last but not least, add the resource to your realm's
> resource-types.xml. But make sure to put it at the top of the list, so
> it gets compiled before all the other resources.
>
> You can look at our konakart-yanel-realm as an example:
>
> http://svn.wyona.com/repos/public/yanel/contributions/realms/konakart-yan=
el-realm/
>
> The shared resource there is simply called "shared".
>
> Greetings,
> Cedric
> --
> Yanel-development mailing list Yanel-development at wyona.com
> http://lists.wyona.org/cgi-bin/mailman/listinfo/yanel-development
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.wyona.org/pipermail/yanel-development/attachments/2010101=
4/3d28eb60/attachment.htm


More information about the Yanel-development mailing list