pointcontainer.js 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. /**
  2. * 点集合容器
  3. */
  4. define(function(require, exports, module) {
  5. return require('../core/class').createClass('PointContainer', {
  6. base: require('./container'),
  7. constructor: function() {
  8. this.callBase();
  9. },
  10. addPoint: function(point, pos) {
  11. return this.addItem.apply(this, arguments);
  12. },
  13. prependPoint: function() {
  14. return this.prependItem.apply(this, arguments);
  15. },
  16. appendPoint: function() {
  17. return this.appendItem.apply(this, arguments);
  18. },
  19. removePoint: function(pos) {
  20. return this.removeItem.apply(this, arguments);
  21. },
  22. addPoints: function() {
  23. return this.addItems.apply(this, arguments);
  24. },
  25. setPoints: function() {
  26. return this.setItems.apply(this, arguments);
  27. },
  28. getPoint: function() {
  29. return this.getItem.apply(this, arguments);
  30. },
  31. getPoints: function() {
  32. return this.getItems.apply(this, arguments);
  33. },
  34. getFirstPoint: function() {
  35. return this.getFirstItem.apply(this, arguments);
  36. },
  37. getLastPoint: function() {
  38. return this.getLastItem.apply(this, arguments);
  39. }
  40. });
  41. });