<PackageReference Include="Microsoft.Packaging.Tools" Version="1.0.0-preview2-25401-01" />

System.Reflection.Metadata.Ecma335.MetadataBuilder

sealed class MetadataBuilder
namespace System.Reflection.Metadata.Ecma335 { internal sealed class MetadataBuilder { public void SetCapacity(TableIndex table, int rowCount); public ModuleDefinitionHandle AddModule(int generation, StringHandle moduleName, GuidHandle mvid, GuidHandle encId, GuidHandle encBaseId); public AssemblyDefinitionHandle AddAssembly(StringHandle name, Version version, StringHandle culture, BlobHandle publicKey, AssemblyFlags flags, AssemblyHashAlgorithm hashAlgorithm); public AssemblyReferenceHandle AddAssemblyReference(StringHandle name, Version version, StringHandle culture, BlobHandle publicKeyOrToken, AssemblyFlags flags, BlobHandle hashValue); public TypeDefinitionHandle AddTypeDefinition(TypeAttributes attributes, StringHandle namespace, StringHandle name, EntityHandle baseType, FieldDefinitionHandle fieldList, MethodDefinitionHandle methodList); public void AddTypeLayout(TypeDefinitionHandle type, ushort packingSize, uint size); public InterfaceImplementationHandle AddInterfaceImplementation(TypeDefinitionHandle type, EntityHandle implementedInterface); public void AddNestedType(TypeDefinitionHandle type, TypeDefinitionHandle enclosingType); public TypeReferenceHandle AddTypeReference(EntityHandle resolutionScope, StringHandle namespace, StringHandle name); public TypeSpecificationHandle AddTypeSpecification(BlobHandle signature); public StandaloneSignatureHandle AddStandaloneSignature(BlobHandle signature); public PropertyDefinitionHandle AddProperty(PropertyAttributes attributes, StringHandle name, BlobHandle signature); public void AddPropertyMap(TypeDefinitionHandle declaringType, PropertyDefinitionHandle propertyList); public EventDefinitionHandle AddEvent(EventAttributes attributes, StringHandle name, EntityHandle type); public void AddEventMap(TypeDefinitionHandle declaringType, EventDefinitionHandle eventList); public ConstantHandle AddConstant(EntityHandle parent, object value); public void AddMethodSemantics(EntityHandle association, MethodSemanticsAttributes semantics, MethodDefinitionHandle methodDefinition); public CustomAttributeHandle AddCustomAttribute(EntityHandle parent, EntityHandle constructor, BlobHandle value); public MethodSpecificationHandle AddMethodSpecification(EntityHandle method, BlobHandle instantiation); public ModuleReferenceHandle AddModuleReference(StringHandle moduleName); public ParameterHandle AddParameter(ParameterAttributes attributes, StringHandle name, int sequenceNumber); public GenericParameterHandle AddGenericParameter(EntityHandle parent, GenericParameterAttributes attributes, StringHandle name, int index); public GenericParameterConstraintHandle AddGenericParameterConstraint(GenericParameterHandle genericParameter, EntityHandle constraint); public FieldDefinitionHandle AddFieldDefinition(FieldAttributes attributes, StringHandle name, BlobHandle signature); public void AddFieldLayout(FieldDefinitionHandle field, int offset); public void AddMarshallingDescriptor(EntityHandle parent, BlobHandle descriptor); public void AddFieldRelativeVirtualAddress(FieldDefinitionHandle field, int relativeVirtualAddress); public MethodDefinitionHandle AddMethodDefinition(MethodAttributes attributes, MethodImplAttributes implAttributes, StringHandle name, BlobHandle signature, int bodyOffset, ParameterHandle paramList); public void AddMethodImport(MethodDefinitionHandle method, MethodImportAttributes attributes, StringHandle name, ModuleReferenceHandle module); public MethodImplementationHandle AddMethodImplementation(TypeDefinitionHandle type, EntityHandle methodBody, EntityHandle methodDeclaration); public MemberReferenceHandle AddMemberReference(EntityHandle parent, StringHandle name, BlobHandle signature); public ManifestResourceHandle AddManifestResource(ManifestResourceAttributes attributes, StringHandle name, EntityHandle implementation, uint offset); public AssemblyFileHandle AddAssemblyFile(StringHandle name, BlobHandle hashValue, bool containsMetadata); public ExportedTypeHandle AddExportedType(TypeAttributes attributes, StringHandle namespace, StringHandle name, EntityHandle implementation, int typeDefinitionId); public uint GetExportedTypeFlags(int rowId); public DeclarativeSecurityAttributeHandle AddDeclarativeSecurityAttribute(EntityHandle parent, DeclarativeSecurityAction action, BlobHandle permissionSet); public void AddEncLogEntry(EntityHandle entity, EditAndContinueOperation code); public void AddEncMapEntry(EntityHandle entity); public DocumentHandle AddDocument(BlobHandle name, GuidHandle hashAlgorithm, BlobHandle hash, GuidHandle language); public MethodDebugInformationHandle AddMethodDebugInformation(DocumentHandle document, BlobHandle sequencePoints); public LocalScopeHandle AddLocalScope(MethodDefinitionHandle method, ImportScopeHandle importScope, LocalVariableHandle variableList, LocalConstantHandle constantList, int startOffset, int length); public LocalVariableHandle AddLocalVariable(LocalVariableAttributes attributes, int index, StringHandle name); public LocalConstantHandle AddLocalConstant(StringHandle name, BlobHandle signature); public ImportScopeHandle AddImportScope(ImportScopeHandle parentScope, BlobHandle imports); public void AddStateMachineMethod(MethodDefinitionHandle moveNextMethod, MethodDefinitionHandle kickoffMethod); public CustomDebugInformationHandle AddCustomDebugInformation(EntityHandle parent, GuidHandle kind, BlobHandle value); public ImmutableArray<int> GetRowCounts(); public MetadataBuilder(int userStringHeapStartOffset = 0, int stringHeapStartOffset = 0, int blobHeapStartOffset = 0, int guidHeapStartOffset = 0); public void SetCapacity(HeapIndex heap, int byteCount); public BlobHandle GetOrAddBlob(BlobBuilder value); public BlobHandle GetOrAddBlob(byte[] value); public BlobHandle GetOrAddBlob(ImmutableArray<byte> value); public BlobHandle GetOrAddConstantBlob(object value); public BlobHandle GetOrAddBlobUTF16(string value); public BlobHandle GetOrAddBlobUTF8(string value, bool allowUnpairedSurrogates = true); public GuidHandle GetOrAddGuid(Guid guid); public GuidHandle ReserveGuid(out Blob content); public StringHandle GetOrAddString(string value); public UserStringHandle ReserveUserString(int length, out Blob reservedUserString); public UserStringHandle GetOrAddUserString(string value); public ImmutableArray<int> GetHeapSizes(); } }