You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Paul Mietz Egli (JIRA)" <ji...@apache.org> on 2007/12/26 22:38:43 UTC
[jira] Created: (JCR-1279) add ability to pass arguments to
instances of field converters
add ability to pass arguments to instances of field converters
--------------------------------------------------------------
Key: JCR-1279
URL: https://issues.apache.org/jira/browse/JCR-1279
Project: Jackrabbit
Issue Type: Wish
Components: jcr-mapping
Affects Versions: 1.4
Reporter: Paul Mietz Egli
Priority: Minor
It would be useful to be able to pass arguments to a custom field converter so related converters can be reused. For example, a converter that stores images could take arguments which specify the image type and maximum dimensions. These arguments could be placed in the @Field annotation:
@Field(converter = BufferedImageConverter.class, converterArgs = { "png", 120, 80 })
private BufferedImage img;
and provided to the type converter instance via a method defined in AtomicTypeConverter:
public BufferedImageConverter implements AtomicTypeConverter {
/**
* new method in the AtomicTypeConverter interface
*/
public void setConverterArgs(Object[] args) {
// ...
}
}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Moved: (OCM-30) add ability to pass arguments to instances
of field converters
Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OCM-30?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jukka Zitting moved JCR-1279 to OCM-30:
---------------------------------------
Component/s: (was: jackrabbit-ocm)
Description: (was: It would be useful to be able to pass arguments to a custom field converter so related converters can be reused. For example, a converter that stores images could take arguments which specify the image type and maximum dimensions. These arguments could be placed in the @Field annotation:
@Field(converter = BufferedImageConverter.class, converterArgs = { "png", 120, 80 })
private BufferedImage img;
and provided to the type converter instance via a method defined in AtomicTypeConverter:
public BufferedImageConverter implements AtomicTypeConverter {
/**
* new method in the AtomicTypeConverter interface
*/
public void setConverterArgs(Object[] args) {
// ...
}
}
)
Affects Version/s: (was: 1.4)
Workflow: no-reopen-closed, patch-avail (was: jira)
Key: OCM-30 (was: JCR-1279)
Project: Jackrabbit OCM (was: Jackrabbit Content Repository)
> add ability to pass arguments to instances of field converters
> --------------------------------------------------------------
>
> Key: OCM-30
> URL: https://issues.apache.org/jira/browse/OCM-30
> Project: Jackrabbit OCM
> Issue Type: Wish
> Reporter: Paul Mietz Egli
> Priority: Minor
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OCM-30) add ability to pass arguments to instances
of field converters
Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OCM-30?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jukka Zitting updated OCM-30:
-----------------------------
Description:
It would be useful to be able to pass arguments to a custom field converter so related converters can be reused. For example, a converter that stores images could take arguments which specify the image type and maximum dimensions. These arguments could be placed in the @Field annotation:
{code}
@Field(converter = BufferedImageConverter.class, converterArgs = { "png", 120, 80 })
private BufferedImage img;
{code}
and provided to the type converter instance via a method defined in AtomicTypeConverter:
{code}
public BufferedImageConverter implements AtomicTypeConverter {
/**
* new method in the AtomicTypeConverter interface
*/
public void setConverterArgs(Object[] args) {
// ...
}
}
{code}
Issue Type: New Feature (was: Wish)
> add ability to pass arguments to instances of field converters
> --------------------------------------------------------------
>
> Key: OCM-30
> URL: https://issues.apache.org/jira/browse/OCM-30
> Project: Jackrabbit OCM
> Issue Type: New Feature
> Reporter: Paul Mietz Egli
> Priority: Minor
>
> It would be useful to be able to pass arguments to a custom field converter so related converters can be reused. For example, a converter that stores images could take arguments which specify the image type and maximum dimensions. These arguments could be placed in the @Field annotation:
> {code}
> @Field(converter = BufferedImageConverter.class, converterArgs = { "png", 120, 80 })
> private BufferedImage img;
> {code}
> and provided to the type converter instance via a method defined in AtomicTypeConverter:
> {code}
> public BufferedImageConverter implements AtomicTypeConverter {
> /**
> * new method in the AtomicTypeConverter interface
> */
> public void setConverterArgs(Object[] args) {
> // ...
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.