Maven - IF Tag problem

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Maven - IF Tag problem

vijayakumar.lakshmanan

Hi All....



Problem Statement:

The condition in the IF tag does not validate correctly, when any
variable retrieved from the property file is being used in the
condition.

We tried to retrieve a variable from the property file
<<build.properties>> and assign it to another variable so that it can be
used in the IF tag for validation.

The IF tag returns 'True' in false condition and vice versa.



The maven.xml contains the following code:



<project default="a" xmlns:j="jelly:core">



            <goal name="a">                      

                        <j:set var="a" value="${c}"/>


                        <j:if test="${a == 'yes'}">


                                    <echo message="Success"/>    

                        </j:if>                          

            </goal>

</project>        



The build.properties file contains a name value pair



c=yes



Actual Output:



__  __

|  \/  |__ _Apache__ ___

| |\/| / _` \ V / -_) ' \  ~ intelligent projects ~

|_|  |_\__,_|\_/\___|_||_|  v. 1.0.2



BUILD SUCCESSFUL

Total time: 1 seconds

Finished at: Thu May 05 17:15:50 IST 2005



Expected Output:



__  __

|  \/  |__ _Apache__ ___

| |\/| / _` \ V / -_) ' \  ~ intelligent projects ~

|_|  |_\__,_|\_/\___|_||_|  v. 1.0.2



build:start:



a:

    [echo] Success

BUILD SUCCESSFUL

Total time: 2 seconds

Finished at: Thu May 05 17:18:29 IST 2005



Question:

Please provide some clue to solve this problem







Confidentiality Notice

The information contained in this electronic message and any attachments to this message are intended
for the exclusive use of the addressee(s) and may contain confidential or privileged information. If
you are not the intended recipient, please notify the sender at Wipro or [hidden email] immediately
and destroy all copies of this message and any attachments.
Reply | Threaded
Open this post in threaded view
|

RE: Maven - IF Tag problem

Vincent Siveton-2
Hi,

For me its not an issue.
Let s try to define the variable a as a String:
<j:set var="a">${c}</j:set>

Cheers,

Vincent

> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]]
> Sent: Thursday, May 05, 2005 8:17 AM
> To: [hidden email]
> Subject: Maven - IF Tag problem
>
>
> Hi All....
>
>
>
>
> Problem Statement:
>
> The condition in the IF tag does not validate correctly, when any
> variable retrieved from the property file is being used in the
> condition.
>
> We tried to retrieve a variable from the property file
> <<build.properties>> and assign it to another variable so that it can be
> used in the IF tag for validation.
>
> The IF tag returns 'True' in false condition and vice versa.
>
>
>
>
> The maven.xml contains the following code:
>
>
>
>
>
> <project default="a" xmlns:j="jelly:core">
>
>
>
>
>             <goal name="a">
>
>
>                         <j:set var="a" value="${c}"/>
>
>
>                         <j:if test="${a == 'yes'}">
>
>
>                                     <echo message="Success"/>
>
>
>                         </j:if>
>
>
>             </goal>
>
> </project>
>
>
>
>
>
> The build.properties file contains a name value pair
>
>
>
>
> c=yes
>
>
>
>
> Actual Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> BUILD SUCCESSFUL
>
> Total time: 1 seconds
>
> Finished at: Thu May 05 17:15:50 IST 2005
>
>
>
>
> Expected Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> build:start:
>
>
>
>
> a:
>
>     [echo] Success
>
> BUILD SUCCESSFUL
>
> Total time: 2 seconds
>
> Finished at: Thu May 05 17:18:29 IST 2005
>
>
>
>
> Question:
>
> Please provide some clue to solve this problem
>
>
>
>
>
>
>
>
> Confidentiality Notice
>
>
> The information contained in this electronic message and any attachments
> to this message are intended
> for the exclusive use of the addressee(s) and may contain confidential or
> privileged information. If
> you are not the intended recipient, please notify the sender at Wipro or
> [hidden email] immediately
> and destroy all copies of this message and any attachments.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: Maven - IF Tag problem

