logoAcademy

Implementing setCounter

Learn how to implement the setCounter method.

Having seen how strings are stored in StringStore, its time for us to store integers with Counter. The thought process for this section can be defined as follows:

  • Define the storage hash for our counter
  • Implement StoreCounterValue, a helper function which acts like StoreString in the previous
  • Implement setCounter

On this page

No Headings