Ewe VM and Class Library Features

Gui Features. 1

GUI Styles. 1

Standard Controls. 1

Advanced Controls. 1

Container and Window/Frame Controls. 1

Extra Gui Services. 2

Utility Library. 2

General Programmer Utilities. 2

Data Manipulation Utilities. 2

Zip File Utilities. 2

Advanced Ewe Features. 2

Registry Access. 2

Infra-Red Communication. 2

PC-to-Mobile Communication API 3

Device Independent Database API 3

 

Gui Features

GUI Styles

Ewe supports four look and feels: Etched, 3D, Soft and Flat. Additionally, Ewe detects the type of user interface available on the running platform (e.g. Keyboard and Mouse or touch screen) and adjusts its behaviour to suit.

Standard Controls

ü      Single and Multi-lined text input and display.

ü      Buttons, Checkboxes and Radio buttons.

ü      Choice controls and Combo-boxes.

ü      Lists.

ü      Menus and Menu Bars.

ü      Progress Bars and Progress Bar windows.

Advanced Controls

ü      Tables – these are fairly advanced controls, capable of displaying row and column headers. They also give the user the ability to resize the width and height of rows and columns. Tables can be used to contain text, images or even other controls of arbitrary complexity.

ü      Trees – these are also fairly advanced. They work very similarly to Windows native Tree controls. Again they can display text and images as well as other simple or complex controls.

ü      Mosaic Panels – these allow any number of animated images to be displayed and allow the user to interact with them. This includes dragging them around, dropping them on other images, etc. This is the perfect base for the writing of simple games.

ü      FileChooser – this is an advanced file chooser dialog that works equally well on the desktop and mobile device.

Container and Window/Frame Controls

ü      A CellPanel object provides a very flexible way of laying out controls. It is so flexible that it eliminates the  need for layout managers completely. It provides all the functionality of an AWT GridBagLayout but with a much simpler API.

ü      Tabbed Panels – standard tabbed panels with automatic scroll buttons to allow for an arbitrary number of tabs.

ü      Scrollable Panels – with customizable scroll bars.

ü      Splitter Panels – these allow the user to dynamically alter the relative size of a divided panel.

ü      Dialog boxes and popup frames are supported.

ü      Multiple Windows are supported on platforms that also support it. However the library can transparently support systems that cannot provide multi-windowed support.

Extra Gui Services

ü      Context sensitive menus are supported. On mobile devices these can pop-up when the pen is held down for an adjustable length of time.

ü      Clipboard operations are supported. Text and other objects may be copied between controls and between applications.

ü      Drag and Drop operations are supported. Object may be dragged between controls and windows within the same application. The mouse pointer will change to indicate the dragging/copying state and whether a control will accept the data being dragged.

ü      Tool-Tips are fully supported, allowing you to select what tooltip to display based on the position of the mouse pointer in the control itself.

Utility Library

General Programmer Utilities

These include:

ü      Collections such as Hashtable and Vector, as well as some expandable primitive value collections such as ByteArray and IntArray.

ü      Text encoding/decoding utilities. These allow you to easily text encode objects for transmission or persistent storage.

ü      Fast string parsing utilities (the SubString class). These can be used to parse many lines of text while creating as few objects as possible to increase speed and reduce memory requirements.

ü      Fast sorting utilities to sort integer values or collections of objects.

Data Manipulation Utilities

The ewe.data package contains base classes that can be extended to create data-centric objects. Such objects can be easily encoded/decoded for data storage and transmission. There are also utilities to allow the object to create UI interfaces (Editors) that automatically transfer data between object fields and GUI controls with no programming required by the developer.

Zip File Utilities

The ewe.zip package contains all the functionality required to read and create Zip compressed streams and files. It is very similar to the standard java.util.zip library. There is even the functionality required to use a standard Ewe FileChooser control to browse the contents of a Zip file.

Advanced Ewe Features

These are some features provided by Ewe on all platforms that are not provided by any other Mobile Java platform.

Registry Access

Ewe provides an API for manipulating the System Registry on a Win32/WinCE based device. This allows for easy storage of application configuration data. On systems that do not support a native System Registry (e.g. on Linux systems, including the Zaurus) a Registry is simulated using a special data file stored on the system. The API is precisely the same, regardless of whether the Registry is real or simulated.

Infra-Red Communication

On devices that have an Infra-Red port (e.g. most WinCE devices and the Sharp Zaurus) you can program the infra-red port as if it were simply another TCP/IP port. Using a reserved host name of "infra-red" A ServerSocket can be set up to listen to incoming connections on a particular port number and a standard Socket can be used to connect to that ServerSocket on the same port number on the Infra-Red port. This system works across different platforms and a Zaurus Ewe application can communicate via Infra-Red with a PocketPC Ewe application with no problems whatsoever.

PC-to-Mobile Communication API

EweSync provides a mechanism and API that allows desktop Ewe applications to connect and communicate with mobile Ewe applications. The API works precisely the same across Microsoft's ActiveSync (for PC to WinCE based systems) and across the Zaurus/PC USB link. Some of the features provided by the API are:

 

1.      A desktop/mobile Ewe application can be set to auto-start once the EweSync connection is established between the desktop and mobile.

2.      A Ewe application can read Registry information across the EweSync connection.

3.      A Ewe application can invoke another application across the EweSync connection.

4.      A Ewe application can connect to another Ewe application across the EweSync connection using a standard Socket.

 

This allows for fully automatic and completely customisable communication and synchronization between desktop and mobile applications using a pure Java API, regardless of the mobile device being connected. In fact the Zaurus and ActiveSync EweSync connections are fully compatible, allowing an Ewe application to communicate with whichever device happens to be connected.

Device Independent Database API

Ewe provides a powerful Database API that is compatible across all mobile devices, whether or not they support a native file system. The API allows for the definition of fields within records and allows for the sorting and searching of records by any field.

 

Defining and using a new Database is also remarkably easy. Using Java Reflection, you can define a Java class and then initialise the fields in a Database to match the fields in the class with a single line of code. From that point, records may be read, edited and written using the same Java class as a data interface object between your application and the Database.

 

A Database can also be initialised to allow for synchronization of desktop and mobile copies of the database. A RemoteSynchronizer Java class can then be used to synchronize databases across the EweSync connection. This can be done in a fully automatic mode, not requiring the user to manually start any synchronizing process at either end.