<!--
	This is an XML document type definition (DTD) for
	CIML (Customer Identity Markup Language).
	Date of Creation: 25th of November, 1999
	Cognito, Inc, Level 12, 67 Albert Avenue
	Chatswood, NSW 2067, AUSTRALIA
	Contact: rkumar@msi.com.au (Ram Kumar)
	Version: 0.5
                  Copyright (c) Cognito, Inc.  
	
-->


<!--===============================CIML Document======================================-->
<!--The root element CIML contains the element RECORD. All other elements are then 
    defined within the RECORD element. This is so multiple records can be in the one XML 
    file. 
-->
<!ELEMENT ciml 			(record+)>
<!ELEMENT record		(unique_identifier?, naml?, company_trading_name*,
				 		 company_regn_number?, company_tax_number?, 
						(company_formation_date|company_formation_date_information)?,
						(date_of_birth|date_of_birth_information)?, age?, age_range?,
				 		 gender?, marital_status?, citizenship*, country_of_birth?,
						(passport*|passport_information?), religion?,
				 		 ethnicity?, (mobile*|mobile_information?),
						(telephone*|telephone_information?), (fax*|fax_information?),
				 		 pager*, (email*|email_information?), (url*|url_information?),
						(credit_card*|credit_card_information?),
				 		 person_identification_number?,
						(drivers_license*|drivers_license_information?),
						(frequent_flier*|frequent_flier_information?),
						(person_tax_number*|person_tax_number_information?))>
		
