01.02.2013 Views

Software Development Cross Solution - Index of - Free

Software Development Cross Solution - Index of - Free

Software Development Cross Solution - Index of - Free

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Apply the SRP to the Automobile class.<br />

Do an SRP analysis on the Automobile class shown below. Fill out the sheet<br />

with the class name methods in Automobile, like we’ve described on the last<br />

page. Then, decide if you think it makes sense for the Automobile class to<br />

have each method, and check the right box.<br />

SRP Analysis for<br />

Automobile<br />

+ start() :void<br />

+ stop() :void<br />

+ changeTires(tires : Tire[]) :void<br />

+ drive() :void<br />

+ wash() :void<br />

+ checkOil() :void<br />

+ getOil() :int<br />

Automobile<br />

The itself.<br />

The itself.<br />

The itself.<br />

The itself.<br />

The itself.<br />

The itself.<br />

The itself.<br />

Download at WoweBook.Com<br />

Follows<br />

SRP<br />

good-enough design<br />

Violates<br />

SRP<br />

If what you read doesn’t<br />

make sense, then the method<br />

on that line is probably<br />

violating the SRP.<br />

you are here 4 157

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!