private void WriteEvent() { AddHeader( "Name", "Add", "Remove", "Fire", "Attributes" ); foreach (var handle in reader.EventDefinitions) { var entry = reader.GetEvent(handle); var accessors = entry.GetAssociatedMethods(); AddRow( Literal(entry.Name), Token(accessors.AddOn), Token(accessors.RemoveOn), Token(accessors.Fire), EnumValue <int>(entry.Attributes) ); } WriteRows("Event (0x12, 0x14, 0x18):"); }
public static StringHandle[] GetEventDefNames(this MetadataReader reader) { var builder = ArrayBuilder <StringHandle> .GetInstance(); foreach (var handle in reader.EventDefinitions) { var def = reader.GetEvent(handle); builder.Add(def.Name); } return(builder.ToArrayAndFree()); }
public static StringHandle[] GetEventDefNames(this MetadataReader reader) { return(reader.EventDefinitions.Select(handle => reader.GetEvent(handle).Name).ToArray()); }