use of com.emc.nas.vnxfile.xmlapi.DeleteFileSystem in project coprhd-controller by CoprHD.
the class VNXFileArgsCreator method deleteFileSystem.
public InputStream deleteFileSystem(final Argument argument, final Map<String, Object> keyMap, int index) throws VNXFilePluginException {
_logger.info("ArgsCreator: Deleting VNX File System {}", keyMap.get(VNXFileConstants.FILESYSTEM_ID));
InputStream iStream = null;
try {
Task task = new Task();
DeleteFileSystem delFS = new DeleteFileSystem();
String fsId = (String) keyMap.get(VNXFileConstants.FILESYSTEM_ID);
if (isInValid(fsId)) {
throw new VNXFilePluginException("Prior command did not execute successfully", VNXFilePluginException.ERRORCODE_ILLEGALARGUMENTEXCEPTION);
}
_logger.info("deleting file system id: {}", fsId);
delFS.setFileSystem(fsId);
task.setDeleteFileSystem(delFS);
iStream = _vnxFileInputRequestBuilder.getTaskParamPacket(task);
} catch (JAXBException jaxbException) {
throw new VNXFilePluginException("Exception occurred while generating input xml for delete file system", jaxbException.getCause());
}
return iStream;
}
Aggregations