All Downloads are FREE. Search and download functionalities are using the official Maven repository.

templates.avro.avro_record.ftl Maven / Gradle / Ivy

The newest version!
{
  "namespace": "${dataElement.namespace}",
  "name": "${dataElement.name}",
  "type": "record",
  "version": "${dataElement.version}",
  "doc": "${dataElement.documentation}",
  "fields": [
      <#list dataElement.fields as field>
      {
        "name": "${field.name}",
        "doc": "${field.documentation}",
        <#if field.array>
            <#if field.required>
                "type": {
                         "type": "array",
                         "items": ["null", "${field.type}"]
                    }
            <#else>
                "type": {
                    "type": "array",
                    "items": ["null", "${field.type}"]
                }
            
        <#else>
             <#if field.required>
                "type": "${field.type}"
             <#else>
                "type": ["null", "${field.type}"]
             
        
      }<#sep>,
     
     ]
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy