public static byte[] SerializeFeatureUsageReport(FeatureUsageReport report) { byte[] retArray = new byte[8]; using (MemoryStream ms = new MemoryStream(retArray, true)) { using (BinaryWriter bw = new BinaryWriter(ms)) { bw.Write(report.FeatureId); bw.Write(report.ReportingKind); bw.Write(report.ReportingOptions); } } return(retArray); }
public static int NotifyFeatureUsage(FeatureUsageReport report) { return(NativeMethods.RtlNotifyFeatureUsage(RtlDataHelpers.SerializeFeatureUsageReport(report))); }