I want to create a tag, using a groovy scriptlet, that will tag only under the following conditions:
1. Its a VM host only, and...
2. VM Host is tagged with "WinOS" tag, and...
3. The specific QID has specific content in (or not in) its results.
I have #1 and #3 but I can't guess what #2 is....anyone have any ideas for me?
// Skip testing on non-VM hosts.
if(asset.getAssetType()!=Asset.AssetType.HOST) return false;
// Skip testing on non-Windows hosts.
if (asset.resultsForQid(45017L) does not contain windows return false
if asset tag != WinOS return false;
// Obtain results for QID and create tag if the results do NOT match.
if (asset.resultsForQid(xxxxxL)!="adsfjasdfkjasdfklasjdfkldsfjF") return true;