vijayakumar.lakshmanan
In reply to this post by vijayakumar.lakshmanan

Thanks man it's working.

-----Original Message-----
From: Vincent Siveton [mailto:[hidden email]]
Sent: Thursday, May 05, 2005 5:58 PM
To: 'Maven Users List'
Subject: RE: Maven - IF Tag problem

Hi,

For me its not an issue.
Let s try to define the variable a as a String:
<j:set var="a">${c}</j:set>

Cheers,

Vincent

> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]]
> Sent: Thursday, May 05, 2005 8:17 AM
> To: [hidden email]
> Subject: Maven - IF Tag problem
>
>
> Hi All....
>
>
>
>
> Problem Statement:
>
> The condition in the IF tag does not validate correctly, when any
> variable retrieved from the property file is being used in the
> condition.
>
> We tried to retrieve a variable from the property file
> <<build.properties>> and assign it to another variable so that it can
be

> used in the IF tag for validation.
>
> The IF tag returns 'True' in false condition and vice versa.
>
>
>
>
> The maven.xml contains the following code:
>
>
>
>
>
> <project default="a" xmlns:j="jelly:core">
>
>
>
>
>             <goal name="a">
>
>
>                         <j:set var="a" value="${c}"/>
>
>
>                         <j:if test="${a == 'yes'}">
>
>
>                                     <echo message="Success"/>
>
>
>                         </j:if>
>
>
>             </goal>
>
> </project>
>
>
>
>
>
> The build.properties file contains a name value pair
>
>
>
>
> c=yes
>
>
>
>
> Actual Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> BUILD SUCCESSFUL
>
> Total time: 1 seconds
>
> Finished at: Thu May 05 17:15:50 IST 2005
>
>
>
>
> Expected Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> build:start:
>
>
>
>
> a:
>
>     [echo] Success
>
> BUILD SUCCESSFUL
>
> Total time: 2 seconds
>
> Finished at: Thu May 05 17:18:29 IST 2005
>
>
>
>
> Question:
>
> Please provide some clue to solve this problem
>
>
>
>
>
>
>
>
> Confidentiality Notice
>
>
> The information contained in this electronic message and any
attachments
> to this message are intended
> for the exclusive use of the addressee(s) and may contain confidential
or
> privileged information. If
> you are not the intended recipient, please notify the sender at Wipro
or
> [hidden email] immediately
> and destroy all copies of this message and any attachments.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]




Confidentiality Notice

The information contained in this electronic message and any attachments to this message are intended
for the exclusive use of the addressee(s) and may contain confidential or privileged information. If
you are not the intended recipient, please notify the sender at Wipro or [hidden email] immediately
and destroy all copies of this message and any attachments.

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: Maven - IF Tag problem

David Jackman
In reply to this post by vijayakumar.lakshmanan
I think this is another place where the docs (or the examples in the
docs) don't quite match reality.  I've seen similar problems trying to
access properties/variables in this way, and noticed that code used in
the plugins looked different.  Try something like this:

<j:if test="${context.getVariable('a') == 'yes'}">
   <echo message="Success"/>
</j:if>


-----Original Message-----
From: Vincent Siveton [mailto:[hidden email]]
Sent: Thursday, May 05, 2005 6:28 AM
To: 'Maven Users List'
Subject: RE: Maven - IF Tag problem

Hi,

For me its not an issue.
Let s try to define the variable a as a String:
<j:set var="a">${c}</j:set>

Cheers,

Vincent

> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]]
> Sent: Thursday, May 05, 2005 8:17 AM
> To: [hidden email]
> Subject: Maven - IF Tag problem
>
>
> Hi All....
>
>
>
>
> Problem Statement:
>
> The condition in the IF tag does not validate correctly, when any
> variable retrieved from the property file is being used in the
> condition.
>
> We tried to retrieve a variable from the property file
> <<build.properties>> and assign it to another variable so that it can
> be used in the IF tag for validation.
>
> The IF tag returns 'True' in false condition and vice versa.
>
>
>
>
> The maven.xml contains the following code:
>
>
>
>
>
> <project default="a" xmlns:j="jelly:core">
>
>
>
>
>             <goal name="a">
>
>
>                         <j:set var="a" value="${c}"/>
>
>
>                         <j:if test="${a == 'yes'}">
>
>
>                                     <echo message="Success"/>
>
>
>                         </j:if>
>
>
>             </goal>
>
> </project>
>
>
>
>
>
> The build.properties file contains a name value pair
>
>
>
>
> c=yes
>
>
>
>
> Actual Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> BUILD SUCCESSFUL
>
> Total time: 1 seconds
>
> Finished at: Thu May 05 17:15:50 IST 2005
>
>
>
>
> Expected Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> build:start:
>
>
>
>
> a:
>
>     [echo] Success
>
> BUILD SUCCESSFUL
>
> Total time: 2 seconds
>
> Finished at: Thu May 05 17:18:29 IST 2005
>
>
>
>
> Question:
>
> Please provide some clue to solve this problem
>
>
>
>
>
>
>
>
> Confidentiality Notice
>
>
> The information contained in this electronic message and any
> attachments to this message are intended for the exclusive use of the
> addressee(s) and may contain confidential or privileged information.
> If you are not the intended recipient, please notify the sender at
> Wipro or [hidden email] immediately and destroy all copies of
> this message and any attachments.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Maven - IF Tag problem

thomasvdv
In reply to this post by vijayakumar.lakshmanan
== != equals()
 ;-)

 On 5/5/05, [hidden email] <
[hidden email]> wrote:
>
>
> Thanks man it's working.
>
> -----Original Message-----
> Wrom:
> UIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPKYLEJGDGVCJVTLBXFGGMEPYOQKEDOTWFAOBUZXUWLSZLKBRNVWWCUFPEGAUTFJMVRESKPNKMBIPBARHDMNNSKVFVWRKJVZCMHVIBGDADRZFSQHYUCDDJBLVLMHAALP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LEJGDGVCJVTLBXFGGMEPYOQKEDOTWFAOBUZXUWLSZLKBRNVWWCUFPEGAUTFJMVRESKPNKMBIPBARHDMNNSKVFVWRKJVZCMHVIBGDADRZFSQHYUCDDJBLVLMHAALPTCXLYRWTQTIPWIGYOKSTTZRCLBDXRQBGJSNBOHMKHJYFMYXOEAIJJPHSCRTNHGSWZIDREXCAXZOWCONEUQZAAFXISHJEXXIMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPKYLEJGDGVCJVTLBXFGGMEPYOQKEDOTWFAOBUZXUWLSZLKBRNVWWCUFPEGAUTFJMVRESKPNKMBIPBARHDMNNSKVFVWRKJVZCMHVIBGDADRZFSQHYUCDDJBLVLMHAALPTCXLYRWTQTIPWIGYOKSTTZRCLBDXRQBGJSNBOHMKHJYFMYXOEAIJJPHSCRTNHGSWZIDREXCAXZOWCONEUQZAAFXISHJEXXIMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPKYLEJGDGVCJVTLBXFGGMEPYOQKEDOTWFAOBUZXUWLSZLKBRNVWWCUFPEGAUTFJMVRESKPNKMBIPBARHDMNNSKVFVWRKJVZCMHVIBGDADRZFSQHYUCDDJBLVLMHAALPTCXLYRWTQTIPWIGYOKSTTZRCLBDXRQBGJSNBOHMKHJYFMYXOEAIJJPHSCRTNHGSWZIDREXCAXZOWCONEUQZAAFXISHJEXXIMQZUIVOTQNQEMSFDULHPQQWOYIYZUNNYCGPKYLEJGDGVCJVTLBXFGGMEPYOQKEDOTWFAO
Reply | Threaded
Open this post in threaded view
|

RE: Maven - IF Tag problem

vijayakumar.lakshmanan
In reply to this post by vijayakumar.lakshmanan

Thank you very much

