Class PathItem
The PathItem Object describes the operations available on a single path. A Path Item may be empty, due to ACL constraints. The path itself is still exposed to the documentation viewer but they will not know which operations and parameters are available.
OpenAPI Specification:
The PathItem Object is composed of the following fields:
summary (string) - An optional, string summary, intended to apply to all operations in this pathdescription (string) - An optional, string description, intended to apply to all operations in this pathget (Operation
) - A definition of a GET operation on this pathput (Operation
) - A definition of a PUT operation on this pathpost (Operation
) - A definition of a POST operation on this pathdelete (Operation
) - A definition of a DELETE operation on this pathoptions (Operation
) - A definition of an OPTIONS operation on this pathhead (Operation
) - A definition of a HEAD operation on this pathpatch (Operation
) - A definition of a PATCH operation on this pathtrace (Operation
) - A definition of a TRACE operation on this pathservers (array ofServer
) - An alternative server array to service all operations in this pathparameters (array ofParameter
) - A list of parameters that are applicable for all the operations described under this path
Example:
See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()
Creates a copy of this object.<T> T
Generic property getter.Returns the DELETE operation.Returns the description.getGet()
Returns the GET operation.getHead()
Returns the HEAD operation.Returns the OPTIONS operation.Returns the parameters list.getPatch()
Returns the PATCH operation.getPost()
Returns the POST operation.getPut()
Returns the PUT operation.Returns the servers list.Returns the summary.getTrace()
Returns the TRACE operation.keySet()
Returns all the keys on this element.Generic property setter.Sets the DELETE operation.setDescription
(String value) Sets the description.Sets the GET operation.Sets the HEAD operation.setOptions
(Operation value) Sets the OPTIONS operation.setParameters
(List<Parameter> value) Sets the parameters list.Sets the PATCH operation.Sets the POST operation.Sets the PUT operation.setServers
(List<Server> value) Sets the servers list.setSummary
(String value) Sets the summary.Sets the TRACE operation.strict()
Sets strict mode on this bean.Sets strict mode on this bean.
-
Constructor Details
-
PathItem
public PathItem()Default constructor. -
PathItem
Copy constructor.- Parameters:
copyFrom
- The object to copy.
-
-
Method Details
-
getSummary
Returns the summary.- Returns:
- The summary.
-
setSummary
Sets the summary.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getDescription
Returns the description.- Returns:
- The description.
-
setDescription
Sets the description.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getGet
Returns the GET operation.- Returns:
- The GET operation.
-
setGet
Sets the GET operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getPut
Returns the PUT operation.- Returns:
- The PUT operation.
-
setPut
Sets the PUT operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getPost
Returns the POST operation.- Returns:
- The POST operation.
-
setPost
Sets the POST operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getDelete
Returns the DELETE operation.- Returns:
- The DELETE operation.
-
setDelete
Sets the DELETE operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getOptions
Returns the OPTIONS operation.- Returns:
- The OPTIONS operation.
-
setOptions
Sets the OPTIONS operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getHead
Returns the HEAD operation.- Returns:
- The HEAD operation.
-
setHead
Sets the HEAD operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getPatch
Returns the PATCH operation.- Returns:
- The PATCH operation.
-
setPatch
Sets the PATCH operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getTrace
Returns the TRACE operation.- Returns:
- The TRACE operation.
-
setTrace
Sets the TRACE operation.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getServers
Returns the servers list.- Returns:
- The servers list.
-
setServers
Sets the servers list.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
getParameters
Returns the parameters list.- Returns:
- The parameters list.
-
setParameters
Sets the parameters list.- Parameters:
value
- The new value for this property.- Returns:
- This object.
-
copy
Creates a copy of this object.- Returns:
- A copy of this object.
-
get
Description copied from class:OpenApiElement
Generic property getter.Can be used to retrieve non-standard Swagger fields such as
"$ref" .- Overrides:
get
in classOpenApiElement
- Type Parameters:
T
- The datatype to cast the value to.- Parameters:
property
- The property name to retrieve.type
- The datatype to cast the value to.- Returns:
- The property value, or
null if the property does not exist or is not set.
-
set
Description copied from class:OpenApiElement
Generic property setter.Can be used to set non-standard Swagger fields such as
"$ref" .- Overrides:
set
in classOpenApiElement
- Parameters:
property
- The property name to set. Must not benull .value
- The new value for the property.- Returns:
- This object
-
keySet
Description copied from class:OpenApiElement
Returns all the keys on this element.- Overrides:
keySet
in classOpenApiElement
- Returns:
- All the keys on this element.
Nevernull .
-
strict
Description copied from class:OpenApiElement
Sets strict mode on this bean.- Overrides:
strict
in classOpenApiElement
- Returns:
- This object
-
strict
Description copied from class:OpenApiElement
Sets strict mode on this bean.- Overrides:
strict
in classOpenApiElement
- Parameters:
value
- The new value for this property.
Non-boolean values will be converted to boolean usingBoolean.
.valueOf (value.toString())
Can benull (interpreted asfalse ).- Returns:
- This object
-