// Copyright © 2020 The CefSharp Authors. All rights reserved.
//
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
using System.Reflection;
namespace CefSharp.JavascriptBinding
{
///
/// Implement this interface to have control of how the names
/// are converted when binding/executing javascript.
///
public interface IJavascriptNameConverter
{
///
/// Get the javascript name for the property/field/method.
/// Typically this would be based on
///
/// property/field/method
/// javascript name
string ConvertToJavascript(MemberInfo memberInfo);
///
/// This method exists for backwards compatability reasons, historically
/// only the bound methods/fields/properties were converted. Objects returned
/// from a method call were not translated. To preserve this functionality
/// for upgrading users we split this into two methods. Typically thie method
/// would return the same result as
/// Issue #2442
///
/// property/field/method
/// javascript name
string ConvertReturnedObjectPropertyAndFieldToNameJavascript(MemberInfo memberInfo);
}
}