WOD3: Rectangle Class with Outline

So far we have created a Circle, Square, and Rectangle class. Next we’ll update your Rectangle class by adding support for an outline color.

Rx: <10 min Av: 10-20 min Sd: 20-30 min DNF: 31+ min

Instructions

  1. Write down your start time on your notecard.
  2. If you haven’t been following along, download the Shapes Project and import it into your workspace.
  3. Add a new field, outlineColor, to the Rectangle class.
  4. Update the constructors to support the outline. You should have 3 constructors:
    • Default constructor (no parameters)
    • Constructor with 5 parameters (no outlineColor)
    • Constructor with 6 parameters (one for each field)
  5. Add get & set methods for the outline color.
  6. Update the paint method to draw the outline.
  7. Test your Rectangle changes in Picture.
  8. Run the program to verify your changes.
  9. Export your program by right-clicking on your project folder, and selecting Export > General > Archive File. Name the file RectangleOutline_uLogin.zip.
  10. Upload the file to the assignment page on canvas.
  11. Write down your stop time on your notecard.