>* My original suggestion of using a Result interface. This requires
>more verbose code on the caller side -- the caller needs to check a
>success flag -- but allows for fine-grained information (which would
>be appropriate for a validation use case).

+1

https://issues.apache.org/jira/browse/SLING-3714

and following alex hint it is still possible to use separate static method to 
convert this result object adaption call into a single-line "adaptOrThrow" 
method with throws a runtime exception, without having to build this into the 
adaptto API. for projects that use this a lot.

stefan

Reply via email to