[forge-issues] [JBoss JIRA] (FORGE-1206) Imported<?>.get() has a different behavior compared to iterator()
Lincoln Baxter III (JIRA)
jira-events at lists.jboss.org
Tue Sep 17 14:19:03 EDT 2013
[ https://issues.jboss.org/browse/FORGE-1206?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Lincoln Baxter III closed FORGE-1206.
-------------------------------------
Assignee: Lincoln Baxter III
Fix Version/s: 2.0.0.Alpha13
(was: 2.x Future)
Resolution: Done
> Imported<?>.get() has a different behavior compared to iterator()
> -----------------------------------------------------------------
>
> Key: FORGE-1206
> URL: https://issues.jboss.org/browse/FORGE-1206
> Project: Forge
> Issue Type: Bug
> Components: Furnace (Container)
> Affects Versions: 2.0.0.Alpha12
> Reporter: George Gastaldi
> Assignee: Lincoln Baxter III
> Fix For: 2.0.0.Alpha13
>
>
> Given:
> {code:java}
> public interface MyInterface {}
> {code}
> and
> {code:java}
> public class Foo implements MyInterface {}
> {code}
> Trying to retrieve it from the Imported object from AddonRegistry:
> {code:java}
> Imported<MyInterface> imported = addonRegistry.getServices(MyInterface.class);
> {code}
> The following statements are observed:
> # imported.get() returns instance of Foo
> # imported.iterator().hasNext() returns false.
> Since no {{@Exported}} is placed in {{MyInterface}}, I believe the first statement is a bug.
--
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
More information about the forge-issues
mailing list