title: Call method in JPA
body: <p>I'm using ObjectDB with JPA. I would like to call myMethod(). For example:</p>
  
  <pre><code>entityManager.createQuery("SELECT ... FROM ... WHERE MyClass.myMethod() = 100")
  </code></pre>
  
  <p>Is it possible? Maybe any annotation is required before method in the class?</p>
  
  <pre><code>@Entity
  public class MyClass implements Serializable {
  
      @Basic 
      private int x;
  
      @Basic
      private int y;
  
      public int myMethod() {
          return x*1000+y;
      }
  }
  </code></pre>