Is there some refactoring tool to use when you want to split a class
in two, so that you have a core set of methods and an extended set or
perhaps even two independent classes.

Signature
Bush crime family lost/embezzled $3 trillion from Pentagon.
Complicit Bush-friendly media keeps mum. Rumsfeld confesses on video.
http://www.infowars.com/articles/us/mckinney_grills_rumsfeld.htm
Canadian Mind Products, Roedy Green.
See http://mindprod.com/iraq.html photos of Bush's war crimes
Roland - 15 Jul 2005 09:30 GMT
> Is there some refactoring tool to use when you want to split a class
> in two, so that you have a core set of methods and an extended set or
> perhaps even two independent classes.
In Eclipse, you can use 'Refactor -> Pull Up' and 'Refactor -> Push
Down' to move members (fields and methods) up and down the class hierarchy.

Signature
Regards,
Roland de Ruiter
` ___ ___
`/__/ w_/ /__/
/ \ /_/ / \
Tim Tyler - 15 Jul 2005 22:17 GMT
Roedy Green <look-on@mindprod.com.invalid> wrote or quoted:
> Is there some refactoring tool to use when you want to split a class
> in two, so that you have a core set of methods and an extended set or
> perhaps even two independent classes.
You can drag groups of selected methods between classes in the
Eclipse Package explorer.

Signature
__________
|im |yler http://timtyler.org/ tim@tt1lock.org Remove lock to reply.
Wibble - 16 Jul 2005 01:19 GMT
> Is there some refactoring tool to use when you want to split a class
> in two, so that you have a core set of methods and an extended set or
> perhaps even two independent classes.
Lol, now you're asking questions where eclipse is the answer...
Roedy Green - 16 Jul 2005 11:30 GMT
>Lol, now you're asking questions where eclipse is the answer...
Pull up never seems to be applicable since I am usually splitting off
a sibling class. there is no hierarchy to push/pull to.

Signature
Bush crime family lost/embezzled $3 trillion from Pentagon.
Complicit Bush-friendly media keeps mum. Rumsfeld confesses on video.
http://www.infowars.com/articles/us/mckinney_grills_rumsfeld.htm
Canadian Mind Products, Roedy Green.
See http://mindprod.com/iraq.html photos of Bush's war crimes
Dale King - 16 Jul 2005 21:29 GMT
>>Lol, now you're asking questions where eclipse is the answer...
>
> Pull up never seems to be applicable since I am usually splitting off
> a sibling class. there is no hierarchy to push/pull to.
I agree and have often wished for a "Create superclass" refactoring to
create an empty super class that you can then "pull-up" to. It should
also support creating superclasses for a set of classes so that all are
then subclasses of the same superclass.

Signature
Dale King