-----Original Message-----
From: Thomas Van de Velde [mailto:[hidden email]]
Sent: Thursday, May 05, 2005 6:42 PM
To: Maven Users List
Subject: Re: Maven - IF Tag problem

== != equals()
 ;-)

 On 5/5/05, [hidden email] <
[hidden email]> wrote:
>
>
> Thanks man it's working.
>
> -----Original Message-----
> Wrom:
>
UIVOTQ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this electronic message and any attachments to this message are intended
for the exclusive use of the addressee(s) and may contain confidential or privileged information. If
you are not the intended recipient, please notify the sender at Wipro or [hidden email] immediately
and destroy all copies of this message and any attachments.

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: Maven - IF Tag problem

vijayakumar.lakshmanan
In reply to this post by vijayakumar.lakshmanan

Thank you very much

-----Original Message-----
From: David Jackman [mailto:[hidden email]]
Sent: Thursday, May 05, 2005 6:41 PM
To: Maven Users List
Subject: RE: Maven - IF Tag problem

I think this is another place where the docs (or the examples in the
docs) don't quite match reality.  I've seen similar problems trying to
access properties/variables in this way, and noticed that code used in
the plugins looked different.  Try something like this:

<j:if test="${context.getVariable('a') == 'yes'}">
   <echo message="Success"/>
</j:if>


-----Original Message-----
From: Vincent Siveton [mailto:[hidden email]]
Sent: Thursday, May 05, 2005 6:28 AM
To: 'Maven Users List'
Subject: RE: Maven - IF Tag problem

Hi,

For me its not an issue.
Let s try to define the variable a as a String:
<j:set var="a">${c}</j:set>

Cheers,

Vincent

> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]]
> Sent: Thursday, May 05, 2005 8:17 AM
> To: [hidden email]
> Subject: Maven - IF Tag problem
>
>
> Hi All....
>
>
>
>
> Problem Statement:
>
> The condition in the IF tag does not validate correctly, when any
> variable retrieved from the property file is being used in the
> condition.
>
> We tried to retrieve a variable from the property file
> <<build.properties>> and assign it to another variable so that it can
> be used in the IF tag for validation.
>
> The IF tag returns 'True' in false condition and vice versa.
>
>
>
>
> The maven.xml contains the following code:
>
>
>
>
>
> <project default="a" xmlns:j="jelly:core">
>
>
>
>
>             <goal name="a">
>
>
>                         <j:set var="a" value="${c}"/>
>
>
>                         <j:if test="${a == 'yes'}">
>
>
>                                     <echo message="Success"/>
>
>
>                         </j:if>
>
>
>             </goal>
>
> </project>
>
>
>
>
>
> The build.properties file contains a name value pair
>
>
>
>
> c=yes
>
>
>
>
> Actual Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> BUILD SUCCESSFUL
>
> Total time: 1 seconds
>
> Finished at: Thu May 05 17:15:50 IST 2005
>
>
>
>
> Expected Output:
>
>
>
>
> __  __
>
> |  \/  |__ _Apache__ ___
>
> | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
>
> |_|  |_\__,_|\_/\___|_||_|  v. 1.0.2
>
>
>
>
> build:start:
>
>
>
>
> a:
>
>     [echo] Success
>
> BUILD SUCCESSFUL
>
> Total time: 2 seconds
>
> Finished at: Thu May 05 17:18:29 IST 2005
>
>
>
>
> Question:
>
> Please provide some clue to solve this problem
>
>
>
>
>
>
>
>
> Confidentiality Notice
>
>
> The information contained in this electronic message and any
> attachments to this message are intended for the exclusive use of the
> addressee(s) and may contain confidential or privileged information.
> If you are not the intended recipient, please notify the sender at
> Wipro or [hidden email] immediately and destroy all copies of
> this message and any attachments.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]




Confidentiality Notice

The information contained in this electronic message and any attachments to this message are intended
for the exclusive use of the addressee(s) and may contain confidential or privileged information. If
you are not the intended recipient, please notify the sender at Wipro or [hidden email] immediately
and destroy all copies of this message and any attachments.

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]