Package com.google.api.ads.dfp.jaxws.v201308

Examples of com.google.api.ads.dfp.jaxws.v201308.PublisherQueryLanguageServiceInterface


    assertEquals(false, Pql.getApiValue(booleanValue1));
    assertEquals(1L, Pql.getApiValue(numberValue1));
    assertEquals(1.02, Pql.getApiValue(numberValue2));
    assertEquals(dateTime1, Pql.getApiValue(dateTimeValue1));
    assertEquals(date1, Pql.getApiValue(dateValue1));
    assertNull(Pql.getApiValue(new TextValue()));
  }
View Full Code Here


   */
  public static Value createValue(Object value) {
    if (value instanceof Value) {
      return (Value) value;
    } else if (value == null) {
      return new TextValue();
    } else {
      if (value instanceof Boolean) {
        BooleanValue booleanValue = new BooleanValue();
        booleanValue.setValue((Boolean) value);
        return booleanValue;
      } else if (value instanceof Double || value instanceof Long || value instanceof Integer) {
        NumberValue numberValue = new NumberValue();
        numberValue.setValue(value.toString());
        return numberValue;
      } else if (value instanceof String) {
        TextValue textValue = new TextValue();
        textValue.setValue((String) value);
        return textValue;
      } else if (value instanceof DateTime) {
        DateTimeValue dateTimeValue = new DateTimeValue();
        dateTimeValue.setValue((DateTime) value);
        return dateTimeValue;
View Full Code Here

      // Get DfpUser from "~/dfp.properties".
      DfpUser user = new DfpUser();

      // Get the PublisherQueryLanguageService.
      PublisherQueryLanguageServiceInterface pqlService =
          user.getService(DfpService.V201208.PUBLISHER_QUERY_LANGUAGE_SERVICE);

      // Create statement to select all targetable cities.
      // For criteria that do not have a "targetable" property, that predicate
      // may be left off, i.e. just "SELECT * FROM Browser_Groups LIMIT 500"
      String selectStatement = "SELECT * FROM City WHERE targetable = true LIMIT 500";
      int offset = 0;
      int resultSetSize = 0;
      List<Row> allRows = new ArrayList<Row>();
      ResultSet resultSet;
     
      do {
        StatementBuilder statementBuilder =
            new StatementBuilder(selectStatement + " OFFSET " + offset);
       
        // Get all cities.
        resultSet = pqlService.select(statementBuilder.toStatement());

        // Collect all cities from each page.
        allRows.addAll(Arrays.asList(resultSet.getRows()));
       
        // Display results.
View Full Code Here

      // Get DfpUser from "~/dfp.properties".
      DfpUser user = new DfpUser();

      // Get the PublisherQueryLanguageService.
      PublisherQueryLanguageServiceInterface pqlService =
          user.getService(DfpService.V201211.PUBLISHER_QUERY_LANGUAGE_SERVICE);

      // Create statement to select all targetable cities.
      // For criteria that do not have a "targetable" property, that predicate
      // may be left off, i.e. just "SELECT * FROM Browser_Groups LIMIT 500"
      String selectStatement = "SELECT * FROM City WHERE targetable = true LIMIT 500";
      int offset = 0;
      int resultSetSize = 0;
      List<Row> allRows = new ArrayList<Row>();
      ResultSet resultSet;
     
      do {
        StatementBuilder statementBuilder =
            new StatementBuilder(selectStatement + " OFFSET " + offset);
       
        // Get all cities.
        resultSet = pqlService.select(statementBuilder.toStatement());

        // Collect all cities from each page.
        allRows.addAll(Arrays.asList(resultSet.getRows()));
       
        // Display results.
View Full Code Here

      // Get DfpUser from "~/dfp.properties".
      DfpUser user = new DfpUser();

      // Get the PublisherQueryLanguageService.
      PublisherQueryLanguageServiceInterface pqlService =
          user.getService(DfpService.V201302.PUBLISHER_QUERY_LANGUAGE_SERVICE);

      // Create statement to select all targetable cities.
      // For criteria that do not have a "targetable" property, that predicate
      // may be left off, i.e. just "SELECT * FROM Browser_Groups LIMIT 500"
      String selectStatement = "SELECT * FROM City WHERE targetable = true LIMIT 500";
      int offset = 0;
      int resultSetSize = 0;
      List<Row> allRows = new ArrayList<Row>();
      ResultSet resultSet;
     
      do {
        StatementBuilder statementBuilder =
            new StatementBuilder(selectStatement + " OFFSET " + offset);
       
        // Get all cities.
        resultSet = pqlService.select(statementBuilder.toStatement());

        // Collect all cities from each page.
        allRows.addAll(Arrays.asList(resultSet.getRows()));
       
        // Display results.
View Full Code Here

      // Get DfpUser from "~/dfp.properties".
      DfpUser user = new DfpUser();

      // Get the PublisherQueryLanguageService.
      PublisherQueryLanguageServiceInterface pqlService =
          user.getService(DfpService.V201306.PUBLISHER_QUERY_LANGUAGE_SERVICE);

      // Create statement to select all targetable cities.
      // For criteria that do not have a "targetable" property, that predicate
      // may be left off, i.e. just "SELECT * FROM Browser_Groups LIMIT 500"
      String selectStatement = "SELECT * FROM City WHERE targetable = true LIMIT 500";
      int offset = 0;
      int resultSetSize = 0;
      List<Row> allRows = new ArrayList<Row>();
      ResultSet resultSet;
     
      do {
        StatementBuilder statementBuilder =
            new StatementBuilder(selectStatement + " OFFSET " + offset);
       
        // Get all cities.
        resultSet = pqlService.select(statementBuilder.toStatement());

        // Collect all cities from each page.
        allRows.addAll(Arrays.asList(resultSet.getRows()));
       
        // Display results.
View Full Code Here

      // Get DfpUser from "~/dfp.properties".
      DfpUser user = new DfpUser();

      // Get the PublisherQueryLanguageService.
      PublisherQueryLanguageServiceInterface pqlService =
          user.getService(DfpService.V201308.PUBLISHER_QUERY_LANGUAGE_SERVICE);

      // Create statement to select all targetable cities.
      // For criteria that do not have a "targetable" property, that predicate
      // may be left off, i.e. just "SELECT * FROM Browser_Groups LIMIT 500"
      String selectStatement = "SELECT * FROM City WHERE targetable = true LIMIT 500";
      int offset = 0;
      int resultSetSize = 0;
      List<Row> allRows = new ArrayList<Row>();
      ResultSet resultSet;
     
      do {
        StatementBuilder statementBuilder =
            new StatementBuilder(selectStatement + " OFFSET " + offset);
       
        // Get all cities.
        resultSet = pqlService.select(statementBuilder.toStatement());

        // Collect all cities from each page.
        allRows.addAll(Arrays.asList(resultSet.getRows()));
       
        // Display results.
View Full Code Here

      // Get DfpUser from "~/dfp.properties".
      DfpUser user = new DfpUser();

      // Get the PublisherQueryLanguageService.
      PublisherQueryLanguageServiceInterface pqlService =
          user.getService(DfpService.V201311.PUBLISHER_QUERY_LANGUAGE_SERVICE);

      // Create statement to select all targetable cities.
      // For criteria that do not have a "targetable" property, that predicate
      // may be left off, i.e. just "SELECT * FROM Browser_Groups LIMIT 500"
      String selectStatement = "SELECT * FROM City WHERE targetable = true LIMIT 500";
      int offset = 0;
      int resultSetSize = 0;
      List<Row> allRows = new ArrayList<Row>();
      ResultSet resultSet;
     
      do {
        StatementBuilder statementBuilder =
            new StatementBuilder(selectStatement + " OFFSET " + offset);
       
        // Get all cities.
        resultSet = pqlService.select(statementBuilder.toStatement());

        // Collect all cities from each page.
        allRows.addAll(Arrays.asList(resultSet.getRows()));
       
        // Display results.
View Full Code Here

TOP

Related Classes of com.google.api.ads.dfp.jaxws.v201308.PublisherQueryLanguageServiceInterface

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.