ObjectTable question & Annotations

View: New views
20 Messages — Rating Filter:   Alert me  
< Prev | 1 - 2 - 3 | Next >

ObjectTable question & Annotations

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello everyone!

I give Trails a go and I have some questions:

1. Is it possible to mark getter Methode using Annotations in order to
definde which columns should be displayed inside on an ObjectsTable or does it mean writing a ITableColumn implementation for every single entity?


2. How do you link from a row "cell" inside an ObjectsTable row to another page?

3. How do you replace a status column id with an image?

Cheers!

Toby

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


RE: ObjectTable question & Annotations

by nhhockeyplayer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I can offer insight to #3

Support is already built into ObjectTable to display images. I am doing this now successfully. It has been air tight for some time now. But... not all the support for this KIND of rendering in the table lives in trails-core... you need to go into the examples and track down the usage of UploadableMedia.JAVA and assemble yourself how-to. Roster models everything for collections many-to-one, one-to-many and one-to-one using imagery.

I tried to get this KIND of e-frastructure part of trails-core but was prevented in order to keep the framework trim.

Take a look at the hibernate classic roster example. It uses Uploadablemedia as a type for POJO properties that are characterized as docs, images, clips or anything that is a BLOB.

Example in ROSTER...

Person.JAVA (every person has a photo)
    private UploadableMedia photo = new UploadableMedia();

    @BlobDescriptor(renderType = RenderType.IMAGE, contentDisposition = ContentDisposition.ATTACHMENT)
    @PropertyDescriptor(summary = true, index = 1)
    @OneToOne(cascade = CascadeType.ALL)
    public UploadableMedia getPhoto()
    {
        return photo;
    }

ObjectTable is already geared to detect this KIND of property in this pojo and render it on the table as-is (in the form of a clickable/downloadable image).

Happy trails...
Best regards
Ken in nashua

> Date: Thu, 11 Oct 2007 16:45:53 +0200
> From: superoverdrive@...
> To: users@...
> Subject: [trails-users] ObjectTable question & Annotations
>
> Hello everyone!
>
> I give Trails a go and I have some questions:
>
> 1. Is it possible to mark getter Methode using Annotations in order to
> definde which columns should be displayed inside on an ObjectsTable or does it mean writing a ITableColumn implementation for every single entity?
>
>
> 2. How do you link from a row "cell" inside an ObjectsTable row to another page?
>
> 3. How do you replace a status column id with an image?
>
> Cheers!
>
> Toby
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
> http://xircles.codehaus.org/manage_email
>


Peek-a-boo FREE Tricks & Treats for You! Get 'em!
Best regards
Ken in nashua

RE: ObjectTable question & Annotations

by nhhockeyplayer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

More insight to #3

ObjectTable.HTML
...
        <div jwcid="blobColumnValue@Block">
            <!-- render if the descriptor supports and actually has a blob -->
            <span jwcid="@If" condition="ognl:column.propertyDescriptor.supportsExtension(@org.trails.descriptor.BlobDescriptorExtension@class)">
                <span jwcid="@TrailsDownload"
                      propertyDescriptor="ognl:column.propertyDescriptor"
                      model="ognl:object"   
                      bytes="ognl:object[#this.column.propertyDescriptor.name]"
                    />

            </span>
        </div>

blobColumnValue is a column override...

If the column is a BLOB, reach into the database and pull out the blob (UploadableMedia) use the TrailsDownload component to render it.

Done...

Best regards
Ken in nashua


From: nhhockeyplayer@...
To: users@...
Date: Thu, 11 Oct 2007 11:05:23 -0400
Subject: RE: [trails-users] ObjectTable question & Annotations

I can offer insight to #3

Support is already built into ObjectTable to display images. I am doing this now successfully. It has been air tight for some time now. But... not all the support for this KIND of rendering in the table lives in trails-core... you need to go into the examples and track down the usage of UploadableMedia.JAVA and assemble yourself how-to. Roster models everything for collections many-to-one, one-to-many and one-to-one using imagery.

I tried to get this KIND of e-frastructure part of trails-core but was prevented in order to keep the framework trim.

Take a look at the hibernate classic roster example. It uses Uploadablemedia as a type for POJO properties that are characterized as docs, images, clips or anything that is a BLOB.

Example in ROSTER...

Person.JAVA (every person has a photo)
    private UploadableMedia photo = new UploadableMedia();

    @BlobDescriptor(renderType = RenderType.IMAGE, contentDisposition = ContentDisposition.ATTACHMENT)
    @PropertyDescriptor(summary = true, index = 1)
    @OneToOne(cascade = CascadeType.ALL)
    public UploadableMedia getPhoto()
    {
        return photo;
    }

ObjectTable is already geared to detect this KIND of property in this pojo and render it on the table as-is (in the form of a clickable/downloadable image).

Happy trails...
Best regards
Ken in nashua

> Date: Thu, 11 Oct 2007 16:45:53 +0200
> From: superoverdrive@...
> To: users@...
> Subject: [trails-users] ObjectTable question & Annotations
>
> Hello everyone!
>
> I give Trails a go and I have some questions:
>
> 1. Is it possible to mark getter Methode using Annotations in order to
> definde which columns should be displayed inside on an ObjectsTable or does it mean writing a ITableColumn implementation for every single entity?
>
>
> 2. How do you link from a row "cell" inside an ObjectsTable row to another page?
>
> 3. How do you replace a status column id with an image?
>
> Cheers!
>
> Toby
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
> http://xircles.codehaus.org/manage_email
>


Peek-a-boo FREE Tricks & Treats for You! Get 'em!


Boo! Scare away worms, viruses and so much more! Try Windows Live OneCare! Try now!
Best regards
Ken in nashua

Re: RE: ObjectTable question & Annotations

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks!

I have found a solution to #1:

@PropertyDescriptor(hidden=true)

BUT: Imagine you re-use the objects in several contexts, i.e.
you have a user, an admin and different roles and need to define the visibility as well as editability dynamically - PropertyDescriptior would
not work.

If I may utter a wish for the Trails Wiki or examples page, what about:

- CRUD application for 3 different roles that is localized in 2 languages!

- Admin: sees everything, can edit everything
- User: sees everything apart from 2 or 3 columns,
can edit only 1 or 2 columns
- SomeOtherRole: sees all colunns but may only edit some other columns

It would be cool if there was a standard way of doing that easily in Trails, without having to write lots of code or without having to use lots of conditions and different templates.



-------- Original-Nachricht --------
> Datum: Thu, 11 Oct 2007 11:05:23 -0400
> Von: Ken nashua <nhhockeyplayer@...>
> An: users@...
> Betreff: RE: [trails-users] ObjectTable question & Annotations

