Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » [Acceleo] eliminate white lines generated by template([Acceleo] eliminate white lines generated by template)
[Acceleo] eliminate white lines generated by template [message #657379] Wed, 02 March 2011 15:58 Go to next message
olafo987  is currently offline olafo987 Friend
Messages: 13
Registered: November 2010
Junior Member
Hi

There is some form of eliminate the white lines generated when one template returns the string ''?

I tried with "trim()" but It does not work.

in advance, thanks for your help
Re: [Acceleo] eliminate white lines generated by template [message #657568 is a reply to message #657379] Thu, 03 March 2011 09:02 Go to previous message
Laurent Goubet is currently offline Laurent GoubetFriend
Messages: 1902
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------010502050705090203060008
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit

Hi,

A template, if it returns the empty String, won't generate anything in
the output file. What you have here is (I assume) something like this :

-----
[file (...)]
some text
[templateCallThatDoesNotGenerateAnything()/]
and some other text
[/file]
-----

And you expect the output to be

-----
some text
and some other text
-----

whereas you get


-----
some text

and some other text
-----

This is normal, and expected. The line where you have a template call
ends with a carriage return, this carriage return _will_ be generated.
There is no way to prevent this from happening.

Laurent Goubet
Obeo

On 02/03/2011 16:58, olafo987 wrote:
> Hi
>
> There is some form of eliminate the white lines generated when one
> template returns the string ''?
>
> I tried with "trim()" but It does not work.
>
> in advance, thanks for your help
>


--------------010502050705090203060008
Content-Type: text/x-vcard; charset=utf-8;
name="laurent_goubet.vcf"
Content-Transfer-Encoding: base64
Content-Disposition: attachment;
filename="laurent_goubet.vcf"

YmVnaW46dmNhcmQNCmZuOkxhdXJlbnQgR291YmV0DQpuOkdvdWJldDtMYXVy ZW50DQpvcmc6
PGEgaHJlZj0iaHR0cDovL3d3dy5vYmVvLmZyIj5PYmVvPC9hPg0KZW1haWw7 aW50ZXJuZXQ6
bGF1cmVudC5nb3ViZXRAb2Jlby5mcg0KdXJsOmh0dHA6Ly93d3cub2Jlby5m cg0KdmVyc2lv
bjoyLjENCmVuZDp2Y2FyZA0KDQo=
--------------010502050705090203060008--
Previous Topic:[ Acceleo 3] java service get a empty Jpa metamodel
Next Topic:[Acceleo 3] ServiceWrapper Problem during generation
Goto Forum:
  


Current Time: Sun Oct 13 17:59:41 GMT 2024

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

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

Back to the top