abdera-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rob Evans (JIRA)" <j...@apache.org>
Subject [jira] Commented: (ABDERA-51) Type parameters of <T> cannot be determined
Date Fri, 13 Jul 2007 17:41:04 GMT

    [ https://issues.apache.org/jira/browse/ABDERA-51?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12512549
] 

Rob Evans commented on ABDERA-51:
---------------------------------

Here's a patch that seems to fix things -- at least the parser and core unit tests pass. 


Index: D:/pl/applications/rest-work/abdera.trunk/core/src/main/java/org/apache/abdera/factory/Factory.java
===================================================================
--- D:/pl/applications/rest-work/abdera.trunk/core/src/main/java/org/apache/abdera/factory/Factory.java
(revision 556050)
+++ D:/pl/applications/rest-work/abdera.trunk/core/src/main/java/org/apache/abdera/factory/Factory.java
(working copy)
@@ -553,7 +553,7 @@
    * Create a new Element with the given QName.
    * @return A newly created element
    */
-  <T extends Element>T newElement(QName qname);
+  Element newElement(QName qname);
 
   /**
    * Create a new Element with the given QName as a child of the given Base.
@@ -561,14 +561,14 @@
    * @param parent The element or document to which the new element should be added as a
child
    * @return A newly created element
    */
-  <T extends Element>T newElement(QName qname, Base parent);
+  Element newElement(QName qname, Base parent);
 
   /**
    * Create a new extension element with the given QName.
    * @param qname The XML QName of the element to create
    * @return A newly created element
    */
-  <T extends Element>T newExtensionElement(QName qname);
+  Element newExtensionElement(QName qname);
 
   /**
    * Create a new extension element with the given QName as a child of the given Base.
@@ -576,7 +576,7 @@
    * @param parent The element or document to which the new element should be added as a
child
    * @return A newly created element
    */
-  <T extends Element>T newExtensionElement(QName qname, Base parent);
+  Element newExtensionElement(QName qname, Base parent);
 
   /**
    * Create a new Control element.  The app:control element is introduced by
Index: D:/pl/applications/rest-work/abdera.trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java
===================================================================
--- D:/pl/applications/rest-work/abdera.trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java
(revision 555876)
+++ D:/pl/applications/rest-work/abdera.trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMFactory.java
(working copy)
@@ -393,21 +393,21 @@
     return new FOMText(type, qname, (OMContainer)parent,this);
   }
   
-  public <T extends Element>T newElement(QName qname) {
+  public Element newElement(QName qname) {
     return newElement(qname, null);
   }
   
-  public <T extends Element>T newElement(
+  public Element newElement(
     QName qname, 
     Base parent) {
       return newExtensionElement(qname, parent);
   }
   
-  public <T extends Element>T newExtensionElement(QName qname) {
+  public Element newExtensionElement(QName qname) {
     return newExtensionElement(qname, (OMContainer)null);
   }
   
-  public <T extends Element>T newExtensionElement(
+  public Element newExtensionElement(
     QName qname, 
     Base parent) {
     return newExtensionElement(qname, (OMContainer)parent);


> Type parameters of <T> cannot be determined
> -------------------------------------------
>
>                 Key: ABDERA-51
>                 URL: https://issues.apache.org/jira/browse/ABDERA-51
>             Project: Abdera
>          Issue Type: Bug
>    Affects Versions: 0.3.0
>            Reporter: Rob Evans
>             Fix For: 0.3.0
>
>
> Can't build the trunk. Details follow: 
> javac 1.5.0_12
> $ mvn -version
> Maven version: 2.0.6
> [INFO] ----------------------------------------------------------------------------
> [INFO] Building Abdera Parser
> [INFO]    task-segment: [install]
> [INFO] ----------------------------------------------------------------------------
> [INFO] [resources:resources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:compile]
> [INFO] Compiling 5 source files to d:\pl\applications\rest-work\abdera.trunk\parser\target\classes
> [INFO] ------------------------------------------------------------------------
> [ERROR] BUILD FAILURE
> [INFO] ------------------------------------------------------------------------
> [INFO] Compilation failure
> d:\pl\applications\rest-work\abdera.trunk\parser\src\main\java\org\apache\abdera\parser\stax\FOMFactory.java:[397,21]
type parameters of <T>T cannot be determined; no unique maximal instance exists for
type variable T with upper bounds T,or
> g.apache.abdera.model.Element
> d:\pl\applications\rest-work\abdera.trunk\parser\src\main\java\org\apache\abdera\parser\stax\FOMFactory.java:[403,32]
type parameters of <T>T cannot be determined; no unique maximal instance exists for
type variable T with upper bounds T,org.apache.abdera.model.Element
> d:\pl\applications\rest-work\abdera.trunk\parser\src\main\java\org\apache\abdera\parser\stax\FOMFactory.java:[407,30]
type parameters of <T>T cannot be determined; no unique maximal instance exists for
type variable T with upper bounds T,org.apache.abdera.model.Element
> d:\pl\applications\rest-work\abdera.trunk\parser\src\main\java\org\apache\abdera\parser\stax\FOMFactory.java:[413,30]
type parameters of <T>T cannot be determined; no unique maximal instance exists for
type variable T with upper bounds T,org.apache.abdera.model.Element

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


Mime
View raw message