Re: howto escape from iterate list in simple-method

2011-06-24 Thread Scott Gray
The implementation would not be trivial, the simple method structure wouldn't easily support this type of control flow. Plus it would be difficult to get the xsd right, allowing the operation to appear only within the iterable operations but possibly deeply nested. Regards Scott On

howto escape from iterate list in simple-method

2011-06-22 Thread Pierre Smits
Hi all, I am stumped... I need to iterate through a list to find the the first entry given a set of parameters in a simple-method, but how do I escape from the iteration after having found the entry? I know that in groovy I can do a while loop and if I have found the entry I can issue a 'break;

Re: howto escape from iterate list in simple-method

2011-06-22 Thread prasanth r
Hi Pierre, I tried it before I could not find any break or continue in miniland iterator. But we can use return/ statement to come out of the simple method. thanks prasath rajan 9442369696 On Wed, Jun 22, 2011 at 2:34 PM, Pierre Smits pierre.sm...@gmail.comwrote: Hi all, I am stumped... I

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Pierre Smits
Thanks for the quick reply. But wouldn't the return / end the entire simple method? In stead of just the section of code that has the iteration? Regards, Pierre 2011/6/22 prasanth r prasanth.sunr...@gmail.com Hi Pierre, I tried it before I could not find any break or continue in miniland

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Hans Bakker
Hi Pierre, I assume you generated the list from the database? why not use entity-condition with the condition you want to search on? regards, Hans On Wed, 2011-06-22 at 11:04 +0200, Pierre Smits wrote: Hi all, I am stumped... I need to iterate through a list to find the the first entry

Re: howto escape from iterate list in simple-method

2011-06-22 Thread prasanth r
Hi all, In this case we can use entity-one , which will bring only on record. thanks prasath rajan On Wed, Jun 22, 2011 at 3:19 PM, Hans Bakker mailingl...@antwebsystems.comwrote: Hi Pierre, I assume you generated the list from the database? why not use entity-condition with the condition

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Adrian Crum
A break/ element would be a useful addition to mini-language. If anyone is interested in creating it, I will take a look at it. -Adrian On 6/22/2011 10:04 AM, Pierre Smits wrote: Hi all, I am stumped... I need to iterate through a list to find the the first entry given a set of parameters in

Re: howto escape from iterate list in simple-method

2011-06-22 Thread prasanth r
update if you get anything prasath rajan On Wed, Jun 22, 2011 at 3:42 PM, Adrian Crum adrian.c...@sandglass-software.com wrote: A break/ element would be a useful addition to mini-language. If anyone is interested in creating it, I will take a look at it. -Adrian On 6/22/2011 10:04 AM,

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Ashish Vijaywargiya
+1 - Thanks Adrian. -- Ashish On Wed, Jun 22, 2011 at 3:42 PM, Adrian Crum adrian.c...@sandglass-software.com wrote: A break/ element would be a useful addition to mini-language. If anyone is interested in creating it, I will take a look at it. -Adrian On 6/22/2011 10:04 AM, Pierre

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Scott Gray
Use a while loop and change the condition to false once you're done, you'll have to manually iterate though. Or you could do as suggested and use the return tag, just move the loop out to a separate inline simple-method so that the return only effects the loop. Regards Scott HotWax Media

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Pierre Smits
Hi Hans, Let me elaborate on the problem I have. For a customer I have to expand the processing of project time entries so that they can do bulk processing of multiple time entries on multiple projects. In current setup of processing all is done with screen screen name =projectBilling in

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Hans Bakker
Hi Pierre, long time no talk! It looks like you want iterate a number of screen sections? did you look at the iterate-section within a widget ? If you want to create invoices for a number of projects at the same time then i would get these projects in a list and then process every project

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Pierre Smits
+1 Thanks Adrian 2011/6/22 Adrian Crum adrian.c...@sandglass-software.com A break/ element would be a useful addition to mini-language. If anyone is interested in creating it, I will take a look at it. -Adrian On 6/22/2011 10:04 AM, Pierre Smits wrote: Hi all, I am stumped... I need

Re: howto escape from iterate list in simple-method

2011-06-22 Thread prasanth r
hi Pierre, not able to understand what is the solution. what is +1. prasath rajan On Wed, Jun 22, 2011 at 4:39 PM, Pierre Smits pierre.sm...@gmail.comwrote: +1 Thanks Adrian 2011/6/22 Adrian Crum adrian.c...@sandglass-software.com A break/ element would be a useful addition to

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Erwan de FERRIERES
Le 22/06/2011 13:12, prasanth r a écrit : hi Pierre, not able to understand what is the solution. what is +1. Hi, here is for the +1 : http://www.apache.org/foundation/voting.html prasath rajan -- Erwan de FERRIERES www.nereide.biz

Re: howto escape from iterate list in simple-method

2011-06-22 Thread Adrian Crum
Prasanth, Also keep in mind that this is an open source project, so everyone can contribute. If you think of an improvement, create a Jira issue for it and we will try to get it included in the project. -Adrian On 6/22/2011 1:44 PM, Erwan de FERRIERES wrote: Le 22/06/2011 13:12, prasanth r