PolygonizeDirectedEdge.js 837 B

1234567891011121314151617181920212223242526272829303132333435
  1. import DirectedEdge from '../../planargraph/DirectedEdge'
  2. export default class PolygonizeDirectedEdge extends DirectedEdge {
  3. constructor() {
  4. super()
  5. PolygonizeDirectedEdge.constructor_.apply(this, arguments)
  6. }
  7. static constructor_() {
  8. this._edgeRing = null
  9. this._next = null
  10. this._label = -1
  11. const from = arguments[0], to = arguments[1], directionPt = arguments[2], edgeDirection = arguments[3]
  12. DirectedEdge.constructor_.call(this, from, to, directionPt, edgeDirection)
  13. }
  14. getNext() {
  15. return this._next
  16. }
  17. isInRing() {
  18. return this._edgeRing !== null
  19. }
  20. setRing(edgeRing) {
  21. this._edgeRing = edgeRing
  22. }
  23. setLabel(label) {
  24. this._label = label
  25. }
  26. getLabel() {
  27. return this._label
  28. }
  29. setNext(next) {
  30. this._next = next
  31. }
  32. getRing() {
  33. return this._edgeRing
  34. }
  35. }