Package com.google.api.ads.dfa.axis.v1_19

Examples of com.google.api.ads.dfa.axis.v1_19.CreativeAsset


    Calendar endTime = Calendar.getInstance();
    endTime.add(Calendar.MONTH, 1);
    rotationGroup.setEndTime(endTime);

    // Add creatives to the ad.
    CreativeAssignment creativeAssignment = new CreativeAssignment();
    creativeAssignment.setActive(true);
    creativeAssignment.setCreativeId(creativeId);

    // Create the click through URL.
    ClickThroughUrl clickThroughUrl = new ClickThroughUrl();
    clickThroughUrl.setDefaultLandingPageUsed(true);
    clickThroughUrl.setLandingPageId(0);
    creativeAssignment.setClickThroughUrl(clickThroughUrl);

    // Create the creative assignments.
    CreativeAssignment[] creativeAssignments = new CreativeAssignment[]{creativeAssignment};
    rotationGroup.setCreativeAssignments(creativeAssignments);
    rotationGroup.setRotationType(1);
View Full Code Here


          throws Exception {
    // Request the service.
    CreativeFieldRemote service = dfaServices.get(session, CreativeFieldRemote.class);

    // Create the creative field.
    CreativeField creativeField = new CreativeField();
    creativeField.setId(-1);
    creativeField.setName(creativeFieldName);
    creativeField.setAdvertiserId(advertiserId);

    // Save the creative field.
    CreativeFieldSaveResult creativeFieldSaveResult = service.saveCreativeField(creativeField);

    // Display the new creative field ID.
View Full Code Here

  public static void runExample(
      DfaServices dfaServices, DfaSession session, String creativeFieldName, long advertiserId)
          throws Exception {
    // Request the service.
    CreativeFieldRemote service = dfaServices.get(session, CreativeFieldRemote.class);

    // Create the creative field.
    CreativeField creativeField = new CreativeField();
    creativeField.setId(-1);
    creativeField.setName(creativeFieldName);
    creativeField.setAdvertiserId(advertiserId);

    // Save the creative field.
    CreativeFieldSaveResult creativeFieldSaveResult = service.saveCreativeField(creativeField);

    // Display the new creative field ID.
    System.out.printf("Creative field with ID \"%s\" was created.%n",
        creativeFieldSaveResult.getId());
  }
View Full Code Here

  public static void runExample(
      DfaServices dfaServices, DfaSession session, String creativeFieldValueName,
      long creativeFieldId) throws Exception {
    // Request the service.
    CreativeFieldRemote service = dfaServices.get(session, CreativeFieldRemote.class);

    // Create the creative field value.
    CreativeFieldValue creativeFieldValue = new CreativeFieldValue();
    creativeFieldValue.setId(-1);
    creativeFieldValue.setName(creativeFieldValueName);
    creativeFieldValue.setCreativeFieldId(creativeFieldId);

    // Save the creative field value.
    CreativeFieldValueSaveResult creativeFieldValueSaveResult =
        service.saveCreativeFieldValue(creativeFieldValue);

    // Display the new creative field value ID.
    System.out.printf("Creative field value with ID \"%s\" was created.%n",
        creativeFieldValueSaveResult.getId());
  }
View Full Code Here

  public static void runExample(
      DfaServices dfaServices, DfaSession session, String searchString) throws Exception {

    // Request the service.
    CreativeFieldRemote service = dfaServices.get(session, CreativeFieldRemote.class);

    // Set up creative field value search criteria structure.
    CreativeFieldValueSearchCriteria creativeValueSearchCriteria =
        new CreativeFieldValueSearchCriteria();
    creativeValueSearchCriteria.setPageSize(10);
    creativeValueSearchCriteria.setSearchString(searchString);

    // Get creative field values for the selected criteria.
    CreativeFieldValueRecordSet creativeFieldValues =
        service.getCreativeFieldValues(creativeValueSearchCriteria);

    // Display creative field value names and IDs.
    if (creativeFieldValues.getRecords() != null) {
      for (CreativeFieldValue result : creativeFieldValues.getRecords()) {
        System.out.println("Creative field value with name \"" + result.getName()
View Full Code Here

    creativeField.setId(-1);
    creativeField.setName(creativeFieldName);
    creativeField.setAdvertiserId(advertiserId);

    // Save the creative field.
    CreativeFieldSaveResult creativeFieldSaveResult = service.saveCreativeField(creativeField);

    // Display the new creative field ID.
    System.out.printf("Creative field with ID \"%s\" was created.%n",
        creativeFieldSaveResult.getId());
  }
View Full Code Here

      long creativeFieldId) throws Exception {
    // Request the service.
    CreativeFieldRemote service = dfaServices.get(session, CreativeFieldRemote.class);

    // Create the creative field value.
    CreativeFieldValue creativeFieldValue = new CreativeFieldValue();
    creativeFieldValue.setId(-1);
    creativeFieldValue.setName(creativeFieldValueName);
    creativeFieldValue.setCreativeFieldId(creativeFieldId);

    // Save the creative field value.
    CreativeFieldValueSaveResult creativeFieldValueSaveResult =
        service.saveCreativeFieldValue(creativeFieldValue);
View Full Code Here

        new CreativeFieldValueSearchCriteria();
    creativeValueSearchCriteria.setPageSize(10);
    creativeValueSearchCriteria.setSearchString(searchString);

    // Get creative field values for the selected criteria.
    CreativeFieldValueRecordSet creativeFieldValues =
        service.getCreativeFieldValues(creativeValueSearchCriteria);

    // Display creative field value names and IDs.
    if (creativeFieldValues.getRecords() != null) {
      for (CreativeFieldValue result : creativeFieldValues.getRecords()) {
        System.out.println("Creative field value with name \"" + result.getName()
            + "\" and ID \"" + result.getId() + "\" was found.");
      }
    } else {
      System.out.print("No creative field values found for your criteria");
View Full Code Here

    creativeFieldValue.setId(-1);
    creativeFieldValue.setName(creativeFieldValueName);
    creativeFieldValue.setCreativeFieldId(creativeFieldId);

    // Save the creative field value.
    CreativeFieldValueSaveResult creativeFieldValueSaveResult =
        service.saveCreativeFieldValue(creativeFieldValue);

    // Display the new creative field value ID.
    System.out.printf("Creative field value with ID \"%s\" was created.%n",
        creativeFieldValueSaveResult.getId());
  }
View Full Code Here

    // Request the service.
    CreativeFieldRemote service = dfaServices.get(session, CreativeFieldRemote.class);

    // Set up creative field value search criteria structure.
    CreativeFieldValueSearchCriteria creativeValueSearchCriteria =
        new CreativeFieldValueSearchCriteria();
    creativeValueSearchCriteria.setPageSize(10);
    creativeValueSearchCriteria.setSearchString(searchString);

    // Get creative field values for the selected criteria.
    CreativeFieldValueRecordSet creativeFieldValues =
        service.getCreativeFieldValues(creativeValueSearchCriteria);
View Full Code Here

TOP

Related Classes of com.google.api.ads.dfa.axis.v1_19.CreativeAsset

Copyright © 2018 www.massapicom. 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.