<!ELEMENT unique_identifier		(#PCDATA)>

<!--Here NAML is defined as an external entity. The external entity in this case is the
    file naml-ciml.dtd which contains all the elements for the Name and Address Markup 
    Language. By entering the entity reference "%naml" all of the content in the 
    naml-ciml.dtd file is imported into this file when this dtd is parsed.
--> 
<!ENTITY % naml SYSTEM "naml-ciml.dtd">
%naml;
		
<!ELEMENT company_trading_name 		(#PCDATA)>
<!ELEMENT company_regn_number 		(#PCDATA)>
<!ELEMENT company_tax_number		(#PCDATA)>
<!ELEMENT company_formation_date 	(#PCDATA)>

<!--If the element COMPANY_FORMATION_DATE_INFORMATION is used it must be followed by the 
    elements DAY, MONTH, YEAR, or its end tag "/COMPANY_FORMATION_DATE_INFORMATION".
-->
<!ELEMENT company_formation_date_information		(day?, month?, year?)>
<!ELEMENT day 										(#PCDATA)>
<!ELEMENT month 									(#PCDATA)>
<!ELEMENT year  									(#PCDATA)>

<!ELEMENT date_of_birth								(#PCDATA)>

<!--If the element DATE_OF_BIRTH_INFORMATION is used it must be followed by the elements
    BIRTH_DAY, BIRTH_MONTH, BIRTH_YEAR, or its end tag "/DATE_OF_BIRTH_INFORMATION".
--> 
<!ELEMENT date_of_birth_information			(birth_day?, birth_month?, birth_year?)>
<!ELEMENT birth_day   						(#PCDATA)>
<!ELEMENT birth_month						(#PCDATA)>
<!ELEMENT birth_year						(#PCDATA)>

<!ELEMENT age 								(#PCDATA)>
<!ELEMENT age_range							(#PCDATA)>
<!ELEMENT gender							(#PCDATA)>
<!ELEMENT marital_status					(#PCDATA)>
<!ELEMENT citizenship						(#PCDATA)>
<!ELEMENT country_of_birth					(#PCDATA)>
<!ELEMENT passport							(#PCDATA)>

<!--If the element PASSPORT_INFORMATION is used it must be followed by the element
    PASSPORT_DETAILS which can occur multiple times for the situation where the 
    customer has multiple passports.
-->
<!ELEMENT passport_information			(passport_details+)>

<!--If the element PASSPORT_DETAILS is used it must be followed by the elements
    PASSPORT_COUNTRY, PASSPORT_NUMBER, ONE of either PASSPORT_EXPIRY_DATE or 
    PASSPORT_EXPIRY_DATE_DETAILS, or its end tag "/PASSPORT_DETAILS".
--> 
<!ELEMENT passport_details		(passport_country?, passport_number?,
								(passport_expiry_date|passport_expiry_date_details)?)>
<!ELEMENT passport_country		(#PCDATA)>
<!ELEMENT passport_number		(#PCDATA)>
<!ELEMENT passport_expiry_date	(#PCDATA)>

<!--If the element PASSPORT_EXPIRY_DATE_DETAILS is used it must be followed by the
    elements PASSPORT_EXPIRY_DAY, PASSPORT_EXPIRY_MONTH, PASSPORT_EXPIRY_YEAR, or its 
    end tag "/PASSPORT_EXPIRY_DATE_DETAILS".
-->
<!ELEMENT passport_expiry_date_details		(passport_expiry_day?, passport_expiry_month?, 
						 					 passport_expiry_year?)>
<!ELEMENT passport_expiry_day				(#PCDATA)>
<!ELEMENT passport_expiry_month				(#PCDATA)>
<!ELEMENT passport_expiry_year				(#PCDATA)>

<!ELEMENT religion							(#PCDATA)>
<!ELEMENT ethnicity							(#PCDATA)>
<!ELEMENT mobile							(#PCDATA)>

<!--If the element MOBILE_INFORMATION is used it must be followed by the element
    MOBILE_DETAILS which can occur multiple times for the situation where the 
    customer has multiple mobile phone numbers.
-->
<!ELEMENT mobile_information			(mobile_details+)>

<!--If the element MOBILE_DETAILS is used it must be followed by the elements
    MOBILE_COUNTRY_CODE, MOBILE_NUMBER, or its end tag "/MOBILE_DETAILS".
-->
<!ELEMENT mobile_details				(mobile_country_code?, mobile_number?)>
<!ELEMENT mobile_country_code			(#PCDATA)>
<!ELEMENT mobile_number					(#PCDATA)>

<!ELEMENT telephone						(#PCDATA)>

<!--If the element TELEPHONE_INFORMATION is used it must be followed by the element 
    TELEPHONE_DETAILS which can occur multiple times for the situation where the
    customer has multiple telephone numbers.
-->
<!ELEMENT telephone_information			(telephone_details+)>

<!--If the element TELEPHONE_DETAILS is used it must be followed by the elements
	TELEPHONE_USAGE, TELEPHONE_COUNTRY_CODE, TELEPHONE_AREA_CODE, TELEPHONE_NUMBER,
	TELEPHONE_EXTENSION, or its end tag "/TELEPHONE_DETAILS".
-->
<!ELEMENT telephone_details				(telephone_usage?, telephone_country_code?,
										 telephone_area_code?, telephone_number?, 
										 telephone_extension?)>
<!ELEMENT telephone_usage				(#PCDATA)>
<!ELEMENT telephone_country_code		(#PCDATA)>
<!ELEMENT telephone_area_code			(#PCDATA)>
<!ELEMENT telephone_number				(#PCDATA)>
<!ELEMENT telephone_extension			(#PCDATA)>

<!ELEMENT fax							(#PCDATA)>

<!--If the element FAX_INFORMATION is used it must be followed by the element
	FAX_DETAILS which can occur multiple times for the situation where the customer
	has multiple fax numbers.
-->
<!ELEMENT fax_information				(fax_details+)>

<!--If the element FAX_DETAILS is used it must be followed by the elements FAX_USAGE,
	FAX_COUNTRY_CODE, FAX_AREA_CODE, FAX_NUMBER, or its end tag "/FAX_DETAILS".
-->
<!ELEMENT fax_details					(fax_usage?, fax_country_code?, 
										 fax_area_code?, fax_number?)>
<!ELEMENT fax_usage						(#PCDATA)>
<!ELEMENT fax_country_code				(#PCDATA)>
<!ELEMENT fax_area_code					(#PCDATA)>
<!ELEMENT fax_number					(#PCDATA)>

<!ELEMENT pager							(#PCDATA)>
<!ELEMENT email							(#PCDATA)>

<!--If the element EMAIL_INFORMATION is used it must be followed by the elements
	BUSINESS_EMAIL, PERSONAL_EMAIL (where both can occur multiple times) or its 
	end tag "/EMAIL_INFORMATION".
-->
<!ELEMENT email_information				(business_email*, personal_email*)>
<!ELEMENT business_email				(#PCDATA)>
<!ELEMENT personal_email				(#PCDATA)>

<!ELEMENT url							(#PCDATA)>

<!--If the element URL_INFORMATION is used it must be followed by the elements
	BUSINESS_URL, PERSONAL_URL (where both can occur multiple times) or its 
	end tag "/URL_INFORMATION".
-->
<!ELEMENT url_information				(business_url*, personal_url*)>
<!ELEMENT business_url					(#PCDATA)>
<!ELEMENT personal_url					(#PCDATA)>

<!ELEMENT credit_card					(#PCDATA)>

<!--If the element CREDIT_CARD_INFORMATION is used it must be followed by the
	element CREDIT_CARD_DETAILS which can occur multiple times for the situation
	where the customer has multiple credit cards.
-->
<!ELEMENT credit_card_information			(credit_card_details+)>

<!--If the element CREDIT_CARD_DETAILS is used it must be followed by the elements 
	CREDIT_CARD_TYPE, CREDIT_CARD_NUMBER, one of either CREDIT_CARD_EXPIRY_DATE or 
	CREDIT_CARD_EXPIRY_DATE_DETAILS, one of either NAME_ON_CREDIT_CARD or 
	NAME_DETAILS_ON_CREDIT_CARD, or its end tag "/CREDIT_CARD_DETAILS".
-->
<!ELEMENT credit_card_details (credit_card_type?, credit_card_number?,
							  (credit_card_expiry_date|credit_card_expiry_date_details)?, 
							  (name_on_credit_card|name_details_on_credit_card)?)>
<!ELEMENT credit_card_type					(#PCDATA)>
<!ELEMENT credit_card_number				(#PCDATA)>
<!ELEMENT credit_card_expiry_date			(#PCDATA)>

<!--If the element CREDIT_CARD_EXPIRY_DATE_DETAILS is used it must be followed by the
	elements CREDIT_CARD_EXPIRY_MONTH, CREDIT_CARD_EXPIRY_YEAR, or its end tag
	"/CREDIT_CARD_EXPIRY_DATE_DETAILS".
-->
<!ELEMENT credit_card_expiry_date_details	(credit_card_expiry_month?, 
											 credit_card_expiry_year?)>
<!ELEMENT credit_card_expiry_month			(#PCDATA)>
<!ELEMENT credit_card_expiry_year			(#PCDATA)>

<!ELEMENT name_on_credit_card				(#PCDATA)>

<!--If the element NAME_DETAILS_ON_CREDIT_CARD is used it must be followed by the 
	elements FIRST_NAME_ON_CREDIT_CARD, MIDDLE_NAME_ON_CREDIT_CARD, 
	LAST_NAME_ON_CREDIT_CARD or its end tag "/NAME_DETAILS_ON_CREDIT_CARD".
-->
<!ELEMENT name_details_on_credit_card		(first_name_on_credit_card?, 
											 middle_name_on_credit_card?,
											 last_name_on_credit_card?)>
<!ELEMENT first_name_on_credit_card			(#PCDATA)>
<!ELEMENT middle_name_on_credit_card		(#PCDATA)>
<!ELEMENT last_name_on_credit_card			(#PCDATA)>

<!ELEMENT person_identification_number		(#PCDATA)>
<!ELEMENT drivers_license					(#PCDATA)>

<!--If the element DRIVERS_LICENSE_INFORMATION is used it must be followed by the
	element DRIVERS_LICENSE_DETAILS which can occur multiple times for the 
	situation where the customer has multiple driver's licenses.
-->
<!ELEMENT drivers_license_information		(drivers_license_details+)>

<!--If the element DRIVERS_LICENSE_DETAILS is used it must be followed by the elements
	DRIVERS_LICENSE_TYPE, DRIVERS_LICENSE_NUMBER, DRIVERS_LICENSE_STATE,
	DRIVERS_LICENSE_COUNTRY, one of either DRIVERS_LICENSE_EXPIRY_DATE or 
	DRIVERS_LICENSE_EXPIRY_DATE_DETAILS, or its	end tag	"/DRIVERS_LICENSE_DETAILS".
-->
<!ELEMENT drivers_license_details			(drivers_license_type?, 
										 	 drivers_license_number?,
										 	 drivers_license_state?,
										 	 drivers_license_country?,
					(drivers_license_expiry_date|drivers_license_expiry_date_details)?)>
<!ELEMENT drivers_license_type				(#PCDATA)>
<!ELEMENT drivers_license_number			(#PCDATA)>
<!ELEMENT drivers_license_state				(#PCDATA)>
<!ELEMENT drivers_license_country			(#PCDATA)>
<!ELEMENT drivers_license_expiry_date		(#PCDATA)>
<!--If the element DRIVERS_LICENSE_EXPIRY_DATE_DETAILS is used it must be followed by
	the elements DRIVERS_LICENSE_EXPIRY_DAY, DRIVERS_LICENSE_EXPIRY_MONTH, 
	DRIVERS_LICENSE_EXPIRY_YEAR, or its end tag "/DRIVERS_LICENSE_EXPIRY_DATE_DETAILS".
-->
<!ELEMENT drivers_license_expiry_date_details	(drivers_license_expiry_day?,
												 drivers_license_expiry_month?,
												 drivers_license_expiry_year?)>
<!ELEMENT drivers_license_expiry_day			(#PCDATA)>
<!ELEMENT drivers_license_expiry_month			(#PCDATA)>
<!ELEMENT drivers_license_expiry_year			(#PCDATA)>

<!ELEMENT frequent_flier				(#PCDATA)>

<!--If the element FREQUENT_FLIER_INFORMATION is used it must be followed by the
	element FREQUENT_FLIER_DETAILS which can occur multiple times for the situation
	where the customer is a member of multiple frequent flier programs.
-->
<!ELEMENT frequent_flier_information	(frequent_flier_details+)>

<!--If the element FREQUENT_FLIER_DETAILS is used it must be followed by the elements
	ALLIANCE, FREQUENT_FLIER_NUMBER, one of either DATE_OF_JOINING or 
	DATE_OF_JOINING_DETAILS, or its end tag "/FREQUENT_FLIER_DETAILS".
-->
<!ELEMENT frequent_flier_details		(alliance?, frequent_flier_number?, 
										(date_of_joining|date_of_joining_details)?)>
<!ELEMENT alliance						(#PCDATA)>
<!ELEMENT frequent_flier_number			(#PCDATA)>
<!ELEMENT date_of_joining				(#PCDATA)>

<!--If the element DATE_OF_JOINING_DETAILS is used it must be followed by the elements
	DATE_OF_JOINING_DAY, DATE_OF_JOINING_MONTH, DATE_OF_JOINING_YEAR, or its end tag
	"/DATE_OF_JOINING_DETAILS".
-->
<!ELEMENT date_of_joining_details		(date_of_joining_day?,
										 date_of_joining_month?,
										 date_of_joining_year?)>
<!ELEMENT date_of_joining_day			(#PCDATA)>
<!ELEMENT date_of_joining_month			(#PCDATA)>
<!ELEMENT date_of_joining_year			(#PCDATA)>

<!ELEMENT person_tax_number				(#PCDATA)>

<!--If the element PERSON_TAX_NUMBER_INFORMATION is used it must be followed by the 
	element PERSON_TAX_NUMBER_DETAILS which can occur multiple times for the situation
	where the customer has multiple tax numbers.
-->
<!ELEMENT person_tax_number_information (person_tax_number_details+)>

<!--If the element PERSON_TAX_NUMBER_DETAILS is used it must be followed by the elements
	TAX_COUNTRY, TAX_NUMBER, or its end tag "/PERSON_TAX_NUMBER_DETAILS".
-->
<!ELEMENT person_tax_number_details		(tax_country?, tax_number?)>
<!ELEMENT tax_country					(#PCDATA)>
<!ELEMENT tax_number					(#PCDATA)>
		
			
			
													 