Package io.spine.validation.java
Class ExtraValidation
- java.lang.Object
-
- io.spine.validation.java.ExtraValidation
-
- All Implemented Interfaces:
io.spine.protodata.renderer.InsertionPoint
public final class ExtraValidation extends Object implements io.spine.protodata.renderer.InsertionPoint
An insertion point at the place where users may add some extra validation code to the one already generated by the standardJavaValidationRenderer
.Goes after all the standard validation checks but before returning/throwing the resulting error.
-
-
Constructor Summary
Constructors Constructor Description ExtraValidation(io.spine.protodata.TypeName name)
Creates a new instance for the given type.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getLabel()
io.spine.protodata.renderer.LineNumber
locate(List<String> list)
Does not try to locate the point.
-
-
-
Method Detail
-
getLabel
public String getLabel()
- Specified by:
getLabel
in interfaceio.spine.protodata.renderer.InsertionPoint
-
locate
public io.spine.protodata.renderer.LineNumber locate(List<String> list)
Does not try to locate the point.This insertion point is printed as a part of the code generated by the
JavaValidationRenderer
. So we never require locating it in code. Thus, this method always returnsLineNumber.notInFile()
.- Specified by:
locate
in interfaceio.spine.protodata.renderer.InsertionPoint
-
-