Demonstrate your ability to ability to use java data , JAVA Programming

Purpose

Demonstrate your ability to ability to use Java data and control structures. Draw with the aid of conditionals and loops.

Background Thought

A note on comments: self-documenting code is a code feature to be striven for. The use of identifier names that have meaning within the context of the problems being solved goes a long way in this direction. Code that is not self-documenting for whatever reasons may be made clearer by appropriate comments inserted in the code.

"The most difficult feature of any programming language to master is the comment." - disgruntled maintenance programmer

"Where the comment and the code disagree, both should be assumed to be in error" - experienced maintenance programmer

Instructions/Design

Write a Java GUI application that displays a city skyline. Your program will contain three classes:

Note: Use the Splat example from Chapter 4; and the Bullseye and Boxes examples from Chapter 5 as guides.

1) A class called Building that represents a graphical depiction of a single building. Allow the parameters to the constructor to specify the building's width and height. You may choose the color of the building. Put this into a file named

Building.java

2) A class called SkylinePanel that instantiates and draws a skyline of building. Put this into a file named

SkylinePanel.java

3) A class called RandomSkyline that contains the main method and does not deal with building details. Instead, the main method sets up the frame for the program and uses it to display an instantiation of the SkylinePanel class. Put this into a file named

RandomSkyline.java

**Class details are given below

4) Additionally, you'll need to name your city. Use your own name(s).

Posted Date: 4/2/2013 3:03:17 AM | Location : United States







Related Discussions:- Demonstrate your ability to ability to use java data , Assignment Help, Ask Question on Demonstrate your ability to ability to use java data , Get Answer, Expert's Help, Demonstrate your ability to ability to use java data Discussions

Write discussion on Demonstrate your ability to ability to use java data
Your posts are moderated
Related Questions
Define enumeration? Enumeration is explained as values type that having of a set of named values. These values are constants and are called enumerators. An enumeration type is

Write a program called LandThePlane that calculates whether a plane successfully lands or not.   The program begins by prompting (asking) the user for the following details, in th

pls telme source code for Padovan String

Project Description: We need to develop software that has a database of players with the ability to delete and add players at will, once captured there can be a draw to set them

Find representative skyline points in to two dimensional data Project Description: Run skyline algorithm run representative skyline algorithm up to skyline algorithm (Affi

Binding is a method of associating or registering a name for a remote object that can be used at a later time to look up that remote object. A remote object can be linked with a na

What is PortableRemoteObject.narrow() method and what is used for?                Ans) Java RMI-IIOP gives a mechanism to narrow the the Object you have received from from your

You are part of a team creating a system to keep track of computer science books that a publisher is producing. Create a UML class diagram for a "computer science book". You must h

what are applets

Question 1: a) What is the meaning of an object-oriented programming? b) List eight simple types of data in Java c) Explain how objects and classes are closely related.