|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jbehave.core.io.StoryFinder
public class StoryFinder
Finds stories by scanning file system. Stories can be either in the form of embeddable class names or story paths.
Constructor Summary | |
---|---|
StoryFinder()
|
|
StoryFinder(Comparator<? super String> sortingComparator)
|
|
StoryFinder(String classNameExtension)
|
Method Summary | |
---|---|
protected String |
classNameExtension()
|
protected List<String> |
classNames(List<String> paths)
|
List<String> |
findClassNames(String searchInDirectory,
List<String> includes,
List<String> excludes)
Finds java source paths from a base directory, allowing for includes/excludes, and converts them to class names. |
List<String> |
findPaths(String searchInDirectory,
List<String> includes,
List<String> excludes)
Finds paths from a base directory, allowing for includes/excludes. |
List<String> |
findPaths(String searchInDirectory,
List<String> includes,
List<String> excludes,
String prefixWith)
Finds paths from a base directory, allowing for includes/excludes. |
List<String> |
findPaths(URL searchInURL,
String include,
String exclude)
Finds paths from a base URL, allowing for single include/exclude pattern. |
protected List<String> |
normalise(List<String> paths)
|
protected List<String> |
prefix(String prefixWith,
List<String> paths)
|
protected List<String> |
scan(String basedir,
List<String> includes,
List<String> excludes)
|
protected List<String> |
sort(List<String> input)
|
protected Comparator<? super String> |
sortingComparator()
Comparator used for sorting. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StoryFinder()
public StoryFinder(String classNameExtension)
public StoryFinder(Comparator<? super String> sortingComparator)
Method Detail |
---|
public List<String> findClassNames(String searchInDirectory, List<String> includes, List<String> excludes)
searchInDirectory
- the base directory path to search inincludes
- the List of include patterns, or null
if noneexcludes
- the List of exclude patterns, or null
if none
public List<String> findPaths(URL searchInURL, String include, String exclude)
StoryFinder#normalise(List)
.
searchInURL
- the base URL to search ininclude
- the include pattern, or ""
if noneexclude
- the exclude pattern, or ""
if none
public List<String> findPaths(String searchInDirectory, List<String> includes, List<String> excludes)
StoryFinder#normalise(List)
.
searchInDirectory
- the base directory path to search inincludes
- the List of include patterns, or null
if noneexcludes
- the List of exclude patterns, or null
if none
public List<String> findPaths(String searchInDirectory, List<String> includes, List<String> excludes, String prefixWith)
StoryFinder#prefix(String, List)
and normalised by StoryFinder#normalise(List)
.
searchInDirectory
- the base directory path to search inincludes
- the List of include patterns, or null
if noneexcludes
- the List of exclude patterns, or null
if noneprefixWith
- the root path prefixed to all paths found, or
null
if none
protected List<String> normalise(List<String> paths)
protected List<String> prefix(String prefixWith, List<String> paths)
protected List<String> classNames(List<String> paths)
protected String classNameExtension()
protected List<String> sort(List<String> input)
protected Comparator<? super String> sortingComparator()
null
comparator means
that Collections#sort()
will use natural ordering.
null
for natural ordering.protected List<String> scan(String basedir, List<String> includes, List<String> excludes)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |