10ec8b83dSEd Tanous #pragma once 20ec8b83dSEd Tanous #include <nlohmann/json.hpp> 30ec8b83dSEd Tanous 40ec8b83dSEd Tanous namespace update_service 50ec8b83dSEd Tanous { 60ec8b83dSEd Tanous // clang-format off 70ec8b83dSEd Tanous 80ec8b83dSEd Tanous enum class TransferProtocolType{ 90ec8b83dSEd Tanous Invalid, 100ec8b83dSEd Tanous CIFS, 110ec8b83dSEd Tanous FTP, 120ec8b83dSEd Tanous SFTP, 130ec8b83dSEd Tanous HTTP, 140ec8b83dSEd Tanous HTTPS, 150ec8b83dSEd Tanous NSF, 160ec8b83dSEd Tanous SCP, 170ec8b83dSEd Tanous TFTP, 180ec8b83dSEd Tanous OEM, 190ec8b83dSEd Tanous NFS, 200ec8b83dSEd Tanous }; 210ec8b83dSEd Tanous 220ec8b83dSEd Tanous enum class ApplyTime{ 230ec8b83dSEd Tanous Invalid, 240ec8b83dSEd Tanous Immediate, 250ec8b83dSEd Tanous OnReset, 260ec8b83dSEd Tanous AtMaintenanceWindowStart, 270ec8b83dSEd Tanous InMaintenanceWindowOnReset, 280ec8b83dSEd Tanous OnStartUpdateRequest, 290ec8b83dSEd Tanous }; 300ec8b83dSEd Tanous 31*2ae81db9SGunnar Mills enum class SupportedUpdateImageFormatType{ 32*2ae81db9SGunnar Mills Invalid, 33*2ae81db9SGunnar Mills PLDMv1_0, 34*2ae81db9SGunnar Mills PLDMv1_1, 35*2ae81db9SGunnar Mills PLDMv1_2, 36*2ae81db9SGunnar Mills PLDMv1_3, 37*2ae81db9SGunnar Mills UEFICapsule, 38*2ae81db9SGunnar Mills VendorDefined, 39*2ae81db9SGunnar Mills }; 40*2ae81db9SGunnar Mills 410ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(TransferProtocolType, { 420ec8b83dSEd Tanous {TransferProtocolType::Invalid, "Invalid"}, 430ec8b83dSEd Tanous {TransferProtocolType::CIFS, "CIFS"}, 440ec8b83dSEd Tanous {TransferProtocolType::FTP, "FTP"}, 450ec8b83dSEd Tanous {TransferProtocolType::SFTP, "SFTP"}, 460ec8b83dSEd Tanous {TransferProtocolType::HTTP, "HTTP"}, 470ec8b83dSEd Tanous {TransferProtocolType::HTTPS, "HTTPS"}, 480ec8b83dSEd Tanous {TransferProtocolType::NSF, "NSF"}, 490ec8b83dSEd Tanous {TransferProtocolType::SCP, "SCP"}, 500ec8b83dSEd Tanous {TransferProtocolType::TFTP, "TFTP"}, 510ec8b83dSEd Tanous {TransferProtocolType::OEM, "OEM"}, 520ec8b83dSEd Tanous {TransferProtocolType::NFS, "NFS"}, 530ec8b83dSEd Tanous }); 540ec8b83dSEd Tanous 550ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(ApplyTime, { 560ec8b83dSEd Tanous {ApplyTime::Invalid, "Invalid"}, 570ec8b83dSEd Tanous {ApplyTime::Immediate, "Immediate"}, 580ec8b83dSEd Tanous {ApplyTime::OnReset, "OnReset"}, 590ec8b83dSEd Tanous {ApplyTime::AtMaintenanceWindowStart, "AtMaintenanceWindowStart"}, 600ec8b83dSEd Tanous {ApplyTime::InMaintenanceWindowOnReset, "InMaintenanceWindowOnReset"}, 610ec8b83dSEd Tanous {ApplyTime::OnStartUpdateRequest, "OnStartUpdateRequest"}, 620ec8b83dSEd Tanous }); 630ec8b83dSEd Tanous 64*2ae81db9SGunnar Mills NLOHMANN_JSON_SERIALIZE_ENUM(SupportedUpdateImageFormatType, { 65*2ae81db9SGunnar Mills {SupportedUpdateImageFormatType::Invalid, "Invalid"}, 66*2ae81db9SGunnar Mills {SupportedUpdateImageFormatType::PLDMv1_0, "PLDMv1_0"}, 67*2ae81db9SGunnar Mills {SupportedUpdateImageFormatType::PLDMv1_1, "PLDMv1_1"}, 68*2ae81db9SGunnar Mills {SupportedUpdateImageFormatType::PLDMv1_2, "PLDMv1_2"}, 69*2ae81db9SGunnar Mills {SupportedUpdateImageFormatType::PLDMv1_3, "PLDMv1_3"}, 70*2ae81db9SGunnar Mills {SupportedUpdateImageFormatType::UEFICapsule, "UEFICapsule"}, 71*2ae81db9SGunnar Mills {SupportedUpdateImageFormatType::VendorDefined, "VendorDefined"}, 72*2ae81db9SGunnar Mills }); 73*2ae81db9SGunnar Mills 740ec8b83dSEd Tanous } 750ec8b83dSEd Tanous // clang-format on 76