>
> I can offer insight to #3
>
> Support is already built into ObjectTable to display images. I am doing
> this now successfully. It has been air tight for some time now. But... not
> all the support for this KIND of rendering in the table lives in
> trails-core... you need to go into the examples and track down the usage of
> UploadableMedia.JAVA and assemble yourself how-to. Roster models everything for
> collections many-to-one, one-to-many and one-to-one using imagery.
>
> I tried to get this KIND of e-frastructure part of trails-core but was
> prevented in order to keep the framework trim.
>
> Take a look at the hibernate classic roster example. It uses
> Uploadablemedia as a type for POJO properties that are characterized as docs, images,
> clips or anything that is a BLOB.
>
> Example in ROSTER...
>
> Person.JAVA (every person has a photo)
>     private UploadableMedia photo = new UploadableMedia();
>
>     @BlobDescriptor(renderType = RenderType.IMAGE, contentDisposition =
> ContentDisposition.ATTACHMENT)
>     @PropertyDescriptor(summary = true, index = 1)
>     @OneToOne(cascade = CascadeType.ALL)
>     public UploadableMedia getPhoto()
>     {
>         return photo;
>     }
>
> ObjectTable is already geared to detect this KIND of property in this pojo
> and render it on the table as-is (in the form of a clickable/downloadable
> image).
>
> Happy trails...
> Best regards
> Ken in nashua
>
> > Date: Thu, 11 Oct 2007 16:45:53 +0200
> > From: superoverdrive@...
> > To: users@...
> > Subject: [trails-users] ObjectTable question & Annotations
> >
> > Hello everyone!
> >
> > I give Trails a go and I have some questions:
> >
> > 1. Is it possible to mark getter Methode using Annotations in order to
> > definde which columns should be displayed inside on an ObjectsTable or
> does it mean writing a ITableColumn implementation for every single entity?
> >
> >
> > 2. How do you link from a row "cell" inside an ObjectsTable row to
> another page?
> >
> > 3. How do you replace a status column id with an image?
> >
> > Cheers!
> >
> > Toby
> >
> > ---------------------------------------------------------------------
> > To unsubscribe from this list please visit:
> >
> >     http://xircles.codehaus.org/manage_email
> >
>
> _________________________________________________________________
> Peek-a-boo FREE Tricks & Treats for You!
> http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


Re: RE: ObjectTable question & Annotations

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Regarding #1:

What about overriding the object in order to have different Annotations for
the visibility?

e.g.

MyAdminObject extends MyObject

@PropertyDescriptor(hidden=false)

        public String emailAddress() {
    return this.emailAddress;
       }


MyUserObject extends MyObject

@PropertyDescriptor(hidden=true)

        public String emailAddress() {
    return this.emailAddress;
       }


But how do you make sure, that Trails does not create Tables for
MyAdminObject and MyUserObject ?

Tobias

-------- Original-Nachricht --------
> Datum: Thu, 11 Oct 2007 17:16:02 +0200
> Von: "Tobias Marx" <superoverdrive@...>
> An: users@...
> Betreff: Re: RE: [trails-users] ObjectTable question & Annotations

> Thanks!
>
> I have found a solution to #1:
>
> @PropertyDescriptor(hidden=true)
>
> BUT: Imagine you re-use the objects in several contexts, i.e.
> you have a user, an admin and different roles and need to define the
> visibility as well as editability dynamically - PropertyDescriptior would
> not work.
>
> If I may utter a wish for the Trails Wiki or examples page, what about:
>
> - CRUD application for 3 different roles that is localized in 2 languages!
>
> - Admin: sees everything, can edit everything
> - User: sees everything apart from 2 or 3 columns,
> can edit only 1 or 2 columns
> - SomeOtherRole: sees all colunns but may only edit some other columns
>
> It would be cool if there was a standard way of doing that easily in
> Trails, without having to write lots of code or without having to use lots of
> conditions and different templates.
>
>
>
> -------- Original-Nachricht --------
> > Datum: Thu, 11 Oct 2007 11:05:23 -0400
> > Von: Ken nashua <nhhockeyplayer@...>
> > An: users@...
> > Betreff: RE: [trails-users] ObjectTable question & Annotations
>
> >
> > I can offer insight to #3
> >
> > Support is already built into ObjectTable to display images. I am doing
> > this now successfully. It has been air tight for some time now. But...
> not
> > all the support for this KIND of rendering in the table lives in
> > trails-core... you need to go into the examples and track down the usage
> of
> > UploadableMedia.JAVA and assemble yourself how-to. Roster models
> everything for
> > collections many-to-one, one-to-many and one-to-one using imagery.
> >
> > I tried to get this KIND of e-frastructure part of trails-core but was
> > prevented in order to keep the framework trim.
> >
> > Take a look at the hibernate classic roster example. It uses
> > Uploadablemedia as a type for POJO properties that are characterized as
> docs, images,
> > clips or anything that is a BLOB.
> >
> > Example in ROSTER...
> >
> > Person.JAVA (every person has a photo)
> >     private UploadableMedia photo = new UploadableMedia();
> >
> >     @BlobDescriptor(renderType = RenderType.IMAGE, contentDisposition =
> > ContentDisposition.ATTACHMENT)
> >     @PropertyDescriptor(summary = true, index = 1)
> >     @OneToOne(cascade = CascadeType.ALL)
> >     public UploadableMedia getPhoto()
> >     {
> >         return photo;
> >     }
> >
> > ObjectTable is already geared to detect this KIND of property in this
> pojo
> > and render it on the table as-is (in the form of a
> clickable/downloadable
> > image).
> >
> > Happy trails...
> > Best regards
> > Ken in nashua
> >
> > > Date: Thu, 11 Oct 2007 16:45:53 +0200
> > > From: superoverdrive@...
> > > To: users@...
> > > Subject: [trails-users] ObjectTable question & Annotations
> > >
> > > Hello everyone!
> > >
> > > I give Trails a go and I have some questions:
> > >
> > > 1. Is it possible to mark getter Methode using Annotations in order to
> > > definde which columns should be displayed inside on an ObjectsTable or
> > does it mean writing a ITableColumn implementation for every single
> entity?
> > >
> > >
> > > 2. How do you link from a row "cell" inside an ObjectsTable row to
> > another page?
> > >
> > > 3. How do you replace a status column id with an image?
> > >
> > > Cheers!
> > >
> > > Toby
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe from this list please visit:
> > >
> > >     http://xircles.codehaus.org/manage_email
> > >
> >
> > _________________________________________________________________
> > Peek-a-boo FREE Tricks & Treats for You!
> > http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
>     http://xircles.codehaus.org/manage_email


---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


Re: RE: ObjectTable question & Annotations

by pfrancav :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi, I think that this is not a good OO Approach, just because we are changing out model because a presentation issue. I think that the Object it´s the same and the Role or permission to edit it must be handled in another place or tier.

It's just my opinion, I just start trying Trails and I haven't a lot of knowledge of them.

On 10/11/07, superoverdrive@... <superoverdrive@...> wrote:
Regarding #1:

What about overriding the object in order to have different Annotations for
the visibility?

e.g.

MyAdminObject extends MyObject

@PropertyDescriptor(hidden=false)

        public String emailAddress() {
        return this.emailAddress;
       }


MyUserObject extends MyObject

@PropertyDescriptor(hidden=true)

        public String emailAddress() {
        return this.emailAddress;
       }


But how do you make sure, that Trails does not create Tables for
MyAdminObject and MyUserObject ?

Tobias

-------- Original-Nachricht --------
> Datum: Thu, 11 Oct 2007 17:16:02 +0200
> Von: "Tobias Marx" <superoverdrive@...>
> An: users@...
> Betreff: Re: RE: [trails-users] ObjectTable question & Annotations

> Thanks!
>
> I have found a solution to #1:
>
> @PropertyDescriptor(hidden=true)
>
> BUT: Imagine you re-use the objects in several contexts, i.e.
> you have a user, an admin and different roles and need to define the
> visibility as well as editability dynamically - PropertyDescriptior would
> not work.
>
> If I may utter a wish for the Trails Wiki or examples page, what about:
>
> - CRUD application for 3 different roles that is localized in 2 languages!
>
> - Admin: sees everything, can edit everything
> - User: sees everything apart from 2 or 3 columns,
> can edit only 1 or 2 columns
> - SomeOtherRole: sees all colunns but may only edit some other columns
>
> It would be cool if there was a standard way of doing that easily in
> Trails, without having to write lots of code or without having to use lots of
> conditions and different templates.
>
>
>
> -------- Original-Nachricht --------
> > Datum: Thu, 11 Oct 2007 11:05:23 -0400
> > Von: Ken nashua <nhhockeyplayer@... >
> > An: users@...
> > Betreff: RE: [trails-users] ObjectTable question & Annotations
>
> >
> > I can offer insight to #3
> >
> > Support is already built into ObjectTable to display images. I am doing
> > this now successfully. It has been air tight for some time now. But...
> not
> > all the support for this KIND of rendering in the table lives in
> > trails-core... you need to go into the examples and track down the usage
> of
> > UploadableMedia.JAVA and assemble yourself how-to. Roster models
> everything for
> > collections many-to-one, one-to-many and one-to-one using imagery.
> >
> > I tried to get this KIND of e-frastructure part of trails-core but was
> > prevented in order to keep the framework trim.
> >
> > Take a look at the hibernate classic roster example. It uses
> > Uploadablemedia as a type for POJO properties that are characterized as
> docs, images,
> > clips or anything that is a BLOB.
> >
> > Example in ROSTER...
> >
> > Person.JAVA (every person has a photo)
> >     private UploadableMedia photo = new UploadableMedia();
> >
> >     @BlobDescriptor(renderType = RenderType.IMAGE, contentDisposition =
> > ContentDisposition.ATTACHMENT)
> >     @PropertyDescriptor(summary = true, index = 1)
> >     @OneToOne(cascade = CascadeType.ALL)
> >     public UploadableMedia getPhoto()
> >     {
> >         return photo;

> >     }
> >
> > ObjectTable is already geared to detect this KIND of property in this
> pojo
> > and render it on the table as-is (in the form of a
> clickable/downloadable
> > image).
> >
> > Happy trails...
> > Best regards
> > Ken in nashua
> >
> > > Date: Thu, 11 Oct 2007 16:45:53 +0200
> > > From: superoverdrive@...
> > > To: users@...
> > > Subject: [trails-users] ObjectTable question & Annotations
> > >
> > > Hello everyone!
> > >
> > > I give Trails a go and I have some questions:
> > >
> > > 1. Is it possible to mark getter Methode using Annotations in order to
> > > definde which columns should be displayed inside on an ObjectsTable or
> > does it mean writing a ITableColumn implementation for every single
> entity?
> > >
> > >
> > > 2. How do you link from a row "cell" inside an ObjectsTable row to
> > another page?
> > >
> > > 3. How do you replace a status column id with an image?
> > >
> > > Cheers!
> > >
> > > Toby
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe from this list please visit:
> > >
> > >     http://xircles.codehaus.org/manage_email
> > >
> >
> > _________________________________________________________________
> > Peek-a-boo FREE Tricks & Treats for You!
> > http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
>     http://xircles.codehaus.org/manage_email


---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email



Re: RE: ObjectTable question & Annotations

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

It would not be "real" objects, just pseudo-objects similiar to database views that are not real tables.

-------- Original-Nachricht --------
> Datum: Thu, 11 Oct 2007 12:58:00 -0300
> Von: "Pablo Francavilla" <pfrancav@...>
> An: users@...
> Betreff: Re: RE: [trails-users] ObjectTable question & Annotations

> Hi, I think that this is not a good OO Approach, just because we are
> changing out model because a presentation issue. I think that the Object
> it´s the same and the Role or permission to edit it must be handled in
> another place or tier.
>
> It's just my opinion, I just start trying Trails and I haven't a lot of
> knowledge of them.
>
> On 10/11/07, superoverdrive@... <superoverdrive@...> wrote:
> >
> > Regarding #1:
> >
> > What about overriding the object in order to have different Annotations
> > for
> > the visibility?
> >
> > e.g.
> >
> > MyAdminObject extends MyObject
> >
> > @PropertyDescriptor(hidden=false)
> >
> >         public String emailAddress() {
> >         return this.emailAddress;
> >        }
> >
> >
> > MyUserObject extends MyObject
> >
> > @PropertyDescriptor(hidden=true)
> >
> >         public String emailAddress() {
> >         return this.emailAddress;
> >        }
> >
> >
> > But how do you make sure, that Trails does not create Tables for
> > MyAdminObject and MyUserObject ?
> >
> > Tobias
> >
> > -------- Original-Nachricht --------
> > > Datum: Thu, 11 Oct 2007 17:16:02 +0200
> > > Von: "Tobias Marx" <superoverdrive@...>
> > > An: users@...
> > > Betreff: Re: RE: [trails-users] ObjectTable question & Annotations
> >
> > > Thanks!
> > >
> > > I have found a solution to #1:
> > >
> > > @PropertyDescriptor(hidden=true)
> > >
> > > BUT: Imagine you re-use the objects in several contexts, i.e.
> > > you have a user, an admin and different roles and need to define the
> > > visibility as well as editability dynamically - PropertyDescriptior
> > would
> > > not work.
> > >
> > > If I may utter a wish for the Trails Wiki or examples page, what
> about:
> > >
> > > - CRUD application for 3 different roles that is localized in 2
> > languages!
> > >
> > > - Admin: sees everything, can edit everything
> > > - User: sees everything apart from 2 or 3 columns,
> > > can edit only 1 or 2 columns
> > > - SomeOtherRole: sees all colunns but may only edit some other columns
> > >
> > > It would be cool if there was a standard way of doing that easily in
> > > Trails, without having to write lots of code or without having to use
> > lots of
> > > conditions and different templates.
> > >
> > >
> > >
> > > -------- Original-Nachricht --------
> > > > Datum: Thu, 11 Oct 2007 11:05:23 -0400
> > > > Von: Ken nashua <nhhockeyplayer@...>
> > > > An: users@...
> > > > Betreff: RE: [trails-users] ObjectTable question & Annotations
> > >
> > > >
> > > > I can offer insight to #3
> > > >
> > > > Support is already built into ObjectTable to display images. I am
> > doing
> > > > this now successfully. It has been air tight for some time now.
> But...
> > > not
> > > > all the support for this KIND of rendering in the table lives in
> > > > trails-core... you need to go into the examples and track down the
> > usage
> > > of
> > > > UploadableMedia.JAVA and assemble yourself how-to. Roster models
> > > everything for
> > > > collections many-to-one, one-to-many and one-to-one using imagery.
> > > >
> > > > I tried to get this KIND of e-frastructure part of trails-core but
> was
> > > > prevented in order to keep the framework trim.
> > > >
> > > > Take a look at the hibernate classic roster example. It uses
> > > > Uploadablemedia as a type for POJO properties that are characterized
> > as
> > > docs, images,
> > > > clips or anything that is a BLOB.
> > > >
> > > > Example in ROSTER...
> > > >
> > > > Person.JAVA (every person has a photo)
> > > >     private UploadableMedia photo = new UploadableMedia();
> > > >
> > > >     @BlobDescriptor(renderType = RenderType.IMAGE,
> contentDisposition
> > =
> > > > ContentDisposition.ATTACHMENT)
> > > >     @PropertyDescriptor(summary = true, index = 1)
> > > >     @OneToOne(cascade = CascadeType.ALL)
> > > >     public UploadableMedia getPhoto()
> > > >     {
> > > >         return photo;
> > > >     }
> > > >
> > > > ObjectTable is already geared to detect this KIND of property in
> this
> > > pojo
> > > > and render it on the table as-is (in the form of a
> > > clickable/downloadable
> > > > image).
> > > >
> > > > Happy trails...
> > > > Best regards
> > > > Ken in nashua
> > > >
> > > > > Date: Thu, 11 Oct 2007 16:45:53 +0200
> > > > > From: superoverdrive@...
> > > > > To: users@...
> > > > > Subject: [trails-users] ObjectTable question & Annotations
> > > > >
> > > > > Hello everyone!
> > > > >
> > > > > I give Trails a go and I have some questions:
> > > > >
> > > > > 1. Is it possible to mark getter Methode using Annotations in
> order
> > to
> > > > > definde which columns should be displayed inside on an
> ObjectsTable
> > or
> > > > does it mean writing a ITableColumn implementation for every single
> > > entity?
> > > > >
> > > > >
> > > > > 2. How do you link from a row "cell" inside an ObjectsTable row to
> > > > another page?
> > > > >
> > > > > 3. How do you replace a status column id with an image?
> > > > >
> > > > > Cheers!
> > > > >
> > > > > Toby
> > > > >
> > > > >
> > ---------------------------------------------------------------------
> > > > > To unsubscribe from this list please visit:
> > > > >
> > > > >     http://xircles.codehaus.org/manage_email
> > > > >
> > > >
> > > > _________________________________________________________________
> > > > Peek-a-boo FREE Tricks & Treats for You!
> > > > http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe from this list please visit:
> > >
> > >     http://xircles.codehaus.org/manage_email
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe from this list please visit:
> >
> >     http://xircles.codehaus.org/manage_email
> >
> >

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


