JudoScript.COM Design principles of Judo the sport and the language
HomeJudo LanguageJuSP PlatformJamaica Language 
Judo ReferenceJuSP ReferenceWiki/WeblogTutorials/PresentationsDownloadsGoodiesFeedback  
Book: The Judo Language 0.9
 








In this chapter:

Chapter 1. Introduction to Judo

By James Jianbo Huang

printer-friendly version
Synopsis: This chapter discusses the Judo language at a high level, including philosophy, language design and standards, and uses of Judo. The Judo language is a versatile and practical language; functionally it is partitioned into major groups like core programming, Java scripting and specific functional areas; structurally it is composed of built-in data structures and objects, system functions and syntax rules that are either general-purpose and special purpose. Judo is a language intended for any IT workers, not necessarily Java developers, and both Java software and Judo software install and usages are introduced, especially for those who do not yet have Java experience. Finally, the book organization and other house-keeping topics are covered.

This chapter introduces the background, high-level description of Judo, general discussions on scripting languages and Java scripting languages and comparisons between Judo and other languages. It tries to answer the questions of why, how and who to use Judo. Finally, it explains the organization of the whole book. Many discussions are general in nature, and those regarding Judo are conclusions that you may revisit after you have learned to use and program in Judo.

 
Background

Judo is a functional scripting language. It is a product of our time.

Modern computers employ the same von Neumann architecture just like fifty years ago, but what we do with computers is drastically different. Today, we run most enterprises on computer systems, and we use computers in homes, offices, schools, libraries and virtually everywhere. In recent years, thanks to the great advances of hardware and the internet boom, the world of computing is experiencing explosive growth, so much so that it is drastically different from as late as 1987, when the Perl language was born.

In the entire 1980's, many important computing technologies were in the development, such as database, graphical user interface, networking, etc. Running Unix and MS-DOS, computers were process-centric, and the information was mostly stored either as flat text files or in proprietary binary formats. It was in such an environment that Perl was incepted to be a language that made easy things easy, and hard things possible; the thing that Perl made the easiest was text processing, as Perl introduced regular expression into the core of the language. It is fair to say that, Perl is a general-purpose programming language plus the special support for one domain — single-byte text processing. As Perl grew in popularity, it has evolved into a general-purpose programming language that builds software systems, beyond its original intent of doing things easily and quickly. Inspired by Perl, many similar languages were invented; some of them support object-oriented programming (OOP); all of them embody so-called syntactic sugar, trying to make coding easier here and there. A new class of languages called scripting languages have emerged. These languages all serve the same purpose that Perl was designed for, in 1987. The result is, today we have a multitude of general-purpose programming languages to choose from, ranging from C, C++ and Java to Perl and Visual Basic, and there are few fundamental differences between them.

But time is changing. The prolifiration of graphical user interface (GUI) and the commoditization of computer hardware have profoundly changed the way we conduct business, live and interact with each other. Software engineering has also undergone an explosion of development. The biggest changes in software engineering are object-orientation and wide-spread distributed computing, best exemplified by today's indispensable and ubiquitous internet and intranet. Many technologies considered exotic or simply did not exist in 1987 are now standard featuers that every computer user deals with, for instance, HTTP, HTML, XML, e-mail, internationalization and Unicode, and SQL and relational databases. They are all used in general software engineering, but each has its own theory and domain knowledge. When you have to do some work quickly that deals with many of these technologies, programming in languages like Perl is clearly not the most productive way. If you still must code a lot to solve a problem, using a scripting language kind of loses its purpose.

First published in November 2001, Judo is a new kid on the block. It is not an alternative way to repeat the same problem, but rather, to provide computer professionals and power users with an easier, more intuitive and productive way to communicate with computers. Judo has defined a new class of scripting languages — functional scripting languages.

In the following sections, we will explore the meaning of functional scripting languages, and also examine the advantages of scripting languages and Java scripting languages in general, because Judo is a genuine Java scripting language as well. Finally, we will take a look at programming language design, and see the pros and cons of the design of some languages.

Judo, a Functional Java Scripting Language

