skip to content
Objects first with Java : a practical introduction using BlueJ Preview this item
ClosePreview this item
Checking...

Objects first with Java : a practical introduction using BlueJ

Author: David J Barnes; Michael Kölling
Publisher: Upper Saddle River, N.J. ; Harlow : Pearson Education, 2011.
Edition/Format:   Print book : English : 5th ed., International edView all editions and formats
Database:WorldCat
Summary:

This introductory programming textbook integrates BlueJ with Java. It provides a thorough treatment of object-oriented principles.

Rating:

(not yet rated) 0 with reviews - Be the first.

Subjects
More like this

 

Find a copy in the library

&AllPage.SpinnerRetrieving; Finding libraries that hold this item...

Details

Document Type: Book
All Authors / Contributors: David J Barnes; Michael Kölling
ISBN: 9780132835541 0132835541
OCLC Number: 804687285
Notes: Índex.
Description: xxvi, 546 p. ; 24 cm
Contents: Foreword xiiiPreface xivList of projects discussed in detailin this book xxiiiAcknowledgments xxvPart 1 Foundations of object orientation 1Chapter 1 Objects and classes 31.1 Objects and classes 31.2 Creating objects 41.3 Calling methods 51.4 Parameters 61.5 Data types 71.6 Multiple instances 81.7 State 81.8 What is in an object? 91.9 Java code 101.10 Object interaction 121.11 Source code 121.12 Another example 141.13 Return values 141.14 Objects as parameters 141.15 Summary 16Chapter 2 Understanding class definitions 182.1 Ticket machines 182.1.1 Exploring the behavior of a naive ticket machine 192.2 Examining a class definition 202.3 The class header 222.3.1 Keywords 232.4 Fields, constructors, and methods 232.4.1 Fields 242.4.2 Constructors 272.5 Parameters: receiving data 282.5.1 Choosing variable names 302.6 Assignment 302.7 Methods 312.8 Accessor and mutator methods 332.9 Printing from methods 362.10 Method summary 382.11 Summary of the naive ticket machine 382.12 Reflecting on the design of the ticket machine 392.13 Making choices: the conditional statement 422.14 A further conditional-statement example 442.15 Scope highlighting 452.16 Local variables 462.17 Fields, parameters, and local variables 482.18 Summary of the better ticket machine 492.19 Self-review exercises 502.20 Reviewing a familiar example 512.21 Calling methods 542.22 Experimenting with expressions: the Code Pad 552.23 Summary 58Chapter 3 Object interaction 623.1 The clock example 623.2 Abstraction and modularization 633.3 Abstraction in software 643.4 Modularization in the clock example 643.5 Implementing the clock display 653.6 Class diagrams versus object diagrams 663.7 Primitive types and object types 673.8 The ClockDisplay source code 673.8.1 Class NumberDisplay 683.8.2 String concatenation 723.8.3 The modulo operator 733.8.4 Class ClockDisplay 733.9 Objects creating objects 773.10 Multiple constructors 783.11 Method calls 793.11.1 Internal method calls 793.11.2 External method calls 793.11.3 Summary of the clock display 813.12 Another example of object interaction 813.12.1 The mail-system example 823.12.2 The this keyword 833.13 Using a debugger 853.13.1 Setting breakpoints 853.13.2 Single stepping 873.13.3 Stepping into methods 883.14 Method calling revisited 883.15 Summary 89Chapter 4 Grouping objects 924.1 Building on themes from Chapter 3 924.2 The collection abstraction 934.3 An organizer for music files 944.4 Using a library class 954.4.1 Importing a library class 974.4.2 Diamond notation 984.4.3 Key methods of ArrayList 984.5 Object structures with collections 984.6 Generic classes 1004.7 Numbering within collections 1014.7.1 The effect of removal on numbering 1024.7.2 The general utility of numbering with collections 1034.8 Playing the music files 1044.8.1 Summary of the music organizer 1064.9 Processing a whole collection 1064.9.1 The for-each loop 1074.9.2 Selective processing of a collection 1094.9.3 A limitation of using strings 1114.9.4 Summary of the for-each loop 1114.10 Indefinite iteration 1124.10.1 The while loop 1124.10.2 Iterating with an index variable 1144.10.3 Searching a collection 1154.10.4 Some non-collection examples 1184.11 Improving structure-the Track class 1194.12 The Iterator type 1224.12.1 Index access versus iterators 1244.12.2 Removing elements 1254.13 Summary of the music-organizer project 1264.14 Another example: An auction system 1284.14.1 Getting started with the project 1294.14.2 The null keyword 1304.14.3 The Lot class 1304.14.4 The Auction class 1314.14.5 Anonymous objects 1344.14.6 Chaining method calls 1354.14.7 Using collections 1364.15 Flexible-collection summary 1384.16 Fixed-size collections 1394.16.1 A log-file analyzer 1394.16.2 Declaring array variables 1424.16.3 Creating array objects 1424.16.4 Using array objects 1444.16.5 Analyzing the log file 1444.16.6 The for loop 1454.16.7 Arrays and the for-each loop 1474.16.8 The for loop and iterators 1484.17 Summary 150Chapter 5 More-sophisticated behavior 1535.1 Documentation for library classes 1545.2 The TechSupport system 1555.2.1 Exploring the TechSupport system 1555.2.2 Reading the code 1575.3 Reading class documentation 1605.3.1 Interfaces versus implementation 1625.3.2 Using library-class methods 1635.3.3 Checking string equality 1655.4 Adding random behavior 1665.4.1 The Random class 1665.4.2 Random numbers with limited range 1675.4.3 Generating random responses 1685.4.4 Reading documentation for parameterized classes 1715.5 Packages and import 1715.6 Using maps for associations 1725.6.1 The concept of a map 1735.6.2 Using a HashMap 1735.6.3 Using a map for the TechSupport system 1755.7 Using sets 1775.8 Dividing strings 1785.9 Finishing the TechSupport system 1795.10 Writing class documentation 1815.10.1 Using javadoc in BlueJ 1825.10.2 Elements of class documentation 1825.11 Public versus private 1835.11.1 Information hiding 1845.11.2 Private methods and public fields 1855.12 Learning about classes from their interfaces 1865.12.1 The scribble demo 1865.12.2 Code completion 1895.12.3 The bouncing-balls demo 1905.13 Class variables and constants 1905.13.1 The static keyword 1915.13.2 Constants 1925.14 Summary 193Chapter 6 Designing classes 1966.1 Introduction 1976.2 The world-of-zuul game example 1986.3 Introduction to coupling and cohesion 2006.4 Code duplication6.5 Making extensions 2046.5.1 The task 2056.5.2 Finding the relevant source code 2056.6 Coupling 2076.6.1 Using encapsulation to reduce coupling 2076.7 Responsibility-driven design 2126.7.1 Responsibilities and coupling 2126.8 Localizing change 2146.9 Implicit coupling 2156.10 Thinking ahead 2186.11 Cohesion 2196.11.1 Cohesion of methods 2196.11.2 Cohesion of classes 2206.11.3 Cohesion for readability 2216.11.4 Cohesion for reuse 2216.12 Refactoring 2226.12.1 Refactoring and testing 2236.12.2 An example of refactoring 2236.13 Refactoring for language independence 2266.13.1 Enumerated types 2276.13.2 Further decoupling of the command interface 2296.14 Design guidelines 2316.15 Executing without BlueJ 2326.15.1 Class methods 2326.15.2 The main method 2336.15.3 Limitations in class methods 2346.16 Summary 234Chapter 7 Well-behaved objects 2367.1 Introduction 2367.2 Testing and debugging 2377.3 Unit testing within BlueJ 2377.3.1 Using inspectors 2437.3.2 Positive versus negative testing 2457.4 Test automation 2457.4.1 Regression testing 2457.4.2 Automated testing using JUnit 2467.4.3 Recording a test 2487.4.4 Fixtures 2517.5 Debugging 2527.6 Commenting and style 2547.7 Manual walkthroughs 2557.7.1 A high-level walkthrough 2557.7.2 Checking state with a walkthrough 2577.7.3 Verbal walkthroughs 2607.8 Print statements 2607.8.1 Turning debugging information on or off 2627.9 Debuggers 2637.10 Choosing a debugging strategy 2657.11 Putting the techniques into practice 2657.12 Summary 265Part 2 Application structures 267Chapter 8 Improving structure with inheritance 2698.1 The network example 2698.1.1 The network project: classes and objects 2708.1.2 Network source code 2738.1.3 Discussion of the network application 2828.2 Using inheritance 2828.3 Inheritance hierarchies 2848.4 Inheritance in Java 2858.4.1 Inheritance and access rights 2868.4.2 Inheritance and initialization 2868.5 Network: adding other post types 2888.6 Advantages of inheritance (so far) 2908.7 Subtyping 2918.7.1 Subclasses and subtypes 2938.7.2 Subtyping and assignment 2938.7.3 Subtyping and parameter passing 2958.7.4 Polymorphic variables 2958.7.5 Casting 2968.8 The Object class 2978.9 Autoboxing and wrapper classes 2988.10 The collection hierarchy 2998.11 Summary 299Chapter 9 More about inheritance 3029.1 The problem: network's display method 3029.2 Static type and dynamic type 3049.2.1 Calling display from NewsFeed 3059.3 Overriding 3079.4 Dynamic method lookup 3099.5 Super call in methods 3119.6 Method polymorphism 3139.7 Object methods: toString 3139.8 Object equality: equals and hashCode 3169.9 Protected access 3189.10 The instanceof operator 3209.11 Another example of inheritance with overriding 3219.12 Summary 323Chapter 10 Further abstraction techniques 32610.1 Simulations 32610.2 The foxes-and-rabbits simulation 32710.2.1 The foxes-and-rabbits project 32810.2.2 The Rabbit class 33110.2.3 The Fox class 33410.2.4 The Simulator class: setup 33710.2.5 The Simulator class: a simulation step 34110.2.6 Taking steps to improve the simulation 34210.3 Abstract classes 34210.3.1 The Animal superclass 34310.3.2 Abstract methods 34410.3.3 Abstract classes 34610.4 More abstract methods 34810.5 Multiple inheritance 35110.5.1 An Actor class 35110.5.2 Flexibility through abstraction 35310.5.3 Selective drawing 35310.5.4 Drawable actors: multiple inheritance 35410.6 Interfaces 35410.6.1 An Actor interface 35510.6.2 Multiple inheritance of interfaces 35610.6.3 Interfaces as types 35710.6.4 Interfaces as specifications 35810.6.5 Library support through abstract classes and interfaces 35910.7 A further example of interfaces 35910.8 The Class class 36110.9 Abstract class or interface? 36210.10 Event-driven simulations 36210.11 Summary of inheritance 36310.12 Summary 364Chapter 11 Building graphical user interfaces 36711.1 Introduction 36711.2 Components, layout, and event handling 36811.3 AWT and Swing 36811.4 The ImageViewer example 36911.4.1 First experiments: creating a frame 36911.4.2 Adding simple components 37211.4.3 An alternative structure 37311.4.4 Adding menus 37411.4.5 Event handling 37511.4.6 Centralized receipt of events 37611.4.7 Inner classes 37811.4.8 Anonymous inner classes 38011.4.9 Summary of key GUI elements 38211.5 ImageViewer 1.0: the first complete version 38311.5.1 Image-processing classes 38311.5.2 Adding the image 38411.5.3 Layout 38611.5.4 Nested containers 38911.5.5 Image filters 39111.5.6 Dialogs 39411.5.7 Summary of layout management 39611.6 ImageViewer 2.0: improving program structure 39611.7 ImageViewer 3.0: more interface components 40211.7.1 Buttons 40211.7.2 Borders 40511.8 Further extensions 40611.9 Another example: MusicPlayer 40811.10 Summary 411Chapter 12 Handling errors 41312.1 The address-book project 41412.2 Defensive programming 41812.2.1 Client-server interaction 41812.2.2 Parameter checking 42012.3 Server-error reporting 42112.3.1 Notifying the user 42212.3.2 Notifying the client object 42212.4 Exception-throwing principles 42512.4.1 Throwing an exception 42612.4.2 Checked and unchecked exceptions 42612.4.3 The effect of an exception 42812.4.4 Using unchecked exceptions 42912.4.5 Preventing object creation 43012.5 Exception handling 43112.5.1 Checked exceptions: the throws clause 43212.5.2 Anticipating exceptions: the try statement 43212.5.3 Throwing and catching multiple exceptions 43412.5.4 Multi-catch Java 7 43612.5.5 Propagating an exception 43612.5.6 The finally clause 43712.6 Defining new exception classes 43812.7 Using assertions 44012.7.1 Internal consistency checks 44012.7.2 The assert statement 44012.7.3 Guidelines for using assertions 44212.7.4 Assertions and the BlueJ unit testing framework 44312.8 Error recovery and avoidance 44312.8.1 Error recovery 44312.8.2 Error avoidance 44512.9 File-based input/output 44612.9.1 Readers, writers, and streams 44712.9.2 The File class and Path interface 44712.9.3 File output 44812.9.4 The try-with-resource statement 45012.9.5 Text input 45212.9.6 Scanner: parsing input 45512.9.7 Object serialization 45712.10 Summary 458Chapter 13 Designing applications 46013.1 Analysis and design 46013.1.1 The verb/noun method 46113.1.2 The cinema booking example 46113.1.3 Discovering classes 46113.1.4 Using CRC cards 46313.1.5 Scenarios 46313.2 Class design 46713.2.1 Designing class interfaces 46713.2.2 User interface design 46813.3 Documentation 46913.4 Cooperation 46913.5 Prototyping 47013.6 Software growth 47013.6.1 Waterfall model 47113.6.2 Iterative development 47113.7 Using design patterns 47213.7.1 Structure of a pattern 47313.7.2 Decorator 47413.7.3 Singleton 47413.7.4 Factory method 47513.7.5 Observer 47613.7.6 Pattern summary 47713.8 Summary 478Chapter 14 A case study 48014.1 The case study 48014.1.1 The problem description 48014.2 Analysis and design 48114.2.1 Discovering classes 48114.2.2 Using CRC cards 48214.2.3 Scenarios 48314.3 Class design 48514.3.1 Designing class interfaces 48514.3.2 Collaborators 48514.3.3 The outline implementation 48614.3.4 Testing 49014.3.5 Some remaining issues 49014.4 Iterative development 49114.4.1 Development steps 49114.4.2 A first stage 49214.4.3 Testing the first stage 49614.4.4 A later stage of development 49614.4.5 Further ideas for development 49814.4.6 Reuse 49914.5 Another example 49914.6 Taking things further 499AppendicesA Working with a BlueJ project 500B Java data types 503C Operators 507D Java control structures 510E Running Java without BlueJ 517F Using the debugger 520G Unit unit-testing tools 524H Teamwork tools 526I Javadoc 528J Program style guide 531K Important library classes 535Index 539
Other Titles: Practical introduction using BlueJ
Responsibility: David J. Barnes, Michael Kolling.

Reviews

User-contributed reviews
Retrieving GoodReads reviews...
Retrieving DOGObooks reviews...

Tags

Be the first.
Confirm this request

You may have already requested this item. Please select Ok if you would like to proceed with this request anyway.

Linked Data


Primary Entity

<http://www.worldcat.org/oclc/804687285> # Objects first with Java : a practical introduction using BlueJ
    a schema:Book, schema:CreativeWork ;
   library:oclcnum "804687285" ;
   library:placeOfPublication <http://id.loc.gov/vocabulary/countries/nju> ;
   library:placeOfPublication <http://experiment.worldcat.org/entity/work/data/867325320#Place/harlow> ; # Harlow
   library:placeOfPublication <http://experiment.worldcat.org/entity/work/data/867325320#Place/upper_saddle_river_n_j> ; # Upper Saddle River, N.J.
   schema:about <http://experiment.worldcat.org/entity/work/data/867325320#Topic/java_llenguatge_de_programacio> ; # Java (Llenguatge de programació)
   schema:about <http://experiment.worldcat.org/entity/work/data/867325320#Topic/programacio_orientada_a_l_objecte_informatica> ; # Programació orientada a l'objecte (Informàtica)
   schema:alternateName "Practical introduction using BlueJ" ;
   schema:bookEdition "5th ed., International ed." ;
   schema:bookFormat bgn:PrintBook ;
   schema:contributor <http://experiment.worldcat.org/entity/work/data/867325320#Person/kolling_michael> ; # Michael Kölling
   schema:creator <http://experiment.worldcat.org/entity/work/data/867325320#Person/barnes_david_j_david_john_1959_june_7> ; # David John Barnes
   schema:datePublished "2011" ;
   schema:exampleOfWork <http://worldcat.org/entity/work/id/867325320> ;
   schema:inLanguage "en" ;
   schema:name "Objects first with Java : a practical introduction using BlueJ" ;
   schema:numberOfPages "546" ;
   schema:productID "804687285" ;
   schema:publication <http://www.worldcat.org/title/-/oclc/804687285#PublicationEvent/upper_saddle_river_n_j_harlow_pearson_education_2011> ;
   schema:publisher <http://experiment.worldcat.org/entity/work/data/867325320#Agent/pearson_education> ; # Pearson Education
   schema:workExample <http://worldcat.org/isbn/9780132835541> ;
   wdrs:describedby <http://www.worldcat.org/title/-/oclc/804687285> ;
    .