RE: ObjectTable question & Annotations

by nhhockeyplayer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> - Admin: sees everything, can edit everything
> - User: sees everything apart from 2 or 3 columns,
> can edit only 1 or 2 columns
> - SomeOtherRole: sees all colunns but may only edit some other columns

I believe Kalle implemented support for all of the above. I use it and it is sweet. Read up on property based and role based security.

And always, check out the classic hibernate roster example... it already does all of this using ACEGI.

Best regards
Ken in nashua

> Date: Thu, 11 Oct 2007 17:16:02 +0200
> From: superoverdrive@...
> To: users@...
> Subject: Re: RE: [trails-users] ObjectTable question & Annotations
>
> Thanks!
>
> I have found a solution to #1:
>
> @PropertyDescriptor(hidden=true)
>
> BUT: Imagine you re-use the objects in several contexts, i.e.
> you have a user, an admin and different roles and need to define the visibility as well as editability dynamically - PropertyDescriptior would
> not work.
>
> If I may utter a wish for the Trails Wiki or examples page, what about:
>
> - CRUD application for 3 different roles that is localized in 2 languages!
>
> - Admin: sees everything, can edit everything
> - User: sees everything apart from 2 or 3 columns,
> can edit only 1 or 2 columns
> - SomeOtherRole: sees all colunns but may only edit some other columns
>
> It would be cool if there was a standard way of doing that easily in Trails, without having to write lots of code or without having to use lots of conditions and different templates.
>
>
>
> -------- Original-Nachricht --------
> > Datum: Thu, 11 Oct 2007 11:05:23 -0400
> > Von: Ken nashua <nhhockeyplayer@...>
> > An: users@...
> > Betreff: RE: [trails-users] ObjectTable question & Annotations
>
> >
> > I can offer insight to #3
> >
> > Support is already built into ObjectTable to display images. I am doing
> > this now successfully. It has been air tight for some time now. But... not
> > all the support for this KIND of rendering in the table lives in
> > trails-core... you need to go into the examples and track down the usage of
> > UploadableMedia.JAVA and assemble yourself how-to. Roster models everything for
> > collections many-to-one, one-to-many and one-to-one using imagery.
> >
> > I tried to get this KIND of e-frastructure part of trails-core but was
> > prevented in order to keep the framework trim.
> >
> > Take a look at the hibernate classic roster example. It uses
> > Uploadablemedia as a type for POJO properties that are characterized as docs, images,
> > clips or anything that is a BLOB.
> >
> > Example in ROSTER...
> >
> > Person.JAVA (every person has a photo)
> > private UploadableMedia photo = new UploadableMedia();
> >
> > @BlobDescriptor(renderType = RenderType.IMAGE, contentDisposition =
> > ContentDisposition.ATTACHMENT)
> > @PropertyDescriptor(summary = true, index = 1)
> > @OneToOne(cascade = CascadeType.ALL)
> > public UploadableMedia getPhoto()
> > {
> > return photo;
> > }
> >
> > ObjectTable is already geared to detect this KIND of property in this pojo
> > and render it on the table as-is (in the form of a clickable/downloadable
> > image).
> >
> > Happy trails...
> > Best regards
> > Ken in nashua
> >
> > > Date: Thu, 11 Oct 2007 16:45:53 +0200
> > > From: superoverdrive@...
> > > To: users@...
> > > Subject: [trails-users] ObjectTable question & Annotations
> > >
> > > Hello everyone!
> > >
> > > I give Trails a go and I have some questions:
> > >
> > > 1. Is it possible to mark getter Methode using Annotations in order to
> > > definde which columns should be displayed inside on an ObjectsTable or
> > does it mean writing a ITableColumn implementation for every single entity?
> > >
> > >
> > > 2. How do you link from a row "cell" inside an ObjectsTable row to
> > another page?
> > >
> > > 3. How do you replace a status column id with an image?
> > >
> > > Cheers!
> > >
> > > Toby
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe from this list please visit:
> > >
> > > http://xircles.codehaus.org/manage_email
> > >
> >
> > _________________________________________________________________
> > Peek-a-boo FREE Tricks & Treats for You!
> > http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
> http://xircles.codehaus.org/manage_email
>


Climb to the top of the charts!  Play Star Shuffle:  the word scramble challenge with star power. Play Now!
Best regards
Ken in nashua

Re: RE: ObjectTable question & Annotations

by Alejandro Scandroli :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Tobias

Lets tackle these questions at a time.

> 1. Is it possible to mark getter Methode using Annotations in order to
> definde which columns should be displayed inside on an ObjectsTable or does it mean writing a ITableColumn implementation for every single entity?
>
You have many option here:

        Without security:
                @PropertyDescriptor(hidden = true), will hide the property in both
