* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*
*/
public class ListDelegates extends Cmd {
- private static final String HEADER = "List Delegates";
+ private static final String HEADER = "List Delegates";
private static final String[] options = {"user","delegate"};
public ListDelegates(List parent) {
- super(parent,"delegates",
+ super(parent,"delegates",
new Param(optionsToString(options),true),
new Param("id",true));
}
return same(new Retryable<Integer>() {
@Override
public Integer code(Rcli<?> client) throws CadiException, APIException {
-
+
Future<Delgs> fp = client.read(
- "/authz/delegates/" + key + '/' + id,
+ "/authz/delegates/" + key + '/' + id,
getDF(Delgs.class)
);
- if(fp.get(AAFcli.timeout())) {
+ if (fp.get(AAFcli.timeout())) {
((List)parent).report(fp.value,HEADER + " by " + key, id);
- if(fp.code()==404)return 200;
+ if (fp.code()==404)return 200;
} else {
error(fp);
}