Boo.Lang.Compiler.TypeSystem.ExternalConstructedTypeInfo.GetMethodTemplate C# (CSharp) 메소드

GetMethodTemplate() 공개 메소드

public GetMethodTemplate ( IMethod method ) : IMethod
method IMethod
리턴 IMethod
        public IMethod GetMethodTemplate(IMethod method)
        {
            // HACK: There is no way to find the method from which the specified
            // method was mapped; we'll use the fact that the two methods share
            // the same metadata token

            int token = ((ExternalMethod)method).MethodInfo.MetadataToken;

            return _tss.Map(Array.Find(
                _type.ActualType.GetGenericTypeDefinition().GetMethods(),
                delegate(System.Reflection.MethodInfo mi)
                {
                    return mi.MetadataToken == token;
                }));
        }