1 / 6

”Java and JMLfor Dummies”

”Java and JMLfor Dummies”. The Java source code is written in a text file using your favourite editor (Notepad) and is saved with extension .java. Be careful not to save with extension .java.txt, but as .java. I use the JML directory (next slide).

Download Presentation

”Java and JMLfor Dummies”

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. ”Java and JMLfor Dummies” • The Java source code is written in a text file using your favourite editor (Notepad) and is saved with extension .java.Be careful not to save with extension .java.txt, but as .java.I use the JML directory (next slide). • The JML-specification is written as special comments in the source code using ‘/*@...@*/

  2. ”Java and JML for Dummies” • I save source in a directory in the JML-directory. • Be careful not to save with extension .java.txt, but as .java. • My bat-file starts this GUI. • In order to compile my JML-specs, I choose JML Runtime Assertion Checker Compiler • And the RacGUI on next slide opens.

  3. ”Java and JML for Dummies” • Choose Open File • A file browser opens, the wanted source- (.java) files in your project are selected and added. • In order to compile (to generate a .class file) and to get my JML-specs checked, I click the ”run”-button. • Note the settings: • Output on the next slide.

  4. ”Java and JML for Dummies” • During compilation a long series of messages are issued. If everything goes well , it ends with ”Done”. • Are there errors in the spec, error messages are issued.

  5. ”Java and JML for Dummies” • Errors in the Java code also result in error messages.

  6. ”Java and JML for Dummies” • Everything went well. • An executable (.class) file has been generated. • It is executed using the command ”jmlrac <class-fil>”from a prompt. The command must be issued from the directory were source and class files are placed. Note: the extension (.class) is omitted. • From here the process is described on the slides ‘JML-1.ppt’.

More Related