{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "title": "CSV Dialect",
  "description": "The CSV dialect descriptor.",
  "type": [
    "string",
    "object"
  ],
  "required": [
    "delimiter",
    "doubleQuote"
  ],
  "properties": {
    "csvddfVersion": {
      "title": "CSV Dialect schema version",
      "description": "A number to indicate the schema version of CSV Dialect. Version 1.0 was named CSV Dialect Description Format and used different field names.",
      "type": "number",
      "default": 1.2,
      "examples:": [
        "{\n  \"csvddfVersion\": \"1.2\"\n}\n"
      ]
    },
    "delimiter": {
      "title": "Delimiter",
      "description": "A character sequence to use as the field separator.",
      "type": "string",
      "default": ",",
      "examples": [
        "{\n  \"delimiter\": \",\"\n}\n",
        "{\n  \"delimiter\": \";\"\n}\n"
      ]
    },
    "doubleQuote": {
      "title": "Double Quote",
      "description": "Specifies the handling of quotes inside fields.",
      "context": "If Double Quote is set to true, two consecutive quotes must be interpreted as one.",
      "type": "boolean",
      "default": true,
      "examples": [
        "{\n  \"doubleQuote\": true\n}\n"
      ]
    },
    "lineTerminator": {
      "title": "Line Terminator",
      "description": "Specifies the character sequence that must be used to terminate rows.",
      "type": "string",
      "default": "\r\n",
      "examples": [
        "{\n  \"lineTerminator\": \"\\r\\n\"\n}\n",
        "{\n  \"lineTerminator\": \"\\n\"\n}\n"
      ]
    },
    "nullSequence": {
      "title": "Null Sequence",
      "description": "Specifies the null sequence, for example, `\\N`.",
      "type": "string",
      "examples": [
        "{\n  \"nullSequence\": \"\\N\"\n}\n"
      ]
    },
    "quoteChar": {
      "title": "Quote Character",
      "description": "Specifies a one-character string to use as the quoting character.",
      "type": "string",
      "default": "\"",
      "examples": [
        "{\n  \"quoteChar\": \"'\"\n}\n"
      ]
    },
    "escapeChar": {
      "title": "Escape Character",
      "description": "Specifies a one-character string to use as the escape character.",
      "type": "string",
      "examples": [
        "{\n  \"escapeChar\": \"\\\\\"\n}\n"
      ]
    },
    "skipInitialSpace": {
      "title": "Skip Initial Space",
      "description": "Specifies the interpretation of whitespace immediately following a delimiter. If false, whitespace immediately after a delimiter should be treated as part of the subsequent field.",
      "type": "boolean",
      "default": false,
      "examples": [
        "{\n  \"skipInitialSpace\": true\n}\n"
      ]
    },
    "header": {
      "title": "Header",
      "description": "Specifies if the file includes a header row, always as the first row in the file.",
      "type": "boolean",
      "default": true,
      "examples": [
        "{\n  \"header\": true\n}\n"
      ]
    },
    "commentChar": {
      "title": "Comment Character",
      "description": "Specifies that any row beginning with this one-character string, without preceeding whitespace, causes the entire line to be ignored.",
      "type": "string",
      "examples": [
        "{\n  \"commentChar\": \"#\"\n}\n"
      ]
    },
    "caseSensitiveHeader": {
      "title": "Case Sensitive Header",
      "description": "Specifies if the case of headers is meaningful.",
      "context": "Use of case in source CSV files is not always an intentional decision. For example, should \"CAT\" and \"Cat\" be considered to have the same meaning.",
      "type": "boolean",
      "default": false,
      "examples": [
        "{\n  \"caseSensitiveHeader\": true\n}\n"
      ]
    }
  },
  "examples": [
    "{\n  \"dialect\": {\n    \"delimiter\": \";\"\n  }\n}\n",
    "{\n  \"dialect\": {\n    \"delimiter\": \"\\t\",\n    \"quoteChar\": \"'\",\n    \"commentChar\": \"#\"\n  }\n}\n"
  ]
}