protectedtag2.js 237 B

1234567891011121314
  1. /** @protected {number} */
  2. var uidCounter = 1;
  3. /**
  4. * Unique ID generator.
  5. * @constructor
  6. */
  7. function UidGenerator() {}
  8. /** Generate a unique ID. */
  9. UidGenerator.prototype.generate = function generate() {
  10. return uidCounter++;
  11. };