Page 1 of 1

vCD query service

Posted: Thu Dec 01, 2016 9:06 am
by leefriend
Find objects in vCD using the query service.

Get all storage profiles for a given vCDHost:

Code: Select all

inputs: vCDHost
var queryService = vCDHost.getQueryService();
var expression = new VclExpression(VclQueryProviderVdcStorageProfileField.NAME, "*", VclExpressionType.EQUALS);
var filter = new VclQueryFilter(expression);
var params = new VclParams();
var resultsSet = queryService.queryRecords(VclQueryRecordType.PROVIDERSTORAGEPROFILE, params);