@implementation Circle 表示将为circle类提供代码。类名出现在@implementation之后。
- (void) setFillColor:(ShapeColor) c setFillColor:这行与@interface部分的声明非常类似,区别在于结尾处没有分号。
{
fillcolor = c;
} // setFillColor
-(void) setBounds: (shapeRect) b
{
bounds = b;
} // setBounds 这几行代码用于设置圆形对象的边界区域,圆形对象将被绘制在参数接收的矩形区
-(void) draw draw后面没有冒号,说明它不使用任何参数
{
NSLog (@ "drawing a circle at (%d %d %d %d) in %@" ,
bounds.x, bounds.y,
bounds.width, bounds.height,
colorName(fillColor));
}// draw