Package org.milyn.scribe

Examples of org.milyn.scribe.NoMethodWithAnnotationFoundException


  public Object lookupByQuery(final String query, final Object ... parameters) {

    final LookupWithPositionalQueryMethod method = daoRuntimeInfo.getLookupByPositionalQueryMethod();

    if(method == null) {
      throw new NoMethodWithAnnotationFoundException("No method found in DAO class '" + dao.getClass().getName() + "' that is annotated " +
          "with '" + LookupByQuery.class.getSimpleName() + "' annotation and has an Array argument for the positional parameters.");
    }

    return method.invoke(dao, query, parameters);
View Full Code Here


  public Object lookupByQuery(final String query, final Map<String, ?> parameters) {

    final LookupWithNamedQueryMethod method = daoRuntimeInfo.getLookupByNamedQueryMethod();

    if(method == null) {
      throw new NoMethodWithAnnotationFoundException("No method found in DAO class '" + dao.getClass().getName() + "' that is annotated " +
          "with '" + LookupByQuery.class.getSimpleName() + "' annotation and has a Map argument for the named parameters.");
    }

    return method.invoke(dao, query, parameters);
  }
View Full Code Here

  }

  private void assertMethod(final Object method, final Class<?> annotation) {

    if(method == null) {
      throw new NoMethodWithAnnotationFoundException("No method found in DAO class '" + dao.getClass().getName() + "' that is annotated with the '" + annotation.getSimpleName() + "' annotation.");
    }

  }
View Full Code Here

  }

  private void assertMethod(final Object method, String name, final Class<?> annotation) {

    if(method == null) {
      throw new NoMethodWithAnnotationFoundException("No method found in DAO class '" + dao.getClass().getName() + "' that is annotated with the '" + annotation.getSimpleName() + "' annotation and has the name '"+ name +"'.");
    }

  }
View Full Code Here

TOP

Related Classes of org.milyn.scribe.NoMethodWithAnnotationFoundException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.