com.thetransactioncompany.jsonrpc2.util.package-info Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jsonrpc2-base Show documentation
Show all versions of jsonrpc2-base Show documentation
Java classes to represent, parse and serialise JSON-RPC
2.0 requests, notifications and responses.
/**
* Utility classes for typed retrieval of JSON-RPC 2.0 request parameters on the
* server side.
*
* The following parameter type conversion choices are available:
*
*
* - JSON true/false to Java {@code boolean}
*
- JSON number to Java {@code int}, {@code long}, {@code float} or
* {@code double}
*
- JSON string to {@code java.lang.String}
*
- Predefined (enumerated) JSON string to a Java {@code enum} constant
* or {@code java.lang.String}
*
- JSON array to Java {@code boolean[]}, {@code int[]}, {@code long[]},
* {@code float[]}, {@code double[]} or {@code string[]} array, or
* to mixed type {@code java.util.List}
*
- JSON object to {@code java.util.Map}
*
*
* If a parameter cannot be retrieved, either because it's missing or
* is of the wrong type, a standard
* {@link com.thetransactioncompany.jsonrpc2.JSONRPC2Error#INVALID_PARAMS}
* exception is thrown.
*
*
There are two concrete classes:
*
*
* - The {@link com.thetransactioncompany.jsonrpc2.util.PositionalParamsRetriever}
* class is for extracting positional parameters (packed in a
* JSON array).
*
- The {@link com.thetransactioncompany.jsonrpc2.util.NamedParamsRetriever}
* class is for extracting named parameters (packed in a JSON
* object).
*
*
*
* Package dependencies: The classes in this package depend on the
* sister {@link com.thetransactioncompany.jsonrpc2} package.
*
* @author Vladimir Dzhuvinov
* @version 1.34.3
*/
package com.thetransactioncompany.jsonrpc2.util;
© 2015 - 2025 Weber Informatics LLC | Privacy Policy