Skip to content
This repository was archived by the owner on Mar 24, 2025. It is now read-only.

Commit 34eea46

Browse files
committed
update readme
1 parent 6ce79d4 commit 34eea46

File tree

1 file changed

+24
-15
lines changed

1 file changed

+24
-15
lines changed

README.md

Lines changed: 24 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
# validation-scala
22

3-
Jakarta Bean Validation 3.0 for Scala. Allows validation of some Scala types (e.g. `Option`, `Seq`, `Set`, `Map`, etc).
4-
5-
Supports Scala `3` and `2.13`, above Java `11`.
3+
Jakarta Bean Validation 3.0 for Scala.
64

75
[![Project stage][Badge-Stage]][Badge-Stage-Page] ![CI][Badge-CI] [![Nexus (Snapshots)][Badge-Snapshots]][Link-Snapshots] [![Sonatype Nexus (Releases)][Badge-Releases]][Link-Releases]
86

9-
[Badge-Stage]: https://img.shields.io/badge/Project%20Stage-Experimental-orange.svg
10-
[Badge-Stage-Page]: https://github.com/bitlap/bitlap/wiki/Project-Stages
7+
## Features
118

12-
[Badge-CI]: https://github.com/bitlap/validation-scala/actions/workflows/scala.yml/badge.svg
13-
[Badge-Snapshots]: https://img.shields.io/nexus/s/org.bitlap/validation-scala-core_3?server=https%3A%2F%2Fs01.oss.sonatype.org
14-
[Link-Snapshots]: https://s01.oss.sonatype.org/content/repositories/snapshots/org/bitlap/validation-scala-core_3/
15-
16-
[Badge-Releases]: https://img.shields.io/nexus/r/org.bitlap/validation-scala-core_3?server=https%3A%2F%2Fs01.oss.sonatype.org
17-
[Link-Releases]: https://s01.oss.sonatype.org/content/repositories/releases/org/bitlap/validation-scala-core_3/
9+
- Support Scala `3.x` and `2.13.x`, Java `11` and above
10+
- Support validate scala types, e.g. `Option`, `Seq`, `Set`, `Map`, `Vector`, etc
11+
- Support validate object
12+
- Support validate method parameter
13+
- Support validate `ZIO` method parameter
14+
- Supports automated error capture
15+
- Support cascade validation
1816

1917
## Introduction
2018

@@ -24,7 +22,7 @@ libraryDependencies ++= Seq(
2422
)
2523
```
2624

27-
## Usage Instructions
25+
## Validate Object
2826

2927
Step 1. Add annotations to your case class:
3028
```scala
@@ -55,9 +53,9 @@ if (violations.nonEmpty) {
5553
}
5654
```
5755

58-
## Use it like SpringBoot
56+
## Validate Method Parameter
5957

60-
> It does not support annotations with group parameters and only supports scala 3!
58+
This allows us to use it like SpringBoot. It does not support annotations with group parameters and only supports scala 3!
6159

6260
Add the following code to `build.sbt`:
6361
```scala
@@ -111,4 +109,15 @@ def validatedNotEmptyParam(@NotBlank name: String): String
111109

112110
## Inspired by
113111

114-
[bean-validation-scala](https://github.com/bean-validation-scala/bean-validation-scala), JSR 303 and 349 Bean Validation for Scala.
112+
[bean-validation-scala](https://github.com/bean-validation-scala/bean-validation-scala), JSR 303 and 349 Bean Validation for Scala.
113+
114+
115+
[Badge-Stage]: https://img.shields.io/badge/Project%20Stage-Experimental-orange.svg
116+
[Badge-Stage-Page]: https://github.com/bitlap/bitlap/wiki/Project-Stages
117+
118+
[Badge-CI]: https://github.com/bitlap/validation-scala/actions/workflows/scala.yml/badge.svg
119+
[Badge-Snapshots]: https://img.shields.io/nexus/s/org.bitlap/validation-scala-core_3?server=https%3A%2F%2Fs01.oss.sonatype.org
120+
[Link-Snapshots]: https://s01.oss.sonatype.org/content/repositories/snapshots/org/bitlap/validation-scala-core_3/
121+
122+
[Badge-Releases]: https://img.shields.io/nexus/r/org.bitlap/validation-scala-core_3?server=https%3A%2F%2Fs01.oss.sonatype.org
123+
[Link-Releases]: https://s01.oss.sonatype.org/content/repositories/releases/org/bitlap/validation-scala-core_3/

0 commit comments

Comments
 (0)