You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pivot.apache.org by "Greg Brown (JIRA)" <ji...@apache.org> on 2010/06/14 00:29:13 UTC

[jira] Created: (PIVOT-528) Allow Dictionary values to be specified using elements in WTKX

Allow Dictionary values to be specified using elements in WTKX
--------------------------------------------------------------

                 Key: PIVOT-528
                 URL: https://issues.apache.org/jira/browse/PIVOT-528
             Project: Pivot
          Issue Type: Improvement
          Components: wtk-wtkx
            Reporter: Greg Brown
            Priority: Minor
             Fix For: 1.5.1


Currently, it is possible to populate a dictionary type via attributes but not elements. For example, this is supported:

<HashMap abc="123"/>

as is this:

<MyBeanClass>
  <abc>
    <MyOtherBeanClass/>
  </abc>
</MyBeanClass>

but this is not:

<HashMap>
  <abc>
    <MyOtherBeanClass/>
  </abc>
</HashMap>

This prevents callers from populating a dictionary with anything other than primitive values. WTKXSerializer should also allow a caller to populate a dictionary with complex types, as shown above.


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (PIVOT-528) Allow Dictionary values to be specified using elements in WTKX

Posted by "Greg Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/PIVOT-528?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12879030#action_12879030 ] 

Greg Brown commented on PIVOT-528:
----------------------------------

Good catch. That exception was no longer valid. This is now fixed.


> Allow Dictionary values to be specified using elements in WTKX
> --------------------------------------------------------------
>
>                 Key: PIVOT-528
>                 URL: https://issues.apache.org/jira/browse/PIVOT-528
>             Project: Pivot
>          Issue Type: Improvement
>          Components: wtk-wtkx
>            Reporter: Greg Brown
>            Priority: Minor
>             Fix For: 1.5.1
>
>
> Currently, it is possible to populate a dictionary type via attributes but not elements. For example, this is supported:
> <HashMap abc="123"/>
> as is this:
> <MyBeanClass>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </MyBeanClass>
> but this is not:
> <HashMap>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </HashMap>
> This prevents callers from populating a dictionary with anything other than primitive values. WTKXSerializer should also allow a caller to populate a dictionary with complex types, as shown above.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (PIVOT-528) Allow Dictionary values to be specified using elements in WTKX

Posted by "Appddevvv (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/PIVOT-528?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12879006#action_12879006 ] 

Appddevvv commented on PIVOT-528:
---------------------------------

Not sure its working that way for the userData property on a component.

Here's the error I get from things like:

Caused by: org.apache.pivot.serialization.SerializationException: Parent element must be a typed object.
	at org.apache.pivot.wtkx.WTKXSerializer.processStartElement(WTKXSerializer.java:643)
	at org.apache.pivot.wtkx.WTKXSerializer.readObject(WTKXSerializer.java:456)
	at org.apache.pivot.wtkx.WTKXSerializer.readObject(WTKXSerializer.java:412)
	at org.apache.pivot.springframework.SerializerFactoryBean.initSerializer(SerializerFactoryBean.java:146)
	... 21 more


> Allow Dictionary values to be specified using elements in WTKX
> --------------------------------------------------------------
>
>                 Key: PIVOT-528
>                 URL: https://issues.apache.org/jira/browse/PIVOT-528
>             Project: Pivot
>          Issue Type: Improvement
>          Components: wtk-wtkx
>            Reporter: Greg Brown
>            Priority: Minor
>             Fix For: 1.5.1
>
>
> Currently, it is possible to populate a dictionary type via attributes but not elements. For example, this is supported:
> <HashMap abc="123"/>
> as is this:
> <MyBeanClass>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </MyBeanClass>
> but this is not:
> <HashMap>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </HashMap>
> This prevents callers from populating a dictionary with anything other than primitive values. WTKXSerializer should also allow a caller to populate a dictionary with complex types, as shown above.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (PIVOT-528) Allow Dictionary values to be specified using elements in WTKX

Posted by "Greg Brown (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/PIVOT-528?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Greg Brown resolved PIVOT-528.
------------------------------

    Resolution: Fixed

> Allow Dictionary values to be specified using elements in WTKX
> --------------------------------------------------------------
>
>                 Key: PIVOT-528
>                 URL: https://issues.apache.org/jira/browse/PIVOT-528
>             Project: Pivot
>          Issue Type: Improvement
>          Components: wtk-wtkx
>            Reporter: Greg Brown
>            Priority: Minor
>             Fix For: 1.5.1
>
>
> Currently, it is possible to populate a dictionary type via attributes but not elements. For example, this is supported:
> <HashMap abc="123"/>
> as is this:
> <MyBeanClass>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </MyBeanClass>
> but this is not:
> <HashMap>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </HashMap>
> This prevents callers from populating a dictionary with anything other than primitive values. WTKXSerializer should also allow a caller to populate a dictionary with complex types, as shown above.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (PIVOT-528) Allow Dictionary values to be specified using elements in WTKX

Posted by "Appddevvv (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/PIVOT-528?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12878655#action_12878655 ] 

Appddevvv commented on PIVOT-528:
---------------------------------

Does this fix allow me to specify the contents of a user data dictionary using primitive and complex types?

> Allow Dictionary values to be specified using elements in WTKX
> --------------------------------------------------------------
>
>                 Key: PIVOT-528
>                 URL: https://issues.apache.org/jira/browse/PIVOT-528
>             Project: Pivot
>          Issue Type: Improvement
>          Components: wtk-wtkx
>            Reporter: Greg Brown
>            Priority: Minor
>             Fix For: 1.5.1
>
>
> Currently, it is possible to populate a dictionary type via attributes but not elements. For example, this is supported:
> <HashMap abc="123"/>
> as is this:
> <MyBeanClass>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </MyBeanClass>
> but this is not:
> <HashMap>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </HashMap>
> This prevents callers from populating a dictionary with anything other than primitive values. WTKXSerializer should also allow a caller to populate a dictionary with complex types, as shown above.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (PIVOT-528) Allow Dictionary values to be specified using elements in WTKX

Posted by "Greg Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/PIVOT-528?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12878771#action_12878771 ] 

Greg Brown commented on PIVOT-528:
----------------------------------

Yes. See the above example, which adds an instance of MyOtherBeanClass to a HashMap with a key of "abc".


> Allow Dictionary values to be specified using elements in WTKX
> --------------------------------------------------------------
>
>                 Key: PIVOT-528
>                 URL: https://issues.apache.org/jira/browse/PIVOT-528
>             Project: Pivot
>          Issue Type: Improvement
>          Components: wtk-wtkx
>            Reporter: Greg Brown
>            Priority: Minor
>             Fix For: 1.5.1
>
>
> Currently, it is possible to populate a dictionary type via attributes but not elements. For example, this is supported:
> <HashMap abc="123"/>
> as is this:
> <MyBeanClass>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </MyBeanClass>
> but this is not:
> <HashMap>
>   <abc>
>     <MyOtherBeanClass/>
>   </abc>
> </HashMap>
> This prevents callers from populating a dictionary with anything other than primitive values. WTKXSerializer should also allow a caller to populate a dictionary with complex types, as shown above.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.