Documentation Archive Developer
Search
PATH  Documentation > WebObjects 4.5 > Getting Started With WebObjects


   

Adding Custom Behavior to Talent

Now add the fullName method to Talent and bind it to the browser.

  1. Open Talent.java in Project Builder.

    The class file declares instance variables for all of Talent's class properties (firstName and lastName) and implements set and get methods for those instance variables.

  2. Add the method, fullName, as follows.

    public String fullName(){
       return firstName() + " " + lastName();
    }

    After you save, fullName appears in the object browser of WebObjects Builder as a property of Talent.

  3. Bind talent.fullName to the browser's value attribute.


© 1999 Apple Computer, Inc. – (Last Updated 24 Aug 99)