public static void ProcessAudit(string[] auditJob) { string[] auditID = auditJob[0].Split(new string[] { ": " }, 2, StringSplitOptions.RemoveEmptyEntries); int auditTypeID = int.Parse(auditID[1]); if (auditTypeID == 1) { StartWindAuditor(auditJob[1]); } else if (auditTypeID == 2) { winaudits.FileFetch audit = winaudits.FileFetch.GetFileFetch(auditJob[1]); winaudits.InsertQueries.InsertFileFetch(audit); } else if (auditTypeID == 3) { winaudits.RegistryFetch audit = winaudits.RegistryFetch.GetFileFetch(auditJob[1]); winaudits.InsertQueries.InsertRegFetch(audit); } }
public static RegistryFetch GetFileFetch(string regAudit) { RegistryFetch oregAudit = JsonConvert.DeserializeObject <RegistryFetch>(regAudit); return(oregAudit); }