A language of a trio
Judo is a general-purpose programming (scripting) language with intimate support for many today's popular computing subjects. That is, it has multiple domain support built in the language, big and small. Domain support in Judo is not only built-in functions and objects, but special-purpose syntax as well. The supported domains include:

  • Java scripting
  • SQL scripting
  • XML scripting
  • SGML/HTML scrapging
  • Send mail
  • Unified file system and archive operations
  • Execute native executables
  • Internet scripting
  • Ant task scripting
  • Scheduling
  • Building Java GUI
  • Microsoft ActiveX scripting on Windows platforms

Judo is itself a powerful scripting language, too. It didn't re-invent the wheel, and simply uses a syntax and programming model similar to JavaScript. It has stronger data structures, better support for thread programming and object-oriented programming, and more syntactic sugar. Judo is thus far a Java-based scripting language; it is not affiliated or related in any ways to the Java-version JavaScript, Rhino. There is an effort underway to make Judo mostly compatible with JavaScript 2.0; JavaScript 2.0 is still a work in progress but is much more robust than JavaScript 1.x.

Judo is also a potent Java scripting language. It can script Java objects and classes to the best capability possible allowed by the Java virtual machine (JVM). To be more specific, you can instantiate and use Java objects, arrays and class objects; you can also extend Java classes and/or implement Java interfaces with the parameters allowed by the JVM. The merits of Java scripting languages are discussed in the next section, but the first and foremost one is that, any Java software and resources are readily available to Java scripting languages.

Hence, Judo is a language of a trio:

  1. a powerful scripting language engine,
  2. free access to the underlying Java platform and resources, and
  3. domain support for modern computing techniques.

The synergy of the trio renders great power, productivity and elegance to programmers.

A powerful programming language
The ultimate power of programming langauges stems from programmability. Judo may be a more powerful programming language because it has more built-in data structures, and they are typically richer in functionality than many their counterparts in other languages. Judo data structures are not just predefined types, they can also have dedicated, intuitive facilities and syntactic support, therefore it can be very easy and expressive. For instance, the two-dimensional TableData data structures has an accompanying printTable statement; the Array object has a method toCsv() than can not only concatenate its elements but also take a decorate function object to do things like quoting the values.

Another source of power is clearly from scripting Java. This is no different from any Java scripting languages and is discussed in detail later.

Greater productivity and easier on mind
Every scripting language is created for productivity by using a syntax and a programming model that make coding easier and more obvious. This is discussed more in the following section. For Judo, the domain support makes it easier on your mind while coding for solutions, because domain-support allows you to specify what you want to do, rather than coding solutions with data structures and algorithms that takes a bigger toll on the mind. The results are a) the code is coherent and directly to-the-point, and b) the code is in context and focused. The following is a code snippet in Judo and a code snippet in Perl.

Listing 1.1 Judo code snippet for database query
prepare qry:
  SELECT * FROM emp
  WHERE last_name = ? AND
        salary < ?
;
executeQuery qry with @1 = 'Lin', @2:number = 50000.0;

Listing 1.2 Perl code snippet for database query
$sth = $dbh->prepare( "
  SELECT * FROM emp
  WHERE last_name = ? AND
        salary < ?
" );
$sth->bind_param( 1, "Lin", SQL_VARCHAR );
$sth->bind_param( 2, 5000.0 );
$sth->execute(  );

The meaning (the thinking process) for the Judo code is: prepare a query; run it with the parameters. The meaing (the thinking process) for the Perl code is: prepare a query; bind one parameter; bind another parameter; execute the query. The Judo thinking is more collected and coherent than Perl's, which is typical for any programming langauges. Domain support also helps to group code in context so your mind is much more focused, as demonstrated by the next example, XML SAX programming.

Listing 1.3 Judo XML scripting example
do 'data.xml' as xml {
  <order>:       println '==============';
  TEXT<number>:  println 'Order #:   ', $_;
  TEXT<invoice>: println 'Invoice #: ', $_;
}

If you have marginal knowledge of the domain of XML, you would be able to guess what this code snippet does. It's quite clear that, for the <order> tag, it prints out a divider; for text enclosed by <number> and <invoice>, print them out as order number and invoice number. Now, let's take a look at a Java counterpart.

Listing 1.4 Java XML SAX programming example
public class OrderFinder extends HandlerBase {
  public OrderFinder() { super(); }

  public void characters(char[] buf, int start, int len) {
    //... process text surrounded by certain tags.
  }

  public void startElement(String elem, AttributeList as) {
    if (elem.equals("order")) {
      System.out.println("==============");
    } else if (elem.equals("number")) {
      //... process
    } else if (elem.equals("invoice")) {
      //... process
    }
  }

  public void endElement(String elem) {
    if (elem.equals("number")) {
      //... process
    } else if (elem.equals("invoice")) {
      //... process
    }
  }
}

Compared to the Judo version, what a sight this is! The program is not even complete. What we see is a class with a number of disparate methods. If you look closely at the method names and the parameter lists, you may be able to guess what they do. The thing is, this program has many assumptions (the SAX framework) and dependencies (the classes in the SAX packages). These assumptions and dependencies are implementational details that are not directly related to the problem we are trying to solve. In other words, when one is trying to print out the order and invoice numbers for an XML document, why must he know the details of a particular framework? In contrast, the declarative nature of the Judo domain support is a higher-level abstraction and is directly pertinent to the problems in the domain. Solving problems in Judo is a natural and intuitive process with much less distraction of unwanted programming details; as you have seen, it is much easier and less stressful on your mind. Before we go, let's look at yet another example of functional scripting in Judo, and try to envision the difference of coding in Perl or Java to do the same.

Listing 1.5 Send mail example
sendMail
    from: 'james.huang@judoscript.com'
      to: cust_email
  attach: '${DOCROOT}/store/judo.jar.zip'
 subject: 'Here is a latest update.'
htmlBody: [[*
  <p>Dear (* cust_name *):</p>
  <p>Attached is the latest software with the bug fixed.
  Thanks for reporting this issue!</p>
  <p>Sincerely,<br>- James</p>
*]]
;

A functional scripting language
Functional languages tell computers to do it, where programming languages tell computers how to do it. Functional support, or domain support, was historically materialized in languages called fourth-generation-languages (4GLs). (3GLs are high-level programming languages, including Fortran, C, C++, Java, C#, VB, Perl, Python, ...; 2GLs are assembly languages and 1GLs are machine languages. The higher the G, the more abstract the L.) Traditionally, 4GLs are domain-specific, that is, languages have syntax and constructs to support knowledge of a specific domain. 4GLs (functional languages) are closely related to or directly in the problem space, whereas 3GLs (programming langauges) are directly for building software, and the software in turn tries to address the problem space. The difference is not just different ways of coding, it is different ways of thinking. Languages are carriers of thoughts, which profoundly affect the way of thinking; this phenomenon applies to both natural and computer languages.

Judo's domain support even extends into the general programming areas. For instance, the TableData data structure and its related syntactic support are indeed the support for the domain of two-dimensional data entities. Same applies to many other data structures in explicit or subtle ways. This is why Judo enjoys great programmability.

Judo is the first general- and multi-purpose 4GL, built atop a powerful 3GL engine and the Java runtime. It is in the class of functional scripting languages. It allows users to interact with computers both declaratively and programmatically, so that the problem solving process becomes easy, effective and intuitive. The resultant programs and the thinking process are direct, coherent, in context and focused. Judo code is typically shorter and more obvious than in other languages, which means great maintainability and flexibility.


The Java Platform and Scripting Languages

Java is a dream platform for scripting languages. On the Java platform, everything is a native object complete with RTTI (Run-Time Type Inforamtion), and are readily and naturally accessible and operational in the native language, Java. The Java Virtual Machine (JVM) is a simple CPU simulated by a software running on top of many operatin systems. Dedicated teams continually work on the JVM performance improvement. Java scripting languages can easily access most of the underlying Java platform and resources. Many Java scripting languages compile the source code directly into the JVM bytecode, resulting in great performance.

One of the greatest merits of Java scripting languages is, there is no need to build special libraries just for that language; you can simply create Java libraries (packages) to be used by both Java and Java scripting languages. In contrast, Perl, Python and many other languages have their own ever-growing libraries, and these libraries for different languages largely overlap in functionality. This is collectively a huge waste in the programming community. Java, being a popular system language and a meta-platform running on various "real" platforms, is a good place to converge all the common computing features. Part of the reason for this is Java's superb scriptability and availability of Java scripting languages.


Vive les Scripting Languages!

Scripting languages greatly improves productivity over system languages. System languages, such as C, C++ and Java, are designed for creating large-scale software systems and computing infrastructures. Typically, they are strongly and statically typed, enforce rigid program structures, and their source programs are compiled before run. Software or libraries created by system languages are well-defined, unambigous, and performant. The downside is that, these languages are generic, verbose and detail-oriented, hence requires a lot of code and attention to achieve goals. Human mind has limited long-term and short-term capacities; when the size of software grows, the chances of mistakes grow accordingly.

Scripting languages are usually untyped or dynamically typed; you can write simple statements directly without rigid structure; and there is syntactic sugar that can express some operation with a single instruction instead of a number of instructions otherwise. Scripting languages not only allow users to write less code to achieve goals, they also enforce a different thinking process than system languages.

Program in context
Data in computer programs general have types. Scripting languages such as Judo use a dynamic type system, that is, variables are simply containers of any values; at any one moment, the value held in a variable (or a data structure) is of a particular type. With object-based systems, that means each value has a set of predefined methods and/or properties. How does the programmer know the type of a variable in a program? by context. When you call x.formatDate('yyyy-MM-dd'), for instance, the programmer knows that x must contain a Date value. Scripting language programmers, therefore, have a stronger sense of context. This dynamicness naturally implies uncertainty of the value types; such seemingly adversary prompts developers to do more testing. It is testing that guarantees software quality, not the language's type system. So, ironically, a weaker type system may actually help software quality, which defies common sense.

Signal/noise ratio
Scripting languages' syntactic sugar allows programmers to concisely express sophisticated ideas. This results in less and more obvious code. For a code maintainer, this means higher "signal/noise ratio". Signal/noise ratio is a concept in communication theory that reflects the confidence level of receiving useful information out of contaminated signals. Think of a TV screen from an antenna receiver with poor signal versus a TV screen of cable TV connection. I once converted a utility program written in Java into Judo. The Java program had 344 lines and 12790 bytes; the corresponding Judo program had 192 lines and 6523 bytes. If we reduce the documentation, the Judo program is about half the line numbers and bytes in size than Java's. In this particular case, suppose Judo spends 5% of code for non-business logic, the signal/noise ratio is about 20; suppose Java spends 50% of code for non-business logic, the signal/noice ratio is 1. For programs of different lengths, such ratios may vary; but scripting languages are consistently more focused than system languages. It is this natural tendency of focusing on problems that helps scripting language programmers to concentrate on problems rather than get distracted by programming details. Scripting language programmers are less stressed, more focused, effective and efficient in problem solving. All these help raise the software quality.

Judo is even more focused
Judo's 4GL-like functional features are highly abstract for many of today's populalr computing needs. They are functional sugar, beyond syntactic sugar in normal scripting languages. Hence, Judo programs are typically more to-the-point, coherent and with less noise. Refer back to listings 1.1 and 1.2 for a comparison; with Java, there will certainly be a lot noisier than either Judo or Perl versions.


Programming Language Design

Programming languages are invented based on specific computing models and ideas. For general algorithmic programming languages, there are many characteristics and design criteria. The most important aspects are expressiveness and simplicity, and the balance between the two.

Simplicity of programming languages is reflected by their orthogonality. An orthogonal language would have the minumum number of constructs to cover all the programming needs. System languages like C, C++ and Java areall highly orthogonal. The benefit is, programmers need to memorize fewest possible rules to code solutions. The downside is, expressiveness is poor.

Expressiveness is critical for code efficiency, effectiveness and aesthetics. For instance, you can practise OOP in any general-purpose programming languages, but languages with native OOP support are certainly better choices just for OOP's sake. Enhancing expressiveness by blending different languages has been experimented by, say, Pro*C and SQL/J; the result is questionable because the code looks confusing. Pursuit of language expressiveness is more art than science. It ultimately comes down to the number of use cases a language intends to cover and the conosistency (or style) of that language.

Scripting languages simplify programming (as compared to system languages) by relaxing the type system, and improve expressiveness by introducing syntactic sugar, at the expenses of violating orthogonality. The number of new rules is limited, and they expressively cover many useful programming use cases. That's why scripting languages are enjoying great popularity. Of course, languages should still refrain themselves from adding too many rules for every trivial use case. Perl, for instance, has been criticized for having too many rules, some of which are quite accentric.

Judo is designed to cover use cases like scripting for SQL, XML, SGML, operating system and internet, as well as any general programming topics such as algorithms, OOP, threads, exceptions, dynamic execution, Java scripting, regular expression, etc. Judo tries to flatten the learning curve for new users by adopting the (hopefully) familiar programming model and syntax of JavaScript. Since JavaScript 1.x is a rather primitive language, Judo has quite a few enhancements to cover the programming use cases, some of which are in-line with the work-in-progress JavaScript 2 specification.

The biggest differentiator of Judo to other languages is its collection of 4GL-like functional domain support; this is the very reason why Judo was incepted! Domain support violates orthogonality of a programming langauge, and requires users to remember special syntactic rules for particular domains. But the cost is really quite small, as domain-specific syntax are so pertinent and intuitive; if you look back at the examples of SQL query (listing 1.1), the XML scripting (listing 1.3) and send mail (listing 1.5), you would know how much (or little) effort is needed to remember those syntactic rules. The benefit of expressiveness far outweighs this small cost.


Judo 0.9, 1.0 and ECMAScript

Judo's basic programming model is similar to that of JavaScript. This include data type system, flow control, function definition and such. JavaScript is best known for its role in web browsers. It is also a general-purpose languages, used in software such as Macromedia's Flash and even server side development. The JavaScript version 1.5 is standardized by ECMA (European Computer Manufacturers Association) as ECMA-262 Edition 3. JavaScript started as a simple scripting language, and up to version 1.5, it has added features to simulate object-oriented programming. As a part of the language, it has a number of built-in simple object types.

The originator of JavaScript was Netscape (acquired by AOL in 1999), who had an experimental proposal of JavaScript 2.0, which was also proposed to ECMA as ECMAScript 4. This proposal is clearly a much more robust language than its predecessor. The major differences are: a) a stronger type system, b) genuine class support, and c) package and namespace. The current version of Judo, 0.9, has genuine class support; the core language of Judo version 1.0 will be compatible with most of the current ECMAScript 4 proposal.



 
Components of Judo Language   to be done

Core Programming Language


Java Scripting


Built-In Data Structures


System Functions


Functional Support



 
Uses of Judo

Judo is a general-purpose scripting language, it can be used anywhere that another general-purpose scripting language is appropriate. It has also features that make it particularly fit for certain types of work, big and small. It is designed for enterprise applications, which is also great for software development and daily uses.

Enterprise Uses

Multi-source, multi-format data processing and reporting
Judo is a superb data processing and reporting tool! Today, enterprise software deal with not only relational databases but also richer data formats such as XML and SGML, abstract data types like Enterprise Java Beans (EJBs), web services, ..., as well as old friends like flat files and spreadsheets. Spreadsheets are so popular in business, they are touted as "the language of business." Traditionally, (and naturally,) people use various tools for data querying, reporting and processing. Judo can handle all these with great easy, and is a unified data processing tool. The benefits of using such a single, unitified tool are obvious: a) you can do any processing with any data sources of any formats at the same time, b) faster to reach correct and right solutions and results, c) less tools to learn, install, configure and launch, d) cheaper, and e) the problem solving process is mentally less taxing because you can focus on the problem at hand without constant worries over environmental issues, context switching from tool to tool, and integration of heteorogeneous pieces of software.

Content management
Comment management is a special type of data processing which is common with publication services. It can be a book or magazine publisher, or an information providing web site. Frequently contents are encoded in SGML or XML, but they may also be stored in flat files or relational databases. There can be dynamic content as well, for instance, weather, stock, traffic or advertisement. Judo has native support for many data formats, in addition to rich data structures and OOP support. It is great for content publishing. This book, for instance, is encoded in SGML and processed by a custom content management system written entirely in Judo; content is encoded in such a way that it is completely independent from its presentation, and various scripts process the content into HTML and publishing ready format.

