/// <summary> /// 加载即时通讯信息; /// </summary> /// <param name="advCFile"></param> /// <param name="infoKind"></param> public static void LoadInstanceChat(AndroidDeviceCaseEvidence advCFile, string pinKind) { //保存内容到案件; var fiUnit = ServiceProvider.Current.GetInstance <ICommonForensicService>().GetForensicInfoUnit(advCFile); if (fiUnit == null) { return; } var afcUnit = fiUnit.Children. FirstOrDefault(p => p is PinTreeUnit fcUnit && fcUnit.ContentId == PinKindsDefinitions.ForensicClassInstantTalk) as PinTreeUnit; if (afcUnit == null) { return; } PinTreeUnit chatUnit = null; if (afcUnit.Children.FirstOrDefault(p => p is PinTreeUnit oTreeUnit && oTreeUnit.ContentId == pinKind) is PinTreeUnit preChatUnit) { chatUnit = preChatUnit; }
/// <summary> /// 保存,显示; /// </summary> public override void Setup() { //进行保存,使用二进制序列化; try { var bf = new BinaryFormatter(); //记录二进制文件的位置; var binName = $"{PinKind}.bin"; } catch { } //保存内容到案件; var fiUnit = ServiceProvider.Current.GetInstance <ICommonForensicService>().GetForensicInfoUnit(CaseFile); if (fiUnit == null) { return; } var afcUnit = fiUnit.Children. FirstOrDefault(p => p is PinTreeUnit fcUnit && fcUnit.ContentId == PinKindsDefinitions.ForensicClassInstantTalk) as PinTreeUnit; if (afcUnit == null) { return; } PinTreeUnit chatUnit = null; if (afcUnit.Children.FirstOrDefault(p => p is PinTreeUnit oTreeUnit && oTreeUnit.ContentId == PinKind) is PinTreeUnit preChatUnit) { chatUnit = preChatUnit; }