/*
 * 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/googleapis/google-api-java-client-services/
 * Modify at your own risk.
 */

package com.google.api.services.contentwarehouse.v1.model;

/**
 * A transit line is a named set of transit trips that are advertised to passengers under a common
 * name, and a number of attributes that are true for all those trips. There is no requirement for
 * each trip to travel through the same list of stops or use the same legs, so a line can contain
 * trips in opposite directions or with variations in the sequence of stops. See go/oysterpedia for
 * an overview of the transit feature types. The standard feature properties are interpreted as
 * follows: name - The names of this line, including both long and short names, if available. Short
 * names like "10" or "Blue" should carry the FLAG_ABBREVIATED, long names like "Dublin/Pleasanton
 * line" should not. The preferred name (one per language) for displaying the line on its own (e.g.,
 * as a search result for the line) should carry the FLAG_PREFERRED. website - The official web page
 * describing this line. Repeated if multilingual. Line features have no geometry (neither points
 * nor polylines nor polygons). Within Transit Oyster, geometry can be found in legs. Additional
 * data only in Transit Oyster: child - The legs of this line, in no particular order. source_info -
 * Specifies the GTFS routes that match this feature. Each is given as a PROVIDER_GOOGLE_TRANSIT
 * source_info where dataset is the feed name and cookie is the route_id.
 *
 * <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
 * transmitted over HTTP when working with the Document AI Warehouse API. For a detailed explanation
 * see:
 * <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a>
 * </p>
 *
 * @author Google, Inc.
 */
@SuppressWarnings("javadoc")
public final class GeostoreTransitLineProto extends com.google.api.client.json.GenericJson {

  /**
   * The transit agencies responsible for operating this line. All lines should have at least one
   * agency, and most will have exactly one. The following cases are reasons for multiple agencies:
   * - Code share: Two or more agencies share trips - Alternations: Each trip is run by one of
   * multiple agencies - Additional: All trips run by one agency, but a second one sells tickets In
   * all cases the order has no meaning. Clarification comes from the trips.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<GeostoreFeatureIdProto> agency;

  static {
    // hack to force ProGuard to consider GeostoreFeatureIdProto used, since otherwise it would be stripped out
    // see https://github.com/google/google-api-java-client/issues/543
    com.google.api.client.util.Data.nullOf(GeostoreFeatureIdProto.class);
  }

  /**
   * The background color of labels for that transit line. The encoding is like in HTML or CSS, eg.
   * 0x11ff00 means a bit of red, full green, no blue, in sRGB color space. The most significant
   * byte must be zero, i.e. no transparency.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Long labelBackgroundColor;

  /**
   * The text color of labels for that transit line. Encoding like label_background_color.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Long labelTextColor;

  /**
   * The transit stations (establishment POIs with gcid:transit_station) which this transit line can
   * go through, in no particular order. Usage note: The source of truth are the transit leg
   * features in Transit Oyster. In MapFacts, that information is cached in two locations: in this
   * field, and in transit station attachments on POIs. Do not assume these locations are always up
   * to date and/or synchronized with each other.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<GeostoreFeatureIdProto> stations;

  static {
    // hack to force ProGuard to consider GeostoreFeatureIdProto used, since otherwise it would be stripped out
    // see https://github.com/google/google-api-java-client/issues/543
    com.google.api.client.util.Data.nullOf(GeostoreFeatureIdProto.class);
  }

  /**
   * The type of vehicle that applies to all trips that use this line.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String vehicleType;

  /**
   * The transit agencies responsible for operating this line. All lines should have at least one
   * agency, and most will have exactly one. The following cases are reasons for multiple agencies:
   * - Code share: Two or more agencies share trips - Alternations: Each trip is run by one of
   * multiple agencies - Additional: All trips run by one agency, but a second one sells tickets In
   * all cases the order has no meaning. Clarification comes from the trips.
   * @return value or {@code null} for none
   */
  public java.util.List<GeostoreFeatureIdProto> getAgency() {
    return agency;
  }

