Skip to content

Commit dd602eb

Browse files
committed
Issue #451: fix checkstyle violations
1 parent b860784 commit dd602eb

File tree

7 files changed

+128
-132
lines changed

7 files changed

+128
-132
lines changed

config/checkstyle_checks.xml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,7 @@
6767

6868
<!-- Miscellaneous -->
6969
<module name="NewlineAtEndOfFile"/>
70-
<module name="Translation">
71-
<property name="requiredTranslations" value="de, es, fi, fr, ja, pt, ru, tr, zh"/>
72-
</module>
70+
<module name="Translation"/>
7371
<module name="UniqueProperties"/>
7472
<module name="OrderedProperties" />
7573

net.sf.eclipsecs.branding/about.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ This software includes the following 3rd-party libraries:\n\
88
Checkstyle, licensed under LGPL 2.1. Visit https://checkstyle.org/\n\
99
Jakarta Commons Lang/IO, licensed under APL 2.0. Visit http://commons.apache.org/\n\
1010
DOM4J, licensed under BSD. Visit http://sourceforge.net/projects/dom4j/\n\
11-
JFreeChart, licensed under LGPL 3. Visit http://www.jfree.org/jfreechart/
11+
JFreeChart, licensed under LGPL 3. Visit http://www.jfree.org/jfreechart/

net.sf.eclipsecs.branding/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@
99
<artifactId>net.sf.eclipsecs.branding</artifactId>
1010
<packaging>eclipse-plugin</packaging>
1111
<name>eclipse-cs Branding Plugin</name>
12-
</project>
12+
</project>
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
Other.group = Other
2-
3-
Checker.name = Checker
4-
Checker.desc = Root module of every checkstyle configuration. Cannot be deleted.
5-
Checker.cacheFile = caches information about files that have checked ok; used to avoid repeated checks of the same files
61
Checker.basedir = base directory name; stripped off in messages about files
7-
Checker.localeCountry = locale country for messages
8-
Checker.localeLanguage = locale language for messages
2+
Checker.cacheFile = caches information about files that have checked ok; used to avoid repeated checks of the same files
93
Checker.charset = name of the file charset (Note: eclipse-cs plugin sets this property to the projects default charset)
4+
Checker.desc = Root module of every checkstyle configuration. Cannot be deleted.
105
Checker.fileExtensions = file extensions that are accepted (comma separated)
116
Checker.haltOnException = Controls whether exceptions should halt execution or not.
7+
Checker.localeCountry = locale country for messages
8+
Checker.localeLanguage = locale language for messages
9+
Checker.name = Checker
1210
Checker.tabWidth = number of expanded spaces for a tab character ('\t'); used in messages and Checks that print violations on files with tabs
1311

14-
TreeWalker.name = TreeWalker
12+
Other.group = Other
13+
1514
TreeWalker.desc = FileSetCheck TreeWalker checks individual Java source files and defines properties that are applicable to checking such files.
1615
TreeWalker.fileExtensions = file type extension to identify java files. Setting this property is typically only required if your java source code is preprocessed before compilation and the original files do not have the extension .java
16+
TreeWalker.name = TreeWalker
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
generateSourceBundle=false
21
bin.includes = META-INF/,\
32
docs/,\
43
toc.xml,\
54
plugin.xml
6-
7-
5+
generateSourceBundle=false

net.sf.eclipsecs.doc/src/main/resources/dtds/checkstyle-metadata_1_0.dtd

Lines changed: 100 additions & 100 deletions
Original file line numberDiff line numberDiff line change
@@ -8,138 +8,138 @@
88
-->
99

1010
<!--
11-
Root element for every metadata definition.
12-
-->
11+
Root element for every metadata definition.
12+
-->
1313
<!ELEMENT checkstyle-metadata (rule-group-metadata+)>
1414

1515

