You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi.
I'm trying to use "validateWith" but encountered the following error:
object java.lang.Class is not a value
validateWith = java.lang.Class[RunningFolderValidator]
annotation argument needs to be a constant; found: java.lang.<Class: error>[com.example.utils.validators.RunningFolderValidator]
validateWith = java.lang.Class[RunningFolderValidator]
no valid targets for annotation on variable runningFolderArg - it is discarded unused. You may specify targets with meta-annotations, e.g. @(<error> @getter)
@Parameter(
I changed the code and now it runs without errors:
@Parameter(
names = Array("-f", "--running-folder"),
required = true,
description = "The current folder in AWS S3 bucket in the format yyyy_MM_dd_HH (%Y_%M_%d_%H)",
validateWith = Array(classOf[RunningFolderValidator])
)
var runningFolderArg: String = _
I would appreciate if you can suggest the better approach
Hi.
I'm trying to use "validateWith" but encountered the following error:
The code is:
The validator:
How can I implement the validation in Scala?
The text was updated successfully, but these errors were encountered: