0
Under review

SquarePegAdapter 没有提供父类的默认构造方法

louis cai 5 months ago updated by anonymous 4 months ago 1
没有提供父类的默认构造方法
public class SquarePegAdapter extends RoundPeg {
    private SquarePeg peg;

    public SquarePegAdapter(SquarePeg peg) {
        this.peg = peg;
    }

    @Override
    public double getRadius() {
        double result;
        // Calculate a minimum circle radius, which can fit this peg.
        result = (Math.sqrt(Math.pow((peg.getWidth() / 2), 2) * 2));
        return result;
    }
}