try {
// Log SOAP XML request and response.
DfpServiceLogger.log();
// Get DfpUser from "~/dfp.properties".
DfpUser user = new DfpUser();
// Get the CustomTargetingService.
CustomTargetingServiceInterface customTargetingService =
user.getService(DfpService.V201311.CUSTOM_TARGETING_SERVICE);
// Create a statement to only select predefined custom targeting keys.
Statement filterStatement = new StatementBuilder("WHERE type = :type LIMIT 500").putValue(
"type", CustomTargetingKeyType.PREDEFINED.toString()).toStatement();