Re: [DISCUSS] Using framework level API argument validation

2016-04-21 Thread Daan Hoogland
checked out the code, looks good Rohit. It will give us a handle to keep the API from becoming even more inconsistent, and maybe even improve. On Thu, Apr 21, 2016 at 1:07 PM, Rohit Yadav wrote: > All, > > Whenever we've to write new APIs, we end up putting a lot of

[DISCUSS] Using framework level API argument validation

2016-04-21 Thread Rohit Yadav
All, Whenever we've to write new APIs, we end up putting a lot of validations such as Strings.isNullOrEmpty or checks on API args such as on id we do this a lot getId() != null && getId() > 0 and on failing throw server api exception (as cloudstack entity ids are always > 0, such as ids of