Comments (2)
An other example:
openapi: 3.0.1
info:
title: ping test
version: '1.0'
servers:
- url: 'http://localhost:8000/'
paths:
/return/ping:
get:
tags:
- return
operationId: pingGet
responses:
'201':
description: OK
components:
schemas: {}
Produces also compile error:
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[43,21] <identifier> expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[43,28] illegal start of type
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[43,29] <identifier> expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[43,30] ';' expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[44,9] illegal start of type
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[44,25] ';' expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[44,55] <identifier> expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[44,57] ';' expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/ApiClient.java:[64,1] class, interface, or enum expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/api/ReturnApi.java:[44,28] <identifier> expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/api/ReturnApi.java:[44,35] illegal start of type
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/api/ReturnApi.java:[44,54] ';' expected
[ERROR] testIssue13-oapigen-rest-assured-java/src/main/java/org/openapitools/client/api/ReturnApi.java:[44,62] <identifier> expected
@viclovsky any input on how the method name should looks like when the name correspond to a java reserved keyword. Obviously those are not working:
public ReturnApi return()
public DefaultApi default()
Maybe we could append Api
to have something like this:
public ReturnApi returnApi()
public DefaultApi defaultApi()
from openapi-generator.
Hello, @jmini
Thanks a lot for detailed description of the issue.
To my mind the best sollution in your case will be to escape java reserved keyword as well in api as for methods.
from openapi-generator.
Related Issues (20)
- [BUG][Kotlin][kotlin-spring] Multi-level inheritance doesn't work
- [BUG][typescript-fetch] Error generating types with OAS 3.1 HOT 6
- [BUG] nodejs-express-server generator does not generate models
- [REQ] Fail build on illegal schema if schema should be validated
- [REQ] Support for extra annotations on path parameters HOT 1
- [REQ] Add support for new Helidon releases (2.x, 3.x, and new major version 4.0)
- [BUG] [typescript-rxjs] Collision for generated model and interface in API that have same name HOT 1
- [BUG] go-gin-server generates empty struct for inappropriate types
- [REQ] support generate event-stream api client for typescrept
- [BUG] [Spring] Compile error in ClientPropertiesConfiguration
- [BUG] [JAVA] 3.1 specs generates String instead of enum value in query params HOT 3
- [BUG] [Kotlin] [Multiplatform] Enum parameters should use value instead of relying on toString HOT 1
- Question: Can generator not remove underscores? HOT 5
- Rate limiting
- [BUG] [JAVA] Is there currently support for oneOf/anyOf keywords in API spec? HOT 3
- [REQ] useJakartaEe should now be true by default (Java) HOT 1
- [BUG] [JetBrains] Query parameters missing HOT 1
- [BUG][csharp] HttClient add in Host configuration can create conflit with other HttpClient HOT 2
- [REQ] add sessionToken support to AWS4Auth
- [REQ] Add support for Helidon 4.x MP
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from openapi-generator.