• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: categories porting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: categories porting


  • Subject: Re: categories porting
  • From: Sacha Mallais <email@hidden>
  • Date: Mon, 23 May 2005 12:46:47 -0700

On May 23, 2005, at 9:28 am, Mohamed Mnajja wrote:

i'm trying to migrate an existent Objective-C
classes to Java using the JavaConverter.
 
i have a problem when porting a Category.
the JavaConverter doesn't generate any associated
class.
 
what is the best way to migrate the categories into Java (especially
categories of the foundation and EOF classes):
 
    1-transform the ObjC categories to classes that inherits
    from the original base class. which includes only the category's
    methods and then i perform the convertion.
 
    2- transform the ObjC categories to classes that inherits
    from the original base class:
        - which adds a new attribute from the base class(which
        will be used as parameter to the constructor),
        - the category's methods ,
        - and reimplements the  base class methods by calling
        the associated method from new attribute attribute.

What we did was create static functions for the methods in the category. AFAIK, there is no better way, since inheriting from the base class gets you nothing if the child is never used.


sacha


-- Sacha Michel Mallais - 400 lb. chimp Global Village Consulting Inc.: http://www.global-village.net/ 1. Never tell everything at once. -- Ken Venturi, Ken Venturi's Two Great Rules of Life

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >categories porting (From: "Mohamed Mnajja" <email@hidden>)

  • Prev by Date: categories porting
  • Next by Date: Re: Active Directory
  • Previous by thread: categories porting
  • Next by thread: [OT] DVD of Chuck Hill's & Sacha Mallais' WO presentation in Seattle
  • Index(es):
    • Date
    • Thread