Refactor QS408M and PDSF File Handlers
- Updated Detail class to include JsonSourceGenerationOptions and JsonSerializable attributes for source generation. - Modified ProcessData class to utilize source generation context for Description deserialization. - Renamed RowSourceGenerationContext to QS408MRowSourceGenerationContext for clarity. - Updated Run class to use QS408MRunSourceGenerationContext for serialization. - Enhanced Description class with source generation attributes. - Refactored FileRead class to use source generation context for Description deserialization. - Added new methods in ProcessDataStandardFormat for JSON element array extraction. - Introduced new PDSF file handler classes: Body, Constant, FileRead, Footer, Header, Row, Run, and Site. - Implemented logic for parsing and handling PDSF data structures. - Added unit tests for PDSF processing to ensure functionality.
This commit is contained in:
@ -4,72 +4,73 @@ using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text.Json;
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace Adaptation.FileHandlers.QS408M;
|
||||
|
||||
public class Description : IDescription, Shared.Properties.IDescription
|
||||
{
|
||||
|
||||
public int Test { get; set; }
|
||||
public int Count { get; set; }
|
||||
public int Index { get; set; }
|
||||
[JsonPropertyName("EventId")] public int Test { get; set; }
|
||||
[JsonPropertyName("Count")] public int Count { get; set; }
|
||||
[JsonPropertyName("Index")] public int Index { get; set; }
|
||||
//
|
||||
public string EventName { get; set; }
|
||||
public string NullData { get; set; }
|
||||
public string JobID { get; set; }
|
||||
public string Sequence { get; set; }
|
||||
public string MesEntity { get; set; }
|
||||
[JsonPropertyName("MesEntity")] public string MesEntity { get; set; }
|
||||
public string ReportFullPath { get; set; }
|
||||
public string ProcessJobID { get; set; }
|
||||
public string MID { get; set; }
|
||||
//
|
||||
public string Date { get; set; }
|
||||
public string Employee { get; set; }
|
||||
[JsonPropertyName("DateTime")] public string Date { get; set; }
|
||||
[JsonPropertyName("Operator")] public string Employee { get; set; }
|
||||
public string Lot { get; set; }
|
||||
public string PSN { get; set; }
|
||||
public string Reactor { get; set; }
|
||||
public string Recipe { get; set; }
|
||||
[JsonPropertyName("PSN")] public string PSN { get; set; }
|
||||
[JsonPropertyName("Reactor")] public string Reactor { get; set; }
|
||||
[JsonPropertyName("Recipe")] public string Recipe { get; set; }
|
||||
//
|
||||
public string Cassette { get; set; }
|
||||
[JsonPropertyName("Cassette")] public string Cassette { get; set; }
|
||||
public string HeaderUniqueId { get; set; }
|
||||
public string Layer { get; set; }
|
||||
public string PassFail { get; set; }
|
||||
public string Position { get; set; }
|
||||
public string RDS { get; set; }
|
||||
public string Title { get; set; }
|
||||
[JsonPropertyName("Layer")] public string Layer { get; set; }
|
||||
[JsonPropertyName("PassFail")] public string PassFail { get; set; }
|
||||
[JsonPropertyName("Position")] public string Position { get; set; }
|
||||
[JsonPropertyName("RDS")] public string RDS { get; set; }
|
||||
[JsonPropertyName("Title")] public string Title { get; set; }
|
||||
public string UniqueId { get; set; }
|
||||
public string Wafer { get; set; }
|
||||
public string Zone { get; set; }
|
||||
[JsonPropertyName("Wafer")] public string Wafer { get; set; }
|
||||
[JsonPropertyName("Zone")] public string Zone { get; set; }
|
||||
//
|
||||
public string MeanThickness { get; set; }
|
||||
public string RVThickness { get; set; }
|
||||
public string StdDev { get; set; }
|
||||
public string Thickness { get; set; }
|
||||
[JsonPropertyName("WaferMeanThickness")] public string MeanThickness { get; set; }
|
||||
[JsonPropertyName("RadialVariationThickness")] public string RVThickness { get; set; }
|
||||
[JsonPropertyName("StdDev")] public string StdDev { get; set; }
|
||||
[JsonPropertyName("Thickness")] public string Thickness { get; set; }
|
||||
//
|
||||
public string Slot { get; set; }
|
||||
public string ThicknessFourteen3mmEdgeMean { get; set; }
|
||||
public string ThicknessFourteen3mmEdgePercent { get; set; }
|
||||
public string ThicknessFourteen5mmEdgeMean { get; set; }
|
||||
public string ThicknessFourteen5mmEdgePercent { get; set; }
|
||||
public string ThicknessFourteenCenterMean { get; set; }
|
||||
public string ThicknessFourteenCriticalPointsAverage { get; set; }
|
||||
public string ThicknessFourteenCriticalPointsStdDev { get; set; }
|
||||
public string ThicknessFourteenMeanFrom { get; set; }
|
||||
[JsonPropertyName("Slot")] public string Slot { get; set; }
|
||||
[JsonPropertyName("Thickness 14 3mm Edge Mean")] public string ThicknessFourteen3mmEdgeMean { get; set; }
|
||||
[JsonPropertyName("Thickness 14 3mm Edge % from R/2")] public string ThicknessFourteen3mmEdgePercent { get; set; }
|
||||
[JsonPropertyName("Thickness 14 5mm Edge Mean")] public string ThicknessFourteen5mmEdgeMean { get; set; }
|
||||
[JsonPropertyName("Thickness 14 5mm Edge % from R/2")] public string ThicknessFourteen5mmEdgePercent { get; set; }
|
||||
[JsonPropertyName("Thickness 14 Center Mean")] public string ThicknessFourteenCenterMean { get; set; }
|
||||
[JsonPropertyName("Thickness 14 Average")] public string ThicknessFourteenCriticalPointsAverage { get; set; }
|
||||
[JsonPropertyName("Thickness 14 Std Dev")] public string ThicknessFourteenCriticalPointsStdDev { get; set; }
|
||||
[JsonPropertyName("Thickness 14 R 2/Mean")] public string ThicknessFourteenMeanFrom { get; set; }
|
||||
//
|
||||
public string Thickness01 { get; set; }
|
||||
public string Thickness02 { get; set; }
|
||||
public string Thickness03 { get; set; }
|
||||
public string Thickness04 { get; set; }
|
||||
public string Thickness05 { get; set; }
|
||||
public string Thickness06 { get; set; }
|
||||
public string Thickness07 { get; set; }
|
||||
public string Thickness08 { get; set; }
|
||||
public string Thickness09 { get; set; }
|
||||
public string Thickness10 { get; set; }
|
||||
public string Thickness11 { get; set; }
|
||||
public string Thickness12 { get; set; }
|
||||
public string Thickness13 { get; set; }
|
||||
public string Thickness14 { get; set; }
|
||||
[JsonPropertyName("Thickness01")] public string Thickness01 { get; set; }
|
||||
[JsonPropertyName("Thickness02")] public string Thickness02 { get; set; }
|
||||
[JsonPropertyName("Thickness03")] public string Thickness03 { get; set; }
|
||||
[JsonPropertyName("Thickness04")] public string Thickness04 { get; set; }
|
||||
[JsonPropertyName("Thickness05")] public string Thickness05 { get; set; }
|
||||
[JsonPropertyName("Thickness06")] public string Thickness06 { get; set; }
|
||||
[JsonPropertyName("Thickness07")] public string Thickness07 { get; set; }
|
||||
[JsonPropertyName("Thickness08")] public string Thickness08 { get; set; }
|
||||
[JsonPropertyName("Thickness09")] public string Thickness09 { get; set; }
|
||||
[JsonPropertyName("Thickness10")] public string Thickness10 { get; set; }
|
||||
[JsonPropertyName("Thickness11")] public string Thickness11 { get; set; }
|
||||
[JsonPropertyName("Thickness12")] public string Thickness12 { get; set; }
|
||||
[JsonPropertyName("Thickness13")] public string Thickness13 { get; set; }
|
||||
[JsonPropertyName("Thickness14")] public string Thickness14 { get; set; }
|
||||
|
||||
string IDescription.GetEventDescription() => "File Has been read and parsed";
|
||||
|
||||
@ -351,4 +352,16 @@ public class Description : IDescription, Shared.Properties.IDescription
|
||||
|
||||
internal static string GetDateFormat() => "MM/dd/yyyy hh:mm:ss tt";
|
||||
|
||||
}
|
||||
|
||||
[JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)]
|
||||
[JsonSerializable(typeof(Description))]
|
||||
internal partial class DescriptionSourceGenerationContext : JsonSerializerContext
|
||||
{
|
||||
}
|
||||
|
||||
[JsonSourceGenerationOptions(WriteIndented = true, NumberHandling = JsonNumberHandling.AllowReadingFromString | JsonNumberHandling.WriteAsString)]
|
||||
[JsonSerializable(typeof(Description[]))]
|
||||
internal partial class DescriptionArraySourceGenerationContext : JsonSerializerContext
|
||||
{
|
||||
}
|
Reference in New Issue
Block a user