Refactoring in RB? 
Author Message
 Refactoring in RB?

Hi,

I'm relatively new to RealBasic. I'm porting an application I originally
wrote in Java. I'm very pleased with the graphics abilities of RB and its
ability to handle very "large" images without annoying memory adjustments.
I'm also happy to find how similar the OOP concepts are to Java. It makes the
transition much simpler. My question has to do with the editing environment.
Is there anything approaching refactoring in RB as there is in Java IDEs like
JBuilder?



Sun, 11 Dec 2005 23:35:59 GMT  
 Refactoring in RB?


Quote:
> Is there anything approaching refactoring in RB as there is in Java IDEs like
> JBuilder?

I haven't used JBuilder.  Assisted refactoring is something I'm very
interested in, however.  Please describe what you have in mind and how
it works.

Thanks,
- Joe

,------------------------------------------------------------------.
|    Joseph J. Strout         Check out the Mac Web Directory:     |

`------------------------------------------------------------------'



Mon, 12 Dec 2005 06:17:44 GMT  
 Refactoring in RB?
On Wed, 25 Jun 2003 15:17:44 -0700, Joe Strout wrote

Quote:
> I haven't used JBuilder.  Assisted refactoring is something I'm very
> interested in, however.  Please describe what you have in mind and how
> it works.

Today, for example, I decided to rename a class. The only way I could see to
do it in RB was to use the search/replace function -- very awkward. Even
then, it seems that search does not see into class parameters and other
"recesses" of objects. My only recourse was to keep attempting to compile and
tracking down every error one by one.

Refactoring would allow renaming classes, methods, variables/parameters, etc.
on the fly. All parts of the project are intelligently searched and the
changed is inserted wherever it is referenced.

I understand that refactoring is no easy matter. There are stand-alone apps
for Java to do nothing but refactoring. When working on a large project the
value of refactoring is incalculable.

Best Regards,
Ola Olsson

http://www.enosis.net



Mon, 12 Dec 2005 08:00:45 GMT  
 Refactoring in RB?


Quote:
> On Wed, 25 Jun 2003 15:17:44 -0700, Joe Strout wrote

> > I haven't used JBuilder.  Assisted refactoring is something I'm very
> > interested in, however.  Please describe what you have in mind and how
> > it works.

> Today, for example, I decided to rename a class. The only way I could see to
> do it in RB was to use the search/replace function -- very awkward. Even
> then, it seems that search does not see into class parameters and other
> "recesses" of objects. My only recourse was to keep attempting to compile and
> tracking down every error one by one.

True.  (Though you could make this go faster by using the "Show Multiple
Compiler Errors" option in the preferences.)

If you want to see this sort of thing, I would recommend you submit a
feature request for the first, say, half a dozen such things you want to
see.  (Example: "Smart Renaming of Classes -- There should be a way for
me to rename a class that updates all references in the code,
properties, or parameters so that the code functions exactly as before.")

You could also make a general feature request for assisted refactoring
tools.  This is something we're all interested in, and we're working on
the infrastructure under the hood already, but it's important for users
to express their interest.

Best,
- Joe

,------------------------------------------------------------------.
|    Joseph J. Strout         Check out the Mac Web Directory:     |

`------------------------------------------------------------------'



Mon, 12 Dec 2005 09:51:44 GMT  
 Refactoring in RB?

Quote:


>> On Wed, 25 Jun 2003 15:17:44 -0700, Joe Strout wrote

>> > I haven't used JBuilder.  Assisted refactoring is something I'm very
>> > interested in, however.  Please describe what you have in mind and how
>> > it works.

>> Today, for example, I decided to rename a class. The only way I could see to
>> do it in RB was to use the search/replace function -- very awkward. Even
>> then, it seems that search does not see into class parameters and other
>> "recesses" of objects. My only recourse was to keep attempting to compile and
>> tracking down every error one by one.

>True.  (Though you could make this go faster by using the "Show Multiple
>Compiler Errors" option in the preferences.)

It's not possible to do it by saving the project in xml, do the change
with a text editor and reopen the xml-project ?

--
Frdric Testuz



Mon, 12 Dec 2005 14:54:04 GMT  
 Refactoring in RB?

Quote:




>>>On Wed, 25 Jun 2003 15:17:44 -0700, Joe Strout wrote

>>>>I haven't used JBuilder.  Assisted refactoring is something I'm very
>>>>interested in, however.  Please describe what you have in mind and how
>>>>it works.

>>>Today, for example, I decided to rename a class. The only way I could see to
>>>do it in RB was to use the search/replace function -- very awkward. Even
>>>then, it seems that search does not see into class parameters and other
>>>"recesses" of objects. My only recourse was to keep attempting to compile and
>>>tracking down every error one by one.

>>True.  (Though you could make this go faster by using the "Show Multiple
>>Compiler Errors" option in the preferences.)

>It's not possible to do it by saving the project in xml, do the change
>with a text editor and reopen the xml-project ?

True, but only if your project is made of a single file. But if your
project only contains reference
to external files (class, window, etc) this solution is not an option.

--

---------------------------------------------------------------------
Francois Menneteau - Software Engineer, MIPSYS
Technoparc du Griffon - Bat 10
511, route de la Seds
13127 Vitrolles
Tel: +33 (0)4 42 46 77 50 - Fax: +33 (0)4 42 46 77 59



Mon, 12 Dec 2005 15:44:09 GMT  
 Refactoring in RB?


Quote:


> > On Wed, 25 Jun 2003 15:17:44 -0700, Joe Strout wrote

> > > I haven't used JBuilder.  Assisted refactoring is something I'm very
> > > interested in, however.  Please describe what you have in mind and how
> > > it works.

> > Today, for example, I decided to rename a class. The only way I could
see to
> > do it in RB was to use the search/replace function -- very awkward. Even
> > then, it seems that search does not see into class parameters and other
> > "recesses" of objects. My only recourse was to keep attempting to
compile and
> > tracking down every error one by one.

> True.  (Though you could make this go faster by using the "Show Multiple
> Compiler Errors" option in the preferences.)

> You could also make a general feature request for assisted refactoring
> tools.  This is something we're all interested in, and we're working on
> the infrastructure under the hood already, but it's important for users
> to express their interest.

Such tools exist, although not designed specifically to work with RealBasic.
What this means is that one has to define the language to the Refactoring
tool before it is usable for such tasks, and to be fair, that's a chunk
of work all by itself.   In any case, a general refactoring tool is called
a "program transformation system" and you can see a little bit about
one at:
   http://www.semanticdesigns.com/Products/DMS/DMSToolkit.html
It presently knows how to parse/transform/prettyprint C, C++, Java,
COBOL, Ada, JavaScript, C#, VisualBasic and quite a long list of other
languages.   We haven't gotten round to do RealBasic yet; the market
demand isn't obviously there.

--
Ira D. Baxter, Ph.D., CTO   512-250-1018
Semantic Designs, Inc.      www.semdesigns.com

----== Posted via Newsfeed.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeed.com The #1 Newsgroup Service in the World! >100,000 Newsgroups
---= 19 East/West-Coast Specialized Servers - Total Privacy via Encryption =---



Wed, 14 Dec 2005 01:31:09 GMT  
 
 [ 7 post ] 

 Relevant Pages 

1. Refactoring Browser. VSE Refactoring Browser

2. RB QuickStart Guider from RB

3. launching an RB app from another RB app - appleevents

4. RB Entwickler gesucht / RB Developers wanted

5. RB: row order by RB database

6. protocol.rb http.rb 1.1.24

7. replace setup.rb/install.rb with builtin module

8. install.rb/setup.rb question

9. Bugs corrected in DBD/ODBC/ODBC.rb and DBD/Proxy/Proxy.rb

10. Refactoring Browser News

11. how to use extract method refactoring

12. Refactoring Browser

 

 
Powered by phpBB® Forum Software