Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed KdocComments #1754

Merged
merged 30 commits into from
Oct 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
37edc00
Fixed KdocComments
DrAlexD Sep 28, 2023
fc88b09
Merge branch 'master' into feature/fix-kdoc-comments
DrAlexD Sep 28, 2023
c1ebe74
- fix
DrAlexD Sep 28, 2023
d5e31fa
Merge branch 'feature/fix-kdoc-comments' of https://github.com/DrAlex…
DrAlexD Sep 28, 2023
bdef44b
- fix
DrAlexD Sep 28, 2023
382736a
- fix
DrAlexD Sep 28, 2023
d01ba9e
- fixed case when @property text in class-KDoc didn't create for KDoc…
DrAlexD Oct 2, 2023
96e3c8f
- fix
DrAlexD Oct 2, 2023
96a271c
- fix
DrAlexD Oct 2, 2023
a10486b
- fix affected classes
DrAlexD Oct 2, 2023
88f429f
- fix affected classes
DrAlexD Oct 2, 2023
8c4d75c
Merge branch 'master' into feature/fix-kdoc-comments
DrAlexD Oct 2, 2023
27fb72f
Merge branch 'master' into feature/fix-kdoc-comments
DrAlexD Oct 9, 2023
7a85200
Merge branch 'master' into feature/fix-kdoc-comments
DrAlexD Oct 9, 2023
19e59ff
- added non-fixed warning `KDOC_EXTRA_PROPERTY` for redundant `@param…
DrAlexD Oct 9, 2023
eec619c
Merge branch 'feature/fix-kdoc-comments' of https://github.com/DrAlex…
DrAlexD Oct 9, 2023
77fc1ba
- fix
DrAlexD Oct 9, 2023
2e180cb
- fix
DrAlexD Oct 9, 2023
67d18fa
- fix
DrAlexD Oct 9, 2023
43fadfc
- fix
DrAlexD Oct 10, 2023
d16ad71
- fix
DrAlexD Oct 10, 2023
78d8012
- fix
DrAlexD Oct 10, 2023
62c5bd3
- added configuration for `@param` tags creation: `isParamTagsForPara…
DrAlexD Oct 11, 2023
91016b9
- fix
DrAlexD Oct 11, 2023
b7ba451
- fix
DrAlexD Oct 11, 2023
5cfbb44
- fix docs
DrAlexD Oct 12, 2023
62bf445
- fix docs
DrAlexD Oct 12, 2023
e986c4d
- fix docs
DrAlexD Oct 16, 2023
275e45c
- fix
DrAlexD Oct 16, 2023
b03af2c
Merge branch 'master' into feature/fix-kdoc-comments
DrAlexD Oct 16, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions diktat-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -450,6 +450,9 @@
# Checks that property in constructor doesn't contain comment
- name: KDOC_NO_CONSTRUCTOR_PROPERTY
enabled: true
configuration:
isParamTagsForParameters: false # create param tags for parameters without val or var
isParamTagsForPrivateProperties: false # create param tags for private properties
# Checks that property in KDoc present in class
- name: KDOC_EXTRA_PROPERTY
enabled: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ private typealias RunAction = (DiktatProcessor, DiktatProcessorListener) -> Unit
/**
* A runner for diktat on bunch of files using baseline and reporter
*
* @param diktatBaselineGenerator
nulls marked this conversation as resolved.
Show resolved Hide resolved
* @property diktatProcessor
* @property diktatBaseline
* @property diktatBaselineGenerator
* @property diktatReporter
*/
data class DiktatRunner(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,20 @@ import com.saveourtool.diktat.api.DiktatBaselineFactory
import com.saveourtool.diktat.api.DiktatProcessorListener
import com.saveourtool.diktat.api.DiktatReporter
import com.saveourtool.diktat.api.DiktatReporterFactory
import com.saveourtool.diktat.api.DiktatRuleConfig
import com.saveourtool.diktat.api.DiktatRuleConfigReader
import com.saveourtool.diktat.api.DiktatRuleSet
import com.saveourtool.diktat.api.DiktatRuleSetFactory
import java.io.OutputStream
import java.nio.file.Path

/**
* A factory to create [DiktatRunner]
*
* @param diktatRuleConfigReader a reader for [DiktatRuleConfig]
* @param diktatRuleSetFactory a factory for [DiktatRuleSet]
* @param diktatProcessorFactory a factory for [DiktatProcessor]
* @param diktatBaselineFactory a factory for [DiktatBaseline]
* @property diktatReporterFactory a factory for [DiktatReporter]
*/
class DiktatRunnerFactory(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ import kotlinx.cli.default
import kotlinx.cli.vararg

/**
* @param groupByFileInPlain
nulls marked this conversation as resolved.
Show resolved Hide resolved
* @param colorNameInPlain
* @param logLevel
* @property config path to `diktat-analysis.yml`
* @property mode mode of `diktat`
* @property reporterProviderId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,12 @@ import kotlinx.serialization.Serializable
/**
* This class is used to serialize/deserialize json representation
* that is used to store command line arguments
* @property shortName short argument representation like -h
* @property longName long argument representation like --help
* @property hasArgs indicates if option should have explicit argument
*
* @param shortName short argument representation like -h
* @param helpDescr
* @param longName long argument representation like --help
* @param hasArgs indicates if option should have explicit argument
* @param isRequired
*/
@Serializable
data class CliArgument(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import com.google.devtools.ksp.symbol.KSClassDeclaration

/**
* [SymbolProcessor] to generate a class with contacts for names from provided enum
*
* @param codeGenerator
*/
class EnumNamesSymbolProcessor(
private val codeGenerator: CodeGenerator,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import java.io.File

/**
* An extension to configure diktat in build.gradle(.kts) file
*
* @param patternSet
*/
open class DiktatExtension(
private val patternSet: PatternSet
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ import java.nio.file.Path

/**
* A base task to run `diktat`
*
* @param inputs
* @property extension
*/
@Suppress("WRONG_NEWLINES", "Deprecation")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ import java.nio.file.Path

/**
* [DiktatReporter] using __KtLint__
*
* @param ktLintReporter
* @param sourceRootDir
*/
class DiktatReporterImpl(
private val ktLintReporter: ReporterV2,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import org.jetbrains.kotlin.com.intellij.lang.ASTNode
/**
* This class represent individual inspections of diktat code style.
* A [Warnings] entry contains rule name, warning message and is used in code check.
*
* @param warn description of the inspection
* @property canBeAutoCorrected whether this inspection can automatically fix the code. Should be public to be able to use it in docs generator.
* @property ruleId number of the inspection according to [diktat code style](https://github.com/saveourtool/diktat/blob/master/info/guide/diktat-coding-convention.md)
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ private typealias DiktatRuleApi = com.saveourtool.diktat.api.DiktatRule
/**
* This is a wrapper around _KtLint_ `com.pinterest.ktlint.core.Rule`.
*
* @param inspections warnings that are used in the rule's code
* @property id id of the rule
* @property configRules all rules from configuration
* @property inspections warnings that are used in the rule's code
*/
@Suppress("TooGenericExceptionCaught")
abstract class DiktatRule(
Expand Down
Loading
Loading