Re: [jira] Created: (CAY-1214) Cayenne should help ensure that callback methods are implemented

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Sat Apr 25 2009 - 02:03:00 EDT

  • Next message: Kevin Menard: "Re: Moving SmartNamingStrategy out of modeler"

    +1

    On Apr 24, 2009, at 7:58 PM, Robert Zeigler (JIRA) wrote:

    > Cayenne should help ensure that callback methods are implemented
    > ----------------------------------------------------------------
    >
    > Key: CAY-1214
    > URL: https://issues.apache.org/jira/browse/CAY-1214
    > Project: Cayenne
    > Issue Type: Improvement
    > Affects Versions: 3.0M5
    > Reporter: Robert Zeigler
    > Assignee: Robert Zeigler
    > Priority: Minor
    >
    >
    > One problem I've had in the past is when I define a callback for a
    > class in the modeler, but then forget to implement the callback, or
    > misspell the callback, etc.
    >
    > Cayenne should ensure that a method is implemented at compile time.
    >
    > At the moment, I think the "right" way to do this is:
    >
    > 1) Make the superclass abstract
    > 2) Add an abstract method in the superclass
    > 3) If generating the subclass, generate a stub method.
    >
    > This ensures that naming issues are caught at compile time.
    >
    >
    >
    > --
    > This message is automatically generated by JIRA.
    > -
    > You can reply to this email to add a comment to the issue online.
    >
    >



    This archive was generated by hypermail 2.0.0 : Sat Apr 25 2009 - 02:03:35 EDT