felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carsten Ziegeler (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (FELIX-4047) Unable to create empty or single valued String array property
Date Sun, 05 May 2013 10:32:17 GMT

     [ https://issues.apache.org/jira/browse/FELIX-4047?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Carsten Ziegeler updated FELIX-4047:
------------------------------------

    Fix Version/s: scr annotations 1.9.4
                   scr generator 1.7.0
                   scr ant task 1.7.0
                   maven-scr-plugin 1.13.0
    
> Unable to create empty or single valued String array property
> -------------------------------------------------------------
>
>                 Key: FELIX-4047
>                 URL: https://issues.apache.org/jira/browse/FELIX-4047
>             Project: Felix
>          Issue Type: Bug
>          Components: Maven SCR Plugin
>    Affects Versions: maven-scr-plugin-1.8.0, maven-scr-plugin-1.12.0
>            Reporter: Thomas Joseph
>            Assignee: Carsten Ziegeler
>             Fix For: maven-scr-plugin 1.13.0, scr ant task 1.7.0, scr generator 1.7.0,
scr annotations 1.9.4
>
>
> There is no way that I can declare an empty or a single valued String array property.
> @Property(label="Multivalued Property", value={"only-single-value"})
> private static final String MV_PROPERTY= "multivalued.property";
> OR
> @Property(label="Multivalued Property", value={"only-single-value"}, unbounded=PropertyUnbounded.ARRAY)
> private static final String MV_PROPERTY= "multivalued.property";
> OR
> @Property(label="Multivalued Property", value={"only-single-value"}, cardinality=N)
> private static final String MV_PROPERTY= "multivalued.property";
> All would generate the same DS XML file as:
> <property name="multivalued.property" value="only-single-value"/>
> As of now the only workaround is to declare an array with at-least two entries:
> @Property(label="Multivalued Property", value={"only-single-value", ""})
> private static final String MV_PROPERTY= "multivalued.property";
> OR
> @Property(label="Multivalued Property", value={"", ""})
> private static final String MV_PROPERTY= "multivalued.property";

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message