1234567891011121314151617181920212223242526 |
- import VectorType from "../enum/VectorType.js";
- import Geometry from "./Geometry";
- export default class Point extends Geometry {
- constructor(position, vectorId) {
- super();
- this.x = null;
- this.y = null;
- this.parent = {};
- this.category = null;
- this.geoType = VectorType.Point;
- this.setId(vectorId);
- this.setPosition(position);
- }
- setPosition(position) {
- this.x = position.x;
- this.y = position.y;
- }
- //基准点:BasePoint
- setCategory(value) {
- this.category = value;
- }
- }
|