001// *************************************************************************************************************************** 002// * Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file * 003// * distributed with this work for additional information regarding copyright ownership. The ASF licenses this file * 004// * to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance * 005// * with the License. You may obtain a copy of the License at * 006// * * 007// * http://www.apache.org/licenses/LICENSE-2.0 * 008// * * 009// * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an * 010// * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the * 011// * specific language governing permissions and limitations under the License. * 012// *************************************************************************************************************************** 013package org.apache.juneau.rest.annotation; 014 015import java.lang.annotation.*; 016 017import org.apache.juneau.jsonschema.annotation.*; 018 019/** 020 * TODO 021 */ 022public class MethodAnnotationSwagger implements MethodSwagger { 023 024 private String 025 operationId = "", 026 deprecated = ""; 027 028 private String[] 029 summary = new String[0], 030 description = new String[0], 031 schemes = new String[0], 032 consumes = new String[0], 033 produces = new String[0], 034 parameters = new String[0], 035 responses = new String[0], 036 tags = new String[0], 037 value = new String[0]; 038 039 private ExternalDocs externalDocs = new ExternalDocsAnnotation(); 040 041 @Override /* MethodSwagger */ 042 public Class<? extends Annotation> annotationType() { 043 return MethodSwagger.class; 044 } 045 046 @Override /* MethodSwagger */ 047 public String[] summary() { 048 return summary; 049 } 050 051 @Override /* MethodSwagger */ 052 public String[] description() { 053 return description; 054 } 055 056 @Override /* MethodSwagger */ 057 public String operationId() { 058 return operationId; 059 } 060 061 @Override /* MethodSwagger */ 062 public String[] schemes() { 063 return schemes; 064 } 065 066 @Override /* MethodSwagger */ 067 public String deprecated() { 068 return deprecated; 069 } 070 071 @Override /* MethodSwagger */ 072 public String[] consumes() { 073 return consumes; 074 } 075 076 @Override /* MethodSwagger */ 077 public String[] produces() { 078 return produces; 079 } 080 081 @Override /* MethodSwagger */ 082 public ExternalDocs externalDocs() { 083 return externalDocs; 084 } 085 086 @Override /* MethodSwagger */ 087 public String[] parameters() { 088 return parameters; 089 } 090 091 @Override /* MethodSwagger */ 092 public String[] responses() { 093 return responses; 094 } 095 096 @Override /* MethodSwagger */ 097 public String[] tags() { 098 return tags; 099 } 100 101 @Override /* MethodSwagger */ 102 public String[] value() { 103 return value; 104 } 105}