the ObjectTable and the ObjectForm
                @PropertyDescriptor(summary = false), will hide the property in the
ObjectTable but it will be available in the ObjectForm
                You can also specify which properties you want to use in the
ObjectTable using the "propertyNames" parameter

        Using security
                @ViewRequiresRole("ROLE_MANAGER") will hide the property to users
that don't have the ROLE_MANAGER role. (I think this is what you are
looking for)
Check Recipe.description in the "security" example.
http://svn.codehaus.org/trails/trunk/trails/examples/security/src/main/java/org/trails/demo/Recipe.java

> 2. How do you link from a row "cell" inside an ObjectsTable row to another page?
It depends. what do you want to do? to which page do you want to go?
If you just want to override the way Trails handles links by default
you have to provide "linkColumnValue" Block inside the ObjectTable.
We discussed this in this thread:
http://archive.trails.codehaus.org/users/e1cf626e0709040402t32e448bfx918f651e65471055@...

If you want to provide a new link in adition the one in the "id",
provide a Block for a given property and create the link in it.
<div jwcid="youPropertyColumnValue@Block">
  <a href="http://www.trailsframework.org/">Trails</a>
</div>

> 3. How do you replace a status column id with an image?
Use a Block for the "status" property. Then you have many options.
Ken has proposed one using BLOBs.
Here you have another option using URLs for the images:
http://www.trailsframework.org/Customizing+pages#Customizingpages-CustomizingObjectTablecomponent.

Another option using assets:

<div jwcid="statusColumnValue@Block">
  <span jwcid="@If" condition="ognl:model.status == 'UP'">
    <img jwcid="@Image" image="asset:imageUP"/>
  </span>
   <span jwcid="@If" condition="ognl:model.status == 'DOWN'">
    <img jwcid="@Image" image="asset:imageDOWN"/>
  </span>
</div>

Check Tapestry's documentation for more info about the Image component.

> It would be cool if there was a standard way of doing that easily in Trails, without >having to write lots of code or without having to use lots of conditions and different templates.

Trails will do that for you, for sure. ;-)

Welcome to Trails.
Saludos.
Alejandro.


On 10/11/07, superoverdrive@... <superoverdrive@...> wrote:

> It would not be "real" objects, just pseudo-objects similiar to database views that are not real tables.
>
> -------- Original-Nachricht --------
> > Datum: Thu, 11 Oct 2007 12:58:00 -0300
> > Von: "Pablo Francavilla" <pfrancav@...>
> > An: users@...
> > Betreff: Re: RE: [trails-users] ObjectTable question & Annotations
>
> > Hi, I think that this is not a good OO Approach, just because we are
> > changing out model because a presentation issue. I think that the Object
> > it´s the same and the Role or permission to edit it must be handled in
> > another place or tier.
> >
> > It's just my opinion, I just start trying Trails and I haven't a lot of
> > knowledge of them.
> >
> > On 10/11/07, superoverdrive@... <superoverdrive@...> wrote:
> > >
> > > Regarding #1:
> > >
> > > What about overriding the object in order to have different Annotations
> > > for
> > > the visibility?
> > >
> > > e.g.
> > >
> > > MyAdminObject extends MyObject
> > >
> > > @PropertyDescriptor(hidden=false)
> > >
> > >         public String emailAddress() {
> > >         return this.emailAddress;
> > >        }
> > >
> > >
> > > MyUserObject extends MyObject
> > >
> > > @PropertyDescriptor(hidden=true)
> > >
> > >         public String emailAddress() {
> > >         return this.emailAddress;
> > >        }
> > >
> > >
> > > But how do you make sure, that Trails does not create Tables for
> > > MyAdminObject and MyUserObject ?
> > >
> > > Tobias
> > >
> > > -------- Original-Nachricht --------
> > > > Datum: Thu, 11 Oct 2007 17:16:02 +0200
> > > > Von: "Tobias Marx" <superoverdrive@...>
> > > > An: users@...
> > > > Betreff: Re: RE: [trails-users] ObjectTable question & Annotations
> > >
> > > > Thanks!
> > > >
> > > > I have found a solution to #1:
> > > >
> > > > @PropertyDescriptor(hidden=true)
> > > >
> > > > BUT: Imagine you re-use the objects in several contexts, i.e.
> > > > you have a user, an admin and different roles and need to define the
> > > > visibility as well as editability dynamically - PropertyDescriptior
> > > would
> > > > not work.
> > > >
> > > > If I may utter a wish for the Trails Wiki or examples page, what
> > about:
> > > >
> > > > - CRUD application for 3 different roles that is localized in 2
> > > languages!
> > > >
> > > > - Admin: sees everything, can edit everything
> > > > - User: sees everything apart from 2 or 3 columns,
> > > > can edit only 1 or 2 columns
> > > > - SomeOtherRole: sees all colunns but may only edit some other columns
> > > >
> > > > It would be cool if there was a standard way of doing that easily in
> > > > Trails, without having to write lots of code or without having to use
> > > lots of
> > > > conditions and different templates.
> > > >
> > > >
> > > >
> > > > -------- Original-Nachricht --------
> > > > > Datum: Thu, 11 Oct 2007 11:05:23 -0400
> > > > > Von: Ken nashua <nhhockeyplayer@...>
> > > > > An: users@...
> > > > > Betreff: RE: [trails-users] ObjectTable question & Annotations
> > > >
> > > > >
> > > > > I can offer insight to #3
> > > > >
> > > > > Support is already built into ObjectTable to display images. I am
> > > doing
> > > > > this now successfully. It has been air tight for some time now.
> > But...
> > > > not
> > > > > all the support for this KIND of rendering in the table lives in
> > > > > trails-core... you need to go into the examples and track down the
> > > usage
> > > > of
> > > > > UploadableMedia.JAVA and assemble yourself how-to. Roster models
> > > > everything for
> > > > > collections many-to-one, one-to-many and one-to-one using imagery.
> > > > >
> > > > > I tried to get this KIND of e-frastructure part of trails-core but
> > was
> > > > > prevented in order to keep the framework trim.
> > > > >
> > > > > Take a look at the hibernate classic roster example. It uses
> > > > > Uploadablemedia as a type for POJO properties that are characterized
> > > as
> > > > docs, images,
> > > > > clips or anything that is a BLOB.
> > > > >
> > > > > Example in ROSTER...
> > > > >
> > > > > Person.JAVA (every person has a photo)
> > > > >     private UploadableMedia photo = new UploadableMedia();
> > > > >
> > > > >     @BlobDescriptor(renderType = RenderType.IMAGE,
> > contentDisposition
> > > =
> > > > > ContentDisposition.ATTACHMENT)
> > > > >     @PropertyDescriptor(summary = true, index = 1)
> > > > >     @OneToOne(cascade = CascadeType.ALL)
> > > > >     public UploadableMedia getPhoto()
> > > > >     {
> > > > >         return photo;
> > > > >     }
> > > > >
> > > > > ObjectTable is already geared to detect this KIND of property in
> > this
> > > > pojo
> > > > > and render it on the table as-is (in the form of a
> > > > clickable/downloadable
> > > > > image).
> > > > >
> > > > > Happy trails...
> > > > > Best regards
> > > > > Ken in nashua
> > > > >
> > > > > > Date: Thu, 11 Oct 2007 16:45:53 +0200
> > > > > > From: superoverdrive@...
> > > > > > To: users@...
> > > > > > Subject: [trails-users] ObjectTable question & Annotations
> > > > > >
> > > > > > Hello everyone!
> > > > > >
> > > > > > I give Trails a go and I have some questions:
> > > > > >
> > > > > > 1. Is it possible to mark getter Methode using Annotations in
> > order
> > > to
> > > > > > definde which columns should be displayed inside on an
> > ObjectsTable
> > > or
> > > > > does it mean writing a ITableColumn implementation for every single
> > > > entity?
> > > > > >
> > > > > >
> > > > > > 2. How do you link from a row "cell" inside an ObjectsTable row to
> > > > > another page?
> > > > > >
> > > > > > 3. How do you replace a status column id with an image?
> > > > > >
> > > > > > Cheers!
> > > > > >
> > > > > > Toby
> > > > > >
> > > > > >
> > > ---------------------------------------------------------------------
> > > > > > To unsubscribe from this list please visit:
> > > > > >
> > > > > >     http://xircles.codehaus.org/manage_email
> > > > > >
> > > > >
> > > > > _________________________________________________________________
> > > > > Peek-a-boo FREE Tricks & Treats for You!
> > > > > http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe from this list please visit:
> > > >
> > > >     http://xircles.codehaus.org/manage_email
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe from this list please visit:
> > >
> > >     http://xircles.codehaus.org/manage_email
> > >
> > >
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
>     http://xircles.codehaus.org/manage_email
>
>

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


Roster example download - where ?

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks for your help! So where can I find this  Roster download example?
The download on
http://www.mvnrepository.com/artifact/org.trailsframework.examples/roster does not work :-(

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


HibernateViewPage?

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Is there something like a HibernateViewPage?

There is a HibernateEditPage, HibernateSearchPage, and HibernateListPage - is there also something like a HibernateViewPage - for simply viewing an object ?

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


PersistenceService for custom queries ?

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Can you use Trails also for custom database queries or is Trails
purely for "the same kind of" CRUD applications that do not need any additional features ?

One example:

I want to link from a row inside an ObjectTable to a custom "ViewObjectPage" that displays all corresponding data and additional stuff
(the ObjectTable only has very few columns to keep the table small).

So I have started doing a:


public abstract class ViewMyObjectPage  extends TrailsPage
    implements IExternalPage, PageBeginRenderListener
{

}


within: activateExternalPage(Object args[], IRequestCycle cycle)

I want to retrieve the unique name of the object (or id) and then fetch all data from the database in order to display it.

Within getPersistenceService(), however, I could not find a way to create custom Queries....
   
Any help is highly appreciated!

Cheers!

Tobias

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


Re: HibernateViewPage?

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I found an answer ;-)

http://archive.trails.codehaus.org/users/e1cf626e0709040402t32e448bfx918f651e65471055@...

-------- Original-Nachricht --------
> Datum: Fri, 12 Oct 2007 10:53:14 +0200
> Von: superoverdrive@...
> An: users@...
> Betreff: [trails-users] HibernateViewPage?

> Is there something like a HibernateViewPage?
>
> There is a HibernateEditPage, HibernateSearchPage, and HibernateListPage -
> is there also something like a HibernateViewPage - for simply viewing an
> object ?
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
>     http://xircles.codehaus.org/manage_email

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


HibernatePersistenceServiceImpl and getPersistenceService()

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Sorry for spamming the mailing list ;-)

Is this an acceptable way to access objects from a Trailspage ?

 HibernatePersistenceServiceImpl service = (HibernatePersistenceServiceImpl)this.getPersistenceService();
 service.getSessionFactory().getCurrentSession().createCriteria(arg0);
       

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


RE: Roster example download - where ?

by nhhockeyplayer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hey superdriver...

I do not manage the maven packaging online.

If you checkout trails source code with SVN you will see the source. It is all checked into the build tree.

happy trails...

Best regards
Ken in nashua

> Date: Fri, 12 Oct 2007 10:47:37 +0200
> From: superoverdrive@...
> To: users@...
> Subject: [trails-users] Roster example download - where ?
>
> Thanks for your help! So where can I find this Roster download example?
> The download on
> http://www.mvnrepository.com/artifact/org.trailsframework.examples/roster does not work :-(
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
> http://xircles.codehaus.org/manage_email
>


Peek-a-boo FREE Tricks & Treats for You! Get 'em!
Best regards
Ken in nashua

RE: HibernatePersistenceServiceImpl and getPersistenceService()

by nhhockeyplayer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Certainly you can reach into the bowels of trails and do anything you want with the core.

There is canonical approach and trails models that already as-is, given one or two spotty lapses in use case. I would encourage following that approach but deviate only when really necessary.

Alejandro is the man modeling the session/view.

Historically we have had some challenging experiences with detached entities. Currently we are seeing some issues with dirty references.

The roster example has been good at flushing all these out since it exercises most/alot of the relationships/associations possible.

Best regards
Ken in nashua

> Date: Fri, 12 Oct 2007 15:39:17 +0200
> From: superoverdrive@...
> To: users@...
> Subject: [trails-users] HibernatePersistenceServiceImpl and getPersistenceService()
>
> Sorry for spamming the mailing list ;-)
>
> Is this an acceptable way to access objects from a Trailspage ?
>
> HibernatePersistenceServiceImpl service = (HibernatePersistenceServiceImpl)this.getPersistenceService();
> service.getSessionFactory().getCurrentSession().createCriteria(arg0);
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
> http://xircles.codehaus.org/manage_email
>


Boo! Scare away worms, viruses and so much more! Try Windows Live OneCare! Try now!
Best regards
Ken in nashua

maven-idea-plugin:maven-plugin:2.0

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I am trying to get the Roster demo working, but maven can not find the maven-idea-plugin:maven-plugin:2.0. What servers do you need in your settings.xml for maven ?

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


Parent Message unknown RE: maven-idea-plugin:maven-plugin:2.0

by nhhockeyplayer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Sometimes if you have tomcat running or eclipse running something on port 8080... then maven will choke and abort -offline building.

Check to see if something is already bind to port 8080.

if your maven configuration is not working properly then thats your job to come up to speed on it.

As for maven setting.xml? Attached is mine... but it just anchors my local repo to a defunct dead installation of tomcat. It works for my builds and local repo though.

So decide on where you want to configure your local repo and set it up. It could be tomcat, jetty, resin, or just C:\TEMP

The 8080 thing is constant issue for me. If I am running my webapp and try to perform maven build it does not get artifacts elsewhere in other repositories on the web. I think I just need to re-configure my maven to operate a different port.

Good luck...

- cheers

Best regards
Ken in nashua

> Date: Fri, 12 Oct 2007 17:53:11 +0200
> From: superoverdrive@...
> To: users@...
> Subject: [trails-users] maven-idea-plugin:maven-plugin:2.0
>
> I am trying to get the Roster demo working, but maven can not find the maven-idea-plugin:maven-plugin:2.0. What servers do you need in your settings.xml for maven ?
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
> http://xircles.codehaus.org/manage_email
>


Boo! Scare away worms, viruses and so much more! Try Windows Live OneCare! Try now!
<!--
  | This is the configuration file for Maven. It can be specified at two levels:
  |
  |  1. User Level. This settings.xml file provides configuration for a single user,
  |                 and is normally provided in $HOME/.m2/settings.xml.
  |
  |                 NOTE: This location can be overridden with the system property:
  |
  |                 -Dorg.apache.maven.user-settings=/path/to/user/settings.xml
  |
  |  2. Global Level. This settings.xml file provides configuration for all maven
  |                 users on a machine (assuming they're all using the same maven
  |                 installation). It's normally provided in
  |                 ${maven.home}/conf/settings.xml.
  |
  |                 NOTE: This location can be overridden with the system property:
  |
  |                 -Dorg.apache.maven.global-settings=/path/to/global/settings.xml
  |
  | The sections in this sample file are intended to give you a running start at
  | getting the most out of your Maven installation. Where appropriate, the default
  | values (values used when the setting is not specified) are provided.
  |
  |-->
  <settings>
    <!-- localRepository
      | The path to the local repository maven will use to store artifacts.
      |
      | Default: ~/.m2/repository
      <localRepository>/path/to/local/repo</localRepository>
    -->
    <localRepository>${env.TOMCAT_HOME}/webapps/m2.repository</localRepository>


    <!-- interactiveMode
      | This will determine whether maven prompts you when it needs input. If set to false,
      | maven will use a sensible default value, perhaps based on some other setting, for
      | the parameter in question.
      |
      | Default: true
      <interactiveMode>true</interactiveMode>
    -->

    <!-- offline
      | Determines whether maven should attempt to connect to the network when executing a build.
      | This will have an effect on artifact downloads, artifact deployment, and others.
      |
      | Default: false
      <offline>false</offline>
    -->

    <!-- proxies
      | This is a list of proxies which can be used on this machine to connect to the network.
      | Unless otherwise specified (by system property or command-line switch), the first proxy
      | specification in this list marked as active will be used.
      |-->
    <proxies>
      <!-- proxy
        | Specification for one proxy, to be used in connecting to the network.
        |
        <proxy>
        <id>optional</id>
        <active>true</active>
        <protocol>http</protocol>
        <username>proxyuser</username>
        <password>proxypass</password>
        <host>proxy.host.net</host>
        <port>80</port>
        <nonProxyHosts>local.net,some.host.com</nonProxyHosts>
        </proxy>



      <proxy>
        <id>jetty6x</id>
        <active>true</active>
        <protocol>http</protocol>
        <username>admin</username>
        <password>admin</password>
        <host>localhost</host>
        <port>8111</port>
        <nonProxyHosts/>
      </proxy>

      <proxy>
        <id>resin3x</id>
        <active>true</active>
        <protocol>http</protocol>
        <username>admin</username>
        <password>admin</password>
        <host>localhost</host>
        <port>8111</port>
        <nonProxyHosts/>
      </proxy>

      <proxy>
        <id>jboss4x</id>
        <active>true</active>
        <protocol>http</protocol>
        <username>admin</username>
        <password>admin</password>
        <host>localhost</host>
        <port>8111</port>
        <nonProxyHosts/>
      </proxy>
      -->

      <proxy>
        <id>tomcat5x</id>
        <active>false</active>
        <protocol>http</protocol>
        <username>admin</username>
        <password>admin</password>
        <host>localhost</host>
        <port>8111</port>
        <nonProxyHosts/>
      </proxy>



    </proxies>

    <!-- servers
      | This is a list of authentication profiles, keyed by the server-id used within the system.
      | Authentication profiles can be used whenever maven must make a connection to a remote server.
      |-->
    <servers>
      <!-- server
        | Specifies the authentication information to use when connecting to a particular server, identified by
        | a unique name within the system (referred to by the 'id' attribute below).
        |
        | NOTE: You should either specify username/password OR privateKey/passphrase, since these pairings are
        |       used together.
        |
        <server>
        <id>deploymentRepo</id>
        <username>repouser</username>
        <password>repopwd</password>
        </server>
      -->
      <server>
        <id>tomcat5x</id>
        <username>admin</username>
        <password>admin</password>
      </server>


      <!-- Another sample, using keys to authenticate.
        <server>
        <id>siteServer</id>
        <privateKey>/path/to/private/key</privateKey>
        <passphrase>optional; leave empty if not used.</passphrase>
        </server>
      -->

    </servers>

    <!-- mirrors
      | This is a list of mirrors to be used in downloading artifacts from remote repositories.
      |
      | It works like this: a POM may declare a repository to use in resolving certain artifacts.
      | However, this repository may have problems with heavy traffic at times, so people have mirrored
      | it to several places.
      |
      | That repository definition will have a unique id, so we can create a mirror reference for that
      | repository, to be used as an alternate download site. The mirror site will be the preferred
      | server for that repository.
      |-->
    <mirrors>
      <!-- mirror
        | Specifies a repository mirror site to use instead of a given repository. The repository that
        | this mirror serves has an ID that matches the mirrorOf element of this mirror. IDs are used
        | for inheritance and direct lookup purposes, and must be unique across the set of mirrors.
        |
        <mirror>
        <id>mirrorId</id>
        <mirrorOf>repositoryId</mirrorOf>
        <name>Human Readable Name for this Mirror.</name>
        <url>http://my.repository.com/repo/path</url>
        </mirror>
      -->
    </mirrors>

    <!-- profiles
      | This is a list of profiles which can be activated in a variety of ways, and which can modify
      | the build process. Profiles provided in the settings.xml are intended to provide local machine-
      | specific paths and repository locations which allow the build to work in the local environment.
      |
      | For example, if you have an integration testing plugin - like cactus - that needs to know where
      | your Tomcat instance is installed, you can provide a variable here such that the variable is
      | dereferenced during the build process to configure the cactus plugin.
      |
      | As noted above, profiles can be activated in a variety of ways. One way - the activeProfiles
      | section of this document (settings.xml) - will be discussed later. Another way essentially
      | relies on the detection of a system property, either matching a particular value for the property,
      | or merely testing its existence. Profiles can also be activated by JDK version prefix, where a
      | value of '1.4' might activate a profile when the build is executed on a JDK version of '1.4.2_07'.
      | Finally, the list of active profiles can be specified directly from the command line.
      |
      | NOTE: For profiles defined in the settings.xml, you are restricted to specifying only artifact
      |       repositories, plugin repositories, and free-form properties to be used as configuration
      |       variables for plugins in the POM.
      |
      |-->
    <profiles>
      <!-- profile
        | Specifies a set of introductions to the build process, to be activated using one or more of the
        | mechanisms described above. For inheritance purposes, and to activate profiles via <activatedProfiles/>
        | or the command line, profiles have to have an ID that is unique.
        |
        | An encouraged best practice for profile identification is to use a consistent naming convention
        | for profiles, such as 'env-dev', 'env-test', 'env-production', 'user-jdcasey', 'user-brett', etc.
        | This will make it more intuitive to understand what the set of introduced profiles is attempting
        | to accomplish, particularly when you only have a list of profile id's for debug.
        |
        | This profile example uses the JDK version to trigger activation, and provides a JDK-specific repo.
        <profile>
        <id>jdk-1.4</id>

        <activation>
        <jdk>1.4</jdk>
        </activation>

        <repositories>
        <repository>
        <id>jdk14</id>
        <name>Repository for JDK 1.4 builds</name>
        <url>http://www.myhost.com/maven/jdk14</url>
        <layout>default</layout>
        <snapshotPolicy>always</snapshotPolicy>
        </repository>
        </repositories>
        </profile>
      -->

      <!--
        | Here is another profile, activated by the system property 'target-env' with a value of 'dev',
        | which provides a specific path to the Tomcat instance. To use this, your plugin configuration
        | might hypothetically look like:
        |
        | ...
        | <plugin>
        |   <groupId>org.myco.myplugins</groupId>
        |   <artifactId>myplugin</artifactId>
        |
        |   <configuration>
        |     <tomcatLocation>${tomcatPath}</tomcatLocation>
        |   </configuration>
        | </plugin>
        | ...
        |
        | NOTE: If you just wanted to inject this configuration whenever someone set 'target-env' to
        |       anything, you could just leave off the <value/> inside the activation-property.
        |
        <profile>
        <id>env-dev</id>

        <activation>
        <property>
        <name>target-env</name>
        <value>dev</value>
        </property>
        </activation>

        <properties>
        <tomcatPath>>${env.TOMCAT_HOME}/webapps</tomcatPath>
        </properties>
        </profile>
      -->
    </profiles>

    <!-- activeProfiles
      | List of profiles that are active for all builds.
      |
      <activeProfiles>
      <activeProfile>alwaysActiveProfile</activeProfile>
      <activeProfile>anotherAlwaysActiveProfile</activeProfile>
      </activeProfiles>
    -->

  </settings>

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email
Best regards
Ken in nashua

