<?xml version="1.0" encoding="UTF-8"?>
<!-- ======================================================================= -->
<!-- Onet Forums 1.0 XML Schema ============================================ -->
<!-- ======================================================================= -->
<!--
    Dates are in the format of: yyyy-MM-dd HH:mm:ss
    example: 2004/12/28 18:51:11
-->
<!-- Top Level Elements ==================================================== -->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
	<xs:element name="Onet">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="PropertyList" minOccurs="0"/>
				<xs:element ref="UserList" minOccurs="0"/>
				<xs:element ref="GroupList" minOccurs="0"/>
				<xs:element ref="ZoneList" minOccurs="0"/>
				<xs:element ref="UserPrivateMessageList" minOccurs="0"/>
				<xs:element ref="AnnouncementList" minOccurs="0"/>
				<xs:element ref="PermissionList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="xmlVersion" use="required"/>
			<xs:attribute name="exportDate" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Property ============================================================== -->
	<xs:element name="PropertyList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Property" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Property">
		<xs:complexType>
			<xs:attribute name="name" use="required"/>
			<xs:attribute name="value" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- User ================================================================= -->
	<xs:element name="UserList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="User" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="User">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Username"/>
				<xs:element ref="PasswordEncrypted"/>
				<xs:element ref="Email"/>
				<xs:element ref="CreationTime"/>
				<xs:element ref="ModificationTime"/>
				<xs:element ref="ActiveValue"/>
				<xs:element ref="ReminderQuestion"/>
				<xs:element ref="ReminderAnswer"/>
				<xs:element ref="PropertyList" minOccurs="0"/>
				<xs:element ref="WatchList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="PasswordEncrypted" type="xs:string"/>
	<xs:element name="Email">
		<xs:complexType mixed="true">
			<xs:attribute name="visible" type="BooleanValue" default="1"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="ReminderQuestion" type="xs:string"/>
	<xs:element name="ReminderAnswer" type="xs:string"/>
	<!-- Group ================================================================= -->
	<xs:element name="GroupList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Group" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Group">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Name"/>
				<xs:element ref="Description"/>
				<xs:element ref="CreationTime"/>
				<xs:element ref="ModificationTime"/>
				<xs:element ref="PropertyList" minOccurs="0"/>
				<xs:element ref="AdminList" minOccurs="0"/>
				<xs:element ref="MemberList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="AdminList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Username" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="MemberList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Username" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<!-- Zone ============================================================== -->
	<xs:element name="ZoneList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Zone" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Zone">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Name" maxOccurs="0"/>
				<xs:element ref="Description" minOccurs="0"/>
				<xs:element ref="CreationTime" minOccurs="0"/>
				<xs:element ref="ModificationTime" minOccurs="0"/>
				<xs:element ref="IndexValue" minOccurs="0"/>
				<xs:element ref="PropertyList" minOccurs="0"/>
				<xs:element ref="PermissionList" minOccurs="0"/>
				<xs:element ref="WatchList" minOccurs="0"/>
				<xs:element ref="ForumList" minOccurs="0"/>
				<xs:element ref="AnnouncementList" minOccurs="0"/>
				<xs:element ref="ZoneList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Forum ================================================================= -->
	<xs:element name="ForumList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Forum" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Forum">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Name" minOccurs="0"/>
				<xs:element ref="Description" minOccurs="0"/>
				<xs:element ref="CreationTime" minOccurs="0"/>
				<xs:element ref="ModificationTime" minOccurs="0"/>
				<xs:element ref="IndexValue" minOccurs="0"/>
				<xs:element ref="PropertyList" minOccurs="0"/>
				<xs:element ref="PermissionList" minOccurs="0"/>
				<xs:element ref="WatchList" minOccurs="0"/>
				<xs:element ref="AnnouncementList" minOccurs="0"/>
				<xs:element ref="ThreadList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Thread ================================================================ -->
	<xs:element name="ThreadList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Thread" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Thread">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="RootID"/>
				<xs:element ref="MsgCount"/>
				<xs:element ref="CreationTime"/>
				<xs:element ref="ModificationTime"/>
				<xs:element ref="PropertyList" minOccurs="0"/>
				<xs:element ref="WatchList" minOccurs="0"/>
				<xs:element ref="MessageList"/>
				<xs:element ref="Poll" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Message =============================================================== -->
	<xs:element name="MessageList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Message" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Message">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Subject"/>
				<xs:element ref="Body"/>
				<xs:element ref="Username"/>
				<xs:element ref="CreationTime"/>
				<xs:element ref="ModificationTime"/>
				<xs:element ref="PropertyList" minOccurs="0"/>
				<xs:element ref="MessageList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Permission ============================================================ -->
	<xs:element name="PermissionList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="UserPermissionList" minOccurs="0"/>
				<xs:element ref="GroupPermissionList" minOccurs="0"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="UserPermissionList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="UserPermission" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="GroupPermissionList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="GroupPermission" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="UserPermission">
		<xs:complexType>
			<xs:attribute name="permissionType" type="PermissionType" use="required"/>
			<xs:attribute name="permission" type="Permission" use="required"/>
			<xs:attribute name="userType" use="required">
				<xs:simpleType>
					<xs:restriction base="xs:token">
						<xs:enumeration value="ANONYMOUS"/>
						<xs:enumeration value="REGISTERED_USER"/>
						<xs:enumeration value="USER"/>
					</xs:restriction>
				</xs:simpleType>
			</xs:attribute>
			<xs:attribute name="username"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="GroupPermission">
		<xs:complexType>
			<xs:attribute name="permissionType" type="PermissionType" use="required"/>
			<xs:attribute name="permission" type="Permission" use="required"/>
			<xs:attribute name="groupName" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:simpleType name="PermissionType">
		<xs:restriction base="xs:token">
			<xs:enumeration value="SYS"/>
			<xs:enumeration value="USER"/>
			<xs:enumeration value="GROUP"/>
			<xs:enumeration value="ZONE"/>
			<xs:enumeration value="FORUM"/>
			<xs:enumeration value="ZONE_FORUM"/>
		</xs:restriction>
	</xs:simpleType>
	<xs:simpleType name="Permission">
		<xs:restriction base="xs:token">
			<xs:enumeration value="SYS_ADMIN"/>
			<xs:enumeration value="USER_ADMIN"/>
			<xs:enumeration value="GROUP_ADMIN"/>
			<xs:enumeration value="ZONE_ADMIN"/>
			<xs:enumeration value="FORUM_ADMIN"/>
			<xs:enumeration value="MODERATOR"/>
			<xs:enumeration value="READ_FORUM"/>
			<xs:enumeration value="READ_MESSAGE"/>
			<xs:enumeration value="CREATE_THREAD"/>
			<xs:enumeration value="CREATE_MESSAGE"/>
			<xs:enumeration value="CREATE_ATTACHMENT"/>
		</xs:restriction>
	</xs:simpleType>
	<!-- Polls =============================================================== -->
	<xs:element name="Poll">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Mode"/>
				<xs:element ref="LifeDays"/>
				<xs:element ref="CreationTime"/>
				<xs:element ref="PollItemList"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Mode">
		<xs:simpleType>
			<xs:restriction base="xs:string">
				<xs:enumeration value="MULTIPLE"/>
				<xs:enumeration value="SINGLE"/>
			</xs:restriction>
		</xs:simpleType>
	</xs:element>
	<xs:element name="LifeDays" type="xs:int"/>
	<xs:element name="PollItemList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="PollItem" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="PollItem">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Name"/>
				<xs:element ref="VoteCount"/>
				<xs:element ref="VoterList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="VoteCount" type="IntValue"/>
	<xs:element name="VoterList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Voter" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Voter">
		<xs:complexType>
			<xs:attribute name="username" use="required"/>
			<xs:attribute name="voteTime" type="GeneralTime" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Watches =============================================================== -->
	<xs:element name="WatchList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Watch" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Watch">
		<xs:complexType>
			<xs:attribute name="id"/>
			<xs:attribute name="username" use="required"/>
			<xs:attribute name="watchType" use="required">
				<xs:simpleType>
					<xs:restriction base="xs:token">
						<xs:enumeration value="NORMAL"/>
						<xs:enumeration value="EMAIL"/>
						<xs:enumeration value="PMESSAGE"/>
						<xs:enumeration value="EMAIL_PMESSAGE"/>
					</xs:restriction>
				</xs:simpleType>
			</xs:attribute>
			<xs:attribute name="scheduled" type="BooleanValue" use="required"/>
			<xs:attribute name="expirable" type="BooleanValue" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Private Message ====================================================== -->
	<xs:element name="UserPrivateMessageList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="FolderList" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="FolderList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Folder" maxOccurs="unbounded"/>
			</xs:sequence>
			<xs:attribute name="username" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="Folder">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Name"/>
				<xs:element ref="PrivateMessageList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="PrivateMessageList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="PrivateMessage" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="PrivateMessage">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Subject"/>
				<xs:element ref="Body"/>
				<xs:element ref="Sender"/>
				<xs:element ref="Recipient"/>
				<xs:element ref="ReadValue"/>
				<xs:element ref="CreationTime"/>
				<xs:element ref="PropertyList" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="Sender">
		<xs:complexType>
			<xs:attribute name="username" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="Recipient">
		<xs:complexType>
			<xs:attribute name="username" use="required"/>
		</xs:complexType>
	</xs:element>
	<xs:element name="ReadValue" type="IntValue"/>
	<!-- Announcements ====================================================== -->
	<xs:element name="AnnouncementList">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Announcement" minOccurs="0" maxOccurs="unbounded"/>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="Announcement">
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Username"/>
				<xs:element ref="Subject"/>
				<xs:element ref="Body"/>
				<xs:element ref="CreationTime"/>
			</xs:sequence>
			<xs:attribute name="id" type="xs:long" use="required"/>
		</xs:complexType>
	</xs:element>
	<!-- Global ================================================================ -->
	<xs:element name="Subject" type="xs:string"/>
	<xs:element name="Body" type="xs:string"/>
	<xs:element name="RootID" type="xs:long"/>
	<xs:element name="MsgCount" type="IntValue"/>
	<xs:element name="IndexValue" type="IntValue"/>
	<xs:element name="ActiveValue" type="BooleanValue"/>
	<xs:element name="Name" type="xs:string"/>
	<xs:element name="ExpireTime" type="GeneralTime"/>
	<xs:element name="CreationTime" type="GeneralTime"/>
	<xs:element name="ModificationTime" type="GeneralTime"/>
	<xs:element name="StartTime" type="GeneralTime"/>
	<xs:element name="EndTime" type="GeneralTime"/>
	<xs:element name="Description" type="xs:string"/>
	<xs:element name="Username" type="xs:string"/>
	<xs:simpleType name="GeneralTime">
		<xs:restriction base="xs:long"/>
	</xs:simpleType>
	<xs:simpleType name="BooleanValue">
		<xs:restriction base="xs:token">
			<xs:enumeration value="1"/>
			<xs:enumeration value="0"/>
		</xs:restriction>
	</xs:simpleType>
	<xs:simpleType name="IntValue">
		<xs:restriction base="xs:int"/>
	</xs:simpleType>
</xs:schema>
