diff --git a/src/main/java/moe/nekojimi/musicsearcher/Query.java b/src/main/java/moe/nekojimi/musicsearcher/Query.java new file mode 100644 index 0000000..88fac19 --- /dev/null +++ b/src/main/java/moe/nekojimi/musicsearcher/Query.java @@ -0,0 +1,33 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package moe.nekojimi.musicsearcher; + +/** + * + * @author jim + */ +public class Query +{ + private String textSearch; + + public static Query fullText(String text) + { + Query query = new Query(); + query.setTextSearch(text); + return query; + } + + public String getTextSearch() + { + return textSearch; + } + + public void setTextSearch(String textSearch) + { + this.textSearch = textSearch; + } + +} diff --git a/src/main/java/moe/nekojimi/musicsearcher/QueryFieldUnsupportedException.java b/src/main/java/moe/nekojimi/musicsearcher/QueryFieldUnsupportedException.java new file mode 100644 index 0000000..0b3efa1 --- /dev/null +++ b/src/main/java/moe/nekojimi/musicsearcher/QueryFieldUnsupportedException.java @@ -0,0 +1,22 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package moe.nekojimi.musicsearcher; + +/** + * + * @author jim + */ +public class QueryFieldUnsupportedException extends RuntimeException +{ + private final String field; + + public QueryFieldUnsupportedException(String field) + { + super("Searcher doesn't support query field: " + field); + this.field = field; + } + +}