Class ImmutableCtxApiOp
java.lang.Object
dk.mada.jaxrs.generator.mpclient.api.tmpl.ImmutableCtxApiOp
- All Implemented Interfaces:
CtxApiOp
@Generated(from="CtxApiOp",
generator="Immutables")
@Generated("org.immutables.processor.ProxyProcessor")
public final class ImmutableCtxApiOp
extends Object
implements CtxApiOp
Immutable implementation of
CtxApiOp
.
Use the builder to create immutable instances:
ImmutableCtxApiOp.builder()
.
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionReturns all parameters of the operation.static ImmutableCtxApiOp.Builder
builder()
Creates a builder forImmutableCtxApiOp
.static ImmutableCtxApiOp
Creates an immutable copy of aCtxApiOp
value.boolean
This instance is equal to all instances ofImmutableCtxApiOp
that have equal attribute values.int
hashCode()
Computes a hash code from attributes:returnType
,nickname
,httpMethod
,path
,summary
,notes
,allParams
,responses
,madaOp
.Returns the operation http method.madaOp()
Returns additional custom template data for the operation.nickname()
Returns the operation nickname.notes()
Returns the optional operation notes.path()
Returns the operation path.Returns all responses of the operation.Returns the operation return type.summary()
Returns the optional operation summary.toString()
Prints the immutable valueCtxApiOp
with attribute values.final ImmutableCtxApiOp
withAllParams
(CtxApiParam... elements) Copy the current immutable object with elements that replace the content ofallParams
.final ImmutableCtxApiOp
withAllParams
(Iterable<? extends CtxApiParam> elements) Copy the current immutable object with elements that replace the content ofallParams
.final ImmutableCtxApiOp
withHttpMethod
(String value) Copy the current immutable object by setting a value for thehttpMethod
attribute.final ImmutableCtxApiOp
withMadaOp
(CtxApiOpExt value) Copy the current immutable object by setting a value for themadaOp
attribute.final ImmutableCtxApiOp
withNickname
(String value) Copy the current immutable object by setting a value for thenickname
attribute.final ImmutableCtxApiOp
Copy the current immutable object by setting a present value for the optionalnotes
attribute.final ImmutableCtxApiOp
Copy the current immutable object by setting an optional value for thenotes
attribute.final ImmutableCtxApiOp
Copy the current immutable object by setting a present value for the optionalpath
attribute.final ImmutableCtxApiOp
Copy the current immutable object by setting an optional value for thepath
attribute.final ImmutableCtxApiOp
withResponses
(CtxApiResponse... elements) Copy the current immutable object with elements that replace the content ofresponses
.final ImmutableCtxApiOp
withResponses
(Iterable<? extends CtxApiResponse> elements) Copy the current immutable object with elements that replace the content ofresponses
.final ImmutableCtxApiOp
withReturnType
(String value) Copy the current immutable object by setting a value for thereturnType
attribute.final ImmutableCtxApiOp
withSummary
(String value) Copy the current immutable object by setting a present value for the optionalsummary
attribute.final ImmutableCtxApiOp
withSummary
(Optional<String> optional) Copy the current immutable object by setting an optional value for thesummary
attribute.
-
Method Details
-
returnType
Returns the operation return type.- Specified by:
returnType
in interfaceCtxApiOp
- Returns:
- the operation return type
-
nickname
Returns the operation nickname. -
httpMethod
Returns the operation http method.- Specified by:
httpMethod
in interfaceCtxApiOp
- Returns:
- the operation http method
-
path
Returns the operation path. -
summary
Returns the optional operation summary. -
notes
Returns the optional operation notes. -
allParams
Returns all parameters of the operation. -
responses
Returns all responses of the operation. -
madaOp
Returns additional custom template data for the operation. -
withReturnType
Copy the current immutable object by setting a value for thereturnType
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for returnType- Returns:
- A modified copy or the
this
object
-
withNickname
Copy the current immutable object by setting a value for thenickname
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for nickname- Returns:
- A modified copy or the
this
object
-
withHttpMethod
Copy the current immutable object by setting a value for thehttpMethod
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for httpMethod- Returns:
- A modified copy or the
this
object
-
withPath
Copy the current immutable object by setting a present value for the optionalpath
attribute.- Parameters:
value
- The value for path- Returns:
- A modified copy or
this
if not changed
-
withPath
Copy the current immutable object by setting an optional value for thepath
attribute. An equality check is used on inner value to prevent copying of the same value by returningthis
.- Parameters:
optional
- An optional value for path- Returns:
- A modified copy or
this
if not changed
-
withSummary
Copy the current immutable object by setting a present value for the optionalsummary
attribute.- Parameters:
value
- The value for summary- Returns:
- A modified copy or
this
if not changed
-
withSummary
Copy the current immutable object by setting an optional value for thesummary
attribute. An equality check is used on inner value to prevent copying of the same value by returningthis
.- Parameters:
optional
- An optional value for summary- Returns:
- A modified copy or
this
if not changed
-
withNotes
Copy the current immutable object by setting a present value for the optionalnotes
attribute.- Parameters:
value
- The value for notes- Returns:
- A modified copy or
this
if not changed
-
withNotes
Copy the current immutable object by setting an optional value for thenotes
attribute. An equality check is used on inner value to prevent copying of the same value by returningthis
.- Parameters:
optional
- An optional value for notes- Returns:
- A modified copy or
this
if not changed
-
withAllParams
Copy the current immutable object with elements that replace the content ofallParams
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withAllParams
Copy the current immutable object with elements that replace the content ofallParams
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of allParams elements to set- Returns:
- A modified copy or
this
if not changed
-
withResponses
Copy the current immutable object with elements that replace the content ofresponses
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withResponses
Copy the current immutable object with elements that replace the content ofresponses
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of responses elements to set- Returns:
- A modified copy or
this
if not changed
-
withMadaOp
Copy the current immutable object by setting a value for themadaOp
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for madaOp- Returns:
- A modified copy or the
this
object
-
equals
This instance is equal to all instances ofImmutableCtxApiOp
that have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:returnType
,nickname
,httpMethod
,path
,summary
,notes
,allParams
,responses
,madaOp
. -
toString
Prints the immutable valueCtxApiOp
with attribute values. -
copyOf
Creates an immutable copy of aCtxApiOp
value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance
- The instance to copy- Returns:
- A copied immutable CtxApiOp instance
-
builder
Creates a builder forImmutableCtxApiOp
.ImmutableCtxApiOp.builder() .returnType(String) // required
returnType
.nickname(String) // requirednickname
.httpMethod(String) // requiredhttpMethod
.path(Optional<String>) // optionalpath
.summary(Optional<String>) // optionalsummary
.notes(Optional<String>) // optionalnotes
.addAllParams|addAllAllParams(dk.mada.jaxrs.generator.mpclient.api.tmpl.CtxApiParam) //allParams
elements .addResponses|addAllResponses(dk.mada.jaxrs.generator.mpclient.api.tmpl.CtxApiResponse) //responses
elements .madaOp(dk.mada.jaxrs.generator.mpclient.api.tmpl.CtxApiOpExt) // requiredmadaOp
.build();- Returns:
- A new ImmutableCtxApiOp builder
-