Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * Write a description of class PointNode here.
- *
- * @author (Liron Mor-Yosef)
- * @version (22/06/17)
- */
- public class PointNode
- {
- // instance variables
- private Point _point;
- private PointNode _next;
- /**
- * 1st consturct
- */
- public PointNode(Point p)
- {
- _point = new Point(p) ;
- _next = null;
- }
- /**
- * second construct
- */
- public PointNode (Point p, PointNode n){
- _point = p;
- _next = n ;
- }
- /**
- *
- * copy constructor
- */
- public PointNode (PointNode p) {
- _point = p._point;
- _next = p; // הצבעה על P
- }
- /**
- *
- *
- */
- public Point getPoint(){
- return new Point (_point);
- }
- /**
- *
- *
- *
- */
- public PointNode getNext(){
- return _next;
- }
- /**
- *
- *
- *
- */
- public void setPoint(Point p) {
- _point = p ;
- }
- /**
- *
- *
- */
- public void setNext(PointNode next){
- _next = next;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement