Пример #1
0
        /// <summary>
        /// Internal use only
        /// </summary>
        /// <param name="file"></param>
        /// <param name="item"></param>
        /// <param name="parrent"></param>
        public DotNetMethod(PEParaser file, MethodTabelRow item, DotNetType parrent, uint nextMethod)
        {
            this.file       = file;
            this.method     = item;
            this.Parrent    = parrent;
            this.flags      = (MethodAttr)item.Flags;
            this.nextMethod = nextMethod;

            this.Signature = file.ClrStringsStream.GetByOffset(item.Signature);
            this.Name      = file.ClrStringsStream.GetByOffset(item.Name);
        }
Пример #2
0
        /// <summary>
        /// Internal use only
        /// </summary>
        /// <param name="file"></param>
        /// <param name="item"></param>
        /// <param name="parrent"></param>
        public DotNetMethod(PEFile file, Method item, DotNetType parrent)
        {
            this.file         = file;
            this.BackendTabel = item;
            this.Parent       = parrent;
            this.flags        = (MethodAttr)item.Flags;
            this.implFlags    = (MethodImp)item.ImplFlags;
            this.file2        = parrent.File;
            ParamListIndex    = item.ParamList;
            this.Name         = file.ClrStringsStream.GetByOffset(item.Name);

            //method signatures
            SignatureInfo      = ParseMethodSignature(item.Signature, File, this.Name);
            this.Signature     = SignatureInfo.Signature;
            this.AmountOfParms = SignatureInfo.AmountOfParms;
            Parms        = SignatureInfo.Params;
            this.HasThis = SignatureInfo.HasThis;

            if (SignatureInfo.ReturnVal.type != StackItemType.None)
            {
                HasReturnValue = true;
            }
        }