-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
programmatic client generation for MP Rest Client, fixes #1317
- Loading branch information
1 parent
2ee62e5
commit cf151ac
Showing
4 changed files
with
53 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
integration-tests/main/src/main/java/io/quarkus/example/rest/ProgrammaticRestInterface.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
package io.quarkus.example.rest; | ||
|
||
import java.util.List; | ||
|
||
import javax.ws.rs.GET; | ||
import javax.ws.rs.Path; | ||
import javax.ws.rs.Produces; | ||
|
||
/** | ||
* A version of {@link RestInterface} that doesn't have {@link org.eclipse.microprofile.rest.client.inject.RegisterRestClient} | ||
* and can be used only programmatically, i.e. with the builder. | ||
*/ | ||
@Path("/test") | ||
public interface ProgrammaticRestInterface { | ||
|
||
@GET | ||
String get(); | ||
|
||
@GET | ||
@Path("/jackson") | ||
@Produces("application/json") | ||
TestResource.MyData getData(); | ||
|
||
@GET | ||
@Path("/complex") | ||
@Produces("application/json") | ||
List<ComponentType> complex(); | ||
} |