Download presentation
Presentation is loading. Please wait.
Published byCalvin Thomas Modified over 9 years ago
1
BlueJScript @ the First BlueJ Day Houston, 2006 Matthew C. Jadud University of Kent
2
2 First BlueJ Day, Houston, Texas, 1st March 2006 Outline What is it? Demo: Purple Cow “Hello World” Wherefore BlueJScript? Demo: Trails
3
3 First BlueJ Day, Houston, Texas, 1st March 2006 What is BlueJScript? It’s just Javascript… –With privileges! What can it do? –Full access to extensions API –Full access to standard Java libraries (java.*, javax.*) BlueJ überscripting environment
4
4 First BlueJ Day, Houston, Texas, 1st March 2006 Demo: Purple Cow
5
5 First BlueJ Day, Houston, Texas, 1st March 2006 “Hello World” In the project folder: –extensions/bluejscript.jar –profile.js What do these do? –Without the BlueJScript extension, there is no BlueJScript –The profile.js is where the magic happens
6
6 First BlueJ Day, Houston, Texas, 1st March 2006 A simple profile.js A “hello, world” if you will –Shows the BlueJScript console –Prints something to it This is the BlueJ project I’ve called “SimpleProfile”
7
7 First BlueJ Day, Houston, Texas, 1st March 2006 A less simple profile.js You’ll probably find yourself listening to BlueJ events a lot This BlueJScript application: –Listens for any events from BlueJ –Prints out their name This is the BlueJ project I’ve called “WatchingEvents”
8
8 First BlueJ Day, Houston, Texas, 1st March 2006 What you get You have the full extensions API (effectively bluej.*) BlueJScript provided support classes (the jsConsole, htmlPane, event handling…) All of java.*, javax.*
9
9 First BlueJ Day, Houston, Texas, 1st March 2006 Start brainstorming… You have full access to all of the Java class libraries from a dynamic scripting language! In NetDemo, I grab data from external sources In SwingDemo, I illustrate what might be a BlueJ bug, or BlueJScript worst-practice…
10
10 First BlueJ Day, Houston, Texas, 1st March 2006 Wherefore? Low cost of entry –Neat things can be done simply as BlueJScript extensions Full access to BlueJ –We can inspect classes and objects –Create objects, invoke methods –Windows, dialogs, etc…
11
11 First BlueJ Day, Houston, Texas, 1st March 2006 Take over world, contd. Functional, dynamic language for driving BlueJ Treat BlueJ, Java libs as a “rich API” for creating interactive instructional applications Easy, lightweight deployment option for interacting with student code
12
12 First BlueJ Day, Houston, Texas, 1st March 2006 Demo: Trails Provide scaffolding for adult learners tackling Java in a condensed course of study Tackle syntax and semantics at a finer grain than Objects First Represents a starting point for a class of applications, not an endpoint
13
13 First BlueJ Day, Houston, Texas, 1st March 2006 More questions? bluej.org (Documentation) bluej-discuss (mailing list) mcj4@kent.ac.uk –Consider the list first…
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.