code: public void setPageCount(int pageN) {
          this.pageN = pageN;
          DocListener listener;
  		for (Iterator iterator = listeners.iterator(); iterator.hasNext();) {
              listener = (DocListener) iterator.next();
              listener.setPageCount(pageN);
          }
      }
docs: Sets the page number.
  
  @param pageN
  the new page number