System.out.print("Enter Point1 X: ");
int point1X = G51OOPInput.readInt();
System.out.print("Enter Point1 Y: ");
int point1Y = G51OOPInput.readInt();
System.out.print("Enter Point2 X: ");
int point2X = G51OOPInput.readInt();
System.out.print("Enter Point2 Y: ");
int point2Y = G51OOPInput.readInt();
MyPoint p1 = new MyPoint(point1X, point1Y);
MyPoint p2 = new MyPoint(point2X, point2Y);
MyLine line = new MyLine(p1, p2);
使用此代码,我收到一条错误消息:“无法实例化 MyLine 类型”,我不知道这意味着什么或如何修复它。请问有什么帮助吗?
那来自主文件,但 MyLine 的摘要在这里http://pastebin.com/3tRbgtge