TopologyException.js 399 B

12345678910111213
  1. import Coordinate from './Coordinate'
  2. import RuntimeException from '../../../../java/lang/RuntimeException'
  3. export default class TopologyException extends RuntimeException {
  4. constructor(msg, pt) {
  5. super(pt ? msg + ' [ ' + pt + ' ]' : msg)
  6. this.pt = pt ? new Coordinate(pt) : undefined
  7. this.name = Object.keys({ TopologyException })[0]
  8. }
  9. getCoordinate() {
  10. return this.pt
  11. }
  12. }