use of com.emc.storageos.model.customservices.InputParameterRestRep in project coprhd-controller by CoprHD.
the class CustomServicesDBHelper method mapInput.
/**
* @param inputGroups
* @return
*/
private static StringSetMap mapInput(Map<String, InputGroup> inputGroups) {
final StringSetMap input = new StringSetMap();
if (null != inputGroups) {
for (final Entry<String, InputGroup> inputGroup : inputGroups.entrySet()) {
final StringSet set = new StringSet();
for (final InputParameterRestRep param : inputGroup.getValue().getInputGroup()) {
set.add(param.getName());
}
input.put(inputGroup.getKey(), set);
}
}
return input;
}
use of com.emc.storageos.model.customservices.InputParameterRestRep in project coprhd-controller by CoprHD.
the class CustomServicesPrimitiveMapper method mapInputParameter.
private static InputParameterRestRep mapInputParameter(final BasicInputParameter<?> param) {
InputParameterRestRep restRep = new InputParameterRestRep();
restRep.setName(param.getName());
restRep.setRequired(param.getRequired());
restRep.setFieldType(param.getType().name());
return restRep;
}
use of com.emc.storageos.model.customservices.InputParameterRestRep in project coprhd-controller by CoprHD.
the class CustomServicesPrimitiveMapper method mapInputGroup.
private static InputGroup mapInputGroup(final List<InputParameter> list) {
final ImmutableList.Builder<InputParameterRestRep> builder = ImmutableList.<InputParameterRestRep>builder();
if (list != null) {
for (final InputParameter param : list) {
builder.add(mapInputParameter(param.asBasicInputParameter()));
}
}
final InputGroup inputGroup = new InputGroup();
inputGroup.setInputGroup(builder.build());
return inputGroup;
}
Aggregations