Newer
Older
/*
**************************************************************************
* Copyright (C) 2023 INAF
*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License
* or (at your option) any later version. This program is distributed
* in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even
* the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU Lesser General Public License for more details.
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
* Authors:
*
* <>Valerio Pastore INAF-OAS Bologna valerio.pastore@inaf.it
****************************************************************************
*/
/**
* @brief The BaseArchiver class is an abstract base class for archivers.
*
* This class provides a common interface for archiving packets. Derived classes
* must implement the pure virtual functions defined in this class.
*/
/**
* @brief Write a packet to the archiver.
*
* This function writes the given packet to the "archive".
*
* @param packet The packet to write.
* @return An integer indicating the success or failure of the write operation.
*/
/**
* @brief Write a packet to the archiver with a specified destination.
*
* This function writes the given packet to the archiver with the specified destination.
*
* @param packet The packet to write.
* @param destination The destination where the packet should be written.
* @return An integer indicating the success or failure of the write operation.
*/
virtual int write(Packets::BasePacket&, std::string destination) = 0;
/**
* @brief Open the archiver.
*
* This function opens the archiver.
*
* @return An integer indicating the success or failure of the open operation.
*/
/**
* @brief Close the archiver.
*
* This function closes the archiver.
*
* @return An integer indicating the success or failure of the close operation.
*/
/**
* @brief Check if the archiver is open.
*
* This function checks if the archiver is open.
*
* @return A boolean value indicating whether the archiver is open or not.
*/
/**
* @brief Set the destination of the archiver.
*
* This function sets the destination of the archiver.
*
* @param dest The destination to set.
*/
/**
* @brief Get the destination of the archiver.
*
* This function gets the destination of the archiver.
*
* @return The destination of the archiver.
*/
/**
* @brief Destructor for the BaseArchiver class.
*/