J2EE and network client programs and batch jobs
Judo, being a potent Java scripting language, can be used to create client programs to access and manipulate J2EE applications and systems through JNI, JMS, JMX and other J2EE protocols. It has great support for HTTP and other networking protocols. Combined with other features, network clients and batch jobs written in Judo can be terse and highly functional.


Software Development Uses

Judo resembles operating system shells in many ways, largely due to its robust support for executing native programs and versatile file system and archive operations. It can be used in many automation processes during software development.

Software prototype
Judo can be used to quickly build software prototypes and proof-of-concept experimental systems, whether it is a data-centric application, a Java GUI based system or a web application. During prototyping, you can easily simulate various data sources without the constraints of a full-blown test environment.

Automated black-box and white-box testing
Judo is great for distributed system testing, especially J2EE systems. For instance, you can script to use HTTP access, direct EJB invocation and/or database access to run use cases and check results. You can even instantiate a Judo engine in the Java software as a remote agent and invoke or inspect Java objects directly. Judo is also a white-box testing tool for Java.

Data investigation tool
Judo's SQL scripting and rich data structures provide quick ways to investigate data problems and scenarios and find the right solutions.

Building software
Judo itself is built with Judo. This is quite a complicated process, because the majority of the Judo software must be compiled with JDK1.3 but a small part is in JDK1.4; and there are optional packages needed at different times. A menu-driven build script was written in Judo and handles the job clearly and effectively. The build targets also includes clobber, archive, and automated testing. Judo is a flatter solution than XML-based build tools, because you have full control over the build steps and no worries about the format and meanings of all kinds of tag attributes for various tasks.

Judo as an embedded scripting solution
Judo language engine can be embedded in Java software and the software can in turn expose Judo to its power users as a means to customize or script actions.


Daily Uses

Judo has many nifty features for everyday uses. One of the most useful task is to copy selected files into a ZIP, JAR or TAR archive for back-ups. You can FTP or SCP files between remote and local machines. You can do quick numeric or date/time calculations, formating and conversions. You can process text and binary files easily, for instance, to print out SGML entity encodings. You can quickly inspect Java static fields. You can easily download a HTTP resource, and can scape it for specific pieces of information. The list goes on and on; all these will make it easier for your life as a computer professional.



 
Who Can Use Judo

Judo is designed for everybody's use. It provides three levels of convenience for users to interact with computers: a) its extended shell-like commands that covers not only operating system operations but also rich data processing and file handling; b) its easy and powerful programming language that allows you to code any solutions, and c) access to any Java classes and resources. IT and software professionals can take the best advantage of Judo. Software developers, especially Java developers, use many automation tools during development; with Judo, you can probably reduce the number of tools needed.

Judo is a unified tool for using most of your computer's resources. Java objects and ActiveX components on Windows, once obtained, are no different from a Judo object or value; so even if you are not a Java programmer or ActiveX expert, you can still take advantage of them once you know the attributes of that object. This is the beauty of object-orientation; this idea is used everywhere nowadays, and in languages like Judo, objects simply appear and behave the same as well.

IT and Software Professionals
There is a surprising number of computer power users who have never used Java. There are veteran system administrators dexterous with both Unix and Windows, who can pick and choose modules to custom build Linux kernel, and are capable of Unix shell scripting and Perl coding; yet they have never used any Java software. There are C++ programmers and device driver writers who never have the chance or urge to learn Java. This is a pitty, because Java is a free and tremendously useful resource; some people and companies have been spending a lot of time and money to really improve the JVMs on various platforms, and it is an umbrella for all sorts of computing resources. The Java language is easy to program in, and is much easier to deploy than C/C++-based software. Judo's richness and usefulness exemplify Java's resourcefulness, and give everyone a good reason to start using Java software. Using Java software does not necessarily mean programming in Java, although a small cup of Java coding doesn't hurt. In the following section, we will introduce using Java software and how to run Judo. For Java gurus, you can simply skip the part that introduces Java.

Business Computer Power Users
Some business professionals are also computer power users. Many can do sophisticated Microsoft Office using and even VBA programming; some are capable of querying relational databases using SQL. Although not working as computer professionals, these people have a logical mind and hands-on spirit. Judo is great for them to research and present business data.

Java Developers
Needless to say, Java developers will be able to take advantage of Java scripting and do more when they need to. They can combine Judo's functional features with Java software and/or J2EE services to achieve great results in compressed time frames for many tasks for development, deployment and production systems. Judo supports BSF (Bean Scripting Framework), so you can embed it in any BSF-capable software (such as Jakarta Ant). Judo also provides a Java API to its language engine, so that it can be embedded in Java software as a customer-facing scripting solution.


 
How to Run Java Software and Judo   to be done

