Repo related to https://github.com/fabtesta/pcml2java-maven-plugin.
Validators for IBM® .PCML-Files (Program Call Markup Language) pcml2java plugin generated classes.
Plugin is available in jitpack repository.
Latest build
Travis status
From version 1.1.0 supports ArrayList of String each elements size validation.
You could use this library indipendently from parent project pcml2java-maven-plugin.
- Add jitpack repository.
- Add it as a dependency in your pom.
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
....
<dependency>
<groupId>com.github.fabtesta</groupId>
<artifactId>pcml2java-validator</artifactId>
<version>1.1.0</version>
</dependency>
Annotated an ArrayList of String to validate the length of every single element.
@Size(max = 10) //THE ARRAY CAN CONTAIN MAX 10 ELEMENTS
@ArrayOfStringsElementSize(singleElementSize = 2) //EVERY STRING IN THE ARRAY MUST BE LTE 2 CHARS LONG
private ArrayList<String> listOfStrings;