Interface JsonProvider
- All Known Implementing Classes:
GsonJsonProvider,JacksonJsonProvider,JsonOrgJsonProvider
public interface JsonProvider
Provides JSON serialization and deserialization.
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic JsonProviderReturns a singleton instance of aJsonProviderbased on available libraries.Parses JSON text into aMaptree.Parses JSON text into aMaptree.Writes aMaptree to a JSON text.
-
Method Details
-
parse
Parses JSON text into aMaptree. ThrowsOAuth2ClientJsonExceptionif the operation fails.- Throws:
OAuth2ClientJsonException
-
tryParse
-
write
Writes aMaptree to a JSON text.- Throws:
OAuth2ClientJsonException
-
getInstance
Returns a singleton instance of aJsonProviderbased on available libraries. Prefers Jackson, then Gson, then org.json. ThrowsOAuth2ClientJsonExceptionif none are available.
-