public override void VisitFieldRVATable(FieldRVATable table)
        {
            int number = m_rows [FieldRVATable.RId];

            table.Rows = new RowCollection(number);
            for (int i = 0; i < number; i++)
            {
                table.Rows.Add(new FieldRVARow());
            }
        }
Beispiel #2
0
        public FieldRVATable GetFieldRVATable()
        {
            FieldRVATable table = m_heap [FieldRVATable.RId] as FieldRVATable;

            if (table != null)
            {
                return(table);
            }

            table = new FieldRVATable();
            InitializeTable(table);
            return(table);
        }
Beispiel #3
0
        public FieldRVATable GetFieldRVATable()
        {
            int rid = FieldRVATable.RId;

            if (m_heap.HasTable(rid))
            {
                return(m_heap [rid] as FieldRVATable);
            }

            FieldRVATable table = new FieldRVATable();

            table.Rows    = new RowCollection();
            m_heap.Valid |= 1L << rid;
            m_heap.Tables.Add(table);
            return(table);
        }
Beispiel #4
0
        public void FixupData(uint data_rva)
        {
            FieldRVATable table = this.GetTable <FieldRVATable>(Table.FieldRVA);

            if (table.length != 0)
            {
                int num      = this.GetTable <FieldTable>(Table.Field).IsLarge ? 4 : 2;
                int position = base.position;
                base.position = table.position;
                for (int i = 0; i < table.length; i++)
                {
                    uint num4 = base.ReadUInt32();
                    base.position -= 4;
                    base.WriteUInt32(num4 + data_rva);
                    base.position += num;
                }
                base.position = position;
            }
        }
        public void FixupData(uint data_rva)
        {
            FieldRVATable table = this.GetTable <FieldRVATable>(Table.FieldRVA);

            if (table.length == 0)
            {
                return;
            }
            int num  = (this.GetTable <FieldTable>(Table.Field).IsLarge ? 4 : 2);
            int num1 = this.position;

            this.position = table.position;
            for (int i = 0; i < table.length; i++)
            {
                uint num2 = base.ReadUInt32();
                this.position -= 4;
                base.WriteUInt32(num2 + data_rva);
                this.position += num;
            }
            this.position = num1;
        }
Beispiel #6
0
		public FieldRVATable GetFieldRVATable ()
		{
			FieldRVATable table = m_heap [FieldRVATable.RId] as FieldRVATable;
			if (table != null)
				return table;

			table = new FieldRVATable ();
			InitializeTable (table);
			return table;
		}
 public override void VisitFieldRVATable(FieldRVATable table)
 {
     int number = m_rows [FieldRVATable.RId];
     table.Rows = new RowCollection (number);
     for (int i = 0; i < number; i++)
         table.Rows.Add (new FieldRVARow ());
 }
        public FieldRVATable GetFieldRVATable()
        {
            int rid = FieldRVATable.RId;
            if (m_heap.HasTable (rid))
                return m_heap [rid] as FieldRVATable;

            FieldRVATable table = new FieldRVATable ();
            table.Rows = new RowCollection ();
            m_heap.Valid |= 1L << rid;
            m_heap.Tables.Add (table);
            return table;
        }
Beispiel #9
0
		void EncodeFieldRVATable (FieldRVATable table)
		{
			int index = 0;

			foreach (FieldRVARow row in table.Rows) {
				this.asm.ALIGN (Assembly.OBJECT_ALIGNMENT);
				this.asm.LABEL (moduleName + " FieldRVARow#" + index);
				this.asm.AddObjectFields (typeof (SharpOS.AOT.Metadata.FieldRVARow).ToString ());
				this.asm.DATA (row.RVA.Value);
				this.asm.DATA (row.Field);
				++index;
			}

			this.MetadataArray ("FieldRVA", table);
		}