Skip to Content

Undocumented Secrets of MATLAB-Java Programming

By Yair M. Altman

Chapman and Hall/CRC – 2012 – 701 pages

Purchasing Options:

  • Add to CartHardback: $73.95
    978-1-43-986903-1
    December 5th 2011

Description

For a variety of reasons, the MATLAB®-Java interface was never fully documented. This is really quite unfortunate: Java is one of the most widely used programming languages, having many times the number of programmers and programming resources as MATLAB. Also unfortunate is the popular claim that while MATLAB is a fine programming platform for prototyping, it is not suitable for real-world, modern-looking applications. Undocumented Secrets of MATLAB®-Java Programming aims to correct this misconception.

This book shows how using Java can significantly improve MATLAB program appearance and functionality, and that this can be done easily and even without any prior Java knowledge.

Readers are led step-by-step from simple to complex customizations. Code snippets, screenshots, and numerous online references are provided to enable the utilization of this book as both a sequential tutorial and as a random-access reference suited for immediate use. Java-savvy readers will find it easy to tailor code samples for their particular needs; for Java newcomers, an introduction to Java and numerous online references are provided.

This book demonstrates how

  • The MATLAB programming environment relies on Java for numerous tasks, including networking, data-processing algorithms and graphical user-interface (GUI)
  • We can use MATLAB for easy access to external Java functionality, either third-party or user-created
  • Using Java, we can extensively customize the MATLAB environment and application GUI, enabling the creation of visually appealing and usable applications

Contents

Introduction to Java in MATLAB®

Creating Java Objects

Java Object Properties

Java Object Methods and Actions

Java Events and MATLAB Callbacks

Safe Java Programming in MATLAB — A How-To Guide

Compiling and Debugging User-Created Java Classes in MATLAB

Compatibility Issues

Java Versions in MATLAB

Java.opts

References

Using Non-GUI Java Libraries in MATLAB®

Complex Data Structures

Database Connectivity

Miscellaneous Other Uses

A Short Pause for Reflection

References

Rich GUI Using Java Swing

Adding Java Swing Components to MATLAB Figures

MATLAB’s Main Thread and the Event Dispatch Thread (EDT)

Customizing Java Components

Component Callbacks

Using Third-Party Libraries in MATLAB

System-Tray Icons

Drag-and-Drop

Adding MATLAB Components to Java Swing Containers

Alternatives to Swing

References

Uitools

Uitable

Uitree

Uitab

Uiundo

Toolbars

Menus

Status Bar

References

Built-in MATLAB ® Widgets and Java Classes

Internal MATLAB Java Packages

MWSwing Package

MWT Package

MLWidgets Package

Widgets Package

MLServices Package

JIDE

Miscellaneous Other Internal Classes

References

Customizing MATLAB® Controls

PushButton

ToggleButton

RadioButton

Checkbox

Editbox

Listbox

Popup Menu (aka Drop-Down, Combo-Box)

Slider

Text Label

Frame

Uipanel

Tooltips

References

The Java Frame

Java Frame Properties and Methods

FindJObj and the Java Frame Components Hierarchy

Important Java Frame Containers

BeanAdapters

References

The MATLAB® Desktop

Desktop Functionality and Layout

System Preferences

Command Window

Editor

Keyboard Bindings

Workspace

Other Desktop Tools

References

Using MATLAB® from within Java

Approaches for Java Control of MATLAB

JMI — Java-to- MATLAB Interface

JMI Wrapper — Local MatlabControl

JMI Wrapper — Remote MatlabControl

Using JNI to Connect Java and MATLAB

References

Putting it All Together

UISplitPane

Integration Debriefing System

Concluding Exercise: UIMultiListbox

References

Appendix A: What is Java?

Appendix B: UDD

Appendix C: Open Questions

Index

Author Bio

Yair Altman, author of the extremely popular UndocumentedMatlab.com website, is well respected in the MATLAB community as the de-facto guru on undocumented MATLAB features and the MATLAB-Java interface in particular. Yair holds a BSc in Physics and an MSc in Computer Science, has over 20 years of programming experience at various levels of responsibility, and currently consults for several software development projects.

Name: Undocumented Secrets of MATLAB-Java Programming (Hardback)Chapman and Hall/CRC 
Description: By Yair M. Altman. For a variety of reasons, the MATLAB®-Java interface was never fully documented. This is really quite unfortunate: Java is one of the most widely used programming languages, having many times the number of programmers and programming resources as...
Categories: Computational Numerical Analysis, Computer Engineering, Algorithms & Complexity