  /**
   * The transit agencies responsible for operating this line. All lines should have at least one
   * agency, and most will have exactly one. The following cases are reasons for multiple agencies:
   * - Code share: Two or more agencies share trips - Alternations: Each trip is run by one of
   * multiple agencies - Additional: All trips run by one agency, but a second one sells tickets In
   * all cases the order has no meaning. Clarification comes from the trips.
   * @param agency agency or {@code null} for none
   */
  public GeostoreTransitLineProto setAgency(java.util.List<GeostoreFeatureIdProto> agency) {
    this.agency = agency;
    return this;
  }

  /**
   * The background color of labels for that transit line. The encoding is like in HTML or CSS, eg.
   * 0x11ff00 means a bit of red, full green, no blue, in sRGB color space. The most significant
   * byte must be zero, i.e. no transparency.
   * @return value or {@code null} for none
   */
  public java.lang.Long getLabelBackgroundColor() {
    return labelBackgroundColor;
  }

  /**
   * The background color of labels for that transit line. The encoding is like in HTML or CSS, eg.
   * 0x11ff00 means a bit of red, full green, no blue, in sRGB color space. The most significant
   * byte must be zero, i.e. no transparency.
   * @param labelBackgroundColor labelBackgroundColor or {@code null} for none
   */
  public GeostoreTransitLineProto setLabelBackgroundColor(java.lang.Long labelBackgroundColor) {
    this.labelBackgroundColor = labelBackgroundColor;
    return this;
  }

  /**
   * The text color of labels for that transit line. Encoding like label_background_color.
   * @return value or {@code null} for none
   */
  public java.lang.Long getLabelTextColor() {
    return labelTextColor;
  }

  /**
   * The text color of labels for that transit line. Encoding like label_background_color.
   * @param labelTextColor labelTextColor or {@code null} for none
   */
  public GeostoreTransitLineProto setLabelTextColor(java.lang.Long labelTextColor) {
    this.labelTextColor = labelTextColor;
    return this;
  }

  /**
   * The transit stations (establishment POIs with gcid:transit_station) which this transit line can
   * go through, in no particular order. Usage note: The source of truth are the transit leg
   * features in Transit Oyster. In MapFacts, that information is cached in two locations: in this
   * field, and in transit station attachments on POIs. Do not assume these locations are always up
   * to date and/or synchronized with each other.
   * @return value or {@code null} for none
   */
  public java.util.List<GeostoreFeatureIdProto> getStations() {
    return stations;
  }

  /**
   * The transit stations (establishment POIs with gcid:transit_station) which this transit line can
   * go through, in no particular order. Usage note: The source of truth are the transit leg
   * features in Transit Oyster. In MapFacts, that information is cached in two locations: in this
   * field, and in transit station attachments on POIs. Do not assume these locations are always up
   * to date and/or synchronized with each other.
   * @param stations stations or {@code null} for none
   */
  public GeostoreTransitLineProto setStations(java.util.List<GeostoreFeatureIdProto> stations) {
    this.stations = stations;
    return this;
  }

  /**
   * The type of vehicle that applies to all trips that use this line.
   * @return value or {@code null} for none
   */
  public java.lang.String getVehicleType() {
    return vehicleType;
  }

  /**
   * The type of vehicle that applies to all trips that use this line.
   * @param vehicleType vehicleType or {@code null} for none
   */
  public GeostoreTransitLineProto setVehicleType(java.lang.String vehicleType) {
    this.vehicleType = vehicleType;
    return this;
  }

  @Override
  public GeostoreTransitLineProto set(String fieldName, Object value) {
    return (GeostoreTransitLineProto) super.set(fieldName, value);
  }

  @Override
  public GeostoreTransitLineProto clone() {
    return (GeostoreTransitLineProto) super.clone();
  }

}