1616
<!--
17-
Used to specify a group of rules.
18-
19-
The 'name' attribute is used as display name and is translatable.
20-
21-
The 'priority' influences the order in which groups appear in the configuration editor.
22-
23-
The 'hidden' attribut can be used to hide an entire group.
24-
-->
17+
Used to specify a group of rules.
18+
19+
The 'name' attribute is used as display name and is translatable.
20+
21+
The 'priority' influences the order in which groups appear in the configuration editor.
22+
23+
The 'hidden' attribut can be used to hide an entire group.
24+
-->
2525
<!ELEMENT rule-group-metadata (description?,rule-metadata*)>
2626
<!ATTLIST rule-group-metadata
27-
name CDATA #REQUIRED
28-
priority CDATA #REQUIRED
29-
hidden (true|false) "false">
27+
name CDATA #REQUIRED
28+
priority CDATA #REQUIRED
29+
hidden (true|false) "false">
3030

3131
<!--
32-
Used to to provide a textual description for the element.
33-
The content might be translatable.
34-
-->
32+
Used to to provide a textual description for the element.
33+
The content might be translatable.
34+
-->
3535
<!ELEMENT description (#PCDATA)>
3636

3737

3838
<!--
39-
'rule-metadata' elements are used to define the metadata for a check (or filter) module.
40-
The 'name' attribute is used as display name and is translatable.
41-
42-
The 'internal-name' attribute defines the logical name of the module.
43-
44-
The 'parent' element defines if the module is a file set check (Checker as parent)
45-
or a regular 'TreeWalker' check.
46-
47-
The 'hasSeverity' attribute specifies if a module has a severity property that can be set.
48-
Some modules (like filters) have no severity property.
49-
50-
The 'hidden' attribute is used to hide a module, so it cannot be seen or
51-
configured in the configuration editor. This is only used for some special modules
52-
like FileContentsHolder. The attribut defaults to 'false'.
53-
54-
The 'deletable' attribute is used to specify if the module can be removed from the
55-
configuration via the configuration editor. This only makes sense for some
56-
special modules like Checker or TreeWalker, which must be present. Therefore
57-
this attribute default to 'false'.
58-
59-
The 'singleton' module is used to specify if the module should occur only once in
60-
a checkstyle configuration. This will be taken into account by the configuration editor.
61-
-->
39+
'rule-metadata' elements are used to define the metadata for a check (or filter) module.
40+
The 'name' attribute is used as display name and is translatable.
41+
42+
The 'internal-name' attribute defines the logical name of the module.
43+
44+
The 'parent' element defines if the module is a file set check (Checker as parent)
45+
or a regular 'TreeWalker' check.
46+
47+
The 'hasSeverity' attribute specifies if a module has a severity property that can be set.
48+
Some modules (like filters) have no severity property.
49+
50+
The 'hidden' attribute is used to hide a module, so it cannot be seen or
51+
configured in the configuration editor. This is only used for some special modules
52+
like FileContentsHolder. The attribut defaults to 'false'.
53+
54+
The 'deletable' attribute is used to specify if the module can be removed from the
55+
configuration via the configuration editor. This only makes sense for some
56+
special modules like Checker or TreeWalker, which must be present. Therefore
57+
this attribute default to 'false'.
58+
59+
The 'singleton' module is used to specify if the module should occur only once in
60+
a checkstyle configuration. This will be taken into account by the configuration editor.
61+
-->
6262
<!ELEMENT rule-metadata (alternative-name+,description?,property-metadata*,quickfix*)>
6363
<!ATTLIST rule-metadata
64-
name CDATA #REQUIRED
65-
internal-name NMTOKEN #REQUIRED
66-
parent NMTOKEN #REQUIRED
67-
hasSeverity (true|false) "true"
68-
hidden (true|false) "false"
69-
deletable (true|false) "true"
70-
singleton (true|false) "false">
64+
name CDATA #REQUIRED
65+
internal-name NMTOKEN #REQUIRED
66+
parent NMTOKEN #REQUIRED
67+
hasSeverity (true|false) "true"
68+
hidden (true|false) "false"
69+
deletable (true|false) "true"
70+
singleton (true|false) "false">
7171

7272

7373
<!--
74-
Every 'rule-metadata' element must have at least one 'alternative-name' child
75-
element, which describes under which name the module might occur in a configuration
76-
file as well. As you may know you can specify modules in a Checkstyle configuration
77-
file using the logical module name or the fully qualified class name.
78-
This means that this element is used to map the fully qualified module class name
79-
to this module.
80-
You are able to provide multiple alternative names, which might be useful if
81-
your package structure for your modules changed over time. In this case specify
82-
the old qualified class names for your module as 'alternative-name' element.
83-
The plugin is then able to load even Checkstyle configuration files where your old
84-
module names are used.
85-
-->
74+
Every 'rule-metadata' element must have at least one 'alternative-name' child
75+
element, which describes under which name the module might occur in a configuration
76+
file as well. As you may know you can specify modules in a Checkstyle configuration
77+
file using the logical module name or the fully qualified class name.
78+
This means that this element is used to map the fully qualified module class name
79+
to this module.
80+
You are able to provide multiple alternative names, which might be useful if
81+
your package structure for your modules changed over time. In this case specify
82+
the old qualified class names for your module as 'alternative-name' element.
83+
The plugin is then able to load even Checkstyle configuration files where your old
84+
module names are used.
85+
-->
8686
<!ELEMENT alternative-name EMPTY>
8787
<!ATTLIST alternative-name
88-
internal-name CDATA #REQUIRED>
88+
internal-name CDATA #REQUIRED>
8989

9090

9191
<!--
92-
'property-metadata' elements are used to describe the properties of a checkstyle
93-
module. Properties described this way can then be configured using the plugins
94-
configuration editor.
95-
96-
The 'name' attributes specifies the name of the property.
97-
98-
The 'datatype' attribute determines which kind of data the property contains.
99-
100-
The 'default-value' attribute is used to specify the default value of the property.
101-
102-
The 'override-default-value' attribute can be used to specify a default value that
103-
differs from the Checkstyle default. For instance this is used to provide different
104-
defaults for the logLoadError and suppressLoadError properties of the AbstractTypeAware checks.
105-
106-
Properties of data type 'MultiCheck' and 'SingleSelect' can (better must) be provided
107-
with an 'enumeration' child element which specifies the valid enumeration values for
108-
this property.
109-
-->
110-
<!ELEMENT property-metadata (description?,enumeration?)>
92+
'property-metadata' elements are used to describe the properties of a checkstyle
93+
module. Properties described this way can then be configured using the plugins
94+
configuration editor.
95+
96+
The 'name' attributes specifies the name of the property.
97+
98+
The 'datatype' attribute determines which kind of data the property contains.
99+
100+
The 'default-value' attribute is used to specify the default value of the property.
101+
102+
The 'override-default-value' attribute can be used to specify a default value that
103+
differs from the Checkstyle default. For instance this is used to provide different
104+
defaults for the logLoadError and suppressLoadError properties of the AbstractTypeAware checks.
105+
106+
Properties of data type 'MultiCheck' and 'SingleSelect' can (better must) be provided
107+
with an 'enumeration' child element which specifies the valid enumeration values for
108+
this property.
109+
-->
110+
<!ELEMENT property-metadata (description?,enumeration?)>
111111
<!ATTLIST property-metadata
112-
name NMTOKEN #REQUIRED
113-
datatype (Boolean|Integer|String|Regex|SingleSelect|MultiCheck|File|Hidden) #REQUIRED
114-
default-value CDATA #IMPLIED
115-
override-default-value CDATA #IMPLIED>
112+
name NMTOKEN #REQUIRED
113+
datatype (Boolean|Integer|String|Regex|SingleSelect|MultiCheck|File|Hidden) #REQUIRED
114+
default-value CDATA #IMPLIED
115+
override-default-value CDATA #IMPLIED>
116116

117117

118118
<!--
119-
The 'enumeration' element is used to provide valid enumeration values for 'MultiCheck'
120-
and 'SingleSelect' properties.
121-
Either the enumeration values are defined using 'property-value-option' child elements
122-
or by an option provider.
123-
An option provider is a java class that implements the interface
124-
'net.sf.eclipsecs.config.meta.IOptionProvider' and provides the
125-
enumeration values via implementation. This can be useful for providing large amounts
126-
of enumeration values (for instance all checkstyle tokens) or reoccurring sequences of
127-
enumeration values (for instance the java visibility values).
128-
The option provider and 'property-value-option' elements can be mixed together to build
129-
a single enumeration.
130-
-->
119+
The 'enumeration' element is used to provide valid enumeration values for 'MultiCheck'
120+
and 'SingleSelect' properties.
121+
Either the enumeration values are defined using 'property-value-option' child elements
122+
or by an option provider.
123+
An option provider is a java class that implements the interface
124+
'net.sf.eclipsecs.config.meta.IOptionProvider' and provides the
125+
enumeration values via implementation. This can be useful for providing large amounts
126+
of enumeration values (for instance all checkstyle tokens) or reoccurring sequences of
127+
enumeration values (for instance the java visibility values).
128+
The option provider and 'property-value-option' elements can be mixed together to build
129+
a single enumeration.
130+
-->
131131
<!ELEMENT enumeration (property-value-option*)>
132132
<!ATTLIST enumeration
133-
option-provider NMTOKEN #IMPLIED>
133+
option-provider NMTOKEN #IMPLIED>
134134

135135

136136
<!--
137-
Specifies a single enumeration value.
138-
-->
137+
Specifies a single enumeration value.
138+
-->
139139
<!ELEMENT property-value-option EMPTY>
140140
<!ATTLIST property-value-option
141-
value CDATA #REQUIRED>
142-
141+
value CDATA #REQUIRED>
142+
143143
<!--
144144
Defines a marker resolution (quickfix) for the module.
145145
Quickfixes are required to implement the
@@ -148,4 +148,4 @@
148148
-->
149149
<!ELEMENT quickfix EMPTY>
150150
<!ATTLIST quickfix
151-
classname NMTOKEN #REQUIRED>
151+
classname NMTOKEN #REQUIRED>

net.sf.eclipsecs.doc/src/main/resources/dtds/checkstyle-metadata_1_1.dtd

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -82,10 +82,10 @@
8282
the old qualified class names for your module as 'alternative-name' element.
8383
The plugin is then able to load even Checkstyle configuration files where your old
8484
module names are used.
85-
-->
85+
-->
8686
<!ELEMENT alternative-name EMPTY>
8787
<!ATTLIST alternative-name
88-
internal-name CDATA #REQUIRED>
88+
internal-name CDATA #REQUIRED>
8989

9090

9191
<!--
@@ -107,7 +107,7 @@
107107
with an 'enumeration' child element which specifies the valid enumeration values for
108108
this property.
109109
-->
110-
<!ELEMENT property-metadata (description?,enumeration?)>
110+
<!ELEMENT property-metadata (description?,enumeration?)>
111111
<!ATTLIST property-metadata
112112
name NMTOKEN #REQUIRED
113113
datatype (Boolean|Integer|String|Regex|SingleSelect|MultiCheck|File|Hidden) #REQUIRED
@@ -116,18 +116,18 @@
116116

117117

118118
<!--
119-
The 'enumeration' element is used to provide valid enumeration values for 'MultiCheck'
120-
and 'SingleSelect' properties.
121-
Either the enumeration values are defined using 'property-value-option' child elements
122-
or by an option provider.
123-
An option provider is a java class that implements the interface
124-
'net.sf.eclipsecs.config.meta.IOptionProvider' and provides the
125-
enumeration values via implementation. This can be useful for providing large amounts
126-
of enumeration values (for instance all checkstyle tokens) or reoccurring sequences of
127-
enumeration values (for instance the java visibility values).
128-
The option provider and 'property-value-option' elements can be mixed together to build
129-
a single enumeration.
130-
-->
119+
The 'enumeration' element is used to provide valid enumeration values for 'MultiCheck'
120+
and 'SingleSelect' properties.
121+
Either the enumeration values are defined using 'property-value-option' child elements
122+
or by an option provider.
123+
An option provider is a java class that implements the interface
124+
'net.sf.eclipsecs.config.meta.IOptionProvider' and provides the
125+
enumeration values via implementation. This can be useful for providing large amounts
126+
of enumeration values (for instance all checkstyle tokens) or reoccurring sequences of
127+
enumeration values (for instance the java visibility values).
128+
The option provider and 'property-value-option' elements can be mixed together to build
129+
a single enumeration.
130+
-->
131131
<!ELEMENT enumeration (property-value-option*)>
132132
<!ATTLIST enumeration
133133
option-provider NMTOKEN #IMPLIED>
@@ -155,4 +155,4 @@
155155
-->
156156
<!ELEMENT message-key EMPTY>
157157
<!ATTLIST message-key
158-
key NMTOKEN #REQUIRED>
158+
key NMTOKEN #REQUIRED>

0 commit comments

Comments
 (0)