class
Bindgen::FindPath::VersionChecker
- Bindgen::FindPath::VersionChecker
- Bindgen::FindPath::Checker
- Reference
- Object
Overview
Checker for a VersionCheck. This is a special checker. It can't be
instantiated in the PathConfig#checks array, but only through
PathConfig#version.
Defined in:
bindgen/find_path/version_checker.crConstant Summary
-
HIGHEST_POSSIBLE =
"~" -
LOWEST_POSSIBLE =
" "
Constructors
Instance Method Summary
-
#best_candidate : String | Nil
Returns the best checked candidate
-
#candidates : Array({String, String})
Stores all candidates
-
#check(path : String) : Bool
Checks path by its
#version_of. -
#sorted_candidates : Array(Tuple(String, String))
Returns the list of sorted candidates, from the best candidate first down to worse candidates.
-
#version_of(path : String) : String | Nil
Returns the version of path: the capture of the configured regex on path, or on the output of the configured shell command with path expanded into it.
Instance methods inherited from class Bindgen::FindPath::Checker
check(path : String) : Bool
check
Constructor methods inherited from class Bindgen::FindPath::Checker
create(config, is_file) : Checker
create
Constructor Detail
Instance Method Detail
Checks path by its #version_of. Only succeeds if a version was
found and is in the configured range, or if the fallback accepts it.
Returns the list of sorted candidates, from the best candidate first down to worse candidates.
Returns the version of path: the capture of the configured regex on
path, or on the output of the configured shell command with path
expanded into it. STDOUT is hidden, but STDERR is shown. Returns
nil if the command failed, or nothing matched.