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

handlebars.JavaJaxRS.spec.api.mustache Maven / Gradle / Ivy

There is a newer version: 1.0.54
Show newest version
package {{package}};

{{#imports}}import {{import}};
{{/imports}}

{{#jakarta}}
import jakarta.ws.rs.*;
import jakarta.ws.rs.core.Response;
{{/jakarta}}
{{^jakarta}}
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
{{/jakarta}}

{{#useOas2}}
import io.swagger.annotations.*;
{{/useOas2}}
{{^useOas2}}
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.responses.ApiResponses;
import io.swagger.v3.oas.annotations.responses.ApiResponse;
import io.swagger.v3.oas.annotations.media.ArraySchema;
import io.swagger.v3.oas.annotations.media.Content;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
{{/useOas2}}

import java.util.Map;
import java.util.List;
{{#useBeanValidation}}
{{#jakarta}}
import jakarta.validation.constraints.*;
import jakarta.validation.Valid;
{{/jakarta}}
{{^jakarta}}
import javax.validation.constraints.*;
import javax.validation.Valid;
{{/jakarta}}
{{/useBeanValidation}}

@Path("/{{{baseName}}}")
{{#useOas2}}
@Api(description = "the {{{baseName}}} API")
{{/useOas2}}{{#hasConsumes}}
@Consumes({ {{#consumes}}"{{{mediaType}}}"{{#hasMore}}, {{/hasMore}}{{/consumes}} }){{/hasConsumes}}{{#hasProduces}}
@Produces({ {{#produces}}"{{{mediaType}}}"{{#hasMore}}, {{/hasMore}}{{/produces}} }){{/hasProduces}}
{{>generatedAnnotation}}public {{#interfaceOnly}}interface{{/interfaceOnly}}{{^interfaceOnly}}class{{/interfaceOnly}} {{classname}} {
{{#operations}}
{{#operation}}
{{#contents}}

{{#interfaceOnly}}{{>apiInterface}}{{/interfaceOnly}}{{^interfaceOnly}}{{>apiMethod}}{{/interfaceOnly}}
{{/contents}}
{{/operation}}
}
{{/operations}}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy