code: public void setTileFactory(TileFactory factory)
      {
          if (factory == null)
              throw new NullPointerException("factory must not be null");
  
          this.factory.removeTileListener(tileLoadListener);
          this.factory.dispose();
  
          this.factory = factory;
          this.setZoom(factory.getInfo().getDefaultZoomLevel());
  
          factory.addTileListener(tileLoadListener);
  
          repaint();
      }
docs: Set the current tile factory (must not be <code>null</code>)
  @param factory the new property value