Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

pharo
Status: New
Owner: ----

New issue 3622 by [hidden email]: [ENH]: Clean up  
Url>>urlClassForScheme:
http://code.google.com/p/pharo/issues/detail?id=3622

Pharo1.2rc2 Latest update: #12325

switch-statement-like code


Reply | Threaded
Open this post in threaded view
|

Re: Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

pharo

Comment #1 on issue 3622 by [hidden email]: [ENH]: Clean up  
Url>>urlClassForScheme:
http://code.google.com/p/pharo/issues/detail?id=3622

Fix in inbox  
SLICE-Issue-3622-ENH-Clean-up-UrlurlClassForScheme-SeanDeNigris.1

* replaced switch-statement-like code with an iterator
* added a test for above change
* fixed the categorization of Url 'instance creation' methods


Reply | Threaded
Open this post in threaded view
|

Re: Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

pharo
Updates:
        Status: Fixed
        Labels: Milestone-1.3

Comment #2 on issue 3622 by [hidden email]: [ENH]: Clean up  
Url>>urlClassForScheme:
http://code.google.com/p/pharo/issues/detail?id=3622

Thanks sean.
We will have a look.


Reply | Threaded
Open this post in threaded view
|

Re: Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

pharo
Updates:
        Status: Closed

Comment #3 on issue 3622 by [hidden email]: [ENH]: Clean up  
Url>>urlClassForScheme:
http://code.google.com/p/pharo/issues/detail?id=3622

Sean I integrated your changes but I think that it would be better to have  
a classVariable in URL that contains a dictionary and that each class  
register to it. Like that we do not have to scan all the classes each time.

What do you think?

Stef


Reply | Threaded
Open this post in threaded view
|

Re: Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

pharo

Comment #4 on issue 3622 by [hidden email]: [ENH]: Clean up  
Url>>urlClassForScheme:
http://code.google.com/p/pharo/issues/detail?id=3622

I'd say postpone it untill it shows up on someones profile.
For all the work introducing a cache and its update-logic entails, the  
performance benefit better be worth it to someone :)


Reply | Threaded
Open this post in threaded view
|

Re: Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

pharo

Comment #5 on issue 3622 by [hidden email]: [ENH]: Clean up  
Url>>urlClassForScheme:
http://code.google.com/p/pharo/issues/detail?id=3622

I agree with both. It would be more efficient. It would also be more  
complicated.

My main concern was eliminating a switch statement and applying the  
open/closed principle as we strive to make the system beautiful.

It seems to me like premature optimization to change the implementation now  
without pressure from the user side. But I'm just happy it's not ugly any  
more, so I'll go along with whatever :)


Reply | Threaded
Open this post in threaded view
|

Re: Issue 3622 in pharo: [ENH]: Clean up Url>>urlClassForScheme:

pharo

Comment #6 on issue 3622 by [hidden email]: [ENH]: Clean up  
Url>>urlClassForScheme:
http://code.google.com/p/pharo/issues/detail?id=3622


"+1"
:)
Sorry for the noise