xmlns="http://pmd.sourceforge.net/ruleset/2.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://pmd.sourceforge.net/ruleset/2.0.0
- http://pmd.sourceforge.net/ruleset_2_0_0.xsd"
+ https://pmd.sourceforge.io/ruleset_2_0_0.xsd"
name="Custom ruleset"
>
<exclude name="UnnecessaryLocalBeforeReturn" />
<exclude name="UnnecessaryReturn" />
</rule>
+ <rule ref="category/java/codestyle.xml/ClassNamingConventions" >
+ <properties>
+ <property name="utilityClassPattern" value="[A-Z][a-zA-Z0-9]*"/>
+ </properties>
+ </rule>
<rule ref="category/java/codestyle.xml/ControlStatementBraces" >
<properties>
<property name="checkIfElseStmt" value="false"/>
<property name="checkSingleIfStmt" value="false"/>
</properties>
</rule>
+ <rule ref="category/java/codestyle.xml/LongVariable" >
+ <properties>
+ <property name="minimum" value="25"/>
+ </properties>
+ </rule>
<rule ref="category/java/design.xml" >
<exclude name="AvoidThrowingNullPointerException" />
<rule ref="category/java/multithreading.xml" />
<rule ref="category/java/performance.xml" >
+ <exclude name="AvoidUsingShortType" />
<exclude name="ConsecutiveAppendsShouldReuse" />
<exclude name="RedundantFieldInitializer" />
</rule>
private final byte[] barray;
- private final TextExporter texporter_w31j;
- private final TextExporter texporter_u16le;
+ private final TextExporter texporterW31j;
+ private final TextExporter texporterU16le;
private final ByteArrayOutputStream xos;
this.barray = new byte[BUFSZ_PRIM];
- this.texporter_w31j = new TextExporter(CS_WIN31J);
- this.texporter_u16le = new TextExporter(CS_UTF16LE);
+ this.texporterW31j = new TextExporter(CS_WIN31J);
+ this.texporterU16le = new TextExporter(CS_UTF16LE);
this.xos = new ByteArrayOutputStream();
return;
int encodedSize;
try{
encodedSize =
- this.texporter_w31j.encodeToByteStream(text, this.xos);
+ this.texporterW31j.encodeToByteStream(text, this.xos);
}catch(CharacterCodingException e){
throw new IllegalTextExportException(ERRMSG_ILLENC, e);
}
int encodedSize;
try{
encodedSize =
- this.texporter_u16le.encodeToByteStream(text, this.xos);
+ this.texporterU16le.encodeToByteStream(text, this.xos);
}catch(CharacterCodingException e){
assert false; // これはない
throw new IllegalTextExportException(ERRMSG_ILLENC, e);