Examples of mutate()


Examples of com.google.api.ads.adwords.axis.v201309.cm.CampaignFeedServiceInterface.mutate()

    CampaignFeedOperation operation = new CampaignFeedOperation();
    operation.setOperand(campaignFeed);
    operation.setOperator(Operator.ADD);
    CampaignFeedReturnValue result =
        campaignFeedService.mutate(new CampaignFeedOperation[] {operation});
    for (CampaignFeed savedCampaignFeed : result.getValue()) {
      System.out.printf("Campaign with ID %d was associated with feed with ID %d.\n",
          savedCampaignFeed.getCampaignId(), savedCampaignFeed.getFeedId());
    }
  }
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.CampaignServiceInterface.mutate()

    // Create operation.
    CampaignOperation operation = new CampaignOperation();
    operation.setOperand(campaign);
    operation.setOperator(Operator.ADD);

    CampaignReturnValue result = campaignService.mutate(new CampaignOperation[] {operation});
    Campaign newCampaign = result.getValue(0);

    System.out.printf("Campaign with name '%s', ID %d and bidding scheme ID %d was created.\n",
        newCampaign.getName(), newCampaign.getId(),
        newCampaign.getBiddingStrategyConfiguration().getBiddingStrategyId());
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.ConversionTrackerServiceInterface.mutate()

    ConversionTrackerOperation uploadConversionOperation = new ConversionTrackerOperation();
    uploadConversionOperation.setOperator(Operator.ADD);
    uploadConversionOperation.setOperand(uploadConversion);

    ConversionTrackerReturnValue conversionTrackerReturnValue = conversionTrackerService.mutate(
        new ConversionTrackerOperation[] {uploadConversionOperation});

    UploadConversion newUploadConversion =
        (UploadConversion) conversionTrackerReturnValue.getValue(0);
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.ExperimentServiceInterface.mutate()

    operation.setOperator(Operator.SET);

    ExperimentOperation[] operations = new ExperimentOperation[] {operation};

    // Promote experiment.
    ExperimentReturnValue result = experimentService.mutate(operations);

    // Display experiments.
    for (Experiment experimentResult : result.getValue()) {
      System.out.println("Experiment with name \"" + experimentResult.getName() + "\" and id \""
          + experimentResult.getId() + "\" was promoted.");
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.FeedItemServiceInterface.mutate()

      operation.setOperator(Operator.SET);
      operation.setOperand(feedItem);
      itemOperations.add(operation);
    }
    FeedItemReturnValue itemsUpdateReturnValue =
        feedItemService.mutate(itemOperations.toArray(new FeedItemOperation[0]));
    System.out.printf("Updated %d items%n", itemsUpdateReturnValue.getValue().length);
  }

  // See the Placeholder reference page for a list of all the placeholder types
  // and fields:
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.FeedMappingServiceInterface.mutate()

        new Predicate("FeedId", PredicateOperator.EQUALS, new String[] {feedId.toString()})});

    FeedMapping feedMapping = mappingService.get(selector).getEntries()[0];

    // Remove the existing mapping (FeedMapping is immutable).
    feedMapping = mappingService.mutate(new FeedMappingOperation[] {
        new FeedMappingOperation(Operator.REMOVE, null, feedMapping)}).getValue(0);

    // Create line 1 and line 2 attribute field mappings.
    AttributeFieldMapping line1FieldMapping = new AttributeFieldMapping();
    line1FieldMapping.setFeedAttributeId(line1FeedAttribute.getId());
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.FeedServiceInterface.mutate()

    FeedOperation feedOperation = new FeedOperation();
    feedOperation.setOperand(feed);
    feedOperation.setOperator(Operator.SET);

    FeedServiceInterface feedService = adWordsServices.get(session, FeedServiceInterface.class);
    FeedReturnValue mutateFeedResult = feedService.mutate(new FeedOperation[] {feedOperation});

    // Get the new attributes from the mutated feed.
    Feed mutatedFeed = mutateFeedResult.getValue()[0];
    line1Attribute = mutatedFeed.getAttributes(nextAttributeIndex);
    line2Attribute = mutatedFeed.getAttributes(nextAttributeIndex + 1);
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.MutateJobServiceInterface.mutate()

    BulkMutateJobPolicy policy = new BulkMutateJobPolicy();
    policy.setPrerequisiteJobIds(new long[] {});

    // Call mutate to create a new job.
    SimpleMutateJob response =
        mutateJobService.mutate(operations.toArray(new Operation[operations.size()]), policy);

    long jobId = response.getId();
    System.out.printf("Job with ID %d was successfully created.\n", jobId);

    // Create selector to retrieve job status and wait for it to complete.
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.cm.OfflineConversionFeedServiceInterface.mutate()

    OfflineConversionFeedOperation offlineConversionOperation =
        new OfflineConversionFeedOperation();
    offlineConversionOperation.setOperator(Operator.ADD);
    offlineConversionOperation.setOperand(feed);

    OfflineConversionFeedReturnValue offlineConversionReturnValue = offlineConversionFeedService
        .mutate(new OfflineConversionFeedOperation[] {offlineConversionOperation});

    OfflineConversionFeed newFeed = offlineConversionReturnValue.getValue(0);

    System.out.printf(
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201309.mcm.ManagedCustomerServiceInterface.mutate()

    operation.setOperator(Operator.ADD);

    ManagedCustomerOperation[] operations = new ManagedCustomerOperation[] {operation};

    // Add account.
    ManagedCustomerReturnValue result = managedCustomerService.mutate(operations);

    // Display accounts.
    for (ManagedCustomer customerResult : result.getValue()) {
      System.out.println("Account with customer ID \"" + customerResult.getCustomerId()
          + "\" was created.");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.