o Added primitive parameters

git-svn-id: https://svn.apache.org/repos/asf/maven/core-integration-testing/trunk@808943 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Benjamin Bentmann 2009-08-28 16:29:03 +00:00
parent 3b0b101f88
commit 634dc3197d
1 changed files with 22 additions and 0 deletions

View File

@ -103,6 +103,13 @@ public class ConfigMojo
*/
private Boolean booleanParam;
/**
* A simple parameter of type {@link java.lang.Boolean#TYPE}.
*
* @parameter expression="${config.primitiveBooleanParam}"
*/
private boolean primitiveBooleanParam;
/**
* A simple parameter of type {@link java.lang.Byte}.
*
@ -124,6 +131,13 @@ public class ConfigMojo
*/
private Integer integerParam;
/**
* A simple parameter of type {@link java.lang.Integer#TYPE}.
*
* @parameter expression="${config.primitiveIntegerParam}"
*/
private int primitiveIntegerParam;
/**
* A simple parameter of type {@link java.lang.Long}.
*
@ -314,9 +328,17 @@ public class ConfigMojo
dumpValue( props, "defaultParamWithExpression", defaultParamWithExpression );
dumpValue( props, "aliasDefaultExpressionParam", aliasDefaultExpressionParam );
dumpValue( props, "booleanParam", booleanParam );
if ( primitiveBooleanParam )
{
dumpValue( props, "primitiveBooleanParam", Boolean.valueOf( primitiveBooleanParam ) );
}
dumpValue( props, "byteParam", byteParam );
dumpValue( props, "shortParam", shortParam );
dumpValue( props, "integerParam", integerParam );
if ( primitiveIntegerParam != 0 )
{
dumpValue( props, "primitiveIntegerParam", new Integer( primitiveIntegerParam ) );
}
dumpValue( props, "longParam", longParam );
dumpValue( props, "floatParam", floatParam );
dumpValue( props, "doubleParam", doubleParam );