title: No exception of type Exception can be thrown, an exception type must be a subclass of Throwable
body: <p>I was seaching this problem in other questions but still didn't figure out 
  what does exactly mean Throwable. Read a few articles about it (its superclas bla bla bla) but still don't know how to implement it. Forgot to mention i am new to java. Any advice would be gratefully accepted :D</p>
  
  <p>Here is the Exception class:</p>
  
  <pre><code>class Exception {
  private int pDen;
  private int pMes;
  private int kDen;
  private int kMes;
  
  public Exception(int pDen, int pMes, int kDen, int kMes) {
      super();
      this.pDen = pDen;
      this.pMes = pMes;
      this.kDen = kDen;
      this.kMes = kMes;
  }
  public void message()
  {
      System.out.println("Isklucok");
  }
  public void promena()
  {
      int tmpDen = 0;
      int tmpMes = 0;
      tmpDen = pDen;
      pDen = kDen;
      kDen = tmpDen;
      tmpMes = pMes;
      pMes = kMes;
      kMes = tmpMes;
  }
  </code></pre>
  
  <p>}</p>
  
  <p>And here is the code that i run in other class where shoud i catch my exception where is thrown.</p>
  
  <pre><code>try {
          if(pMes &gt; kMes)
          {
              throw new Exception(pDen,pMes,kDen,kMes);
          }
          else if(pMes == kMes)
              if(pDen &gt; kDen)
              {
                  throw new Exception(pDen,pMes,kDen,kMes);
              }
      }
      catch(Exception e)
      {
          e.message();
          e.promena();
      }
  </code></pre>