Velocity Template _Entity Error Question

From: James Cicenia (jame..imijon.com)
Date: Sun Dec 16 2007 - 16:36:55 EST

  • Next message: John Huss (JIRA): "[OS-JIRA] Created: (WOL-695) Unchecking "Create Packages" in the .eogen file doesn't affect the Velocity generator"

    Hello -

    I have this in my superclasses:

       public TOSUser localInstanceIn(EOEditingContext editingContext) {
         TOSUser localInstance =
    (TOSUser)EOUtilities.localInstanceOfObject(editingContext, this);
         if (localInstance == null) {
           throw new IllegalStateException("You attempted to localInstance
    " + this + ", which has not yet committed.");
         }
         return localInstance;
       }

    However, the compiler is telling me that is should be returning a type
    of extended superclass? Strangely when I compile this for java5 I
    don't get the error?

    In this case the compiler wants me to return of type TOSBase which
    TOSUser extends.

    Thoughts?

    Thanks
    James Cicenia



    This archive was generated by hypermail 2.0.0 : Sun Dec 16 2007 - 16:38:17 EST