Install Java and Run Java Software


Install and Run Judo



 
How This Book is Organized

This book is a comprehensive documentation, tutorial and reference guide of Judo. It is organized based on usages. The whole book is planned for Judo 1.0; for now, as Judo 0.9 is the latest version, only relevant chapters are included, but unsupported chapters are reserved in the book. That's why chapter numbers are not consecutive.

The book is grouped in several parts. Parts II and III cover what's mostly in conventional Java scripting languages. Parts III, IV and V are all functional support of Judo. The following is a complete listing of all parts and chapters. Part VI contains the complete cross-reference for the Judo language.

Part I is introductory. Chapter 1 is a high-level overview. Chapter 2 presents all the use cases Judo is designed for, usually supported by code examples. This is almost a how-to guide.

Part II covers all the important programming and Java scripting topics. Chapter 3 covers the basic program structures, including lexical entities, variables and constants, !include, dynamic evaluation and the run-time environment. Chapter 4 discusses all the aspects of running the Judo language engine. Chapter 5 introduces the data types in Judo, and details on simple data types, their values and expressions. The string data type has very rich functionlity and serves many purposes; this chapters details on text embedded expressions and variables, representation of files and URLs, and regular expressions. Chapter 6 covers basic program flow control, including function and exception handling. Chapter 7 details on all the built-in, general-purpose data structures. Chapter 8 introduces thread programming and its issues. Chapter 10 is for creating and using user-defined classes. Chapter 11 covers all aspects of Java scripting.

Part III explains the system-level services. Most such services are typically supported in conventional scripting languages, and Judo has many enhanced features. Chapter 14 explains input-output, including the in-script text feature. Chapter 15 introduces all the commands for manipulating files, directories and archives. Chapter 16 details the flexibility of running native executables. Chapter 17 covers internet scripting, such as HTTP scripting, sendMail, SSH, SCP and FTP. Chapter 18 introduces the schedule facility. Chapter 19 is dedicated to building Java GUI applications using AWT or Swing. Chapter 20 explains how to embed Judo code in Ant build scripts and how to take advantage of the growing resources of the Ant tasks in Judo. Chapter 21 introduces no specific language features but discusses the internationalization with Judo and Java programming.

Part IV is about advanced data processing services; data processing is the emphasis of the Judo language. Chapter 22 introduces all the ways you can run SQL through JDBC scripting. Chapter 23 continues JDBC scripting discussion and tries to cover a number of popular RDBMSs. Chapter 24 natively supports Hibernate ORM and HQL similar to SQL scripting. Chapter 25 introduces SGML/HTML and JSP scraping and its usages in documentation, content management and building template systems. Chapter 26 introduces XML scripting in Judo, including its own SAX-style statement, DOM programming and XSLT. Chapter 27 introduces yet another way to script XML — native XML scripting, also known as Chapter 28 introduces scripting SOAP web services in Judo. Chapter 29 discussses using Judo with Windows registry and other services. Chapter 30 details on Microsoft ActiveX scripting, and includes using ADO to access databases. Chapter 31 discusses using Microsoft Office products through ActiveX scripting.

Part V discusses topics of the Judo language software. Chapter 32 introduces the JuSP technology, a server-side web development solution built on top of the Judo language. Chapter 33 explains how to embed the Judo language engine in Java software via BSF and its own language engine Java API. Chapter 34 explores ways to extend Judo. Chapter 35 covers some of the tools.

Part VI contains cross-reference for the Judo language. Judo is a functionally rich language. The language constituents are a) grammar, b) system functions and c) built-in object types. Each functional support has its own collection of syntax rules, system functions and/or built-in object types. Appendix I lists all the functional areas and assigns a unique name for each, used in the following appendices. Appendix II lists Judo grammar in BNF. Appendix III lists all the built-in system functions. Appendix IV lists all the built-in object types.

Again, certain chapters are not relevant to Judo version 0.9 and are therefore not present in this edition.


 
Conventions and Terminologies Used in This Book   to be done


 
back to top
 



Copyright © 2001-2005 JudoScript.COM. All Rights Reserved.