Related Entities

<http://experiment.worldcat.org/entity/work/data/867325320#Agent/pearson_education> # Pearson Education
    a bgn:Agent ;
   schema:name "Pearson Education" ;
    .

<http://experiment.worldcat.org/entity/work/data/867325320#Person/barnes_david_j_david_john_1959_june_7> # David John Barnes
    a schema:Person ;
   schema:birthDate "1959 June 7" ;
   schema:familyName "Barnes" ;
   schema:givenName "David John" ;
   schema:givenName "David J." ;
   schema:name "David John Barnes" ;
    .

<http://experiment.worldcat.org/entity/work/data/867325320#Person/kolling_michael> # Michael Kölling
    a schema:Person ;
   schema:familyName "Kölling" ;
   schema:givenName "Michael" ;
   schema:name "Michael Kölling" ;
    .

<http://experiment.worldcat.org/entity/work/data/867325320#Place/upper_saddle_river_n_j> # Upper Saddle River, N.J.
    a schema:Place ;
   schema:name "Upper Saddle River, N.J." ;
    .

<http://experiment.worldcat.org/entity/work/data/867325320#Topic/java_llenguatge_de_programacio> # Java (Llenguatge de programació)
    a schema:Intangible ;
   schema:name "Java (Llenguatge de programació)" ;
    .

<http://experiment.worldcat.org/entity/work/data/867325320#Topic/programacio_orientada_a_l_objecte_informatica> # Programació orientada a l'objecte (Informàtica)
    a schema:Intangible ;
   schema:name "Programació orientada a l'objecte (Informàtica)" ;
    .

<http://worldcat.org/isbn/9780132835541>
    a schema:ProductModel ;
   schema:isbn "0132835541" ;
   schema:isbn "9780132835541" ;
    .


Content-negotiable representations

Close Window

Please sign in to WorldCat 

Don't have an account? You can easily create a free account.