generic-object.js 669 B

1234567891011121314151617181920212223242526
  1. // iGeomJS
  2. // LInE
  3. import { identifier } from "../../application/identifier";
  4. export class GenericObject {
  5. constructor (id) {
  6. if (id == undefined) {
  7. this.id = identifier.next(); // app/core/application/identifier.js: next(): return this.number++;
  8. } else {
  9. this.id = id;
  10. identifier.setIdentifierNumber(id+1); // app/core/application/identifier.js: setIdentifierNumber(id): this.number = id;
  11. }
  12. this.elementClass;
  13. this.label = "";
  14. this.labelIgeom = "";
  15. this.dependentsOnThis = [];
  16. this.definitions = [];
  17. this.labelColor = "";
  18. this.defined = 1;
  19. this.color = -16776961;
  20. this.visible = true;
  21. }
  22. }