Annotation Type UseClasspathSqlLocator


@Target({TYPE,METHOD}) @Retention(RUNTIME) public @interface UseClasspathSqlLocator
Configures SQL Object to locate SQL using the ClasspathSqlLocator.findSqlOnClasspath(Class, String) method. If the SQL annotation (e.g. @SqlQuery) defines a value (e.g. @SqlQuery("hello")), that value ("hello") will be used for the name parameter; if undefined, the name of the SQL object method will be used:
     @UseClasspathSqlLocator
     interface Viccini {
         @SqlUpdate
         void doTheThing(long id);     // => ClasspathSqlLocator.findSqlOnClasspath(Viccini.class, "doTheThing")

         @SqlUpdate("thatOtherThing")
         void doTheThing(String name); // => ClasspathSqlLocator.findSqlOnClasspath(Viccini.class, "thatOtherThing")
     }
 
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    boolean
     
  • Element Details

    • stripComments

      boolean stripComments
      Default:
      true