示例#1
0
 public MetaDataTableNode(MetaDataTableVM mdTable)
     : base(mdTable.Span)
 {
     TableInfo             = mdTable.TableInfo;
     MetaDataTableVM       = mdTable;
     MetaDataTableVM.Owner = this;
 }
示例#2
0
		public MetaDataTableNode(HexDocument doc, MDTable mdTable, IMetaData md)
			: base((ulong)mdTable.StartOffset, (ulong)mdTable.EndOffset - 1) {
			this.doc = doc;
			this.tableInfo = mdTable.TableInfo;
			this.tablesStreamVM = MetaDataTableVM.Create(this, doc, StartOffset, mdTable);
			this.tablesStreamVM.FindMetaDataTable = FindMetaDataTable;
			this.tablesStreamVM.InitializeHeapOffsets((ulong)md.StringsStream.StartOffset, (ulong)md.StringsStream.EndOffset - 1);
		}
示例#3
0
 public MetaDataTableNode(HexDocument doc, MDTable mdTable, IMetaData md)
     : base((ulong)mdTable.StartOffset, (ulong)mdTable.EndOffset - 1)
 {
     this.doc            = doc;
     this.tableInfo      = mdTable.TableInfo;
     this.tablesStreamVM = MetaDataTableVM.Create(this, doc, StartOffset, mdTable);
     this.tablesStreamVM.FindMetaDataTable = FindMetaDataTable;
     this.tablesStreamVM.InitializeHeapOffsets((ulong)md.StringsStream.StartOffset, (ulong)md.StringsStream.EndOffset - 1);
 }
示例#4
0
        public MetaDataTableNode(HexBuffer buffer, MDTable mdTable, IMetaData md)
            : base(HexSpan.FromBounds((ulong)mdTable.StartOffset, (ulong)mdTable.EndOffset))
        {
            Buffer    = buffer;
            TableInfo = mdTable.TableInfo;
            var stringsHeapSpan = HexSpan.FromBounds((ulong)md.StringsStream.StartOffset, (ulong)md.StringsStream.EndOffset);
            var guidHeapSpan    = HexSpan.FromBounds((ulong)md.GuidStream.StartOffset, (ulong)md.GuidStream.EndOffset);

            MetaDataTableVM = MetaDataTableVM.Create(this, buffer, Span.Start, mdTable, stringsHeapSpan, guidHeapSpan);
            MetaDataTableVM.FindMetaDataTable = FindMetaDataTable;
        }
示例#5
0
        protected override void DecompileFields(IDecompiler decompiler, IDecompilerOutput output)
        {
            decompiler.WriteCommentLine(output, string.Empty);
            decompiler.WriteCommentBegin(output, true);
            WriteHeader(output);
            decompiler.WriteCommentEnd(output, true);
            output.WriteLine();

            for (int i = 0; i < (int)MetaDataTableVM.Rows; i++)
            {
                var obj = MetaDataTableVM.Get(i);
                decompiler.WriteCommentBegin(output, true);
                Write(output, obj);
                decompiler.WriteCommentEnd(output, true);
                output.WriteLine();
            }
        }
示例#6
0
        public void WriteHeader(IDecompilerOutput output)
        {
            var cols = MetaDataTableVM.TableInfo.Columns;

            output.Write(string.Format("{0}\t{1}\t{2}", dnSpy_AsmEditor_Resources.RowIdentifier, dnSpy_AsmEditor_Resources.Token, dnSpy_AsmEditor_Resources.Offset), BoxedTextColor.Comment);
            for (int i = 0; i < cols.Count; i++)
            {
                output.Write("\t", BoxedTextColor.Comment);
                output.Write(MetaDataTableVM.GetColumnName(i), BoxedTextColor.Comment);
            }
            if (MetaDataTableVM.HasInfo)
            {
                output.Write("\t", BoxedTextColor.Comment);
                output.Write(MetaDataTableVM.InfoName, BoxedTextColor.Comment);
            }
            output.WriteLine();
        }
		public DeclSecurityMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
		public FieldMarshalMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
		public StateMachineMethodMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#10
0
		public TypeSpecMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#11
0
		public MethodSemanticsMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#12
0
		public EventMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#13
0
		public GenericParamMetaDataTableRecordV11VM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#14
0
		public NestedClassMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#15
0
		public ManifestResourceMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#16
0
		public ExportedTypeMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#17
0
		public AssemblyRefOSMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#18
0
		public AssemblyProcessorMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#19
0
		public ImportScopeMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#20
0
		public FieldLayoutMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#21
0
		public StandAloneSigMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#22
0
		public GenericParamConstraintMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#23
0
		public PropertyMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#24
0
		protected MetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM.Owner) {
			this.mdVM = mdVM;
			this.mdToken = mdToken;
			this.hexFields = new HexField[mdVM.TableInfo.Columns.Count];
			for (int i = 0; i < this.hexFields.Length; i++)
				this.hexFields[i] = CreateField(mdVM.TableInfo.Columns[i]);
		}
示例#25
0
		public ModuleRefMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#26
0
		public LocalConstantMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#27
0
		public ImplMapMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#28
0
		public CustomAttributeMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#29
0
		public ParamPtrMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#30
0
		public CustomDebugInformationMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#31
0
		public InterfaceImplMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}
示例#32
0
		public LocalVariableMetaDataTableRecordVM(MetaDataTableVM mdVM, MDToken mdToken)
			: base(mdVM, mdToken) {
		}