Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
chess
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Felicien IHIRWE
chess
Commits
1851c7c6
Commit
1851c7c6
authored
4 years ago
by
Luca Cristoforetti
Browse files
Options
Downloads
Patches
Plain Diff
Add new constructors to NameDistance checker
parent
4990f2b9
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
plugins/org.polarsys.chess.checkers/src/org/polarsys/chess/checkers/core/impl/NameDistance.java
+31
-3
31 additions, 3 deletions
...c/org/polarsys/chess/checkers/core/impl/NameDistance.java
with
31 additions
and
3 deletions
plugins/org.polarsys.chess.checkers/src/org/polarsys/chess/checkers/core/impl/NameDistance.java
+
31
−
3
View file @
1851c7c6
...
...
@@ -37,14 +37,14 @@ public class NameDistance extends Checker {
private
static
final
String
checkerName
=
"NameDistance"
;
/**
* Creates a name distance checker with default threshold
* Creates a name distance checker with default threshold
.
*/
public
NameDistance
()
{
super
(
checkerName
,
getTags
());
}
/**
* Creates a name distance checker with the given priority
* Creates a name distance checker with the given priority
.
* @param priority the priority
*/
public
NameDistance
(
int
priority
)
{
...
...
@@ -52,7 +52,7 @@ public class NameDistance extends Checker {
}
/**
* Creates a name distance checker with the given priority and threshold
* Creates a name distance checker with the given priority and threshold
.
* @param priority the priority
* @param threshold the threshold to use
*/
...
...
@@ -61,6 +61,34 @@ public class NameDistance extends Checker {
setThreshold
(
threshold
);
}
/**
* Constructor with explicit tags.
* @param tags the tags identifying this checker
*/
public
NameDistance
(
Set
<
String
>
tags
)
{
super
(
checkerName
,
tags
);
}
/**
* Constructor with explicit tags and priority.
* @param tags the tags identifying this checker
* @param priority the priority
*/
public
NameDistance
(
Set
<
String
>
tags
,
int
priority
)
{
super
(
checkerName
,
tags
,
priority
);
}
/**
* Constructor with explicit tags, priority and threshold.
* @param tags the tags identifying this checker
* @param priority the priority
* @param threshold the threshold to use
*/
public
NameDistance
(
Set
<
String
>
tags
,
int
priority
,
int
threshold
)
{
super
(
checkerName
,
tags
,
priority
);
setThreshold
(
threshold
);
}
private
static
Set
<
String
>
getTags
()
{
Set
<
String
>
tags
=
new
HashSet
<
String
>();
tags
.
add
(
"fast"
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment