|
Author |
Topic: making P5 even more "pedagogical"... (Read 959 times) |
|
arielm
|
making P5 even more "pedagogical"...
« on: Oct 8th, 2003, 5:33pm » |
|
... by making BApplet "pluggable" *) Technically speaking: Enabling advanced developpers to fully extend Bagel (e.g. the way amit did with BSpace), in a friendly way (both for the developpers and the users). I mean something like: - renaming BApplet to, say, "OriginalBApplet". - adding a new (and empty) BApplet that would extend OriginalBApplet. So at this stage, processing sketches are still extending BApplet, but it's now possible for developpers to hack it safely: adding new methods, new core objects, having things happening within loop(), etc. without touching the original. Then, there should be a way to easilly include into the processing environment those custom BApplets (something like a "plugins" folder...), instead of having to hack one of the processing core .jar files. To push the concept even more, there could be several versions of extended BApplets at a time: then you could choose to start the processing environment using the one you like! *) How it relates to pedagogy and teaching programming see this new thread: http://proce55ing.net/discourse/yabb/board_CourseBlueprints_act_ion_display_num_1065627431.html
|
« Last Edit: Oct 8th, 2003, 5:38pm by arielm » |
|
Ariel Malka | www.chronotext.org
|
|
|
fry
|
Re: making P5 even more "pedagogical"...
« Reply #1 on: Nov 4th, 2003, 12:11am » |
|
it's a level of indirection that i'd rather not have as a "standard" part of the core. i'm trying to keep bagel small (and not succeeeding currently, but it's going to get smaller.. i.e. video, net, and sound are probably going to be moved out of the core soon) but this would serve to make things larger, for a small proportion of people. an additional level of indirection would also make things slower, though it's difficult to say if it would be enough to show itself. however! despair not.. this could actually be done without any changes to the core BApplet. you can go in the opposite direction, by making a class called "ExtendableBApplet" or whatever, which would take care of all the mechanics and indirection for you. then include "ExtendableBApplet" in a jar file wherever you want to do this sort of thing, and just subclass from there.
|
|
|
|
arielm
|
Re: making P5 even more "pedagogical"...
« Reply #2 on: Nov 4th, 2003, 1:00am » |
|
yeah, i guess making Bagel less than 100K is a respectable goal... concerning the workaround you proposed, do you mean that if make my own ExtendableBApplet and import it into the "Code" folder, and then create a sketch in java-mode, e.g.: Code:public class MySketch extends ExtendableBApplet { } |
| it will work within the processing environment? (or is it more like a bagel.jar + eclipse solution?)
|
Ariel Malka | www.chronotext.org
|
|
|
Martin
|
Re: making P5 even more "pedagogical"...
« Reply #3 on: Nov 6th, 2003, 3:53am » |
|
It will work. what I did: + create ExtendableBApplet that extends BApplet + compile the java file inside the export folder + create a new sketch that uses java mode and extends ExtendableBApplet + move (not copy) ExtendableBApplet.class to sketch's code folder + run it should work without even testing because this just demonstrates cheating multiple inheritance in java. ExtendableTest --> ExtendableBApplet --> BApplet
|
« Last Edit: Nov 6th, 2003, 3:55am by Martin » |
|
|
|
|
|