/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
 *
 * The contents of this file are subject to the Netscape Public
 * License Version 1.1 (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.mozilla.org/NPL/
 *
 * Software distributed under the License is distributed on an "AS
 * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
 * implied. See the License for the specific language governing
 * rights and limitations under the License.
 *
 * The Original Code is mozilla.org code.
 *
 * The Initial Developer of the Original Code is Netscape
 * Communications Corporation. Portions created by Netscape are
 * Copyright (C) 2000 Netscape Communications Corporation. All
 * Rights Reserved.
 *
 * Contributor(s): Tao Cheng <tao@netscape.com>
 */

#include "nsISupports.idl"

%{C++

// Define Contractid and CID
// {383F6C15-2797-11d4-BA1C-001083344DE7} 
#define NS_ACCEPTLANG_CID \
{ 0x383f6c15, 0x2797, 0x11d4, \
	{ 0xba, 0x1c, 0x0, 0x10, 0x83, 0x34, 0x4d, 0xe7 }}

#define NS_ACCEPTLANG_CONTRACTID "@mozilla.org/intl/acceptlang;1"
%}

[scriptable, uuid(383F6C16-2797-11d4-BA1C-001083344DE7)]
interface nsIAcceptLang : nsISupports
{
  wstring getAcceptLangFromLocale([const] in wstring aLocale);
  wstring getLocaleFromAcceptLang([const] in wstring aName);
  wstring acceptLang2List([const] in wstring aName, [const] in wstring aList);
};
