Skip to content

Commit ab54f67

Browse files
Merge pull request #253 from SpineEventEngine/io-spine-validation
Rename `io.spine.validate` to `io.spine.validation`
2 parents b0eea6c + a876a29 commit ab54f67

File tree

168 files changed

+832
-730
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+832
-730
lines changed

buildSrc/src/main/kotlin/io/spine/dependency/local/CoreJvmCompiler.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,12 @@ object CoreJvmCompiler {
4646
/**
4747
* The version used to in the build classpath.
4848
*/
49-
const val dogfoodingVersion = "2.0.0-SNAPSHOT.040"
49+
const val dogfoodingVersion = "2.0.0-SNAPSHOT.042"
5050

5151
/**
5252
* The version to be used for integration tests.
5353
*/
54-
const val version = "2.0.0-SNAPSHOT.040"
54+
const val version = "2.0.0-SNAPSHOT.042"
5555

5656
/**
5757
* The ID of the Gradle plugin.

buildSrc/src/main/kotlin/io/spine/dependency/local/Validation.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ object Validation {
3636
/**
3737
* The version of the Validation library artifacts.
3838
*/
39-
const val version = "2.0.0-SNAPSHOT.375"
39+
const val version = "2.0.0-SNAPSHOT.378"
4040

4141
/**
4242
* The last version of Validation compatible with ProtoData.
@@ -65,5 +65,5 @@ object Validation {
6565
const val model = "$group:$prefix-model:$version"
6666

6767
const val configModule = "$group:$prefix-configuration"
68-
const val configuration = "$configModule:$version"
68+
const val context = "$group:$prefix-context:$version"
6969
}

context/src/main/kotlin/io/spine/tools/validation/ErrorPlaceholder.kt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,16 +33,16 @@ package io.spine.tools.validation
3333
* Each validation option declares the supported placeholders. Take a look at
3434
* `options.proto` for examples.
3535
*
36-
* Important Note: we have the same [enum][io.spine.validate.RuntimeErrorPlaceholder]
36+
* Important Note: we have the same [enum][io.spine.validation.RuntimeErrorPlaceholder]
3737
* in the runtime library, which is exactly as this one. Please keep them in sync.
3838
* This duplication is done intentionally to prevent clash between the runtime library,
39-
* which is added to the classpath of ProtoData and the runtime library, which is part
40-
* of ProtoData itself because it is a part of Spine. As we complete our migration
39+
* which is added to the classpath of the Compiler and the runtime library, which is part
40+
* of the Compiler itself because it is a part of Spine. As we complete our migration
4141
* of validation to codegen, the runtime library will either be significantly simplified,
4242
* or even its content may be moved to `base`. Then, the duplicate enum should be removed.
4343
*
44-
* @see io.spine.validate.TemplateString
45-
* @see io.spine.validate.RuntimeErrorPlaceholder
44+
* @see io.spine.validation.TemplateString
45+
* @see io.spine.validation.RuntimeErrorPlaceholder
4646
*/
4747
public enum class ErrorPlaceholder(public val value: String) {
4848

dependencies.md

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

22

3-
# Dependencies of `io.spine.tools:validation-context:2.0.0-SNAPSHOT.378`
3+
# Dependencies of `io.spine.tools:validation-context:2.0.0-SNAPSHOT.380`
44

55
## Runtime
66
1. **Group** : com.fasterxml.jackson. **Name** : jackson-bom. **Version** : 2.20.0.
@@ -1139,14 +1139,14 @@
11391139

11401140
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
11411141

1142-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
1142+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
11431143
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
11441144
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
11451145

11461146

11471147

11481148

1149-
# Dependencies of `io.spine.tools:validation-context-tests:2.0.0-SNAPSHOT.378`
1149+
# Dependencies of `io.spine.tools:validation-context-tests:2.0.0-SNAPSHOT.380`
11501150

11511151
## Runtime
11521152
1. **Group** : com.fasterxml.jackson. **Name** : jackson-bom. **Version** : 2.20.0.
@@ -2233,14 +2233,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
22332233

22342234
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
22352235

2236-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
2236+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
22372237
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
22382238
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
22392239

22402240

22412241

22422242

2243-
# Dependencies of `io.spine.tools:validation-gradle-plugin:2.0.0-SNAPSHOT.378`
2243+
# Dependencies of `io.spine.tools:validation-gradle-plugin:2.0.0-SNAPSHOT.380`
22442244

22452245
## Runtime
22462246
1. **Group** : com.fasterxml.jackson. **Name** : jackson-bom. **Version** : 2.20.0.
@@ -3309,14 +3309,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
33093309

33103310
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
33113311

3312-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
3312+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
33133313
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
33143314
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
33153315

33163316

33173317

33183318

3319-
# Dependencies of `io.spine.tools:validation-java:2.0.0-SNAPSHOT.378`
3319+
# Dependencies of `io.spine.tools:validation-java:2.0.0-SNAPSHOT.380`
33203320

33213321
## Runtime
33223322
1. **Group** : com.fasterxml.jackson. **Name** : jackson-bom. **Version** : 2.20.0.
@@ -4403,14 +4403,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
44034403

44044404
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
44054405

4406-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
4406+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
44074407
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
44084408
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
44094409

44104410

44114411

44124412

4413-
# Dependencies of `io.spine.tools:validation-java-bundle:2.0.0-SNAPSHOT.378`
4413+
# Dependencies of `io.spine.tools:validation-java-bundle:2.0.0-SNAPSHOT.380`
44144414

44154415
## Runtime
44164416
1. **Group** : com.google.auto.service. **Name** : auto-service-annotations. **Version** : 1.1.1.
@@ -5188,14 +5188,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
51885188

51895189
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
51905190

5191-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
5191+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
51925192
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
51935193
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
51945194

51955195

51965196

51975197

5198-
# Dependencies of `io.spine:validation-jvm-runtime:2.0.0-SNAPSHOT.378`
5198+
# Dependencies of `io.spine:validation-jvm-runtime:2.0.0-SNAPSHOT.380`
51995199

52005200
## Runtime
52015201
1. **Group** : com.google.code.findbugs. **Name** : jsr305. **Version** : 3.0.2.
@@ -6044,14 +6044,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
60446044

60456045
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
60466046

6047-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
6047+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
60486048
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
60496049
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
60506050

60516051

60526052

60536053

6054-
# Dependencies of `io.spine.tools:validation-ksp:2.0.0-SNAPSHOT.378`
6054+
# Dependencies of `io.spine.tools:validation-ksp:2.0.0-SNAPSHOT.380`
60556055

60566056
## Runtime
60576057
1. **Group** : com.google.auto.service. **Name** : auto-service-annotations. **Version** : 1.1.1.
@@ -6996,14 +6996,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
69966996

69976997
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
69986998

6999-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
6999+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
70007000
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
70017001
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
70027002

70037003

70047004

70057005

7006-
# Dependencies of `io.spine.tools:validation-consumer:2.0.0-SNAPSHOT.378`
7006+
# Dependencies of `io.spine.tools:validation-consumer:2.0.0-SNAPSHOT.380`
70077007

70087008
## Runtime
70097009
1. **Group** : com.fasterxml.jackson. **Name** : jackson-bom. **Version** : 2.20.0.
@@ -8090,14 +8090,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
80908090

80918091
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
80928092

8093-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
8093+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
80948094
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
80958095
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
80968096

80978097

80988098

80998099

8100-
# Dependencies of `io.spine.tools:validation-consumer-dependency:2.0.0-SNAPSHOT.378`
8100+
# Dependencies of `io.spine.tools:validation-consumer-dependency:2.0.0-SNAPSHOT.380`
81018101

81028102
## Runtime
81038103
1. **Group** : com.google.code.findbugs. **Name** : jsr305. **Version** : 3.0.2.
@@ -9087,14 +9087,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
90879087

90889088
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
90899089

9090-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
9090+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
90919091
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
90929092
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
90939093

90949094

90959095

90969096

9097-
# Dependencies of `io.spine.tools:validation-extensions:2.0.0-SNAPSHOT.378`
9097+
# Dependencies of `io.spine.tools:validation-extensions:2.0.0-SNAPSHOT.380`
90989098

90999099
## Runtime
91009100
1. **Group** : com.fasterxml.jackson. **Name** : jackson-bom. **Version** : 2.20.0.
@@ -10237,14 +10237,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
1023710237

1023810238
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
1023910239

10240-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
10240+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
1024110241
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
1024210242
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
1024310243

1024410244

1024510245

1024610246

10247-
# Dependencies of `io.spine.tools:validation-runtime:2.0.0-SNAPSHOT.378`
10247+
# Dependencies of `io.spine.tools:validation-runtime:2.0.0-SNAPSHOT.380`
1024810248

1024910249
## Runtime
1025010250
1. **Group** : com.google.code.findbugs. **Name** : jsr305. **Version** : 3.0.2.
@@ -11234,14 +11234,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
1123411234

1123511235
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
1123611236

11237-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
11237+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
1123811238
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
1123911239
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
1124011240

1124111241

1124211242

1124311243

11244-
# Dependencies of `io.spine.tools:validation-validating:2.0.0-SNAPSHOT.378`
11244+
# Dependencies of `io.spine.tools:validation-validating:2.0.0-SNAPSHOT.380`
1124511245

1124611246
## Runtime
1124711247
1. **Group** : com.google.code.findbugs. **Name** : jsr305. **Version** : 3.0.2.
@@ -12235,14 +12235,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
1223512235

1223612236
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
1223712237

12238-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
12238+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
1223912239
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
1224012240
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
1224112241

1224212242

1224312243

1224412244

12245-
# Dependencies of `io.spine.tools:validation-validator:2.0.0-SNAPSHOT.378`
12245+
# Dependencies of `io.spine.tools:validation-validator:2.0.0-SNAPSHOT.380`
1224612246

1224712247
## Runtime
1224812248
1. **Group** : com.fasterxml.jackson. **Name** : jackson-bom. **Version** : 2.20.0.
@@ -13333,14 +13333,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
1333313333

1333413334
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
1333513335

13336-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
13336+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
1333713337
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
1333813338
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
1333913339

1334013340

1334113341

1334213342

13343-
# Dependencies of `io.spine.tools:validation-validator-dependency:2.0.0-SNAPSHOT.378`
13343+
# Dependencies of `io.spine.tools:validation-validator-dependency:2.0.0-SNAPSHOT.380`
1334413344

1334513345
## Runtime
1334613346
1. **Group** : com.google.code.findbugs. **Name** : jsr305. **Version** : 3.0.2.
@@ -14165,14 +14165,14 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
1416514165

1416614166
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
1416714167

14168-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
14168+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
1416914169
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
1417014170
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).
1417114171

1417214172

1417314173

1417414174

14175-
# Dependencies of `io.spine.tools:validation-vanilla:2.0.0-SNAPSHOT.378`
14175+
# Dependencies of `io.spine.tools:validation-vanilla:2.0.0-SNAPSHOT.380`
1417614176

1417714177
## Runtime
1417814178
1. **Group** : com.google.code.findbugs. **Name** : jsr305. **Version** : 3.0.2.
@@ -15028,6 +15028,6 @@ This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
1502815028

1502915029
The dependencies distributed under several licenses, are used according their commercial-use-friendly license.
1503015030

15031-
This report was generated on **Wed Dec 17 19:51:15 WET 2025** using
15031+
This report was generated on **Thu Dec 18 20:32:39 WET 2025** using
1503215032
[Gradle-License-Report plugin](https://github.com/jk1/Gradle-License-Report) by Evgeny Naumenko, licensed under
1503315033
[Apache 2.0 License](https://github.com/jk1/Gradle-License-Report/blob/master/LICENSE).

java/src/main/kotlin/io/spine/tools/validation/java/JavaValidationPlugin.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ private val customOptions: List<ValidationOption> by lazy {
6969

7070
/**
7171
* Dynamically discovered instances of custom
72-
* [MessageValidator][io.spine.validate.MessageValidator]s.
72+
* [MessageValidator][io.spine.validation.MessageValidator]s.
7373
*
7474
* Please note that the KSP module is responsible for the actual discovering
7575
* of the message validators. The discovered validators are written to a text file

java/src/main/kotlin/io/spine/tools/validation/java/expression/ClassNames.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ import io.spine.tools.compiler.jvm.ClassName
4242
import io.spine.type.KnownTypes
4343
import io.spine.type.TypeName
4444
import io.spine.type.TypeUrl
45-
import io.spine.validate.ConstraintViolation
46-
import io.spine.validate.TemplateString
47-
import io.spine.validate.ValidatableMessage
48-
import io.spine.validate.ValidationError
45+
import io.spine.validation.ConstraintViolation
46+
import io.spine.validation.TemplateString
47+
import io.spine.validation.ValidatableMessage
48+
import io.spine.validation.ValidationError
4949
import java.util.*
5050
import java.util.regex.Pattern
5151
import java.util.stream.Collectors

java/src/main/kotlin/io/spine/tools/validation/java/expression/ConstraintViolations.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ import io.spine.tools.compiler.jvm.ClassName
3333
import io.spine.tools.compiler.jvm.Expression
3434
import io.spine.tools.compiler.jvm.newBuilder
3535
import io.spine.tools.compiler.jvm.packToAny
36-
import io.spine.validate.ConstraintViolation
37-
import io.spine.validate.TemplateString
36+
import io.spine.validation.ConstraintViolation
37+
import io.spine.validation.TemplateString
3838

3939
/**
4040
* Yields an expression that creates a new instance of [ConstraintViolation]

java/src/main/kotlin/io/spine/tools/validation/java/expression/FieldPaths.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public fun Expression<FieldPath>.mergeFrom(other: Expression<FieldPath>): Expres
7070
*
7171
* Strictly speaking, [OneofName] does not represent a field, but a group of fields.
7272
* But we still use [FieldPath] to provide a path to this message member because
73-
* [io.spine.validate.ConstraintViolation] expects exactly [FieldPath] type.
73+
* [io.spine.validation.ConstraintViolation] expects exactly [FieldPath] type.
7474
*/
7575
public fun Expression<FieldPath>.resolve(oneof: OneofName): Expression<FieldPath> =
7676
toBuilder()

java/src/main/kotlin/io/spine/tools/validation/java/expression/TemplateStrings.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ import io.spine.tools.compiler.jvm.StringLiteral
3434
import io.spine.tools.compiler.jvm.mapExpression
3535
import io.spine.tools.compiler.jvm.newBuilder
3636
import io.spine.tools.validation.ErrorPlaceholder
37-
import io.spine.validate.TemplateString
38-
import io.spine.validate.checkPlaceholdersHasValue
37+
import io.spine.validation.TemplateString
38+
import io.spine.validation.checkPlaceholdersHasValue
3939

4040
/**
4141
* Yields an expression that creates a new instance of [TemplateString].

java/src/main/kotlin/io/spine/tools/validation/java/generate/ValidateScope.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,12 @@ import io.spine.tools.compiler.jvm.ReadVar
3131
import io.spine.tools.validation.java.generate.ValidateScope.parentName
3232
import io.spine.tools.validation.java.generate.ValidateScope.parentPath
3333
import io.spine.type.TypeName
34-
import io.spine.validate.ConstraintViolation
34+
import io.spine.validation.ConstraintViolation
3535

3636
/**
3737
* Scope variables available within the `validate(FieldPath)` method.
3838
*
39-
* Use these variables to create an instance of [io.spine.validate.ConstraintViolation]
39+
* Use these variables to create an instance of [io.spine.validation.ConstraintViolation]
4040
* for the failed option constraint.
4141
*/
4242
public object ValidateScope {

0 commit comments

Comments
 (0)