Olay Örnekleri. Button Event public class Frame1 extends javax.swing.jframe { public Frame1() { initcomponents(); }

Size: px
Start display at page:

Download "Olay Örnekleri. Button Event public class Frame1 extends javax.swing.jframe { public Frame1() { initcomponents(); }"

Transcription

1 Olay Örnekleri Button Event public class Frame1 extends javax.swing.jframe { public Frame1() { // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jtextfield1 = new javax.swing.jtextfield( jbutton1 = new javax.swing.jbutton( setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close jtextfield1.settext("jtextfield1" jbutton1.settext("jbutton1" jbutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton1actionperformed(evt javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane() getcontentpane().setlayout(layout layout.sethorizontalgroup(.addgroup(layout.createsequentialgroup().addgap(44, 44, 44).addGroup(.addComponent(jTextField1, javax.swing.grouplayout.preferred_size, 110, javax.swing.grouplayout.preferred_size).addcomponent(jbutton1)).addcontainergap(246, Short.MAX_VALUE)) layout.setverticalgroup(.addgroup(layout.createsequentialgroup().addgap(45, 45, 45) 1

2 .addcomponent(jtextfield1, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addgap(27, 27, 27).addComponent(jButton1).addContainerGap(185, Short.MAX_VALUE)) pack( // </editor-fold> private void jbutton1actionperformed(java.awt.event.actionevent evt) { jtextfield1.settext("merhaba Java" public static void main(string args[]) { java.awt.eventqueue.invokelater(new Runnable() { public void run() { new Frame1().setVisible(true // Variables declaration - do not modify private javax.swing.jbutton jbutton1; private javax.swing.jtextfield jtextfield1; // End of variables declaration package jfilechooserdemo.resources; FileChooserDemo import java.io.file; import java.io.filereader; import java.io.ioexception; import javax.swing.jfilechooser; class MyCustomFilter extends javax.swing.filechooser.filefilter public boolean accept(file file) { // Allow only directories, or files with ".txt" extension return file.isdirectory() file.getabsolutepath().endswith(".txt" 2

3 @Override public String getdescription() { // This description will be displayed in the dialog, // hard-coded = ugly, should be done via I18N return "Text documents (*.txt)"; /** * *@author as public class JFileChooserDemo extends javax.swing.jframe { /** Creates new form JFileChooserDemo public JFileChooserDemo() { initcomponents( /** This method is called from within the constructor to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is * always regenerated by the Form // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jscrollpane1 = new javax.swing.jscrollpane( textarea = new javax.swing.jtextarea( filechooser = new javax.swing.jfilechooser( jmenubar1 = new javax.swing.jmenubar( jmenu1 = new javax.swing.jmenu( Open = new javax.swing.jmenuitem( Exit = new javax.swing.jmenuitem( setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close settitle("demo application" textarea.setcolumns(20 textarea.setrows(5 jscrollpane1.setviewportview(textarea filechooser.setdialogtitle("this is my open dialog" filechooser.setfilefilter(new MyCustomFilter() jmenu1.settext("file" Open.setText("Open" Open.addActionListener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { 3

4 OpenActionPerformed(evt jmenu1.add(open Exit.setText("Exit" Exit.addActionListener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { ExitActionPerformed(evt jmenu1.add(exit jmenubar1.add(jmenu1 setjmenubar(jmenubar1 javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane() getcontentpane().setlayout(layout layout.sethorizontalgroup(.addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jscrollpane1, javax.swing.grouplayout.default_size, 582, Short.MAX_VALUE).addContainerGap()).addGroup(.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addcontainergap().addcomponent(filechooser, javax.swing.grouplayout.default_size, 582, Short.MAX_VALUE).addContainerGap())) layout.setverticalgroup(.addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jscrollpane1, javax.swing.grouplayout.default_size, 382, Short.MAX_VALUE).addContainerGap()).addGroup(.addGroup(layout.createSequentialGroup().addContainerGap().addComponent(fileChooser, javax.swing.grouplayout.preferred_size, 382, javax.swing.grouplayout.preferred_size).addcontainergap(javax.swing.grouplayout.default_size, Short.MAX_VALUE))) pack( // </editor-fold> private void OpenActionPerformed(java.awt.event.ActionEvent evt) { int returnval = filechooser.showopendialog(this 4

5 if (returnval == JFileChooser.APPROVE_OPTION) { File file = filechooser.getselectedfile( try { // What to do with the file, e.g. display it in a TextArea textarea.read( new FileReader( file.getabsolutepath() ), null catch (IOException ex) { System.out.println("problem accessing file"+file.getabsolutepath() else { System.out.println("File access cancelled by user." // TODO add your handling code here: private void ExitActionPerformed(java.awt.event.ActionEvent evt) { System.exit(0 // TODO add your handling code here: /** args the command line arguments public static void main(string args[]) { java.awt.eventqueue.invokelater(new Runnable() { public void run() { new JFileChooserDemo().setVisible(true // Variables declaration - do not modify private javax.swing.jmenuitem Exit; private javax.swing.jmenuitem Open; private javax.swing.jfilechooser filechooser; private javax.swing.jmenu jmenu1; private javax.swing.jmenubar jmenubar1; private javax.swing.jscrollpane jscrollpane1; private javax.swing.jtextarea textarea; // End of variables declaration 5

6 Resim Göster package resim.resourses; public class ResimDemo extends javax.swing.jframe { /** Creates new form ResimDemo public ResimDemo() { // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jlabel1 = new javax.swing.jlabel( setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close jlabel1.seticon(new javax.swing.imageicon(getclass().getresource("/resim/resourses/duke1.gif")) // NOI18N javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane() getcontentpane().setlayout(layout layout.sethorizontalgroup(.addgroup(javax.swing.grouplayout.alignment.trailing, layout.createsequentialgroup().addcontainergap(126, Short.MAX_VALUE).addComponent(jLabel1).addGap(75, 75, 75)) layout.setverticalgroup( 6

7 .addgroup(javax.swing.grouplayout.alignment.trailing, layout.createsequentialgroup().addcontainergap(70, Short.MAX_VALUE).addComponent(jLabel1).addGap(64, 64, 64)) pack( // </editor-fold> /** args the command line arguments public static void main(string args[]) { java.awt.eventqueue.invokelater(new Runnable() { public void run() { new ResimDemo().setVisible(true // Variables declaration - do not modify private javax.swing.jlabel jlabel1; // End of variables declaration 7

8 Resim Göster 2: /* * To change this template, choose Tools Templates * and open the template in the editor. /* * ImageDemo.java * * Created on Dec 18, 2011, 7:32:49 PM package image; /** * Timur public class ImageDemo extends javax.swing.jframe { /** Creates new form ImageDemo public ImageDemo() { initcomponents( /** This method is called from within the constructor to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is * always regenerated by the Form // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jpanel1 = new javax.swing.jpanel( jbutton1 = new javax.swing.jbutton( setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close jbutton1.seticon(new javax.swing.imageicon(getclass().getresource("/image/1.png")) // NOI18N jbutton1.settext("jbutton1" javax.swing.grouplayout jpanel1layout = new javax.swing.grouplayout(jpanel1 jpanel1.setlayout(jpanel1layout jpanel1layout.sethorizontalgroup( jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(javax.swing.grouplayout.alignment.trailing, jpanel1layout.createsequentialgroup() 8

9 .addcomponent(jbutton1, javax.swing.grouplayout.preferred_size, 1080, javax.swing.grouplayout.preferred_size).addcontainergap(javax.swing.grouplayout.default_size, Short.MAX_VALUE)) jpanel1layout.setverticalgroup( jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(jpanel1layout.createsequentialgroup().addcontainergap().addcomponent(jbutton1, javax.swing.grouplayout.preferred_size, 654, javax.swing.grouplayout.preferred_size).addcontainergap(javax.swing.grouplayout.default_size, Short.MAX_VALUE)) javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane() getcontentpane().setlayout(layout layout.sethorizontalgroup(.addcomponent(jpanel1, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE) layout.setverticalgroup(.addcomponent(jpanel1, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE) pack( // </editor-fold> /** args the command line arguments public static void main(string args[]) { java.awt.eventqueue.invokelater(new Runnable() { public void run() { new ImageDemo().setVisible(true // Variables declaration - do not modify private javax.swing.jbutton jbutton1; private javax.swing.jpanel jpanel1; // End of variables declaration 9

10 10

11 package ücretöde; /** * Timur Karaçay public class ÜcretÖde extends javax.swing.jframe { double hsaat; double sücret; double nücret; double mücret; double tücret; public ÜcretÖde() { initcomponents( /** This method is called from within the constructor to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is * always regenerated by the Form // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jpanel1 = new javax.swing.jpanel( jlabel1 = new javax.swing.jlabel( jtextfield1 = new javax.swing.jtextfield( jlabel2 = new javax.swing.jlabel( jtextfield2 = new javax.swing.jtextfield( jlabel3 = new javax.swing.jlabel( jtextfield3 = new javax.swing.jtextfield( jlabel4 = new javax.swing.jlabel( jtextfield4 = new javax.swing.jtextfield( jlabel5 = new javax.swing.jlabel( jtextfield5 = new javax.swing.jtextfield( jbutton1 = new javax.swing.jbutton( jbutton2 = new javax.swing.jbutton( setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close jlabel1.setbackground(new java.awt.color(255, 153, 255) jlabel1.settext("saat/hafta" jtextfield1.setbackground(new java.awt.color(255, 153, 255) jtextfield1.sethorizontalalignment(javax.swing.jtextfield.right jtextfield1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { 11

12 jtextfield1actionperformed(evt jlabel2.setbackground(new java.awt.color(255, 255, 153) jlabel2.settext("ücret/saat" jtextfield2.setbackground(new java.awt.color(255, 255, 153) jtextfield2.sethorizontalalignment(javax.swing.jtextfield.right jtextfield2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield2actionperformed(evt jlabel3.settext("normal Ücret" jtextfield3.setbackground(new java.awt.color(102, 255, 0) jtextfield3.sethorizontalalignment(javax.swing.jtextfield.right jtextfield3.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield3actionperformed(evt jlabel4.settext("fazla Mesai Ücreti" jtextfield4.setbackground(new java.awt.color(255, 102, 51) jtextfield4.sethorizontalalignment(javax.swing.jtextfield.right jtextfield4.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield4actionperformed(evt jlabel5.settext("toplam Ücret" jtextfield5.setbackground(new java.awt.color(255, 204, 255) jtextfield5.sethorizontalalignment(javax.swing.jtextfield.right jtextfield5.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield5actionperformed(evt jbutton1.settext("ücret Hesapla" jbutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton1actionperformed(evt 12

13 jbutton2.settext("sil" jbutton2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton2actionperformed(evt javax.swing.grouplayout jpanel1layout = new javax.swing.grouplayout(jpanel1 jpanel1.setlayout(jpanel1layout jpanel1layout.sethorizontalgroup( jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(jpanel1layout.createsequentialgroup().addcontainergap().addgroup(jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jlabel1).addcomponent(jlabel2).addcomponent(jlabel3).addcomponent(jlabel4).addcomponent(jlabel5).addcomponent(jbutton1)).addgap(81, 81, 81).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addcomponent(jtextfield1, javax.swing.grouplayout.default_size, 76, Short.MAX_VALUE).addComponent(jTextField2, javax.swing.grouplayout.default_size, 76, Short.MAX_VALUE).addComponent(jTextField3, javax.swing.grouplayout.default_size, 76, Short.MAX_VALUE).addComponent(jTextField4, javax.swing.grouplayout.default_size, 76, Short.MAX_VALUE).addComponent(jTextField5, javax.swing.grouplayout.default_size, 76, Short.MAX_VALUE).addComponent(jButton2, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE)).addContainerGap(132, Short.MAX_VALUE)) jpanel1layout.setverticalgroup( jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(jpanel1layout.createsequentialgroup().addgap(25, 25, 25).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel1, javax.swing.grouplayout.alignment.trailing).addcomponent(jtextfield1, javax.swing.grouplayout.alignment.trailing, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jlabel2, javax.swing.grouplayout.alignment.trailing).addcomponent(jtextfield2, javax.swing.grouplayout.alignment.trailing, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading) 13

14 .addcomponent(jlabel3, javax.swing.grouplayout.alignment.trailing).addcomponent(jtextfield3, javax.swing.grouplayout.alignment.trailing, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addgroup(jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jlabel4, javax.swing.grouplayout.alignment.trailing).addcomponent(jtextfield4, javax.swing.grouplayout.alignment.trailing, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addgroup(jpanel1layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jlabel5, javax.swing.grouplayout.alignment.trailing).addcomponent(jtextfield5, javax.swing.grouplayout.alignment.trailing, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addgap(49, 49, 49).addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1).addComponent(jButton2)).addContainerGap(58, Short.MAX_VALUE)) javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane() getcontentpane().setlayout(layout layout.sethorizontalgroup(.addcomponent(jpanel1, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE) layout.setverticalgroup(.addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jpanel1, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE)) pack( // </editor-fold> private void jtextfield1actionperformed(java.awt.event.actionevent evt) { hsaat = Double.valueOf(jTextField1.getText().trim()).doubleValue( private void jtextfield2actionperformed(java.awt.event.actionevent evt) { sücret = Double.valueOf(jTextField2.getText().trim()).doubleValue( 14

15 private void jtextfield3actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jtextfield4actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jtextfield5actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: public void ücrethesapla() { if ((hsaat - 40) > 0) { nücret = hsaat * sücret; mücret = (hsaat - 40) * sücret * 1.5; else { nücret = hsaat * sücret; tücret = nücret + mücret; private void jbutton1actionperformed(java.awt.event.actionevent evt) { ücrethesapla( jtextfield3.settext(double.tostring(nücret) jtextfield4.settext(double.tostring(mücret) jtextfield5.settext(double.tostring(tücret) private void jbutton2actionperformed(java.awt.event.actionevent evt) { jtextfield1.settext("" jtextfield2.settext("" jtextfield3.settext("" jtextfield4.settext("" jtextfield5.settext("" /** args the command line arguments public static void main(string args[]) { java.awt.eventqueue.invokelater(new Runnable() { public void run() { new ÜcretÖde().setVisible(true // Variables declaration - do not modify 15

16 private javax.swing.jbutton jbutton1; private javax.swing.jbutton jbutton2; private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel2; private javax.swing.jlabel jlabel3; private javax.swing.jlabel jlabel4; private javax.swing.jlabel jlabel5; private javax.swing.jpanel jpanel1; private javax.swing.jtextfield jtextfield1; private javax.swing.jtextfield jtextfield2; private javax.swing.jtextfield jtextfield3; private javax.swing.jtextfield jtextfield4; private javax.swing.jtextfield jtextfield5; // End of variables declaration 16

17 package jtexteditor.resources; public class JTextEditorDemo extends javax.swing.jframe { /** Creates new form JTextEditorDemo public JTextEditorDemo() { // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jpanel1 = new javax.swing.jpanel( jscrollpane1 = new javax.swing.jscrollpane( jeditorpane1 = new javax.swing.jeditorpane( setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close settitle("java text Editor" jpanel1.setlayout(new java.awt.borderlayout() jscrollpane1.setviewportview(jeditorpane1 jpanel1.add(jscrollpane1, java.awt.borderlayout.center javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane() getcontentpane().setlayout(layout layout.sethorizontalgroup(.addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jpanel1, javax.swing.grouplayout.default_size, 390, Short.MAX_VALUE)) layout.setverticalgroup(.addcomponent(jpanel1, javax.swing.grouplayout.default_size, 300, Short.MAX_VALUE) pack( // </editor-fold> public static void main(string args[]) { java.awt.eventqueue.invokelater(new Runnable() { public void run() { new JTextEditorDemo().setVisible(true 17

18 // Variables declaration - do not modify private javax.swing.jeditorpane jeditorpane1; private javax.swing.jpanel jpanel1; private javax.swing.jscrollpane jscrollpane1; // End of variables declaration 18

19 /* * To change this template, choose Tools Templates * and open the template in the editor. /* * JTextPane.java * * Created on Dec 19, 2011, 7:31:39 AM package javatextpane.resources; /** * Timur public class JTextPane extends javax.swing.jframe { /** Creates new form JTextPane public JTextPane() { initcomponents( /** This method is called from within the constructor to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is * always regenerated by the Form // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jscrollpane1 = new javax.swing.jscrollpane( jtextpane1 = new javax.swing.jtextpane( setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close settitle("java Text Pane" setname("java TextPane" // NOI18N jtextpane1.settext("java TextPane" jscrollpane1.setviewportview(jtextpane1 javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane() getcontentpane().setlayout(layout layout.sethorizontalgroup(.addgroup(javax.swing.grouplayout.alignment.trailing, layout.createsequentialgroup().addcomponent(jscrollpane1, javax.swing.grouplayout.default_size, 390, Short.MAX_VALUE).addContainerGap()) 19

20 layout.setverticalgroup(.addcomponent(jscrollpane1, javax.swing.grouplayout.alignment.trailing, javax.swing.grouplayout.default_size, 300, Short.MAX_VALUE) pack( // </editor-fold> /** args the command line arguments public static void main(string args[]) { java.awt.eventqueue.invokelater(new Runnable() { public void run() { new JTextPane().setVisible(true // Variables declaration - do not modify private javax.swing.jscrollpane jscrollpane1; private javax.swing.jtextpane jtextpane1; // End of variables declaration 20

Appendix B Task 2: questionnaire and artefacts

Appendix B Task 2: questionnaire and artefacts Appendix B Task 2: questionnaire and artefacts This section shows the questionnaire, the UML class and sequence diagrams, and the source code provided for the task 1 (T2) Buy a Ticket Unsuccessfully. It

More information

http://netbeans.org/kb/docs/java/gui-functionality.html?print=yes

http://netbeans.org/kb/docs/java/gui-functionality.html?print=yes Page 1 of 6 Introduction to GUI Building Contributed by Saleem Gul and Tomas Pavek, maintained by Ruth Kusterer and Irina Filippova This beginner tutorial teaches you how to create a simple graphical user

More information

How To Create A Digital Signature Certificate

How To Create A Digital Signature Certificate Tool. For Signing & Verification Submitted To: Submitted By: Shri Patrick Kishore Chief Operating Officer Sujit Kumar Tiwari MCA, I Year University Of Hyderabad Certificate by Guide This is certifying

More information

Advanced Network Programming Lab using Java. Angelos Stavrou

Advanced Network Programming Lab using Java. Angelos Stavrou Advanced Network Programming Lab using Java Angelos Stavrou Table of Contents A simple Java Client...3 A simple Java Server...4 An advanced Java Client...5 An advanced Java Server...8 A Multi-threaded

More information

NetBeans, Java, and JFreeChart. An introduction for the complete novice (Part 1)

NetBeans, Java, and JFreeChart. An introduction for the complete novice (Part 1) NetBeans, Java, and JFreeChart An introduction for the complete novice (Part 1) Carl David Carl.David@uconn.edu Introduction This set of papers consists of an introduction to JFreeChart and NetBeans as

More information

Homework/Program #5 Solutions

Homework/Program #5 Solutions Homework/Program #5 Solutions Problem #1 (20 points) Using the standard Java Scanner class. Look at http://natch3z.blogspot.com/2008/11/read-text-file-using-javautilscanner.html as an exampleof using the

More information

INTRODUCTION TO COMPUTER PROGRAMMING. Richard Pierse. Class 7: Object-Oriented Programming. Introduction

INTRODUCTION TO COMPUTER PROGRAMMING. Richard Pierse. Class 7: Object-Oriented Programming. Introduction INTRODUCTION TO COMPUTER PROGRAMMING Richard Pierse Class 7: Object-Oriented Programming Introduction One of the key issues in programming is the reusability of code. Suppose that you have written a program

More information

ICOM 4015: Advanced Programming

ICOM 4015: Advanced Programming ICOM 4015: Advanced Programming Lecture 10 Reading: Chapter Ten: Inheritance Copyright 2009 by John Wiley & Sons. All rights reserved. Chapter 10 Inheritance Chapter Goals To learn about inheritance To

More information

Altas, Bajas y Modificaciones de Registros en tabla MYSQL

Altas, Bajas y Modificaciones de Registros en tabla MYSQL Altas, Bajas y Modificaciones de Registros en tabla MYSQL 1. En MySql crear una base de datos de nombre EmpresaABC y dentro de ella la tabla Empleados con la siguiente estructura: DNI integer(8) Definir

More information

Swing. A Quick Tutorial on Programming Swing Applications

Swing. A Quick Tutorial on Programming Swing Applications Swing A Quick Tutorial on Programming Swing Applications 1 MVC Model View Controller Swing is based on this design pattern It means separating the implementation of an application into layers or components:

More information

CSS 543 Program 3: Online Tic-Tac-Toe Game Professor: Munehiro Fukuda Due date: see the syllabus

CSS 543 Program 3: Online Tic-Tac-Toe Game Professor: Munehiro Fukuda Due date: see the syllabus CSS 543 Program 3: Online Tic-Tac-Toe Game Professor: Munehiro Fukuda Due date: see the syllabus 1. Purpose This assignment exercises how to write a peer-to-peer communicating program using non-blocking

More information

DHBW Karlsruhe, Vorlesung Programmieren, Remote Musterlösungen

DHBW Karlsruhe, Vorlesung Programmieren, Remote Musterlösungen DHBW Karlsruhe, Vorlesung Programmieren, Remote Musterlösungen Aufgabe 1 RMI - TimeService public interface TimeServerInterface extends Remote { public String gettime() throws RemoteException; import java.util.date;

More information

Java is commonly used for deploying applications across a network. Compiled Java code

Java is commonly used for deploying applications across a network. Compiled Java code Module 5 Introduction to Java/Swing Java is commonly used for deploying applications across a network. Compiled Java code may be distributed to different machine architectures, and a native-code interpreter

More information

11. Applets, normal window applications, packaging and sharing your work

11. Applets, normal window applications, packaging and sharing your work 11. Applets, normal window applications, packaging and sharing your work In this chapter Converting Full Screen experiments into normal window applications, Packaging and sharing applications packaging

More information

Using NetBeans IDE to Build Quick UI s Ray Hylock, GISo Tutorial 3/8/2011

Using NetBeans IDE to Build Quick UI s Ray Hylock, GISo Tutorial 3/8/2011 Using NetBeans IDE to Build Quick UI s Ray Hylock, GISo Tutorial 3/8/2011 We will be building the following application using the NetBeans IDE. It s a simple nucleotide search tool where we have as input

More information

Java GUI Programming. Building the GUI for the Microsoft Windows Calculator Lecture 2. Des Traynor 2005

Java GUI Programming. Building the GUI for the Microsoft Windows Calculator Lecture 2. Des Traynor 2005 Java GUI Programming Building the GUI for the Microsoft Windows Calculator Lecture 2 Des Traynor 2005 So, what are we up to Today, we are going to create the GUI for the calculator you all know and love.

More information

D06 PROGRAMMING with JAVA

D06 PROGRAMMING with JAVA Cicles Formatius de Grau Superior Desenvolupament d Aplicacions Informàtiques D06 PROGRAMMING with JAVA Ch16 Files and Streams PowerPoint presentation, created by Angel A. Juan - ajuanp(@)gmail.com, for

More information

Compedit. Ë Developped within the E-Mediate project (France Telecom) Ë What CompEdit is intended for? Ë Three aims imply three development steps :

Compedit. Ë Developped within the E-Mediate project (France Telecom) Ë What CompEdit is intended for? Ë Three aims imply three development steps : Compedit Ë Developped within the E-Mediate project (France Telecom) Ë What CompEdit is intended for? u to provide a graphic editor to build or modify Fractal compositions v to allow the launching of one

More information

The Abstract Windowing Toolkit. Java Foundation Classes. Swing. In April 1997, JavaSoft announced the Java Foundation Classes (JFC).

The Abstract Windowing Toolkit. Java Foundation Classes. Swing. In April 1997, JavaSoft announced the Java Foundation Classes (JFC). The Abstract Windowing Toolkit Since Java was first released, its user interface facilities have been a significant weakness The Abstract Windowing Toolkit (AWT) was part of the JDK form the beginning,

More information

Essentials of the Java(TM) Programming Language, Part 1

Essentials of the Java(TM) Programming Language, Part 1 Essentials of the Java(TM) Programming Language, Part 1 http://developer.java.sun.com/developer...ining/programming/basicjava1/index.html Training Index Essentials of the Java TM Programming Language:

More information

During the process of creating ColorSwitch, you will learn how to do these tasks:

During the process of creating ColorSwitch, you will learn how to do these tasks: GUI Building in NetBeans IDE 3.6 This short tutorial guides you through the process of creating an application called ColorSwitch. You will build a simple program that enables you to switch the color of

More information

5.17 GUI. Xiaoyi Jiang Informatik I Grundlagen der Programmierung

5.17 GUI. Xiaoyi Jiang Informatik I Grundlagen der Programmierung AWT vs. Swing AWT (Abstract Window Toolkit; Package java.awt) Benutzt Steuerelemente des darunterliegenden Betriebssystems Native Code (direkt für die Maschine geschrieben, keine VM); schnell Aussehen

More information

CS 335 Lecture 06 Java Programming GUI and Swing

CS 335 Lecture 06 Java Programming GUI and Swing CS 335 Lecture 06 Java Programming GUI and Swing Java: Basic GUI Components Swing component overview Event handling Inner classes and anonymous inner classes Examples and various components Layouts Panels

More information

// Correntista. //Conta Corrente. package Banco; public class Correntista { String nome, sobrenome; int cpf;

// Correntista. //Conta Corrente. package Banco; public class Correntista { String nome, sobrenome; int cpf; // Correntista public class Correntista { String nome, sobrenome; int cpf; public Correntista(){ nome = "zé"; sobrenome = "Pereira"; cpf = 123456; public void setnome(string n){ nome = n; public void setsobrenome(string

More information

Using A Frame for Output

Using A Frame for Output Eventos Roteiro Frames Formatting Output Event Handling Entering Data Using Fields in a Frame Creating a Data Entry Field Using a Field Reading Data in an Event Handler Handling Multiple Button Events

More information

JIDE Action Framework Developer Guide

JIDE Action Framework Developer Guide JIDE Action Framework Developer Guide Contents PURPOSE OF THIS DOCUMENT... 1 WHAT IS JIDE ACTION FRAMEWORK... 1 PACKAGES... 3 MIGRATING FROM EXISTING APPLICATIONS... 3 DOCKABLEBARMANAGER... 9 DOCKABLE

More information

Programming with Java GUI components

Programming with Java GUI components Programming with Java GUI components Java includes libraries to provide multi-platform support for Graphic User Interface objects. The multi-platform aspect of this is that you can write a program on a

More information

Creating a Simple, Multithreaded Chat System with Java

Creating a Simple, Multithreaded Chat System with Java Creating a Simple, Multithreaded Chat System with Java Introduction by George Crawford III In this edition of Objective Viewpoint, you will learn how to develop a simple chat system. The program will demonstrate

More information

GUIs with Swing. Principles of Software Construction: Objects, Design, and Concurrency. Jonathan Aldrich and Charlie Garrod Fall 2012

GUIs with Swing. Principles of Software Construction: Objects, Design, and Concurrency. Jonathan Aldrich and Charlie Garrod Fall 2012 GUIs with Swing Principles of Software Construction: Objects, Design, and Concurrency Jonathan Aldrich and Charlie Garrod Fall 2012 Slides copyright 2012 by Jeffrey Eppinger, Jonathan Aldrich, William

More information

Illustration 1: An applet showing constructed responses in an intuitive mode. Note the misprint!

Illustration 1: An applet showing constructed responses in an intuitive mode. Note the misprint! Applets in Java using NetBeans as an IDE (Part 1) C.W. David Department of Chemistry University of Connecticut Storrs, CT 06269-3060 Carl.David@uconn.edu We are interested in creating a teaching/testing

More information

Graphical User Interfaces

Graphical User Interfaces M14_REGE1813_02_SE_C14.qxd 2/10/10 3:43 PM Page 822 Chapter14 Graphical User Interfaces 14.1 GUI Basics Graphical Input and Output with Option Panes Working with Frames Buttons, Text Fields, and Labels

More information

Project 4 DB A Simple database program

Project 4 DB A Simple database program Project 4 DB A Simple database program Due Date April (Friday) Before Starting the Project Read this entire project description before starting Learning Objectives After completing this project you should

More information

Zebra and MapReduce. Table of contents. 1 Overview...2 2 Hadoop MapReduce APIs...2 3 Zebra MapReduce APIs...2 4 Zebra MapReduce Examples...

Zebra and MapReduce. Table of contents. 1 Overview...2 2 Hadoop MapReduce APIs...2 3 Zebra MapReduce APIs...2 4 Zebra MapReduce Examples... Table of contents 1 Overview...2 2 Hadoop MapReduce APIs...2 3 Zebra MapReduce APIs...2 4 Zebra MapReduce Examples... 2 1. Overview MapReduce allows you to take full advantage of Zebra's capabilities.

More information

Informatik II. // ActionListener hinzufügen btnconvert.addactionlistener(this); super.setdefaultcloseoperation(jframe.

Informatik II. // ActionListener hinzufügen btnconvert.addactionlistener(this); super.setdefaultcloseoperation(jframe. Universität Augsburg, Institut für Informatik Sommersemester 2006 Prof. Dr. Werner Kießling 20. Juli. 2006 M. Endres, A. Huhn, T. Preisinger Lösungsblatt 11 Aufgabe 1: Währungsrechner CurrencyConverter.java

More information

How To Build A Swing Program In Java.Java.Netbeans.Netcode.Com (For Windows) (For Linux) (Java) (Javax) (Windows) (Powerpoint) (Netbeans) (Sun) (

How To Build A Swing Program In Java.Java.Netbeans.Netcode.Com (For Windows) (For Linux) (Java) (Javax) (Windows) (Powerpoint) (Netbeans) (Sun) ( Chapter 11. Graphical User Interfaces To this point in the text, our programs have interacted with their users to two ways: The programs in Chapters 1-5, implemented in Processing, displayed graphical

More information

LAYOUT MANAGERS. Layout Managers Page 1. java.lang.object. java.awt.component. java.awt.container. java.awt.window. java.awt.panel

LAYOUT MANAGERS. Layout Managers Page 1. java.lang.object. java.awt.component. java.awt.container. java.awt.window. java.awt.panel LAYOUT MANAGERS A layout manager controls how GUI components are organized within a GUI container. Each Swing container (e.g. JFrame, JDialog, JApplet and JPanel) is a subclass of java.awt.container and

More information

JAVA Program For Processing SMS Messages

JAVA Program For Processing SMS Messages JAVA Program For Processing SMS Messages Krishna Akkulu The paper describes the Java program implemented for the MultiModem GPRS wireless modem. The MultiModem offers standards-based quad-band GSM/GPRS

More information

A practical introduction

A practical introduction Spring Rich Client A practical introduction An introduction to the Spring Rich Client framework Lieven DOCLO CONTENTS Introduction... 5 Overview... 5 Getting our hands dirty... 5 The Spring Rich Client

More information

method is never called because it is automatically called by the window manager. An example of overriding the paint() method in an Applet follows:

method is never called because it is automatically called by the window manager. An example of overriding the paint() method in an Applet follows: Applets - Java Programming for the Web An applet is a Java program designed to run in a Java-enabled browser or an applet viewer. In a browser, an applet is called into execution when the APPLET HTML tag

More information

Java Classes. GEEN163 Introduction to Computer Programming

Java Classes. GEEN163 Introduction to Computer Programming Java Classes GEEN163 Introduction to Computer Programming Never interrupt someone doing what you said couldn't be done. Amelia Earhart Classes, Objects, & Methods Object-oriented programming uses classes,

More information

Karsten Lentzsch JGoodies SWING WITH STYLE

Karsten Lentzsch JGoodies SWING WITH STYLE Karsten Lentzsch JGoodies SWING WITH STYLE JGoodies: Karsten Lentzsch Open source Swing libraries Example applications Consultant for Java desktop Design assistance Training for visual design and implementation

More information

file://c:\dokumente und Einstellungen\Marco Favorito\Desktop\ScanCmds.html

file://c:\dokumente und Einstellungen\Marco Favorito\Desktop\ScanCmds.html file:c:\dokumente und Einstellungen\Marco Favorito\Desktop\ScanCmds.html Seite 1 von 5 ScanCmds.java ------------------------------------------------------------------------------- ScanCmds Demontration

More information

Chulalongkorn University International School of Engineering Department of Computer Engineering 2140105 Computer Programming Lab.

Chulalongkorn University International School of Engineering Department of Computer Engineering 2140105 Computer Programming Lab. Chulalongkorn University Name International School of Engineering Student ID Department of Computer Engineering Station No. 2140105 Computer Programming Lab. Date Lab 2 Using Java API documents, command

More information

JAVA - EXCEPTIONS. An exception can occur for many different reasons, below given are some scenarios where exception occurs.

JAVA - EXCEPTIONS. An exception can occur for many different reasons, below given are some scenarios where exception occurs. http://www.tutorialspoint.com/java/java_exceptions.htm JAVA - EXCEPTIONS Copyright tutorialspoint.com An exception orexceptionalevent is a problem that arises during the execution of a program. When an

More information

How To Program In Java (Ipt) With A Bean And An Animated Object In A Powerpoint (For A Powerbook)

How To Program In Java (Ipt) With A Bean And An Animated Object In A Powerpoint (For A Powerbook) Graphic Interface Programming II Applets and Beans and animation in Java IT Uppsala universitet Applets Small programs embedded in web pages

More information

www.virtualians.pk CS506 Web Design and Development Solved Online Quiz No. 01 www.virtualians.pk

www.virtualians.pk CS506 Web Design and Development Solved Online Quiz No. 01 www.virtualians.pk CS506 Web Design and Development Solved Online Quiz No. 01 Which of the following is a general purpose container? JFrame Dialog JPanel JApplet Which of the following package needs to be import while handling

More information

How to Convert an Application into an Applet.

How to Convert an Application into an Applet. How to Convert an Application into an Applet. A java application contains a main method. An applet is a java program part of a web page and runs within a browser. I am going to show you three different

More information

Essentials of the Java Programming Language

Essentials of the Java Programming Language Essentials of the Java Programming Language A Hands-On Guide by Monica Pawlan 350 East Plumeria Drive San Jose, CA 95134 USA May 2013 Part Number TBD v1.0 Sun Microsystems. Inc. All rights reserved If

More information

Lecture J - Exceptions

Lecture J - Exceptions Lecture J - Exceptions Slide 1 of 107. Exceptions in Java Java uses the notion of exception for 3 related (but different) purposes: Errors: an internal Java implementation error was discovered E.g: out

More information

Assignment # 2: Design Patterns and GUIs

Assignment # 2: Design Patterns and GUIs CSUS COLLEGE OF ENGINEERING AND COMPUTER SCIENCE Department of Computer Science CSc 133 Object-Oriented Computer Graphics Programming Spring 2014 John Clevenger Assignment # 2: Design Patterns and GUIs

More information

Java Program Coding Standards 4002-217-9 Programming for Information Technology

Java Program Coding Standards 4002-217-9 Programming for Information Technology Java Program Coding Standards 4002-217-9 Programming for Information Technology Coding Standards: You are expected to follow the standards listed in this document when producing code for this class. Whether

More information

CS 111 Classes I 1. Software Organization View to this point:

CS 111 Classes I 1. Software Organization View to this point: CS 111 Classes I 1 Software Organization View to this point: Data Objects and primitive types Primitive types operators (+, /,,*, %). int, float, double, char, boolean Memory location holds the data Objects

More information

CSE 308. Coding Conventions. Reference

CSE 308. Coding Conventions. Reference CSE 308 Coding Conventions Reference Java Coding Conventions googlestyleguide.googlecode.com/svn/trunk/javaguide.html Java Naming Conventions www.ibm.com/developerworks/library/ws-tipnamingconv.html 2

More information

D06 PROGRAMMING with JAVA

D06 PROGRAMMING with JAVA Cicles Formatius de Grau Superior Desenvolupament d Aplicacions Informàtiques D06 PROGRAMMING with JAVA Ch15 Exception Handling PowerPoint presentation, created by Angel A. Juan - ajuanp(@)gmail.com, for

More information

Section 6 Spring 2013

Section 6 Spring 2013 Print Your Name You may use one page of hand written notes (both sides) and a dictionary. No i-phones, calculators or any other type of non-organic computer. Do not take this exam if you are sick. Once

More information

LAB4 Making Classes and Objects

LAB4 Making Classes and Objects LAB4 Making Classes and Objects Objective The main objective of this lab is class creation, how its constructer creation, object creation and instantiation of objects. We will use the definition pane to

More information

Management Information Systems 260 Web Programming Fall 2006 (CRN: 42459)

Management Information Systems 260 Web Programming Fall 2006 (CRN: 42459) Management Information Systems 260 Web Programming Fall 2006 (CRN: 42459) Class Time: 6:00 8:05 p.m. (T,Th) Venue: WSL 5 Web Site: www.pbvusd.net/mis260 Instructor Name: Terrell Tucker Office: BDC 127

More information

LAB 1. Familiarization of Rational Rose Environment And UML for small Java Application Development

LAB 1. Familiarization of Rational Rose Environment And UML for small Java Application Development LAB 1 Familiarization of Rational Rose Environment And UML for small Java Application Development OBJECTIVE AND BACKGROUND The purpose of this first UML lab is to familiarize programmers with Rational

More information

File class in Java. Scanner reminder. Files 10/19/2012. File Input and Output (Savitch, Chapter 10)

File class in Java. Scanner reminder. Files 10/19/2012. File Input and Output (Savitch, Chapter 10) File class in Java File Input and Output (Savitch, Chapter 10) TOPICS File Input Exception Handling File Output Programmers refer to input/output as "I/O". The File class represents files as objects. The

More information

16.1 DataFlavor. 16.1.1 DataFlavor Methods. Variables

16.1 DataFlavor. 16.1.1 DataFlavor Methods. Variables In this chapter: DataFlavor Transferable Interface ClipboardOwner Interface Clipboard StringSelection UnsupportedFlavorException Reading and Writing the Clipboard 16 Data Transfer One feature that was

More information

Third AP Edition. Object-Oriented Programming and Data Structures. Maria Litvin. Gary Litvin. Phillips Academy, Andover, Massachusetts

Third AP Edition. Object-Oriented Programming and Data Structures. Maria Litvin. Gary Litvin. Phillips Academy, Andover, Massachusetts Third AP Edition Object-Oriented Programming and Data Structures Maria Litvin Phillips Academy, Andover, Massachusetts Gary Litvin Skylight Software, Inc. Skylight Publishing Andover, Massachusetts Skylight

More information

Classes and Objects in Java Constructors. In creating objects of the type Fraction, we have used statements similar to the following:

Classes and Objects in Java Constructors. In creating objects of the type Fraction, we have used statements similar to the following: In creating objects of the type, we have used statements similar to the following: f = new (); The parentheses in the expression () makes it look like a method, yet we never created such a method in our

More information

Tutorial: Time Of Day Part 2 GUI Design in NetBeans

Tutorial: Time Of Day Part 2 GUI Design in NetBeans Tutorial: Time Of Day Part 2 GUI Design in NetBeans October 7, 2010 Author Goals Kees Hemerik / Gerard Zwaan Getting acquainted with NetBeans GUI Builder Illustrate the separation between GUI and computation

More information

WRITING DATA TO A BINARY FILE

WRITING DATA TO A BINARY FILE WRITING DATA TO A BINARY FILE TEXT FILES VS. BINARY FILES Up to now, we have looked at how to write and read characters to and from a text file. Text files are files that contain sequences of characters.

More information

Crash Course in Java

Crash Course in Java Crash Course in Java Based on notes from D. Hollinger Based in part on notes from J.J. Johns also: Java in a Nutshell Java Network Programming and Distributed Computing Netprog 2002 Java Intro 1 What is

More information

public class demo1swing extends JFrame implements ActionListener{

public class demo1swing extends JFrame implements ActionListener{ import java.io.*; import java.net.*; import java.io.*; import javax.swing.*; import java.awt.*; import java.awt.event.*; public class demo1swing extends JFrame implements ActionListener JButton demodulacion;

More information

How Scala Improved Our Java

How Scala Improved Our Java How Scala Improved Our Java Sam Reid PhET Interactive Simulations University of Colorado http://spot.colorado.edu/~reids/ PhET Interactive Simulations Provides free, open source educational science simulations

More information

Masters programmes in Computer Science and Information Systems. Object-Oriented Design and Programming. Sample module entry test xxth December 2013

Masters programmes in Computer Science and Information Systems. Object-Oriented Design and Programming. Sample module entry test xxth December 2013 Masters programmes in Computer Science and Information Systems Object-Oriented Design and Programming Sample module entry test xxth December 2013 This sample paper has more questions than the real paper

More information

First Java Programs. V. Paúl Pauca. CSC 111D Fall, 2015. Department of Computer Science Wake Forest University. Introduction to Computer Science

First Java Programs. V. Paúl Pauca. CSC 111D Fall, 2015. Department of Computer Science Wake Forest University. Introduction to Computer Science First Java Programs V. Paúl Pauca Department of Computer Science Wake Forest University CSC 111D Fall, 2015 Hello World revisited / 8/23/15 The f i r s t o b l i g a t o r y Java program @author Paul Pauca

More information

Object-Oriented Programming in Java

Object-Oriented Programming in Java CSCI/CMPE 3326 Object-Oriented Programming in Java Class, object, member field and method, final constant, format specifier, file I/O Dongchul Kim Department of Computer Science University of Texas Rio

More information

FILE I/O IN JAVA. Prof. Chris Jermaine cmj4@cs.rice.edu. Prof. Scott Rixner rixner@cs.rice.edu

FILE I/O IN JAVA. Prof. Chris Jermaine cmj4@cs.rice.edu. Prof. Scott Rixner rixner@cs.rice.edu FILE I/O IN JAVA Prof. Chris Jermaine cmj4@cs.rice.edu Prof. Scott Rixner rixner@cs.rice.edu 1 Our Simple Java Programs So Far Aside from screen I/O......when they are done, they are gone They have no

More information

WA2099 Introduction to Java using RAD 8.0 EVALUATION ONLY. Student Labs. Web Age Solutions Inc.

WA2099 Introduction to Java using RAD 8.0 EVALUATION ONLY. Student Labs. Web Age Solutions Inc. WA2099 Introduction to Java using RAD 8.0 Student Labs Web Age Solutions Inc. 1 Table of Contents Lab 1 - The HelloWorld Class...3 Lab 2 - Refining The HelloWorld Class...20 Lab 3 - The Arithmetic Class...25

More information

Continuous Integration Part 2

Continuous Integration Part 2 1 Continuous Integration Part 2 This blog post is a follow up to my blog post Continuous Integration (CI), in which I described how to execute test cases in Code Tester (CT) in a CI environment. What I

More information

Object Oriented Programming with Java. School of Computer Science University of KwaZulu-Natal

Object Oriented Programming with Java. School of Computer Science University of KwaZulu-Natal Object Oriented Programming with Java School of Computer Science University of KwaZulu-Natal January 30, 2006 2 Object Oriented Programming with Java Notes for the Computer Science Module Object Oriented

More information

public static void main(string[] args) { System.out.println("hello, world"); } }

public static void main(string[] args) { System.out.println(hello, world); } } Java in 21 minutes hello world basic data types classes & objects program structure constructors garbage collection I/O exceptions Strings Hello world import java.io.*; public class hello { public static

More information

Introduction to Object-Oriented Programming

Introduction to Object-Oriented Programming Introduction to Object-Oriented Programming Programs and Methods Christopher Simpkins chris.simpkins@gatech.edu CS 1331 (Georgia Tech) Programs and Methods 1 / 8 The Anatomy of a Java Program It is customary

More information

Tutorial Reference Manual. Java WireFusion 4.1

Tutorial Reference Manual. Java WireFusion 4.1 Tutorial Reference Manual Java WireFusion 4.1 Contents INTRODUCTION...1 About this Manual...2 REQUIREMENTS...3 User Requirements...3 System Requirements...3 SHORTCUTS...4 DEVELOPMENT ENVIRONMENT...5 Menu

More information

Coding Standard for Java

Coding Standard for Java Coding Standard for Java 1. Content 1. Content 1 2. Introduction 1 3. Naming convention for Files/Packages 1 4. Naming convention for Classes, Interfaces, Members and Variables 2 5. File Layout (.java)

More information

Tutorial: Getting Started

Tutorial: Getting Started 9 Tutorial: Getting Started INFRASTRUCTURE A MAKEFILE PLAIN HELLO WORLD APERIODIC HELLO WORLD PERIODIC HELLO WORLD WATCH THOSE REAL-TIME PRIORITIES THEY ARE SERIOUS SUMMARY Getting started with a new platform

More information

Lab 1A. Create a simple Java application using JBuilder. Part 1: make the simplest Java application Hello World 1. Start Jbuilder. 2.

Lab 1A. Create a simple Java application using JBuilder. Part 1: make the simplest Java application Hello World 1. Start Jbuilder. 2. Lab 1A. Create a simple Java application using JBuilder In this lab exercise, we ll learn how to use a Java integrated development environment (IDE), Borland JBuilder 2005, to develop a simple Java application

More information

Lab 9. Spam, Spam, Spam. Handout 11 CSCI 134: Spring, 2015. To gain experience with Strings. Objective

Lab 9. Spam, Spam, Spam. Handout 11 CSCI 134: Spring, 2015. To gain experience with Strings. Objective Lab 9 Handout 11 CSCI 134: Spring, 2015 Spam, Spam, Spam Objective To gain experience with Strings. Before the mid-90s, Spam was a canned meat product. These days, the term spam means just one thing unwanted

More information

Introduction to Java. Module 12: Networking (Java Sockets) Prepared by Costantinos Costa for EPL 233. ΕΠΛ233 Αντικειμενοστρεφής Προγραμματισμός 1

Introduction to Java. Module 12: Networking (Java Sockets) Prepared by Costantinos Costa for EPL 233. ΕΠΛ233 Αντικειμενοστρεφής Προγραμματισμός 1 Introduction to Java Module 12: Networking (Java Sockets) Prepared by Costantinos Costa for EPL 233 ΕΠΛ233 Αντικειμενοστρεφής Προγραμματισμός 1 What Is a Socket? A socket is one end-point of a two-way

More information

Translating to Java. Translation. Input. Many Level Translations. read, get, input, ask, request. Requirements Design Algorithm Java Machine Language

Translating to Java. Translation. Input. Many Level Translations. read, get, input, ask, request. Requirements Design Algorithm Java Machine Language Translation Translating to Java Introduction to Computer Programming The job of a programmer is to translate a problem description into a computer language. You need to be able to convert a problem description

More information

Arrays. Atul Prakash Readings: Chapter 10, Downey Sun s Java tutorial on Arrays: http://java.sun.com/docs/books/tutorial/java/nutsandbolts/arrays.

Arrays. Atul Prakash Readings: Chapter 10, Downey Sun s Java tutorial on Arrays: http://java.sun.com/docs/books/tutorial/java/nutsandbolts/arrays. Arrays Atul Prakash Readings: Chapter 10, Downey Sun s Java tutorial on Arrays: http://java.sun.com/docs/books/tutorial/java/nutsandbolts/arrays.html 1 Grid in Assignment 2 How do you represent the state

More information

Dev Articles 05/25/07 11:07:33

Dev Articles 05/25/07 11:07:33 Java Crawling the Web with Java Contributed by McGraw Hill/Osborne 2005 06 09 Access Your PC from Anywhere Download Your Free Trial Take your office with you, wherever you go with GoToMyPC. It s the remote

More information

Graphical User Interface Programming. Robert M. Dondero, Ph.D. Princeton University

Graphical User Interface Programming. Robert M. Dondero, Ph.D. Princeton University Graphical User Interface Programming Robert M. Dondero, Ph.D. Princeton University 1 Objectives You will learn about: Graphical user interface (GUI) programming Specifically... For Java: The AWT/Swing

More information

Sample CSE8A midterm Multiple Choice (circle one)

Sample CSE8A midterm Multiple Choice (circle one) Sample midterm Multiple Choice (circle one) (2 pts) Evaluate the following Boolean expressions and indicate whether short-circuiting happened during evaluation: Assume variables with the following names

More information

Final Project Report E3390 Electronic Circuit Design Lab. Electronic Notepad

Final Project Report E3390 Electronic Circuit Design Lab. Electronic Notepad Final Project Report E3390 Electronic Circuit Design Lab Electronic Notepad Keith Dronson Sam Subbarao Submitted in partial fulfillment of the requirements for the Bachelor of Science Degree May 10, 2008

More information

Overview of Web Services API

Overview of Web Services API 1 CHAPTER The Cisco IP Interoperability and Collaboration System (IPICS) 4.5(x) application programming interface (API) provides a web services-based API that enables the management and control of various

More information

Prof. Edwar Saliba Júnior

Prof. Edwar Saliba Júnior package Conexao; 2 3 /** 4 * 5 * @author Cynthia Lopes 6 * @author Edwar Saliba Júnior 7 */ 8 import java.io.filenotfoundexception; 9 import java.io.ioexception; 10 import java.sql.sqlexception; 11 import

More information

An Overview of Java. overview-1

An Overview of Java. overview-1 An Overview of Java overview-1 Contents What is Java Major Java features Java virtual machine Java programming language Java class libraries (API) GUI Support in Java Networking and Threads in Java overview-2

More information

Application Development with TCP/IP. Brian S. Mitchell Drexel University

Application Development with TCP/IP. Brian S. Mitchell Drexel University Application Development with TCP/IP Brian S. Mitchell Drexel University Agenda TCP/IP Application Development Environment Client/Server Computing with TCP/IP Sockets Port Numbers The TCP/IP Application

More information

Introduction to the Java Programming Language

Introduction to the Java Programming Language Software Design Introduction to the Java Programming Language Material drawn from [JDK99,Sun96,Mitchell99,Mancoridis00] Java Features Write Once, Run Anywhere. Portability is possible because of Java virtual

More information

How to use the Eclipse IDE for Java Application Development

How to use the Eclipse IDE for Java Application Development How to use the Eclipse IDE for Java Application Development Java application development is supported by many different tools. One of the most powerful and helpful tool is the free Eclipse IDE (IDE = Integrated

More information

OTN Developer Day: Oracle Big Data. Hands On Lab Manual. Introduction to Oracle NoSQL Database

OTN Developer Day: Oracle Big Data. Hands On Lab Manual. Introduction to Oracle NoSQL Database OTN Developer Day: Oracle Big Data Hands On Lab Manual Introduction to ORACLE NOSQL DATABASE HANDS-ON WORKSHOP ii Hands on Workshop Lab Exercise 1 Start and run the Movieplex application. In this lab,

More information

Using NetBeans IDE for Desktop Development. Geertjan Wielenga http://blogs.sun.com/geertjan

Using NetBeans IDE for Desktop Development. Geertjan Wielenga http://blogs.sun.com/geertjan Using NetBeans IDE for Desktop Development Geertjan Wielenga http://blogs.sun.com/geertjan Agenda Goals Design: Matisse GUI Builder Medium Applications: JSR-296 Tooling Large Applications: NetBeans Platform

More information

Arduino & Android. A How to on interfacing these two devices. Bryant Tram

Arduino & Android. A How to on interfacing these two devices. Bryant Tram Arduino & Android A How to on interfacing these two devices Bryant Tram Contents 1 Overview... 2 2 Other Readings... 2 1. Android Debug Bridge -... 2 2. MicroBridge... 2 3. YouTube tutorial video series

More information

How To Write A Program For The Web In Java (Java)

How To Write A Program For The Web In Java (Java) 21 Applets and Web Programming As noted in Chapter 2, although Java is a general purpose programming language that can be used to create almost any type of computer program, much of the excitement surrounding

More information

European Access Point for Truck Parking Data

European Access Point for Truck Parking Data Delegated Regulation (EU) N 885/2013 of 15 May 2013 with regard to the provision of information services for safe and secure parking places for trucks and commercial vehicles European Access Point for

More information

Java from a C perspective. Plan

Java from a C perspective. Plan Java from a C perspective Cristian Bogdan 2D2052/ingint04 Plan Objectives and Book Packages and Classes Types and memory allocation Syntax and C-like Statements Object Orientation (minimal intro) Exceptions,

More information