TelevisionDemo copy 76 -...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
//This class demonstrates the Television class import  java.util.Scanner; //Amir  poudel //COSC 1437.8001 //Television class for lab 3, store in Lab3_apoudel class  Television { //Task #1 step 1 and step 2 private  String  MANUFACTURER  =  "Toshiba" ; //The maker of the TV private   int   SCREEN_SIZE ; //size of the TV //Task #1 step 3 and step 4 private   boolean   powerOn ; // private   int   channel ; // private   int   volume ; // //Task#2 step 1 - constructor public  Television(String brand,  int  size) { //Task#2 step 2 MANUFACTURER  = brand; SCREEN_SIZE  = size; //Task@ step 3 powerOn  =  false ; volume  = 20; channel  = 2; } //Task #3 step 2 - mutator setChannel public   void  setChannel( int  station) { channel  = station; } //Task#3 - return the volume public   int  getVolume() { return   volume ; } public   int  getChannel() { return   channel ; } public  String getManufacturer()
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
{ return
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 10/26/2011 for the course COSC-1437 lab4 taught by Professor Dandao during the Spring '11 term at Richland Community College.

Page1 / 3

TelevisionDemo copy 76 -...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online