Exemplo n.º 1
0
        /// <summary>
        /// Writes the custom attribute table.
        /// </summary>
        /// <param name="metadataSource">The metadata source.</param>
        /// <param name="metadataWriter">The metadata writer.</param>
        private static void WriteCustomAttributeTable(IMetadataProvider metadataSource, MetadataBuilderStage metadataWriter)
        {
            CustomAttributeRow row;

            WriteTable(TokenTypes.CustomAttribute, metadataSource, token =>
            {
                metadataSource.Read(token, out row);

                metadataWriter.WriteHasCustomAttributeIndex(row.ParentTableIdx);
                metadataWriter.WriteCustomAttributeTypeIndex(row.TypeIdx);
                metadataWriter.Write(row.ValueBlobIdx);
            });
        }
Exemplo n.º 2
0
        /// <summary>
        /// Writes the custom attribute table.
        /// </summary>
        /// <param name="metadataSource">The metadata source.</param>
        /// <param name="metadataWriter">The metadata writer.</param>
        private static void WriteCustomAttributeTable(IMetadataProvider metadataSource, MetadataBuilderStage metadataWriter)
        {
            CustomAttributeRow row;

            WriteTable(TokenTypes.CustomAttribute, metadataSource, token =>
            {
                metadataSource.Read(token, out row);

                metadataWriter.WriteHasCustomAttributeIndex(row.ParentTableIdx);
                metadataWriter.WriteCustomAttributeTypeIndex(row.TypeIdx);
                metadataWriter.Write(row.ValueBlobIdx);
            });
        }