Re: RE: maven-idea-plugin:maven-plugin:2.0

by Toby78 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Is it possible there is still something wrong in the pom files or is that just a local problem here ?

When I try to do a mvn eclipse:eclipse in the examples directory I get:

Project ID: com.javaforge.tapestry:tapestry-spring:jar:1.0.0

Reason: Cannot find parent: com.javaforge.tapestry:tapestry-javaforge for projec
t: com.javaforge.tapestry:tapestry-spring:jar:1.0.0

Although both tapestry-javaforge and tapestry-spring are there.....

-------- Original-Nachricht --------
> Datum: Fri, 12 Oct 2007 12:22:54 -0400
> Von: Ken nashua <nhhockeyplayer@...>
> An: users@...
> Betreff: RE: [trails-users] maven-idea-plugin:maven-plugin:2.0

>
> Sometimes if you have tomcat running or eclipse running something on port
> 8080... then maven will choke and abort -offline building.
>
> Check to see if something is already bind to port 8080.
>
> if your maven configuration is not working properly then thats your job to
> come up to speed on it.
>
> As for maven setting.xml? Attached is mine... but it just anchors my local
> repo to a defunct dead installation of tomcat. It works for my builds and
> local repo though.
>
> So decide on where you want to configure your local repo and set it up. It
> could be tomcat, jetty, resin, or just C:\TEMP
>
> The 8080 thing is constant issue for me. If I am running my webapp and try
> to perform maven build it does not get artifacts elsewhere in other
> repositories on the web. I think I just need to re-configure my maven to operate
> a different port.
>
> Good luck...
>
> - cheers
>
> Best regards
> Ken in nashua
>
> > Date: Fri, 12 Oct 2007 17:53:11 +0200
> > From: superoverdrive@...
> > To: users@...
> > Subject: [trails-users] maven-idea-plugin:maven-plugin:2.0
> >
> > I am trying to get the Roster demo working, but maven can not find the
> maven-idea-plugin:maven-plugin:2.0. What servers do you need in your
> settings.xml for maven ?
> >
> > ---------------------------------------------------------------------
> > To unsubscribe from this list please visit:
> >
> >     http://xircles.codehaus.org/manage_email
> >
>
> _________________________________________________________________
> Boo! Scare away worms, viruses and so much more! Try Windows Live
> OneCare!
> http://onecare.live.com/standard/en-us/purchase/trial.aspx?s_cid=wl_hotmailnews

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


RE: maven-idea-plugin:maven-plugin:2.0

by nhhockeyplayer :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

http://permalink.gmane.org/gmane.comp.java.trails.user/1642


Best regards
Ken in nashua

> Date: Fri, 12 Oct 2007 20:36:00 +0200
> From: superoverdrive@...
> To: users@...
> Subject: Re: RE: [trails-users] maven-idea-plugin:maven-plugin:2.0
>
> Is it possible there is still something wrong in the pom files or is that just a local problem here ?
>
> When I try to do a mvn eclipse:eclipse in the examples directory I get:
>
> Project ID: com.javaforge.tapestry:tapestry-spring:jar:1.0.0
>
> Reason: Cannot find parent: com.javaforge.tapestry:tapestry-javaforge for projec
> t: com.javaforge.tapestry:tapestry-spring:jar:1.0.0
>
> Although both tapestry-javaforge and tapestry-spring are there.....
>
> -------- Original-Nachricht --------
> > Datum: Fri, 12 Oct 2007 12:22:54 -0400
> > Von: Ken nashua <nhhockeyplayer@...>
> > An: users@...
> > Betreff: RE: [trails-users] maven-idea-plugin:maven-plugin:2.0
>
> >
> > Sometimes if you have tomcat running or eclipse running something on port
> > 8080... then maven will choke and abort -offline building.
> >
> > Check to see if something is already bind to port 8080.
> >
> > if your maven configuration is not working properly then thats your job to
> > come up to speed on it.
> >
> > As for maven setting.xml? Attached is mine... but it just anchors my local
> > repo to a defunct dead installation of tomcat. It works for my builds and
> > local repo though.
> >
> > So decide on where you want to configure your local repo and set it up. It
> > could be tomcat, jetty, resin, or just C:\TEMP
> >
> > The 8080 thing is constant issue for me. If I am running my webapp and try
> > to perform maven build it does not get artifacts elsewhere in other
> > repositories on the web. I think I just need to re-configure my maven to operate
> > a different port.
> >
> > Good luck...
> >
> > - cheers
> >
> > Best regards
> > Ken in nashua
> >
> > > Date: Fri, 12 Oct 2007 17:53:11 +0200
> > > From: superoverdrive@...
> > > To: users@...
> > > Subject: [trails-users] maven-idea-plugin:maven-plugin:2.0
> > >
> > > I am trying to get the Roster demo working, but maven can not find the
> > maven-idea-plugin:maven-plugin:2.0. What servers do you need in your
> > settings.xml for maven ?
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe from this list please visit:
> > >
> > > http://xircles.codehaus.org/manage_email
> > >
> >
> > _________________________________________________________________
> > Boo! Scare away worms, viruses and so much more! Try Windows Live
> > OneCare!
> > http://onecare.live.com/standard/en-us/purchase/trial.aspx?s_cid=wl_hotmailnews
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
> http://xircles.codehaus.org/manage_email
>


Help yourself to FREE treats served up daily at the Messenger Café. Stop by today!
Best regards
Ken in nashua
< Prev | 1 - 2 - 3 | Next >