getDataSchema

Lookup a data schema by name. Panic if the data schema does not exist.

Example checking if a data schema exists:
open fun checkDataSchemaExistsExample(): kotlin.Unit
{
    val csdlDocument = this.service.metadata;
    if (csdlDocument.dataSchemas.has("Microsoft.OData.Service.Sample.TrippinInMemory.Models"))
    {
        Ignore.valueOf_any(csdlDocument.getDataSchema("Microsoft.OData.Service.Sample.TrippinInMemory.Models"));
    }
    else
    {
        // The data schema Microsoft.OData.Service.Sample.TrippinInMemory.Models does not exists, add logic to handle the issue/throw an Exception, etc..
    }
}
See Also:

{@link com.sap.cloud.mobile.kotlin.odata.csdl.CsdlDocument#dataSchemas CsdlDocument.dataSchemas}, for looking up schemas that might not exist.

Return

The requested data schema.

Parameters

name

Name of the data schema to be returned.