File indexing completed on 2025-01-05 05:23:31
0001 /* 0002 This file is part of the Okteta Kasten module, made within the KDE community. 0003 0004 SPDX-FileCopyrightText: 2009 Friedrich W. H. Kossebau <kossebau@kde.org> 0005 0006 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL 0007 */ 0008 0009 #include "bytearraychecksumparameterseteditfactory.hpp" 0010 0011 // lib 0012 #include "algorithm/crc64bytearraychecksumparametersetedit.hpp" 0013 #include "algorithm/modsumbytearraychecksumparametersetedit.hpp" 0014 #include "algorithm/nobytearraychecksumparametersetedit.hpp" 0015 //// NEWCHECKSUMPARAMETERSET(start) 0016 //// Here add the name of your header file of your edit widget for the parameterset, 0017 //// e.g. 0018 //// #include "algorithm/mybytearraychecksumparametersetedit.hpp" 0019 //// NEWCHECKSUMPARAMETERSET(end) 0020 0021 AbstractByteArrayChecksumParameterSetEdit* ByteArrayChecksumParameterSetEditFactory::createEdit(const char* id) 0022 { 0023 AbstractByteArrayChecksumParameterSetEdit* result; 0024 0025 if (qstrcmp(id, ModSumByteArrayChecksumParameterSetEdit::Id) == 0) { 0026 result = new ModSumByteArrayChecksumParameterSetEdit(); 0027 } else if (qstrcmp(id, Crc64ByteArrayChecksumParameterSetEdit::Id) == 0) { 0028 result = new Crc64ByteArrayChecksumParameterSetEdit(); 0029 } 0030 //// NEWCHECKSUMPARAMETERSET(start) 0031 //// Here add the check for the id of your parameter set 0032 //// and, if it matches, the creation of the widget 0033 //// e.g. 0034 //// else if (qstrcmp(id, MyByteArrayChecksumParameterSetEdit::Id) == 0) 0035 //// result = new MyByteArrayChecksumParameterSetEdit(); 0036 //// NEWCHECKSUMPARAMETERSET(end) 0037 else { // if (qstrcmp(id, NoByteArrayChecksumParameterSetEdit::Id) == 0) TODO: default should be a message "Not found" 0038 result = new NoByteArrayChecksumParameterSetEdit(); 0039 } 0040 0041 return result; 0042 }