decodeFromStringOrNull

fun decodeFromStringOrNull(@Language(value = "xml") string: String): Document?(source)

Decodes a Document from the given XML string. If the string is not a well-formed GPX document, null is returned.

Return

A Document object if decoding is successful, or null if the string is invalid.

Parameters

string

The XML string to decode.