Skip to content

Commit

Permalink
fix(fhir.rest): Use "handling=strict" and "handling=lenient" values...
Browse files Browse the repository at this point in the history
...for the Prefer header on operations
  • Loading branch information
apeteri committed Oct 22, 2024
1 parent 14070fd commit 2e2fe38
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -239,8 +239,11 @@ public Promise<ResponseEntity<byte[]>> lookup(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -301,8 +301,11 @@ public Promise<ResponseEntity<byte[]>> subsumes(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down Expand Up @@ -418,8 +421,11 @@ public Promise<ResponseEntity<byte[]>> subsumes(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,11 @@ public Promise<ResponseEntity<byte[]>> validateCode(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down Expand Up @@ -470,8 +473,11 @@ public Promise<ResponseEntity<byte[]>> validateCode(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,11 @@ public Promise<ResponseEntity<byte[]>> translate(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down Expand Up @@ -471,8 +474,11 @@ public Promise<ResponseEntity<byte[]>> translate(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -254,8 +254,11 @@ public Promise<ResponseEntity<byte[]>> expand(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -249,8 +249,11 @@ public Promise<ResponseEntity<byte[]>> validateCode(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down Expand Up @@ -495,8 +498,11 @@ public Promise<ResponseEntity<byte[]>> validateCode(
@RequestHeader(value = HttpHeaders.ACCEPT)
final String accept,

@Parameter(description = "Prefer header", schema = @Schema(allowableValues = {"strict", "lenient"}, defaultValue = "lenient"))
@RequestHeader(value = "Prefer", required = false)
@Parameter(description = "Prefer header", schema = @Schema(
allowableValues = { PREFER_HANDLING_STRICT, PREFER_HANDLING_LENIENT },
defaultValue = PREFER_HANDLING_LENIENT
))
@RequestHeader(value = PREFER, required = false)
final String prefer,

@Parameter(description = "Alternative response format", schema = @Schema(allowableValues = {
Expand Down

0 comments on commit 2e2fe38

Please sign in to comment.