<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~  Licensed to the Apache Software Foundation (ASF) under one
  ~  or more contributor license agreements.  See the NOTICE file
  ~  distributed with this work for additional information
  ~  regarding copyright ownership.  The ASF licenses this file
  ~  to you under the Apache License, Version 2.0 (the
  ~  "License"); you may not use this file except in compliance
  ~  with the License.  You may obtain a copy of the License at
  ~
  ~   http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~  Unless required by applicable law or agreed to in writing,
  ~  software distributed under the License is distributed on an
  ~   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  ~  KIND, either express or implied.  See the License for the
  ~  specific language governing permissions and limitations
  ~  under the License.
  -->
<schema xmlns="http://www.w3.org/2001/XMLSchema"
        targetNamespace="http://synapse.apache.org/ns/syslog"
        xmlns:tns="http://synapse.apache.org/ns/syslog"
        elementFormDefault="qualified">
    <simpleType name="facilityType">
        <restriction base="string">
            <enumeration value="kern"/>
            <enumeration value="user"/>
            <enumeration value="mail"/>
            <enumeration value="daemon"/>
            <enumeration value="auth"/>
            <enumeration value="syslog"/>
            <enumeration value="lpr"/>
            <enumeration value="news"/>
            <enumeration value="uucp"/>
            <enumeration value="cron"/>
            <enumeration value="authpriv"/>
            <enumeration value="ftp"/>
            <enumeration value="reserved0"/>
            <enumeration value="reserved1"/>
            <enumeration value="reserved2"/>
            <enumeration value="reserved3"/>
            <enumeration value="local0"/>
            <enumeration value="local1"/>
            <enumeration value="local2"/>
            <enumeration value="local3"/>
            <enumeration value="local4"/>
            <enumeration value="local5"/>
            <enumeration value="local6"/>
            <enumeration value="local7"/>
        </restriction>
    </simpleType>
    
    <simpleType name="severityType">
        <restriction base="string">
            <enumeration value="emerg"/>
            <enumeration value="alert"/>
            <enumeration value="crit"/>
            <enumeration value="err"/>
            <enumeration value="warning"/>
            <enumeration value="notice"/>
            <enumeration value="info"/>
            <enumeration value="debug"/>
        </restriction>
    </simpleType>
    
    <element name="message">
        <complexType>
            <simpleContent>
                <extension base="string">
                    <attribute name="facility" type="tns:facilityType" use="required"/>
                    <attribute name="severity" type="tns:severityType" use="required"/>
                    <attribute name="tag" type="string" use="optional"/>
                    <attribute name="pid" type="int" use="optional"/>
                </extension>
            </simpleContent>
        </complexType>
    </element>
</schema>
