Class FolderQuerySource
java.lang.Object
org.aksw.iguana.cc.query.source.QuerySource
org.aksw.iguana.cc.query.source.impl.FolderQuerySource
The FileSeparatorQuerySource reads queries from a folder with query files.
Each query contains one (multiline) query.
- Author:
- frensing
-
Field Summary
FieldsFields inherited from class org.aksw.iguana.cc.query.source.QuerySource
hashCode, path -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThis method returns all queries in the source as a list of Strings.getQuery(int index) This method returns the query at the given index.getQueryStream(int index) inthashCode()intsize()This method returns the amount of queries in the source.Methods inherited from class org.aksw.iguana.cc.query.source.QuerySource
getPath
-
Field Details
-
LOGGER
protected static final org.slf4j.Logger LOGGER -
files
-
-
Constructor Details
-
FolderQuerySource
- Throws:
IOException
-
-
Method Details
-
size
public int size()Description copied from class:QuerySourceThis method returns the amount of queries in the source.- Specified by:
sizein classQuerySource- Returns:
- the number of queries in the source
-
getQuery
Description copied from class:QuerySourceThis method returns the query at the given index.- Specified by:
getQueryin classQuerySource- Parameters:
index- the index of the query counted from the first query (in the first file)- Returns:
- String of the query
- Throws:
IOException- if the query could not be read
-
getQueryStream
- Specified by:
getQueryStreamin classQuerySource- Throws:
IOException
-
getAllQueries
Description copied from class:QuerySourceThis method returns all queries in the source as a list of Strings.- Specified by:
getAllQueriesin classQuerySource- Returns:
- List of Strings of all queries
- Throws:
IOException- if the queries could not be read
-
hashCode
public int hashCode()- Overrides:
hashCodein classQuerySource
-