All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.apache.juneau.dto.swagger.Info Maven / Gradle / Ivy

There is a newer version: 9.0.1
Show newest version
// ***************************************************************************************************************************
// * Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements.  See the NOTICE file *
// * distributed with this work for additional information regarding copyright ownership.  The ASF licenses this file        *
// * to you 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.                                              *
// ***************************************************************************************************************************
package org.apache.juneau.dto.swagger;

import org.apache.juneau.annotation.*;

/**
 * The object provides metadata about the API. The metadata can be used by the clients if needed, and can be presented
 * in the Swagger-UI for convenience.
 *
 * 
Example:
*

* { * "title": "Swagger Sample App", * "description": "This is a sample server Petstore server.", * "termsOfService": "http://swagger.io/terms/", * "contact": { * "name": "API Support", * "url": "http://www.swagger.io/support", * "email": "[email protected]" * }, * "license": { * "name": "Apache 2.0", * "url": "http://www.apache.org/licenses/LICENSE-2.0.html" * }, * "version": "1.0.1" * } *

* *
Additional Information
* */ @Bean(properties="title,description,termsOfService,contact,license,version") public class Info extends SwaggerElement { private String title; private String description; private String termsOfService; private Contact contact; private License license; private String version; /** * Bean property getter: title. * *

* Required. The title of the application. * * @return The value of the title property on this bean, or null if it is not set. */ public String getTitle() { return title; } /** * Bean property setter: title. * *

* Required. The title of the application. * * @param title The new value for the title property on this bean. * @return This object (for method chaining). */ public Info setTitle(String title) { this.title = title; return this; } /** * Synonym for {@link #setTitle(String)}. * * @param title The new value for the title property on this bean. * @return This object (for method chaining). */ public Info title(String title) { return setTitle(title); } /** * Bean property getter: description. * *

* A short description of the application. GFM syntax can be used for rich text representation. * * @return * The value of the description property on this bean, or null if it is not set. */ public String getDescription() { return description; } /** * Bean property setter: description. * *

* A short description of the application. GFM syntax can be used for rich text representation. * * @param description The new value for the description property on this bean. * @return This object (for method chaining). */ public Info setDescription(String description) { this.description = description; return this; } /** * Synonym for {@link #setDescription(String)}. * * @param description The new value for the description property on this bean. * @return This object (for method chaining). */ public Info description(String description) { return setDescription(description); } /** * Bean property getter: termsOfService. * *

* The Terms of Service for the API. * * @return The value of the termsOfService property on this bean, or null if it is not * set. */ public String getTermsOfService() { return termsOfService; } /** * Bean property setter: termsOfService. * *

* The Terms of Service for the API. * * @param termsOfService The new value for the termsOfService property on this bean. * @return This object (for method chaining). */ public Info setTermsOfService(String termsOfService) { this.termsOfService = termsOfService; return this; } /** * Synonym for {@link #setTermsOfService(String)}. * * @param termsOfService The new value for the termsOfService property on this bean. * @return This object (for method chaining). */ public Info termsOfService(String termsOfService) { return setTermsOfService(termsOfService); } /** * Bean property getter: contact. * *

* The contact information for the exposed API. * * @return The value of the contact property on this bean, or null if it is not set. */ public Contact getContact() { return contact; } /** * Bean property setter: contact. * *

* The contact information for the exposed API. * * @param contact The new value for the contact property on this bean. * @return This object (for method chaining). */ public Info setContact(Contact contact) { this.contact = contact; return this; } /** * Synonym for {@link #setContact(Contact)}. * * @param contact The new value for the contact property on this bean. * @return This object (for method chaining). */ public Info contact(Contact contact) { return setContact(contact); } /** * Bean property getter: license. * *

* The license information for the exposed API. * * @return The value of the license property on this bean, or null if it is not set. */ public License getLicense() { return license; } /** * Bean property setter: license. * *

* The license information for the exposed API. * * @param license The new value for the license property on this bean. * @return This object (for method chaining). */ public Info setLicense(License license) { this.license = license; return this; } /** * Synonym for {@link #setLicense(License)}. * * @param license The new value for the license property on this bean. * @return This object (for method chaining). */ public Info license(License license) { return setLicense(license); } /** * Bean property getter: version. * *

* Required. Provides the version of the application API (not to be confused with the specification version). * * @return The value of the version property on this bean, or null if it is not set. */ public String getVersion() { return version; } /** * Bean property setter: version. * *

* Required. Provides the version of the application API (not to be confused with the specification version). * * @param version The new value for the version property on this bean. * @return This object (for method chaining). */ public Info setVersion(String version) { this.version = version; return this; } /** * Synonym for {@link #setVersion(String)}. * * @param version The new value for the version property on this bean. * @return This object (for method chaining). */ public Info version(String version) { return setVersion(version); } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy