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.Builderbuilder()Creates a builder forImmutableCtxApiOp.static ImmutableCtxApiOpCreates an immutable copy of aCtxApiOpvalue.booleanThis instance is equal to all instances ofImmutableCtxApiOpthat have equal attribute values.inthashCode()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 valueCtxApiOpwith attribute values.final ImmutableCtxApiOpwithAllParams(CtxApiParam... elements) Copy the current immutable object with elements that replace the content ofallParams.final ImmutableCtxApiOpwithAllParams(Iterable<? extends CtxApiParam> elements) Copy the current immutable object with elements that replace the content ofallParams.final ImmutableCtxApiOpwithHttpMethod(String value) Copy the current immutable object by setting a value for thehttpMethodattribute.final ImmutableCtxApiOpwithMadaOp(CtxApiOpExt value) Copy the current immutable object by setting a value for themadaOpattribute.final ImmutableCtxApiOpwithNickname(String value) Copy the current immutable object by setting a value for thenicknameattribute.final ImmutableCtxApiOpCopy the current immutable object by setting a present value for the optionalnotesattribute.final ImmutableCtxApiOpCopy the current immutable object by setting an optional value for thenotesattribute.final ImmutableCtxApiOpCopy the current immutable object by setting a present value for the optionalpathattribute.final ImmutableCtxApiOpCopy the current immutable object by setting an optional value for thepathattribute.final ImmutableCtxApiOpwithResponses(CtxApiResponse... elements) Copy the current immutable object with elements that replace the content ofresponses.final ImmutableCtxApiOpwithResponses(Iterable<? extends CtxApiResponse> elements) Copy the current immutable object with elements that replace the content ofresponses.final ImmutableCtxApiOpwithReturnType(String value) Copy the current immutable object by setting a value for thereturnTypeattribute.final ImmutableCtxApiOpwithSummary(String value) Copy the current immutable object by setting a present value for the optionalsummaryattribute.final ImmutableCtxApiOpwithSummary(Optional<String> optional) Copy the current immutable object by setting an optional value for thesummaryattribute.
-
Method Details
-
returnType
Returns the operation return type.- Specified by:
returnTypein interfaceCtxApiOp- Returns:
- the operation return type
-
nickname
Returns the operation nickname. -
httpMethod
Returns the operation http method.- Specified by:
httpMethodin 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 thereturnTypeattribute. 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
thisobject
-
withNickname
Copy the current immutable object by setting a value for thenicknameattribute. 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
thisobject
-
withHttpMethod
Copy the current immutable object by setting a value for thehttpMethodattribute. 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
thisobject
-
withPath
Copy the current immutable object by setting a present value for the optionalpathattribute.- Parameters:
value- The value for path- Returns:
- A modified copy or
thisif not changed
-
withPath
Copy the current immutable object by setting an optional value for thepathattribute. 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
thisif not changed
-
withSummary
Copy the current immutable object by setting a present value for the optionalsummaryattribute.- Parameters:
value- The value for summary- Returns:
- A modified copy or
thisif not changed
-
withSummary
Copy the current immutable object by setting an optional value for thesummaryattribute. 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
thisif not changed
-
withNotes
Copy the current immutable object by setting a present value for the optionalnotesattribute.- Parameters:
value- The value for notes- Returns:
- A modified copy or
thisif not changed
-
withNotes
Copy the current immutable object by setting an optional value for thenotesattribute. 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
thisif 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
thisobject
-
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
thisif 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
thisobject
-
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
thisif not changed
-
withMadaOp
Copy the current immutable object by setting a value for themadaOpattribute. 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
thisobject
-
equals
This instance is equal to all instances ofImmutableCtxApiOpthat 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 valueCtxApiOpwith attribute values. -
copyOf
Creates an immutable copy of aCtxApiOpvalue. 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) // requiredreturnType.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) //allParamselements .addResponses|addAllResponses(dk.mada.jaxrs.generator.mpclient.api.tmpl.CtxApiResponse) //responseselements .madaOp(dk.mada.jaxrs.generator.mpclient.api.tmpl.CtxApiOpExt) // requiredmadaOp.build();- Returns:
- A new ImmutableCtxApiOp builder
-