Source: Scene/TileDiscardPolicy.js

  1. /*global define*/
  2. define([
  3. '../Core/DeveloperError'
  4. ], function(
  5. DeveloperError) {
  6. 'use strict';
  7. /**
  8. * A policy for discarding tile images according to some criteria. This type describes an
  9. * interface and is not intended to be instantiated directly.
  10. *
  11. * @alias TileDiscardPolicy
  12. * @constructor
  13. *
  14. * @see DiscardMissingTileImagePolicy
  15. * @see NeverTileDiscardPolicy
  16. */
  17. function TileDiscardPolicy(options) {
  18. DeveloperError.throwInstantiationError();
  19. }
  20. /**
  21. * Determines if the discard policy is ready to process images.
  22. * @function
  23. *
  24. * @returns {Boolean} True if the discard policy is ready to process images; otherwise, false.
  25. */
  26. TileDiscardPolicy.prototype.isReady = DeveloperError.throwInstantiationError;
  27. /**
  28. * Given a tile image, decide whether to discard that image.
  29. * @function
  30. *
  31. * @param {Image} image An image to test.
  32. * @returns {Boolean} True if the image should be discarded; otherwise, false.
  33. */
  34. TileDiscardPolicy.prototype.shouldDiscardImage = DeveloperError.throwInstantiationError;
  35. return TileDiscardPolicy;
  36. });