Q:

Spring SpEL - set a property only if the value is not null

I'm using Spring and I want to set a property only if the value passed is not null? 
I tried this example but it doesn't work. 
I want to add the property only if it is not null else not add it. 
I don't want to add a default value. 
Thanks for your help 
<util:properties id="mailProperties" location="classpath:mail.properties"/>
  <property name="javaMailProperties">
        <props>
            <prop key="mail.smtp.starttls.enable">#{mailProperties['mail.smtp.starttls.enable']:''}</prop>             
           </props>
    </property>

A:

#{mailProperties['mail.smtp.starttls.enable']==null ?  false: mailProperties['mail.smtp.starttls.enable']}

Here is an example To set a default value: if value is null I set it to false else I set it to its value.