intl/locale/nsUConvPropertySearch.h
author Yoshi Huang <allstars.chh@mozilla.com>
Tue, 03 Nov 2015 09:50:54 +0800
changeset 295784 0e4c4db3b90ff45937cc1eab4b7bbd61f4674326
parent 210362 b79894a533bcd2c5b742f55e0de9eff40d8b86c3
child 312625 87dc4355a517fdd4b4273ed0043195a3c2610efd
permissions -rw-r--r--
Bug 1209162 - Create OriginAttributes subtypes. IGNORE IDL r=sicking.

/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#ifndef nsUConvPropertySearch_h_
#define nsUConvPropertySearch_h_

#include "nsStringFwd.h"

class nsUConvPropertySearch
{
  public:
    /**
     * Looks up a property by value.
     *
     * @param aProperties
     *   the static property array
     * @param aKey
     *   the key to look up
     * @param aValue
     *   the return value (empty string if not found)
     * @return NS_OK if found or NS_ERROR_FAILURE if not found
     */
    static nsresult SearchPropertyValue(const char* aProperties[][3],
                                        int32_t aNumberOfProperties,
                                        const nsACString& aKey,
                                        nsACString& aValue);
};

#endif /* nsUConvPropertySearch_h_ */