public abstract class Point<T extends Point<T>> extends Object implements Comparable<Point<T>>
Modifier | Constructor and Description |
---|---|
protected |
Point(int x,
int y,
int type) |
Modifier and Type | Method and Description |
---|---|
abstract T |
add(T other) |
int |
compareTo(Point o) |
abstract T |
divide(int divisor) |
boolean |
equals(Object o) |
int |
getApproxDistance(T point) |
double |
getDistance(T point) |
double |
getLength() |
int |
getX() |
int |
getY() |
int |
hashCode() |
boolean |
isValid(Game game)
Check if the current point is a valid point for the current game
|
abstract T |
multiply(int multiplier) |
abstract T |
subtract(T other) |
String |
toString() |
public int getX()
public int getY()
public double getLength()
public double getDistance(T point)
public int getApproxDistance(T point)
public abstract T divide(int divisor)
public abstract T multiply(int multiplier)
public boolean isValid(Game game)
Copyright © 2022. All rights reserved.