Adding PactProvider for verifying consumer contrcat #20
Annotations
4 errors and 3 warnings
|
Usage of System.out/err:
src/main/java/uk/gov/hmcts/cp/repositories/InMemoryCourtScheduleRepositoryImpl.java#L71
References to System.(out|err).print are usually intended for debugging purposes and can remain in
the codebase even in production code. By using a logger one can enable/disable this behaviour at
will (and by priority) and avoid clogging the Standard out log.
SystemPrintln (Priority: 2, Ruleset: Best Practices)
https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_bestpractices.html#systemprintln
|
|
The final method parameter name 'CourtScheduleResponse' doesn't match '[a-z][a-zA-Z0-9]*':
src/main/java/uk/gov/hmcts/cp/repositories/InMemoryCourtScheduleRepositoryImpl.java#L24
Configurable naming conventions for formal parameters of methods and lambdas.
This rule reports formal parameters which do not match the regex that applies to their
specific kind (e.g. lambda parameter, or final formal parameter). Each regex can be
configured through properties.
By default this rule uses the standard Java naming convention (Camel case).
FormalParameterNamingConventions (Priority: 1, Ruleset: Code Style)
https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_codestyle.html#formalparameternamingconventions
|
|
The final method parameter name 'CourtScheduleResponse' doesn't match '[a-z][a-zA-Z0-9]*':
src/main/java/uk/gov/hmcts/cp/repositories/CourtScheduleRepository.java#L11
Configurable naming conventions for formal parameters of methods and lambdas.
This rule reports formal parameters which do not match the regex that applies to their
specific kind (e.g. lambda parameter, or final formal parameter). Each regex can be
configured through properties.
By default this rule uses the standard Java naming convention (Camel case).
FormalParameterNamingConventions (Priority: 1, Ruleset: Code Style)
https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_codestyle.html#formalparameternamingconventions
|
|
Final parameter in abstract method:
src/main/java/uk/gov/hmcts/cp/repositories/CourtScheduleRepository.java#L11
Declaring a method parameter as final for an interface method is useless because the implementation may choose to not respect it.
FinalParameterInAbstractMethod (Priority: 1, Ruleset: Code Style)
https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_codestyle.html#finalparameterinabstractmethod
|
|
Local variable 'sittingStartTime' could be declared final:
src/main/java/uk/gov/hmcts/cp/repositories/InMemoryCourtScheduleRepositoryImpl.java#L69
A local variable assigned only once can be declared final.
LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style)
https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_codestyle.html#localvariablecouldbefinal
|
|
Local variable 'sittingStartTime' could be declared final:
src/main/java/uk/gov/hmcts/cp/repositories/InMemoryCourtScheduleRepositoryImpl.java#L41
A local variable assigned only once can be declared final.
LocalVariableCouldBeFinal (Priority: 3, Ruleset: Code Style)
https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_codestyle.html#localvariablecouldbefinal
|
|
Unused import 'org.springframework.context.annotation.Profile':
src/main/java/uk/gov/hmcts/cp/repositories/InMemoryCourtScheduleRepositoryImpl.java#L3
Reports import statements that can be removed. They are either unused,
duplicated, or the members they import are already implicitly in scope,
because they're in java.lang, or the current package.
If some imports cannot be resolved, for instance because you run PMD with
an incomplete auxiliary classpath, some imports may be conservatively marked
as used even if they're not to avoid false positives.
UnnecessaryImport (Priority: 4, Ruleset: Code Style)
https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_codestyle.html#unnecessaryimport
|
Artifacts
Produced during runtime
| Name | Size | Digest | |
|---|---|---|---|
|
PMD Report
Expired
|
1.75 KB |
sha256:b83d922264c72135e3e32896834648572e6f2951f80586ccd1076fd85b75ae5b
|
|