Collaborative sketch editor
A Java client/server drawing application.

Shape model
The shared Sketch maps sequential integer IDs to Shape instances. Rectangle, Ellipse, Segment, and Polyline each implement drawing, hit testing, movement, color access, and a text form that can be sent over the network.
Server-side coordination
SketchServer accepts clients, creates one communicator thread per connection, and broadcasts each edit to all connected clients. Its update method parses draw, move, recolor, and delete messages before changing the shared sketch. Synchronized Sketch methods make additions and removals atomic. In the local loopback capture, two socket clients both received five broadcasts: two draws, a move, a recolor, and a delete.
Rendering a shared state
The capture then sends move, recolor, and delete commands across the same two local clients. Both clients received each update, and the original server's shared Sketch was rendered off-screen with the project’s own draw methods. The final state contains the moved, recolored ellipse after the rectangle is deleted.
