Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » Getting Double Quotes in a string
Getting Double Quotes in a string [message #30381] Wed, 08 August 2007 11:33 Go to next message
Eclipse UserFriend
Originally posted by: evaandoli.dodo.com.au

Hi,

Just wondering if there is a quick way to get double quotes into a setVar

eg. Using the Java escape char would be :-
<c:setVariable var="namesToEnter"
select="/"{$tempCompoundNode/@leftOperand}/""/>

I got around this by creating a Jet custom function called
surroundWithDoubleQuotes.

But just wondering if there is an easy way :-)

Stu
Re: Getting Double Quotes in a string [message #30522 is a reply to message #30381] Wed, 08 August 2007 15:42 Go to previous message
Paul Elder is currently offline Paul ElderFriend
Messages: 849
Registered: July 2009
Senior Member
Stu:

I know of no simpler way than the XPath function approach. Part of the
problem is that XPath 1.0 doesn't have a quote escaping mechanism. The other
part of the problem is that the JET tag parser doesn't have a working quote
escaping mechanism either.

I should probably implement both.

Paul

"Stu" <evaandoli@dodo.com.au> wrote in message
news:f9c9lv$t4u$1@build.eclipse.org...
> Hi,
>
> Just wondering if there is a quick way to get double quotes into a setVar
>
> eg. Using the Java escape char would be :-
> <c:setVariable var="namesToEnter"
> select="/"{$tempCompoundNode/@leftOperand}/""/>
>
> I got around this by creating a Jet custom function called
> surroundWithDoubleQuotes.
>
> But just wondering if there is an easy way :-)
>
> Stu
>
>
Previous Topic:Re: [JET] [RSA] How can I transform a Rational Software Architect model (.emx) using JET ?
Next Topic:Aggregate Concat with a jet function
Goto Forum:
  


Current Time: Sun Dec 21 12:55:25 GMT 2014

Powered by FUDForum. Page generated in 0.01432 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software