<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/apigateway/v1/apigateway.proto

namespace Google\Cloud\ApiGateway\V1\ApiConfig;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 * An OpenAPI Specification Document describing an API.
 *
 * Generated from protobuf message <code>google.cloud.apigateway.v1.ApiConfig.OpenApiDocument</code>
 */
class OpenApiDocument extends \Google\Protobuf\Internal\Message
{
    /**
     * The OpenAPI Specification document file.
     *
     * Generated from protobuf field <code>.google.cloud.apigateway.v1.ApiConfig.File document = 1;</code>
     */
    private $document = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\ApiGateway\V1\ApiConfig\File $document
     *           The OpenAPI Specification document file.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Apigateway\V1\Apigateway::initOnce();
        parent::__construct($data);
    }

    /**
     * The OpenAPI Specification document file.
     *
     * Generated from protobuf field <code>.google.cloud.apigateway.v1.ApiConfig.File document = 1;</code>
     * @return \Google\Cloud\ApiGateway\V1\ApiConfig\File|null
     */
    public function getDocument()
    {
        return $this->document;
    }

    public function hasDocument()
    {
        return isset($this->document);
    }

    public function clearDocument()
    {
        unset($this->document);
    }

    /**
     * The OpenAPI Specification document file.
     *
     * Generated from protobuf field <code>.google.cloud.apigateway.v1.ApiConfig.File document = 1;</code>
     * @param \Google\Cloud\ApiGateway\V1\ApiConfig\File $var
     * @return $this
     */
    public function setDocument($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\ApiGateway\V1\ApiConfig\File::class);
        $this->document = $var;

        return $this;
    }

}


