Inheritance: IDisposable, ICacheProvider
Exemple #1
0
 public PInvokeImplementation(MetaDataMember member, PInvokeImplAttributes attributes, ModuleReference moduleRef, string entrypoint)
     : base(new MetaDataRow((uint)attributes, (uint) 0, (uint) 0, moduleRef.TableIndex))
 {
     this._member      = member;
     this._importScope = moduleRef;
     this._entrypoint  = entrypoint;
 }
 public PInvokeImplementation(MetaDataMember member, PInvokeImplAttributes attributes, ModuleReference moduleRef, string entrypoint)
     : base(new MetaDataRow((uint)attributes, (uint)0, (uint)0, moduleRef.TableIndex))
 {
     this._member = member;
     this._importScope = moduleRef;
     this._entrypoint = entrypoint;
 }
 public MethodImplementation(TypeDefinition @class, MethodReference methodDeclaration, MethodReference newMethod)
     : base(new MetaDataRow(@class.TableIndex, 0U, newMethod.TableIndex))
 {
     this.@class            = @class;
     this.methodDeclaration = methodDeclaration;
     this.methodBody        = newMethod;
 }
 internal bool TryGetMember(int token, out MetaDataMember member)
 {
     try
     {
         member = GetMember(token);
         return true;
     }
     catch { member = null; return false; }
 }
Exemple #5
0
 public override void ClearCache()
 {
     if (_stream != null)
     {
         _stream.Dispose();
     }
     _stream         = null;
     _name           = null;
     _implementation = null;
 }
 public override void ClearCache()
 {
     if (stream != null)
     {
         stream.Dispose();
     }
     stream         = null;
     name           = null;
     implementation = null;
 }
Exemple #7
0
        private TreeNode CreateTreeNode(MetaDataMember member)
        {
            TreeNode node = new TreeNode();
            try
            {
                node.Text = index + (member is MemberReference ? " (" + (member as MemberReference).Name + ")" : "");
            }
            catch { node.Text = index.ToString(); }
            index++;

            node.Tag = member;
            return node;
        }
 public override void ClearCache()
 {
     parent = null;
 }
Exemple #9
0
 public override void LoadCache()
 {
     _method = Method;
     _association = Association;
 }
Exemple #10
0
 public MethodSemantics(MethodDefinition method, MetaDataMember association, MethodSemanticsAttributes attributes)
     : base(new MetaDataRow((uint)attributes, method.TableIndex, (uint)0))
 {
     this._method = method;
     this._association = association;
 }
Exemple #11
0
 public FieldMarshal(MetaDataMember parent, uint nativeType)
     : base(new MetaDataRow((uint)0, nativeType))
 {
     this._parent = parent;
 }
 public override void LoadCache()
 {
     _member = Member;
     _entrypoint = Entrypoint;
     _importScope = ImportScope;
 }
Exemple #13
0
 public override void LoadCache()
 {
     _member      = Member;
     _entrypoint  = Entrypoint;
     _importScope = ImportScope;
 }
 public override void ClearCache()
 {
     parent      = null;
     constructor = null;
     signature   = null;
 }
Exemple #15
0
 public override void LoadCache()
 {
     _stream         = Stream;
     _name           = Name;
     _implementation = Implementation;
 }
Exemple #16
0
 public override void ClearCache()
 {
     value  = null;
     parent = null;
 }
Exemple #17
0
 public Constant(MetaDataMember parent, ElementType type, uint signature)
     : base(new MetaDataRow((byte)type, 0U, signature))
 {
 }
Exemple #18
0
 public override void LoadCache()
 {
     _method      = Method;
     _association = Association;
 }
Exemple #19
0
 public override void ClearCache()
 {
     _method      = null;
     _association = null;
 }
Exemple #20
0
 public MethodSemantics(MethodDefinition method, MetaDataMember association, MethodSemanticsAttributes attributes)
     : base(new MetaDataRow((uint)attributes, method.TableIndex, (uint) 0))
 {
     this._method      = method;
     this._association = association;
 }
 public override void LoadCache()
 {
     _parent      = Parent;
     _constructor = Constructor;
     _signature   = Signature;
 }
 public override void ClearCache()
 {
     @class            = null;
     methodBody        = null;
     methodDeclaration = null;
 }
Exemple #23
0
 public Constant(MetaDataMember parent, ElementType type, uint signature)
     : base(new MetaDataRow((byte)type, 0U, signature))
 {
 }
Exemple #24
0
 public override void LoadCache()
 {
     _value  = Value;
     _parent = Parent;
 }
 public override void ClearCache()
 {
     parent = null;
 }
Exemple #26
0
 public override void LoadCache()
 {
     _implementation = Implementation;
 }
Exemple #27
0
 public override void LoadCache()
 {
     _stream = Stream;
     _name = Name;
     _implementation = Implementation;
 }
Exemple #28
0
 public override void LoadCache()
 {
     _parent = Parent;
 }
Exemple #29
0
 public override void ClearCache()
 {
     _implementation = null;
 }
Exemple #30
0
 public override void LoadCache()
 {
     _value = Value;
     _parent = Parent;
 }
Exemple #31
0
 private void tablesTree_AfterSelect(object sender, TreeViewEventArgs e)
 {
     dataGridView.Rows.Clear();
     if (tablesTree.SelectedNode.Tag != null)
     {
         currentMember = (MetaDataMember)tablesTree.SelectedNode.Tag;
         propertyGrid.SelectedObject = currentMember;
         SetMetaDataRow(currentMember.MetaDataRow);
     }
 }
Exemple #32
0
 public override void ClearCache()
 {
     if (_stream != null)
         _stream.Dispose();
     _stream = null;
     _name = null;
     _implementation = null;
 }
Exemple #33
0
 private TreeNode CreateTreeNode(MetaDataMember member)
 {
     TreeNode node = new TreeNode();
     uint index = (member.MetaDataToken | ((uint)0xFF << 24)) - ((uint)0xFF << 24);
     try
     {
         node.Text = string.Format("{0} ({1})", index, (member is MemberReference ? (member as MemberReference).Name : member.ToString()));
     }
     catch { node.Text = index.ToString(); }
     index++;
     node.Tag = member;
     return node;
 }
Exemple #34
0
 public ManifestResource(string name, ManifestResourceAttributes attributes, MetaDataMember implementation, uint offset)
     : base(new MetaDataRow(offset, (uint)attributes, 0U, 0U))
 {
     this._name = name;
     this._implementation = implementation;
 }
Exemple #35
0
        private void tablesTree_AfterSelect(object sender, TreeViewEventArgs e)
        {
            dataGridView.Rows.Clear();
            if (e.Node.Tag is MetaDataTable)
            {
                MetaDataTable table = e.Node.Tag as MetaDataTable;
                if (e.Node.Nodes.Count == 1 && e.Node.Nodes[0].Text == "Loading...")
                {
                    e.Node.Nodes.Clear();
                    TreeNode[] subNodes = new TreeNode[table.Members.Count];
                    for (int i = 0; i < subNodes.Length; i++)
                        subNodes[i] = CreateTreeNode(table.Members[i]);

                    tablesTree.BeginUpdate();
                    e.Node.Nodes.AddRange(subNodes);
                    tablesTree.EndUpdate();
                }
            }
            else if (e.Node.Tag is MetaDataMember)
            {
                currentMember = (MetaDataMember)e.Node.Tag;
                propertyGrid.SelectedObject = currentMember;
                SetMetaDataRow(currentMember.MetaDataRow);
            }
        }
Exemple #36
0
 public override void LoadCache()
 {
     _implementation = Implementation;
 }
 public override void ClearCache()
 {
     member = null;
     entrypoint = null;
     importScope = null;
 }
Exemple #38
0
 public override void ClearCache()
 {
     _method = null;
     _association = null;
 }
Exemple #39
0
 public FieldMarshal(MetaDataMember parent, uint nativeType)
     : base(new MetaDataRow((uint) 0, nativeType))
 {
     this.parent = parent;
 }
 public SecurityDeclaration(SecurityAction Action, MetaDataMember parent, uint permissionSet)
     : base(new MetaDataRow((ushort)Action, 0U, permissionSet))
 {
 }
Exemple #41
0
 public CustomAttribute(MetaDataMember parent, MethodReference constructor, uint value)
     : base(new MetaDataRow(0U,0U, value))
 {
     this._parent = parent;
     this._constructor = constructor;
 }
 public ManifestResource(string name, ManifestResourceAttributes attributes, MetaDataMember implementation, uint offset)
     : base(new MetaDataRow(offset, (uint)attributes, 0U, 0U))
 {
     this.name           = name;
     this.implementation = implementation;
 }
Exemple #43
0
 public override void ClearCache()
 {
     _parent = null;
     _constructor = null;
     _signature = null;
 }
Exemple #44
0
 public override void LoadCache()
 {
     _parent = Parent;
     _constructor = Constructor;
     _signature = Signature;
 }
Exemple #45
0
 public SecurityDeclaration(SecurityAction Action, MetaDataMember parent, uint permissionSet)
     : base(new MetaDataRow((ushort)Action, 0U, permissionSet))
 {
 }
 public CustomAttribute(MetaDataMember parent, MethodReference constructor, uint value)
     : base(new MetaDataRow(0U, 0U, value))
 {
     this.parent      = parent;
     this.constructor = constructor;
 }
Exemple #47
0
 public override void LoadCache()
 {
     _parent = Parent;
 }
Exemple #48
0
 public override void ClearCache()
 {
     value = null;
     parent = null;
 }
Exemple #49
0
 private ValueType GetMemberIndex(Workspace workspace, MetaDataMember member)
 {
     if (member.Table.IsLarge(0))
         return member.TableIndex;
     return (ushort)member.TableIndex;
 }
Exemple #50
0
 public override void ClearCache()
 {
     _member      = null;
     _entrypoint  = null;
     _importScope = null;
 }
Exemple #51
0
 private ValueType GetMemberIndex(Workspace workspace, MetaDataTableGroup group, MetaDataMember member)
 {
     if (group.IsLarge)
         return group.GetCodedIndex(member);
     return (ushort)group.GetCodedIndex(member);
 }
Exemple #52
0
 public override void ClearCache()
 {
     _implementation = null;
 }
Exemple #53
0
 public override void ClearCache()
 {
     resolutionScope = null;
     name = null;
     @namespace = null;
 }
 public override void ClearCache()
 {
     if (stream != null)
         stream.Dispose();
     stream = null;
     name = null;
     implementation = null;
 }
Exemple #55
0
 public GenericParameter(string name, ushort index, GenericParameterAttributes attributes, MetaDataMember owner)
     : base(new MetaDataRow(index, (ushort)attributes, 0U, 0U))
 {
     this.name  = name;
     this.owner = owner;
 }