com.google.api.services.gan.Gan Maven / Gradle / Ivy
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
* in compliance with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
* or implied. See the License for the specific language governing permissions and limitations under
* the License.
*/
/*
* This code was generated by https://github.com/google/apis-client-generator/
* (build: 2016-04-08 17:16:44 UTC)
* on 2016-04-27 at 00:52:02 UTC
* Modify at your own risk.
*/
package com.google.api.services.gan;
/**
* Service definition for Gan (v1beta1).
*
*
* Lets you have programmatic access to your Google Affiliate Network data.
*
*
*
* For more information about this service, see the
* API Documentation
*
*
*
* This service uses {@link GanRequestInitializer} to initialize global parameters via its
* {@link Builder}.
*
*
* @since 1.3
* @author Google, Inc.
*/
@SuppressWarnings("javadoc")
public class Gan extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient {
// Note: Leave this static initializer at the top of the file.
static {
com.google.api.client.util.Preconditions.checkState(
com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION == 1 &&
com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION >= 15,
"You are currently running with version %s of google-api-client. " +
"You need at least version 1.15 of google-api-client to run version " +
"1.21.0 of the Google Affiliate Network API library.", com.google.api.client.googleapis.GoogleUtils.VERSION);
}
/**
* The default encoded root URL of the service. This is determined when the library is generated
* and normally should not be changed.
*
* @since 1.7
*/
public static final String DEFAULT_ROOT_URL = "https://www.googleapis.com/";
/**
* The default encoded service path of the service. This is determined when the library is
* generated and normally should not be changed.
*
* @since 1.7
*/
public static final String DEFAULT_SERVICE_PATH = "gan/v1beta1/";
/**
* The default encoded base URL of the service. This is determined when the library is generated
* and normally should not be changed.
*/
public static final String DEFAULT_BASE_URL = DEFAULT_ROOT_URL + DEFAULT_SERVICE_PATH;
/**
* Constructor.
*
*
* Use {@link Builder} if you need to specify any of the optional parameters.
*
*
* @param transport HTTP transport, which should normally be:
*
* - Google App Engine:
* {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}
* - Android: {@code newCompatibleTransport} from
* {@code com.google.api.client.extensions.android.http.AndroidHttp}
* - Java: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()}
*
*
* @param jsonFactory JSON factory, which may be:
*
* - Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}
* - Google GSON: {@code com.google.api.client.json.gson.GsonFactory}
* - Android Honeycomb or higher:
* {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}
*
* @param httpRequestInitializer HTTP request initializer or {@code null} for none
* @since 1.7
*/
public Gan(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory,
com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) {
this(new Builder(transport, jsonFactory, httpRequestInitializer));
}
/**
* @param builder builder
*/
Gan(Builder builder) {
super(builder);
}
@Override
protected void initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest> httpClientRequest) throws java.io.IOException {
super.initialize(httpClientRequest);
}
/**
* An accessor for creating requests from the Advertisers collection.
*
* The typical use is:
*
* {@code Gan gan = new Gan(...);}
* {@code Gan.Advertisers.List request = gan.advertisers().list(parameters ...)}
*
*
* @return the resource collection
*/
public Advertisers advertisers() {
return new Advertisers();
}
/**
* The "advertisers" collection of methods.
*/
public class Advertisers {
/**
* Retrieves data about a single advertiser if that the requesting advertiser/publisher has access
* to it. Only publishers can lookup advertisers. Advertisers can request information about
* themselves by omitting the advertiserId query parameter.
*
* Create a request for the method "advertisers.get".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @return the request
*/
public Get get(java.lang.String role, java.lang.String roleId) throws java.io.IOException {
Get result = new Get(role, roleId);
initialize(result);
return result;
}
public class Get extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/advertiser";
/**
* Retrieves data about a single advertiser if that the requesting advertiser/publisher has access
* to it. Only publishers can lookup advertisers. Advertisers can request information about
* themselves by omitting the advertiserId query parameter.
*
* Create a request for the method "advertisers.get".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation. {@link
* Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @since 1.13
*/
protected Get(java.lang.String role, java.lang.String roleId) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Advertiser.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public Get setAlt(java.lang.String alt) {
return (Get) super.setAlt(alt);
}
@Override
public Get setFields(java.lang.String fields) {
return (Get) super.setFields(fields);
}
@Override
public Get setKey(java.lang.String key) {
return (Get) super.setKey(key);
}
@Override
public Get setOauthToken(java.lang.String oauthToken) {
return (Get) super.setOauthToken(oauthToken);
}
@Override
public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
return (Get) super.setPrettyPrint(prettyPrint);
}
@Override
public Get setQuotaUser(java.lang.String quotaUser) {
return (Get) super.setQuotaUser(quotaUser);
}
@Override
public Get setUserIp(java.lang.String userIp) {
return (Get) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public Get setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public Get setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/** The ID of the advertiser to look up. Optional. */
@com.google.api.client.util.Key
private java.lang.String advertiserId;
/** The ID of the advertiser to look up. Optional.
*/
public java.lang.String getAdvertiserId() {
return advertiserId;
}
/** The ID of the advertiser to look up. Optional. */
public Get setAdvertiserId(java.lang.String advertiserId) {
this.advertiserId = advertiserId;
return this;
}
@Override
public Get set(String parameterName, Object value) {
return (Get) super.set(parameterName, value);
}
}
/**
* Retrieves data about all advertisers that the requesting advertiser/publisher has access to.
*
* Create a request for the method "advertisers.list".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @return the request
*/
public List list(java.lang.String role, java.lang.String roleId) throws java.io.IOException {
List result = new List(role, roleId);
initialize(result);
return result;
}
public class List extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/advertisers";
/**
* Retrieves data about all advertisers that the requesting advertiser/publisher has access to.
*
* Create a request for the method "advertisers.list".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation. {@link
* List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @since 1.13
*/
protected List(java.lang.String role, java.lang.String roleId) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Advertisers.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public List setAlt(java.lang.String alt) {
return (List) super.setAlt(alt);
}
@Override
public List setFields(java.lang.String fields) {
return (List) super.setFields(fields);
}
@Override
public List setKey(java.lang.String key) {
return (List) super.setKey(key);
}
@Override
public List setOauthToken(java.lang.String oauthToken) {
return (List) super.setOauthToken(oauthToken);
}
@Override
public List setPrettyPrint(java.lang.Boolean prettyPrint) {
return (List) super.setPrettyPrint(prettyPrint);
}
@Override
public List setQuotaUser(java.lang.String quotaUser) {
return (List) super.setQuotaUser(quotaUser);
}
@Override
public List setUserIp(java.lang.String userIp) {
return (List) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public List setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public List setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/**
* Caret(^) delimted list of advertiser categories. Valid categories are defined here:
* http://www.google.com/support/affiliatenetwork/advertiser/bin/answer.py?hl=en=107581.
* Filters out all advertisers not in one of the given advertiser categories. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String advertiserCategory;
/** Caret(^) delimted list of advertiser categories. Valid categories are defined here:
http://www.google.com/support/affiliatenetwork/advertiser/bin/answer.py?hl=en=107581. Filters out
all advertisers not in one of the given advertiser categories. Optional.
*/
public java.lang.String getAdvertiserCategory() {
return advertiserCategory;
}
/**
* Caret(^) delimted list of advertiser categories. Valid categories are defined here:
* http://www.google.com/support/affiliatenetwork/advertiser/bin/answer.py?hl=en=107581.
* Filters out all advertisers not in one of the given advertiser categories. Optional.
*/
public List setAdvertiserCategory(java.lang.String advertiserCategory) {
this.advertiserCategory = advertiserCategory;
return this;
}
/** Max number of items to return in this page. Optional. Defaults to 20. */
@com.google.api.client.util.Key
private java.lang.Long maxResults;
/** Max number of items to return in this page. Optional. Defaults to 20.
[minimum: 0] [maximum: 100]
*/
public java.lang.Long getMaxResults() {
return maxResults;
}
/** Max number of items to return in this page. Optional. Defaults to 20. */
public List setMaxResults(java.lang.Long maxResults) {
this.maxResults = maxResults;
return this;
}
/**
* Filters out all advertisers that have a ninety day EPC average lower than the given value
* (inclusive). Min value: 0.0. Optional.
*/
@com.google.api.client.util.Key
private java.lang.Double minNinetyDayEpc;
/** Filters out all advertisers that have a ninety day EPC average lower than the given value
(inclusive). Min value: 0.0. Optional.
*/
public java.lang.Double getMinNinetyDayEpc() {
return minNinetyDayEpc;
}
/**
* Filters out all advertisers that have a ninety day EPC average lower than the given value
* (inclusive). Min value: 0.0. Optional.
*/
public List setMinNinetyDayEpc(java.lang.Double minNinetyDayEpc) {
this.minNinetyDayEpc = minNinetyDayEpc;
return this;
}
/**
* A value between 1 and 4, where 1 represents the quartile of advertisers with the lowest
* ranks and 4 represents the quartile of advertisers with the highest ranks. Filters out all
* advertisers with a lower rank than the given quartile. For example if a 2 was given only
* advertisers with a payout rank of 25 or higher would be included. Optional.
*/
@com.google.api.client.util.Key
private java.lang.Integer minPayoutRank;
/** A value between 1 and 4, where 1 represents the quartile of advertisers with the lowest ranks and 4
represents the quartile of advertisers with the highest ranks. Filters out all advertisers with a
lower rank than the given quartile. For example if a 2 was given only advertisers with a payout
rank of 25 or higher would be included. Optional.
[minimum: 1] [maximum: 4]
*/
public java.lang.Integer getMinPayoutRank() {
return minPayoutRank;
}
/**
* A value between 1 and 4, where 1 represents the quartile of advertisers with the lowest
* ranks and 4 represents the quartile of advertisers with the highest ranks. Filters out all
* advertisers with a lower rank than the given quartile. For example if a 2 was given only
* advertisers with a payout rank of 25 or higher would be included. Optional.
*/
public List setMinPayoutRank(java.lang.Integer minPayoutRank) {
this.minPayoutRank = minPayoutRank;
return this;
}
/**
* Filters out all advertisers that have a seven day EPC average lower than the given value
* (inclusive). Min value: 0.0. Optional.
*/
@com.google.api.client.util.Key
private java.lang.Double minSevenDayEpc;
/** Filters out all advertisers that have a seven day EPC average lower than the given value
(inclusive). Min value: 0.0. Optional.
*/
public java.lang.Double getMinSevenDayEpc() {
return minSevenDayEpc;
}
/**
* Filters out all advertisers that have a seven day EPC average lower than the given value
* (inclusive). Min value: 0.0. Optional.
*/
public List setMinSevenDayEpc(java.lang.Double minSevenDayEpc) {
this.minSevenDayEpc = minSevenDayEpc;
return this;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
@com.google.api.client.util.Key
private java.lang.String pageToken;
/** The value of 'nextPageToken' from the previous page. Optional.
*/
public java.lang.String getPageToken() {
return pageToken;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
public List setPageToken(java.lang.String pageToken) {
this.pageToken = pageToken;
return this;
}
/**
* Filters out all advertisers for which do not have the given relationship status with the
* requesting publisher.
*/
@com.google.api.client.util.Key
private java.lang.String relationshipStatus;
/** Filters out all advertisers for which do not have the given relationship status with the requesting
publisher.
*/
public java.lang.String getRelationshipStatus() {
return relationshipStatus;
}
/**
* Filters out all advertisers for which do not have the given relationship status with the
* requesting publisher.
*/
public List setRelationshipStatus(java.lang.String relationshipStatus) {
this.relationshipStatus = relationshipStatus;
return this;
}
@Override
public List set(String parameterName, Object value) {
return (List) super.set(parameterName, value);
}
}
}
/**
* An accessor for creating requests from the CcOffers collection.
*
* The typical use is:
*
* {@code Gan gan = new Gan(...);}
* {@code Gan.CcOffers.List request = gan.ccOffers().list(parameters ...)}
*
*
* @return the resource collection
*/
public CcOffers ccOffers() {
return new CcOffers();
}
/**
* The "ccOffers" collection of methods.
*/
public class CcOffers {
/**
* Retrieves credit card offers for the given publisher.
*
* Create a request for the method "ccOffers.list".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation.
*
* @param publisher The ID of the publisher in question.
* @return the request
*/
public List list(java.lang.String publisher) throws java.io.IOException {
List result = new List(publisher);
initialize(result);
return result;
}
public class List extends GanRequest {
private static final String REST_PATH = "publishers/{publisher}/ccOffers";
/**
* Retrieves credit card offers for the given publisher.
*
* Create a request for the method "ccOffers.list".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation. {@link
* List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param publisher The ID of the publisher in question.
* @since 1.13
*/
protected List(java.lang.String publisher) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.CcOffers.class);
this.publisher = com.google.api.client.util.Preconditions.checkNotNull(publisher, "Required parameter publisher must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public List setAlt(java.lang.String alt) {
return (List) super.setAlt(alt);
}
@Override
public List setFields(java.lang.String fields) {
return (List) super.setFields(fields);
}
@Override
public List setKey(java.lang.String key) {
return (List) super.setKey(key);
}
@Override
public List setOauthToken(java.lang.String oauthToken) {
return (List) super.setOauthToken(oauthToken);
}
@Override
public List setPrettyPrint(java.lang.Boolean prettyPrint) {
return (List) super.setPrettyPrint(prettyPrint);
}
@Override
public List setQuotaUser(java.lang.String quotaUser) {
return (List) super.setQuotaUser(quotaUser);
}
@Override
public List setUserIp(java.lang.String userIp) {
return (List) super.setUserIp(userIp);
}
/** The ID of the publisher in question. */
@com.google.api.client.util.Key
private java.lang.String publisher;
/** The ID of the publisher in question.
*/
public java.lang.String getPublisher() {
return publisher;
}
/** The ID of the publisher in question. */
public List setPublisher(java.lang.String publisher) {
this.publisher = publisher;
return this;
}
/** The advertiser ID of a card issuer whose offers to include. Optional, may be repeated. */
@com.google.api.client.util.Key
private java.util.List advertiser;
/** The advertiser ID of a card issuer whose offers to include. Optional, may be repeated.
*/
public java.util.List getAdvertiser() {
return advertiser;
}
/** The advertiser ID of a card issuer whose offers to include. Optional, may be repeated. */
public List setAdvertiser(java.util.List advertiser) {
this.advertiser = advertiser;
return this;
}
/** The set of fields to return. */
@com.google.api.client.util.Key
private java.lang.String projection;
/** The set of fields to return.
*/
public java.lang.String getProjection() {
return projection;
}
/** The set of fields to return. */
public List setProjection(java.lang.String projection) {
this.projection = projection;
return this;
}
@Override
public List set(String parameterName, Object value) {
return (List) super.set(parameterName, value);
}
}
}
/**
* An accessor for creating requests from the Events collection.
*
* The typical use is:
*
* {@code Gan gan = new Gan(...);}
* {@code Gan.Events.List request = gan.events().list(parameters ...)}
*
*
* @return the resource collection
*/
public Events events() {
return new Events();
}
/**
* The "events" collection of methods.
*/
public class Events {
/**
* Retrieves event data for a given advertiser/publisher.
*
* Create a request for the method "events.list".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @return the request
*/
public List list(java.lang.String role, java.lang.String roleId) throws java.io.IOException {
List result = new List(role, roleId);
initialize(result);
return result;
}
public class List extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/events";
/**
* Retrieves event data for a given advertiser/publisher.
*
* Create a request for the method "events.list".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation. {@link
* List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @since 1.13
*/
protected List(java.lang.String role, java.lang.String roleId) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Events.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public List setAlt(java.lang.String alt) {
return (List) super.setAlt(alt);
}
@Override
public List setFields(java.lang.String fields) {
return (List) super.setFields(fields);
}
@Override
public List setKey(java.lang.String key) {
return (List) super.setKey(key);
}
@Override
public List setOauthToken(java.lang.String oauthToken) {
return (List) super.setOauthToken(oauthToken);
}
@Override
public List setPrettyPrint(java.lang.Boolean prettyPrint) {
return (List) super.setPrettyPrint(prettyPrint);
}
@Override
public List setQuotaUser(java.lang.String quotaUser) {
return (List) super.setQuotaUser(quotaUser);
}
@Override
public List setUserIp(java.lang.String userIp) {
return (List) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public List setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public List setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/**
* Caret(^) delimited list of advertiser IDs. Filters out all events that do not reference one
* of the given advertiser IDs. Only used when under publishers role. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String advertiserId;
/** Caret(^) delimited list of advertiser IDs. Filters out all events that do not reference one of the
given advertiser IDs. Only used when under publishers role. Optional.
*/
public java.lang.String getAdvertiserId() {
return advertiserId;
}
/**
* Caret(^) delimited list of advertiser IDs. Filters out all events that do not reference one
* of the given advertiser IDs. Only used when under publishers role. Optional.
*/
public List setAdvertiserId(java.lang.String advertiserId) {
this.advertiserId = advertiserId;
return this;
}
/**
* Filters out all charge events that are not of the given charge type. Valid values: 'other',
* 'slotting_fee', 'monthly_minimum', 'tier_bonus', 'credit', 'debit'. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String chargeType;
/** Filters out all charge events that are not of the given charge type. Valid values: 'other',
'slotting_fee', 'monthly_minimum', 'tier_bonus', 'credit', 'debit'. Optional.
*/
public java.lang.String getChargeType() {
return chargeType;
}
/**
* Filters out all charge events that are not of the given charge type. Valid values: 'other',
* 'slotting_fee', 'monthly_minimum', 'tier_bonus', 'credit', 'debit'. Optional.
*/
public List setChargeType(java.lang.String chargeType) {
this.chargeType = chargeType;
return this;
}
/**
* Filters out all events later than given date. Optional. Defaults to 24 hours after
* eventMin.
*/
@com.google.api.client.util.Key
private java.lang.String eventDateMax;
/** Filters out all events later than given date. Optional. Defaults to 24 hours after eventMin.
*/
public java.lang.String getEventDateMax() {
return eventDateMax;
}
/**
* Filters out all events later than given date. Optional. Defaults to 24 hours after
* eventMin.
*/
public List setEventDateMax(java.lang.String eventDateMax) {
this.eventDateMax = eventDateMax;
return this;
}
/**
* Filters out all events earlier than given date. Optional. Defaults to 24 hours from current
* date/time.
*/
@com.google.api.client.util.Key
private java.lang.String eventDateMin;
/** Filters out all events earlier than given date. Optional. Defaults to 24 hours from current
date/time.
*/
public java.lang.String getEventDateMin() {
return eventDateMin;
}
/**
* Filters out all events earlier than given date. Optional. Defaults to 24 hours from current
* date/time.
*/
public List setEventDateMin(java.lang.String eventDateMin) {
this.eventDateMin = eventDateMin;
return this;
}
/**
* Caret(^) delimited list of link IDs. Filters out all events that do not reference one of
* the given link IDs. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String linkId;
/** Caret(^) delimited list of link IDs. Filters out all events that do not reference one of the given
link IDs. Optional.
*/
public java.lang.String getLinkId() {
return linkId;
}
/**
* Caret(^) delimited list of link IDs. Filters out all events that do not reference one of
* the given link IDs. Optional.
*/
public List setLinkId(java.lang.String linkId) {
this.linkId = linkId;
return this;
}
/** Max number of offers to return in this page. Optional. Defaults to 20. */
@com.google.api.client.util.Key
private java.lang.Long maxResults;
/** Max number of offers to return in this page. Optional. Defaults to 20.
[minimum: 0] [maximum: 100]
*/
public java.lang.Long getMaxResults() {
return maxResults;
}
/** Max number of offers to return in this page. Optional. Defaults to 20. */
public List setMaxResults(java.lang.Long maxResults) {
this.maxResults = maxResults;
return this;
}
/**
* Caret(^) delimited list of member IDs. Filters out all events that do not reference one of
* the given member IDs. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String memberId;
/** Caret(^) delimited list of member IDs. Filters out all events that do not reference one of the
given member IDs. Optional.
*/
public java.lang.String getMemberId() {
return memberId;
}
/**
* Caret(^) delimited list of member IDs. Filters out all events that do not reference one of
* the given member IDs. Optional.
*/
public List setMemberId(java.lang.String memberId) {
this.memberId = memberId;
return this;
}
/**
* Filters out all events modified later than given date. Optional. Defaults to 24 hours after
* modifyDateMin, if modifyDateMin is explicitly set.
*/
@com.google.api.client.util.Key
private java.lang.String modifyDateMax;
/** Filters out all events modified later than given date. Optional. Defaults to 24 hours after
modifyDateMin, if modifyDateMin is explicitly set.
*/
public java.lang.String getModifyDateMax() {
return modifyDateMax;
}
/**
* Filters out all events modified later than given date. Optional. Defaults to 24 hours after
* modifyDateMin, if modifyDateMin is explicitly set.
*/
public List setModifyDateMax(java.lang.String modifyDateMax) {
this.modifyDateMax = modifyDateMax;
return this;
}
/**
* Filters out all events modified earlier than given date. Optional. Defaults to 24 hours
* before the current modifyDateMax, if modifyDateMax is explicitly set.
*/
@com.google.api.client.util.Key
private java.lang.String modifyDateMin;
/** Filters out all events modified earlier than given date. Optional. Defaults to 24 hours before the
current modifyDateMax, if modifyDateMax is explicitly set.
*/
public java.lang.String getModifyDateMin() {
return modifyDateMin;
}
/**
* Filters out all events modified earlier than given date. Optional. Defaults to 24 hours
* before the current modifyDateMax, if modifyDateMax is explicitly set.
*/
public List setModifyDateMin(java.lang.String modifyDateMin) {
this.modifyDateMin = modifyDateMin;
return this;
}
/**
* Caret(^) delimited list of order IDs. Filters out all events that do not reference one of
* the given order IDs. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String orderId;
/** Caret(^) delimited list of order IDs. Filters out all events that do not reference one of the given
order IDs. Optional.
*/
public java.lang.String getOrderId() {
return orderId;
}
/**
* Caret(^) delimited list of order IDs. Filters out all events that do not reference one of
* the given order IDs. Optional.
*/
public List setOrderId(java.lang.String orderId) {
this.orderId = orderId;
return this;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
@com.google.api.client.util.Key
private java.lang.String pageToken;
/** The value of 'nextPageToken' from the previous page. Optional.
*/
public java.lang.String getPageToken() {
return pageToken;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
public List setPageToken(java.lang.String pageToken) {
this.pageToken = pageToken;
return this;
}
/**
* Caret(^) delimited list of product categories. Filters out all events that do not reference
* a product in one of the given product categories. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String productCategory;
/** Caret(^) delimited list of product categories. Filters out all events that do not reference a
product in one of the given product categories. Optional.
*/
public java.lang.String getProductCategory() {
return productCategory;
}
/**
* Caret(^) delimited list of product categories. Filters out all events that do not reference
* a product in one of the given product categories. Optional.
*/
public List setProductCategory(java.lang.String productCategory) {
this.productCategory = productCategory;
return this;
}
/**
* Caret(^) delimited list of publisher IDs. Filters out all events that do not reference one
* of the given publishers IDs. Only used when under advertiser role. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String publisherId;
/** Caret(^) delimited list of publisher IDs. Filters out all events that do not reference one of the
given publishers IDs. Only used when under advertiser role. Optional.
*/
public java.lang.String getPublisherId() {
return publisherId;
}
/**
* Caret(^) delimited list of publisher IDs. Filters out all events that do not reference one
* of the given publishers IDs. Only used when under advertiser role. Optional.
*/
public List setPublisherId(java.lang.String publisherId) {
this.publisherId = publisherId;
return this;
}
/**
* Caret(^) delimited list of SKUs. Filters out all events that do not reference one of the
* given SKU. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String sku;
/** Caret(^) delimited list of SKUs. Filters out all events that do not reference one of the given SKU.
Optional.
*/
public java.lang.String getSku() {
return sku;
}
/**
* Caret(^) delimited list of SKUs. Filters out all events that do not reference one of the
* given SKU. Optional.
*/
public List setSku(java.lang.String sku) {
this.sku = sku;
return this;
}
/**
* Filters out all events that do not have the given status. Valid values: 'active',
* 'canceled'. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String status;
/** Filters out all events that do not have the given status. Valid values: 'active', 'canceled'.
Optional.
*/
public java.lang.String getStatus() {
return status;
}
/**
* Filters out all events that do not have the given status. Valid values: 'active',
* 'canceled'. Optional.
*/
public List setStatus(java.lang.String status) {
this.status = status;
return this;
}
/**
* Filters out all events that are not of the given type. Valid values: 'action',
* 'transaction', 'charge'. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String type;
/** Filters out all events that are not of the given type. Valid values: 'action', 'transaction',
'charge'. Optional.
*/
public java.lang.String getType() {
return type;
}
/**
* Filters out all events that are not of the given type. Valid values: 'action',
* 'transaction', 'charge'. Optional.
*/
public List setType(java.lang.String type) {
this.type = type;
return this;
}
@Override
public List set(String parameterName, Object value) {
return (List) super.set(parameterName, value);
}
}
}
/**
* An accessor for creating requests from the Links collection.
*
* The typical use is:
*
* {@code Gan gan = new Gan(...);}
* {@code Gan.Links.List request = gan.links().list(parameters ...)}
*
*
* @return the resource collection
*/
public Links links() {
return new Links();
}
/**
* The "links" collection of methods.
*/
public class Links {
/**
* Retrieves data about a single link if the requesting advertiser/publisher has access to it.
* Advertisers can look up their own links. Publishers can look up visible links or links belonging
* to advertisers they are in a relationship with.
*
* Create a request for the method "links.get".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @param linkId The ID of the link to look up.
* @return the request
*/
public Get get(java.lang.String role, java.lang.String roleId, java.lang.Long linkId) throws java.io.IOException {
Get result = new Get(role, roleId, linkId);
initialize(result);
return result;
}
public class Get extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/link/{linkId}";
/**
* Retrieves data about a single link if the requesting advertiser/publisher has access to it.
* Advertisers can look up their own links. Publishers can look up visible links or links
* belonging to advertisers they are in a relationship with.
*
* Create a request for the method "links.get".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation. {@link
* Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @param linkId The ID of the link to look up.
* @since 1.13
*/
protected Get(java.lang.String role, java.lang.String roleId, java.lang.Long linkId) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Link.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
this.linkId = com.google.api.client.util.Preconditions.checkNotNull(linkId, "Required parameter linkId must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public Get setAlt(java.lang.String alt) {
return (Get) super.setAlt(alt);
}
@Override
public Get setFields(java.lang.String fields) {
return (Get) super.setFields(fields);
}
@Override
public Get setKey(java.lang.String key) {
return (Get) super.setKey(key);
}
@Override
public Get setOauthToken(java.lang.String oauthToken) {
return (Get) super.setOauthToken(oauthToken);
}
@Override
public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
return (Get) super.setPrettyPrint(prettyPrint);
}
@Override
public Get setQuotaUser(java.lang.String quotaUser) {
return (Get) super.setQuotaUser(quotaUser);
}
@Override
public Get setUserIp(java.lang.String userIp) {
return (Get) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public Get setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public Get setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/** The ID of the link to look up. */
@com.google.api.client.util.Key
private java.lang.Long linkId;
/** The ID of the link to look up.
*/
public java.lang.Long getLinkId() {
return linkId;
}
/** The ID of the link to look up. */
public Get setLinkId(java.lang.Long linkId) {
this.linkId = linkId;
return this;
}
@Override
public Get set(String parameterName, Object value) {
return (Get) super.set(parameterName, value);
}
}
/**
* Inserts a new link.
*
* Create a request for the method "links.insert".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link Insert#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @param content the {@link com.google.api.services.gan.model.Link}
* @return the request
*/
public Insert insert(java.lang.String role, java.lang.String roleId, com.google.api.services.gan.model.Link content) throws java.io.IOException {
Insert result = new Insert(role, roleId, content);
initialize(result);
return result;
}
public class Insert extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/link";
/**
* Inserts a new link.
*
* Create a request for the method "links.insert".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link Insert#execute()} method to invoke the remote operation. {@link
* Insert#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must
* be called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @param content the {@link com.google.api.services.gan.model.Link}
* @since 1.13
*/
protected Insert(java.lang.String role, java.lang.String roleId, com.google.api.services.gan.model.Link content) {
super(Gan.this, "POST", REST_PATH, content, com.google.api.services.gan.model.Link.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
}
@Override
public Insert setAlt(java.lang.String alt) {
return (Insert) super.setAlt(alt);
}
@Override
public Insert setFields(java.lang.String fields) {
return (Insert) super.setFields(fields);
}
@Override
public Insert setKey(java.lang.String key) {
return (Insert) super.setKey(key);
}
@Override
public Insert setOauthToken(java.lang.String oauthToken) {
return (Insert) super.setOauthToken(oauthToken);
}
@Override
public Insert setPrettyPrint(java.lang.Boolean prettyPrint) {
return (Insert) super.setPrettyPrint(prettyPrint);
}
@Override
public Insert setQuotaUser(java.lang.String quotaUser) {
return (Insert) super.setQuotaUser(quotaUser);
}
@Override
public Insert setUserIp(java.lang.String userIp) {
return (Insert) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public Insert setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public Insert setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
@Override
public Insert set(String parameterName, Object value) {
return (Insert) super.set(parameterName, value);
}
}
/**
* Retrieves all links that match the query parameters.
*
* Create a request for the method "links.list".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @return the request
*/
public List list(java.lang.String role, java.lang.String roleId) throws java.io.IOException {
List result = new List(role, roleId);
initialize(result);
return result;
}
public class List extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/links";
/**
* Retrieves all links that match the query parameters.
*
* Create a request for the method "links.list".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation. {@link
* List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @since 1.13
*/
protected List(java.lang.String role, java.lang.String roleId) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Links.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public List setAlt(java.lang.String alt) {
return (List) super.setAlt(alt);
}
@Override
public List setFields(java.lang.String fields) {
return (List) super.setFields(fields);
}
@Override
public List setKey(java.lang.String key) {
return (List) super.setKey(key);
}
@Override
public List setOauthToken(java.lang.String oauthToken) {
return (List) super.setOauthToken(oauthToken);
}
@Override
public List setPrettyPrint(java.lang.Boolean prettyPrint) {
return (List) super.setPrettyPrint(prettyPrint);
}
@Override
public List setQuotaUser(java.lang.String quotaUser) {
return (List) super.setQuotaUser(quotaUser);
}
@Override
public List setUserIp(java.lang.String userIp) {
return (List) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public List setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public List setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/** Limits the resulting links to the ones belonging to the listed advertisers. */
@com.google.api.client.util.Key
private java.util.List advertiserId;
/** Limits the resulting links to the ones belonging to the listed advertisers.
*/
public java.util.List getAdvertiserId() {
return advertiserId;
}
/** Limits the resulting links to the ones belonging to the listed advertisers. */
public List setAdvertiserId(java.util.List advertiserId) {
this.advertiserId = advertiserId;
return this;
}
/** The size of the given asset. */
@com.google.api.client.util.Key
private java.util.List assetSize;
/** The size of the given asset.
*/
public java.util.List getAssetSize() {
return assetSize;
}
/** The size of the given asset. */
public List setAssetSize(java.util.List assetSize) {
this.assetSize = assetSize;
return this;
}
/** The role of the author of the link. */
@com.google.api.client.util.Key
private java.lang.String authorship;
/** The role of the author of the link.
*/
public java.lang.String getAuthorship() {
return authorship;
}
/** The role of the author of the link. */
public List setAuthorship(java.lang.String authorship) {
this.authorship = authorship;
return this;
}
/** The end of the create date range. */
@com.google.api.client.util.Key
private java.lang.String createDateMax;
/** The end of the create date range.
*/
public java.lang.String getCreateDateMax() {
return createDateMax;
}
/** The end of the create date range. */
public List setCreateDateMax(java.lang.String createDateMax) {
this.createDateMax = createDateMax;
return this;
}
/** The beginning of the create date range. */
@com.google.api.client.util.Key
private java.lang.String createDateMin;
/** The beginning of the create date range.
*/
public java.lang.String getCreateDateMin() {
return createDateMin;
}
/** The beginning of the create date range. */
public List setCreateDateMin(java.lang.String createDateMin) {
this.createDateMin = createDateMin;
return this;
}
/** The type of the link. */
@com.google.api.client.util.Key
private java.lang.String linkType;
/** The type of the link.
*/
public java.lang.String getLinkType() {
return linkType;
}
/** The type of the link. */
public List setLinkType(java.lang.String linkType) {
this.linkType = linkType;
return this;
}
/** Max number of items to return in this page. Optional. Defaults to 20. */
@com.google.api.client.util.Key
private java.lang.Long maxResults;
/** Max number of items to return in this page. Optional. Defaults to 20.
[minimum: 0] [maximum: 100]
*/
public java.lang.Long getMaxResults() {
return maxResults;
}
/** Max number of items to return in this page. Optional. Defaults to 20. */
public List setMaxResults(java.lang.Long maxResults) {
this.maxResults = maxResults;
return this;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
@com.google.api.client.util.Key
private java.lang.String pageToken;
/** The value of 'nextPageToken' from the previous page. Optional.
*/
public java.lang.String getPageToken() {
return pageToken;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
public List setPageToken(java.lang.String pageToken) {
this.pageToken = pageToken;
return this;
}
/** The promotion type. */
@com.google.api.client.util.Key
private java.util.List promotionType;
/** The promotion type.
*/
public java.util.List getPromotionType() {
return promotionType;
}
/** The promotion type. */
public List setPromotionType(java.util.List promotionType) {
this.promotionType = promotionType;
return this;
}
/** The status of the relationship. */
@com.google.api.client.util.Key
private java.lang.String relationshipStatus;
/** The status of the relationship.
*/
public java.lang.String getRelationshipStatus() {
return relationshipStatus;
}
/** The status of the relationship. */
public List setRelationshipStatus(java.lang.String relationshipStatus) {
this.relationshipStatus = relationshipStatus;
return this;
}
/**
* Field for full text search across title and merchandising text, supports link id search.
*/
@com.google.api.client.util.Key
private java.lang.String searchText;
/** Field for full text search across title and merchandising text, supports link id search.
*/
public java.lang.String getSearchText() {
return searchText;
}
/**
* Field for full text search across title and merchandising text, supports link id search.
*/
public List setSearchText(java.lang.String searchText) {
this.searchText = searchText;
return this;
}
/** The end of the start date range. */
@com.google.api.client.util.Key
private java.lang.String startDateMax;
/** The end of the start date range.
*/
public java.lang.String getStartDateMax() {
return startDateMax;
}
/** The end of the start date range. */
public List setStartDateMax(java.lang.String startDateMax) {
this.startDateMax = startDateMax;
return this;
}
/** The beginning of the start date range. */
@com.google.api.client.util.Key
private java.lang.String startDateMin;
/** The beginning of the start date range.
*/
public java.lang.String getStartDateMin() {
return startDateMin;
}
/** The beginning of the start date range. */
public List setStartDateMin(java.lang.String startDateMin) {
this.startDateMin = startDateMin;
return this;
}
@Override
public List set(String parameterName, Object value) {
return (List) super.set(parameterName, value);
}
}
}
/**
* An accessor for creating requests from the Publishers collection.
*
* The typical use is:
*
* {@code Gan gan = new Gan(...);}
* {@code Gan.Publishers.List request = gan.publishers().list(parameters ...)}
*
*
* @return the resource collection
*/
public Publishers publishers() {
return new Publishers();
}
/**
* The "publishers" collection of methods.
*/
public class Publishers {
/**
* Retrieves data about a single advertiser if that the requesting advertiser/publisher has access
* to it. Only advertisers can look up publishers. Publishers can request information about
* themselves by omitting the publisherId query parameter.
*
* Create a request for the method "publishers.get".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @return the request
*/
public Get get(java.lang.String role, java.lang.String roleId) throws java.io.IOException {
Get result = new Get(role, roleId);
initialize(result);
return result;
}
public class Get extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/publisher";
/**
* Retrieves data about a single advertiser if that the requesting advertiser/publisher has access
* to it. Only advertisers can look up publishers. Publishers can request information about
* themselves by omitting the publisherId query parameter.
*
* Create a request for the method "publishers.get".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation. {@link
* Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @since 1.13
*/
protected Get(java.lang.String role, java.lang.String roleId) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Publisher.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public Get setAlt(java.lang.String alt) {
return (Get) super.setAlt(alt);
}
@Override
public Get setFields(java.lang.String fields) {
return (Get) super.setFields(fields);
}
@Override
public Get setKey(java.lang.String key) {
return (Get) super.setKey(key);
}
@Override
public Get setOauthToken(java.lang.String oauthToken) {
return (Get) super.setOauthToken(oauthToken);
}
@Override
public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
return (Get) super.setPrettyPrint(prettyPrint);
}
@Override
public Get setQuotaUser(java.lang.String quotaUser) {
return (Get) super.setQuotaUser(quotaUser);
}
@Override
public Get setUserIp(java.lang.String userIp) {
return (Get) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public Get setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public Get setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/** The ID of the publisher to look up. Optional. */
@com.google.api.client.util.Key
private java.lang.String publisherId;
/** The ID of the publisher to look up. Optional.
*/
public java.lang.String getPublisherId() {
return publisherId;
}
/** The ID of the publisher to look up. Optional. */
public Get setPublisherId(java.lang.String publisherId) {
this.publisherId = publisherId;
return this;
}
@Override
public Get set(String parameterName, Object value) {
return (Get) super.set(parameterName, value);
}
}
/**
* Retrieves data about all publishers that the requesting advertiser/publisher has access to.
*
* Create a request for the method "publishers.list".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @return the request
*/
public List list(java.lang.String role, java.lang.String roleId) throws java.io.IOException {
List result = new List(role, roleId);
initialize(result);
return result;
}
public class List extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/publishers";
/**
* Retrieves data about all publishers that the requesting advertiser/publisher has access to.
*
* Create a request for the method "publishers.list".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link List#execute()} method to invoke the remote operation. {@link
* List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @since 1.13
*/
protected List(java.lang.String role, java.lang.String roleId) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Publishers.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public List setAlt(java.lang.String alt) {
return (List) super.setAlt(alt);
}
@Override
public List setFields(java.lang.String fields) {
return (List) super.setFields(fields);
}
@Override
public List setKey(java.lang.String key) {
return (List) super.setKey(key);
}
@Override
public List setOauthToken(java.lang.String oauthToken) {
return (List) super.setOauthToken(oauthToken);
}
@Override
public List setPrettyPrint(java.lang.Boolean prettyPrint) {
return (List) super.setPrettyPrint(prettyPrint);
}
@Override
public List setQuotaUser(java.lang.String quotaUser) {
return (List) super.setQuotaUser(quotaUser);
}
@Override
public List setUserIp(java.lang.String userIp) {
return (List) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public List setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public List setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/** Max number of items to return in this page. Optional. Defaults to 20. */
@com.google.api.client.util.Key
private java.lang.Long maxResults;
/** Max number of items to return in this page. Optional. Defaults to 20.
[minimum: 0] [maximum: 100]
*/
public java.lang.Long getMaxResults() {
return maxResults;
}
/** Max number of items to return in this page. Optional. Defaults to 20. */
public List setMaxResults(java.lang.Long maxResults) {
this.maxResults = maxResults;
return this;
}
/**
* Filters out all publishers that have a ninety day EPC average lower than the given value
* (inclusive). Min value: 0.0. Optional.
*/
@com.google.api.client.util.Key
private java.lang.Double minNinetyDayEpc;
/** Filters out all publishers that have a ninety day EPC average lower than the given value
(inclusive). Min value: 0.0. Optional.
*/
public java.lang.Double getMinNinetyDayEpc() {
return minNinetyDayEpc;
}
/**
* Filters out all publishers that have a ninety day EPC average lower than the given value
* (inclusive). Min value: 0.0. Optional.
*/
public List setMinNinetyDayEpc(java.lang.Double minNinetyDayEpc) {
this.minNinetyDayEpc = minNinetyDayEpc;
return this;
}
/**
* A value between 1 and 4, where 1 represents the quartile of publishers with the lowest
* ranks and 4 represents the quartile of publishers with the highest ranks. Filters out all
* publishers with a lower rank than the given quartile. For example if a 2 was given only
* publishers with a payout rank of 25 or higher would be included. Optional.
*/
@com.google.api.client.util.Key
private java.lang.Integer minPayoutRank;
/** A value between 1 and 4, where 1 represents the quartile of publishers with the lowest ranks and 4
represents the quartile of publishers with the highest ranks. Filters out all publishers with a
lower rank than the given quartile. For example if a 2 was given only publishers with a payout rank
of 25 or higher would be included. Optional.
[minimum: 1] [maximum: 4]
*/
public java.lang.Integer getMinPayoutRank() {
return minPayoutRank;
}
/**
* A value between 1 and 4, where 1 represents the quartile of publishers with the lowest
* ranks and 4 represents the quartile of publishers with the highest ranks. Filters out all
* publishers with a lower rank than the given quartile. For example if a 2 was given only
* publishers with a payout rank of 25 or higher would be included. Optional.
*/
public List setMinPayoutRank(java.lang.Integer minPayoutRank) {
this.minPayoutRank = minPayoutRank;
return this;
}
/**
* Filters out all publishers that have a seven day EPC average lower than the given value
* (inclusive). Min value 0.0. Optional.
*/
@com.google.api.client.util.Key
private java.lang.Double minSevenDayEpc;
/** Filters out all publishers that have a seven day EPC average lower than the given value
(inclusive). Min value 0.0. Optional.
*/
public java.lang.Double getMinSevenDayEpc() {
return minSevenDayEpc;
}
/**
* Filters out all publishers that have a seven day EPC average lower than the given value
* (inclusive). Min value 0.0. Optional.
*/
public List setMinSevenDayEpc(java.lang.Double minSevenDayEpc) {
this.minSevenDayEpc = minSevenDayEpc;
return this;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
@com.google.api.client.util.Key
private java.lang.String pageToken;
/** The value of 'nextPageToken' from the previous page. Optional.
*/
public java.lang.String getPageToken() {
return pageToken;
}
/** The value of 'nextPageToken' from the previous page. Optional. */
public List setPageToken(java.lang.String pageToken) {
this.pageToken = pageToken;
return this;
}
/**
* Caret(^) delimted list of publisher categories. Valid categories: (unclassified|community_a
* nd_content|shopping_and_promotion|loyalty_and_rewards|network|search_specialist|comparison_
* shopping|email). Filters out all publishers not in one of the given advertiser categories.
* Optional.
*/
@com.google.api.client.util.Key
private java.lang.String publisherCategory;
/** Caret(^) delimted list of publisher categories. Valid categories: (unclassified|community_and_conte
nt|shopping_and_promotion|loyalty_and_rewards|network|search_specialist|comparison_shopping|email).
Filters out all publishers not in one of the given advertiser categories. Optional.
*/
public java.lang.String getPublisherCategory() {
return publisherCategory;
}
/**
* Caret(^) delimted list of publisher categories. Valid categories: (unclassified|community_a
* nd_content|shopping_and_promotion|loyalty_and_rewards|network|search_specialist|comparison_
* shopping|email). Filters out all publishers not in one of the given advertiser categories.
* Optional.
*/
public List setPublisherCategory(java.lang.String publisherCategory) {
this.publisherCategory = publisherCategory;
return this;
}
/**
* Filters out all publishers for which do not have the given relationship status with the
* requesting publisher.
*/
@com.google.api.client.util.Key
private java.lang.String relationshipStatus;
/** Filters out all publishers for which do not have the given relationship status with the requesting
publisher.
*/
public java.lang.String getRelationshipStatus() {
return relationshipStatus;
}
/**
* Filters out all publishers for which do not have the given relationship status with the
* requesting publisher.
*/
public List setRelationshipStatus(java.lang.String relationshipStatus) {
this.relationshipStatus = relationshipStatus;
return this;
}
@Override
public List set(String parameterName, Object value) {
return (List) super.set(parameterName, value);
}
}
}
/**
* An accessor for creating requests from the Reports collection.
*
* The typical use is:
*
* {@code Gan gan = new Gan(...);}
* {@code Gan.Reports.List request = gan.reports().list(parameters ...)}
*
*
* @return the resource collection
*/
public Reports reports() {
return new Reports();
}
/**
* The "reports" collection of methods.
*/
public class Reports {
/**
* Retrieves a report of the specified type.
*
* Create a request for the method "reports.get".
*
* This request holds the parameters needed by the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @param reportType The type of report being requested. Valid values: 'order_delta'. Required.
* @return the request
*/
public Get get(java.lang.String role, java.lang.String roleId, java.lang.String reportType) throws java.io.IOException {
Get result = new Get(role, roleId, reportType);
initialize(result);
return result;
}
public class Get extends GanRequest {
private static final String REST_PATH = "{role}/{roleId}/report/{reportType}";
/**
* Retrieves a report of the specified type.
*
* Create a request for the method "reports.get".
*
* This request holds the parameters needed by the the gan server. After setting any optional
* parameters, call the {@link Get#execute()} method to invoke the remote operation. {@link
* Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must be
* called to initialize this instance immediately after invoking the constructor.
*
* @param role The role of the requester. Valid values: 'advertisers' or 'publishers'.
* @param roleId The ID of the requesting advertiser or publisher.
* @param reportType The type of report being requested. Valid values: 'order_delta'. Required.
* @since 1.13
*/
protected Get(java.lang.String role, java.lang.String roleId, java.lang.String reportType) {
super(Gan.this, "GET", REST_PATH, null, com.google.api.services.gan.model.Report.class);
this.role = com.google.api.client.util.Preconditions.checkNotNull(role, "Required parameter role must be specified.");
this.roleId = com.google.api.client.util.Preconditions.checkNotNull(roleId, "Required parameter roleId must be specified.");
this.reportType = com.google.api.client.util.Preconditions.checkNotNull(reportType, "Required parameter reportType must be specified.");
}
@Override
public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
return super.executeUsingHead();
}
@Override
public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
return super.buildHttpRequestUsingHead();
}
@Override
public Get setAlt(java.lang.String alt) {
return (Get) super.setAlt(alt);
}
@Override
public Get setFields(java.lang.String fields) {
return (Get) super.setFields(fields);
}
@Override
public Get setKey(java.lang.String key) {
return (Get) super.setKey(key);
}
@Override
public Get setOauthToken(java.lang.String oauthToken) {
return (Get) super.setOauthToken(oauthToken);
}
@Override
public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
return (Get) super.setPrettyPrint(prettyPrint);
}
@Override
public Get setQuotaUser(java.lang.String quotaUser) {
return (Get) super.setQuotaUser(quotaUser);
}
@Override
public Get setUserIp(java.lang.String userIp) {
return (Get) super.setUserIp(userIp);
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
@com.google.api.client.util.Key
private java.lang.String role;
/** The role of the requester. Valid values: 'advertisers' or 'publishers'.
*/
public java.lang.String getRole() {
return role;
}
/** The role of the requester. Valid values: 'advertisers' or 'publishers'. */
public Get setRole(java.lang.String role) {
this.role = role;
return this;
}
/** The ID of the requesting advertiser or publisher. */
@com.google.api.client.util.Key
private java.lang.String roleId;
/** The ID of the requesting advertiser or publisher.
*/
public java.lang.String getRoleId() {
return roleId;
}
/** The ID of the requesting advertiser or publisher. */
public Get setRoleId(java.lang.String roleId) {
this.roleId = roleId;
return this;
}
/** The type of report being requested. Valid values: 'order_delta'. Required. */
@com.google.api.client.util.Key
private java.lang.String reportType;
/** The type of report being requested. Valid values: 'order_delta'. Required.
*/
public java.lang.String getReportType() {
return reportType;
}
/** The type of report being requested. Valid values: 'order_delta'. Required. */
public Get setReportType(java.lang.String reportType) {
this.reportType = reportType;
return this;
}
/** The IDs of the advertisers to look up, if applicable. */
@com.google.api.client.util.Key
private java.util.List advertiserId;
/** The IDs of the advertisers to look up, if applicable.
*/
public java.util.List getAdvertiserId() {
return advertiserId;
}
/** The IDs of the advertisers to look up, if applicable. */
public Get setAdvertiserId(java.util.List advertiserId) {
this.advertiserId = advertiserId;
return this;
}
/** Whether or not to calculate totals rows. Optional. */
@com.google.api.client.util.Key
private java.lang.Boolean calculateTotals;
/** Whether or not to calculate totals rows. Optional.
*/
public java.lang.Boolean getCalculateTotals() {
return calculateTotals;
}
/** Whether or not to calculate totals rows. Optional. */
public Get setCalculateTotals(java.lang.Boolean calculateTotals) {
this.calculateTotals = calculateTotals;
return this;
}
/**
* The end date (exclusive), in RFC 3339 format, for the report data to be returned. Defaults
* to one day after startDate, if that is given, or today. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String endDate;
/** The end date (exclusive), in RFC 3339 format, for the report data to be returned. Defaults to one
day after startDate, if that is given, or today. Optional.
*/
public java.lang.String getEndDate() {
return endDate;
}
/**
* The end date (exclusive), in RFC 3339 format, for the report data to be returned. Defaults
* to one day after startDate, if that is given, or today. Optional.
*/
public Get setEndDate(java.lang.String endDate) {
this.endDate = endDate;
return this;
}
/**
* Filters out all events that are not of the given type. Valid values: 'action',
* 'transaction', or 'charge'. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String eventType;
/** Filters out all events that are not of the given type. Valid values: 'action', 'transaction', or
'charge'. Optional.
*/
public java.lang.String getEventType() {
return eventType;
}
/**
* Filters out all events that are not of the given type. Valid values: 'action',
* 'transaction', or 'charge'. Optional.
*/
public Get setEventType(java.lang.String eventType) {
this.eventType = eventType;
return this;
}
/** Filters to capture one of given link IDs. Optional. */
@com.google.api.client.util.Key
private java.util.List linkId;
/** Filters to capture one of given link IDs. Optional.
*/
public java.util.List getLinkId() {
return linkId;
}
/** Filters to capture one of given link IDs. Optional. */
public Get setLinkId(java.util.List linkId) {
this.linkId = linkId;
return this;
}
/** Max number of items to return in this page. Optional. Defaults to return all results. */
@com.google.api.client.util.Key
private java.lang.Long maxResults;
/** Max number of items to return in this page. Optional. Defaults to return all results.
[minimum: 0]
*/
public java.lang.Long getMaxResults() {
return maxResults;
}
/** Max number of items to return in this page. Optional. Defaults to return all results. */
public Get setMaxResults(java.lang.Long maxResults) {
this.maxResults = maxResults;
return this;
}
/** Filters to capture one of the given order IDs. Optional. */
@com.google.api.client.util.Key
private java.util.List orderId;
/** Filters to capture one of the given order IDs. Optional.
*/
public java.util.List getOrderId() {
return orderId;
}
/** Filters to capture one of the given order IDs. Optional. */
public Get setOrderId(java.util.List orderId) {
this.orderId = orderId;
return this;
}
/** The IDs of the publishers to look up, if applicable. */
@com.google.api.client.util.Key
private java.util.List publisherId;
/** The IDs of the publishers to look up, if applicable.
*/
public java.util.List getPublisherId() {
return publisherId;
}
/** The IDs of the publishers to look up, if applicable. */
public Get setPublisherId(java.util.List publisherId) {
this.publisherId = publisherId;
return this;
}
/**
* The start date (inclusive), in RFC 3339 format, for the report data to be returned.
* Defaults to one day before endDate, if that is given, or yesterday. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String startDate;
/** The start date (inclusive), in RFC 3339 format, for the report data to be returned. Defaults to one
day before endDate, if that is given, or yesterday. Optional.
*/
public java.lang.String getStartDate() {
return startDate;
}
/**
* The start date (inclusive), in RFC 3339 format, for the report data to be returned.
* Defaults to one day before endDate, if that is given, or yesterday. Optional.
*/
public Get setStartDate(java.lang.String startDate) {
this.startDate = startDate;
return this;
}
/** Offset on which to return results when paging. Optional. */
@com.google.api.client.util.Key
private java.lang.Long startIndex;
/** Offset on which to return results when paging. Optional.
[minimum: 0]
*/
public java.lang.Long getStartIndex() {
return startIndex;
}
/** Offset on which to return results when paging. Optional. */
public Get setStartIndex(java.lang.Long startIndex) {
this.startIndex = startIndex;
return this;
}
/**
* Filters out all events that do not have the given status. Valid values: 'active',
* 'canceled', or 'invalid'. Optional.
*/
@com.google.api.client.util.Key
private java.lang.String status;
/** Filters out all events that do not have the given status. Valid values: 'active', 'canceled', or
'invalid'. Optional.
*/
public java.lang.String getStatus() {
return status;
}
/**
* Filters out all events that do not have the given status. Valid values: 'active',
* 'canceled', or 'invalid'. Optional.
*/
public Get setStatus(java.lang.String status) {
this.status = status;
return this;
}
@Override
public Get set(String parameterName, Object value) {
return (Get) super.set(parameterName, value);
}
}
}
/**
* Builder for {@link Gan}.
*
*
* Implementation is not thread-safe.
*
*
* @since 1.3.0
*/
public static final class Builder extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient.Builder {
/**
* Returns an instance of a new builder.
*
* @param transport HTTP transport, which should normally be:
*
* - Google App Engine:
* {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}
* - Android: {@code newCompatibleTransport} from
* {@code com.google.api.client.extensions.android.http.AndroidHttp}
* - Java: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()}
*
*
* @param jsonFactory JSON factory, which may be:
*
* - Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}
* - Google GSON: {@code com.google.api.client.json.gson.GsonFactory}
* - Android Honeycomb or higher:
* {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}
*
* @param httpRequestInitializer HTTP request initializer or {@code null} for none
* @since 1.7
*/
public Builder(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory,
com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) {
super(
transport,
jsonFactory,
DEFAULT_ROOT_URL,
DEFAULT_SERVICE_PATH,
httpRequestInitializer,
false);
}
/** Builds a new instance of {@link Gan}. */
@Override
public Gan build() {
return new Gan(this);
}
@Override
public Builder setRootUrl(String rootUrl) {
return (Builder) super.setRootUrl(rootUrl);
}
@Override
public Builder setServicePath(String servicePath) {
return (Builder) super.setServicePath(servicePath);
}
@Override
public Builder setHttpRequestInitializer(com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) {
return (Builder) super.setHttpRequestInitializer(httpRequestInitializer);
}
@Override
public Builder setApplicationName(String applicationName) {
return (Builder) super.setApplicationName(applicationName);
}
@Override
public Builder setSuppressPatternChecks(boolean suppressPatternChecks) {
return (Builder) super.setSuppressPatternChecks(suppressPatternChecks);
}
@Override
public Builder setSuppressRequiredParameterChecks(boolean suppressRequiredParameterChecks) {
return (Builder) super.setSuppressRequiredParameterChecks(suppressRequiredParameterChecks);
}
@Override
public Builder setSuppressAllChecks(boolean suppressAllChecks) {
return (Builder) super.setSuppressAllChecks(suppressAllChecks);
}
/**
* Set the {@link GanRequestInitializer}.
*
* @since 1.12
*/
public Builder setGanRequestInitializer(
GanRequestInitializer ganRequestInitializer) {
return (Builder) super.setGoogleClientRequestInitializer(ganRequestInitializer);
}
@Override
public Builder setGoogleClientRequestInitializer(
com.google.api.client.googleapis.services.GoogleClientRequestInitializer googleClientRequestInitializer) {
return (Builder) super.setGoogleClientRequestInitializer(googleClientRequestInitializer);
}
}
}