Java Mailing List Archive

http://www.gg3721.com/

Home » user.groovy »

Re: [groovy-user] Opposite of map.toMapString() is...?

Dierk Koenig

2010-03-09

Replies: Find Java Web Hosting

Author LoginPost Reply
def map = evaluate(str)

cheers
Dierk

Am 09.03.2010 um 16:05 schrieb c-dev-groovy@(protected):

> I'm looking to parse some files which include embedded Groovy maps
> (including possible regex's) so I'd like to do something like:
>
> def str = "[field:value, field2:value2, field3:/^[a-z,]+$/]"
> def map = new Map(str)
> // or
> def map = str.toMap()
>
> Is there a Groovy mechanism for that?
>
> Thanks!
>
>
> ---------------------------------------------------------------------
> 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


©2008 gg3721.com - Jax Systems, LLC, U.S.A.