Search in sources :

Example 1 with FileSystemUsageSet

use of com.emc.nas.vnxfile.xmlapi.FileSystemUsageSet in project coprhd-controller by CoprHD.

the class VNXFileArgsCreator method fetchFileSystemUsageStats.

/**
 * create a FileSystemUsage XML request and returns a stream after marshalling.
 *
 * @param argument
 * @param keyMap
 * @param index
 * @return
 * @throws VNXFilePluginException
 */
public InputStream fetchFileSystemUsageStats(final Argument argument, final Map<String, Object> keyMap, int index) throws VNXFilePluginException {
    _logger.info("Creating filesystem usage query");
    InputStream iStream = null;
    try {
        QueryStats queryStats = new QueryStats();
        FileSystemUsageSet fsUsageSet = new FileSystemUsageSet();
        queryStats.setFileSystemUsage(fsUsageSet);
        iStream = _vnxFileInputRequestBuilder.getSingleQueryStatsPacket(queryStats);
    } catch (JAXBException jaxbException) {
        throw new VNXFilePluginException("Exception occurred while generating input xml for fileSystem usage info", jaxbException.getCause());
    }
    return iStream;
}
Also used : FileSystemUsageSet(com.emc.nas.vnxfile.xmlapi.FileSystemUsageSet) QueryStats(com.emc.nas.vnxfile.xmlapi.QueryStats) InputStream(java.io.InputStream) JAXBException(javax.xml.bind.JAXBException)

Aggregations

FileSystemUsageSet (com.emc.nas.vnxfile.xmlapi.FileSystemUsageSet)1 QueryStats (com.emc.nas.vnxfile.xmlapi.QueryStats)1 InputStream (java.io.InputStream)1 JAXBException (javax.xml.bind.JAXBException)1