本文整理汇总了C#中ModuleDef.UpdateRowId方法的典型用法代码示例。如果您正苦于以下问题:C# ModuleDef.UpdateRowId方法的具体用法?C# ModuleDef.UpdateRowId怎么用?C# ModuleDef.UpdateRowId使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ModuleDef
的用法示例。
在下文中一共展示了ModuleDef.UpdateRowId方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AddToNewAssemblyDef
public static AssemblyDef AddToNewAssemblyDef(ModuleDef module, ModuleKind moduleKind, out Characteristics characteristics)
{
var asmDef = module.UpdateRowId(new AssemblyDefUser(GetAssemblyName(module)));
asmDef.Modules.Add(module);
WriteNewModuleKind(module, moduleKind, out characteristics);
return asmDef;
}
示例2: FindOrCreateTypeRef
public TypeDefOrRefSig FindOrCreateTypeRef(ModuleDef module, AssemblyRef asmRef, string ns, string name, bool isValueType)
{
var typeRef = module.UpdateRowId(new TypeRefUser(module, ns, name, asmRef));
if (isValueType)
return new ValueTypeSig(typeRef);
return new ClassSig(typeRef);
}
示例3: CopyTo
public TypeDef CopyTo(TypeDef type, ModuleDef ownerModule) {
type.Attributes = this.Attributes;
type.Namespace = this.Namespace ?? UTF8String.Empty;
type.Name = this.Name ?? UTF8String.Empty;
if (PackingSize != null || ClassSize != null)
type.ClassLayout = ownerModule.UpdateRowId(new ClassLayoutUser(PackingSize ?? 0, ClassSize ?? 0));
else
type.ClassLayout = null;
type.BaseType = this.BaseType;
type.CustomAttributes.Clear();
type.CustomAttributes.AddRange(CustomAttributes);
type.DeclSecurities.Clear();
type.DeclSecurities.AddRange(DeclSecurities);
type.GenericParameters.Clear();
type.GenericParameters.AddRange(GenericParameters);
type.Interfaces.Clear();
type.Interfaces.AddRange(Interfaces);
return type;
}
示例4: Create
public ParamDef Create(ModuleDef ownerModule)
{
return ownerModule.UpdateRowId(CopyTo(new ParamDefUser()));
}
示例5: CreateFieldDef
public FieldDef CreateFieldDef(ModuleDef ownerModule) {
return ownerModule.UpdateRowId(CopyTo(new FieldDefUser()));
}
示例6: CreateTypeDef
public TypeDef CreateTypeDef(ModuleDef ownerModule) {
return ownerModule.UpdateRowId(CopyTo(new TypeDefUser(UTF8String.Empty), ownerModule));
}
示例7: CreatePropertyDef
public PropertyDef CreatePropertyDef(ModuleDef ownerModule)
{
return ownerModule.UpdateRowId(CopyTo(new PropertyDefUser()));
}
示例8: CreateInterfaceImpl
public InterfaceImpl CreateInterfaceImpl(ModuleDef ownerModule)
{
return ownerModule.UpdateRowId(CopyTo(new InterfaceImplUser()));
}
示例9: CreateGenericParamConstraint
public GenericParamConstraint CreateGenericParamConstraint(ModuleDef ownerModule)
{
return ownerModule.UpdateRowId(CopyTo(new GenericParamConstraintUser()));
}
示例10: CreateAssemblyDef
public AssemblyDef CreateAssemblyDef(ModuleDef ownerModule) => ownerModule.UpdateRowId(CopyTo(new AssemblyDefUser()));
示例11: Create
public MethodSpec Create(ModuleDef ownerModule)
{
return ownerModule.UpdateRowId(CopyTo(new MethodSpecUser()));
}
示例12: CreateEventDef
public EventDef CreateEventDef(ModuleDef ownerModule) {
return ownerModule.UpdateRowId(CopyTo(new EventDefUser()));
}
示例13: Create
public DeclSecurity Create(ModuleDef module) {
return module.UpdateRowId(CopyTo(module, new DeclSecurityUser()));
}
示例14: CreateMethodDef
public MethodDef CreateMethodDef(ModuleDef ownerModule)
{
return ownerModule.UpdateRowId(CopyTo(new MethodDefUser()));
}
示例15: Create
public MemberRef Create(ModuleDef ownerModule) => ownerModule.UpdateRowId(CopyTo(new MemberRefUser(ownerModule)));