class ComplianceServiceImpl implements ComplianceService, Constants {

    @Override
    public List<String> getResourceType(String assetgroup, String domain) throws ServiceException {
        List<String> targetTypes = new ArrayList<>();

        if (!StringUtils.isEmpty(projEligibletypes)) {
            String[] projectionTargetTypes = projEligibletypes.split(",");
            String ttypes = repository.getTargetTypeForAG(assetgroup, domain);
            for (String projTargetType : projectionTargetTypes) {
                if (ttypes.contains(projTargetType)) {
                    targetTypes.add(projTargetType);
                }
            }
        } else {
            throw new ServiceException("Please configure the projection targettypes");
        }
        return targetTypes;
    }

}