update: pushing the start ex04 of the module 01

This commit is contained in:
raphael 2024-11-06 14:09:29 +01:00
parent 2b197d8d05
commit 08a23cc42b
6 changed files with 291 additions and 0 deletions

37
cpp01/ex04/sed.hpp Normal file
View file

@ -0,0 +1,37 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* sed.hpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: rparodi <rparodi@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/11/05 15:27:45 by rparodi #+# #+# */
/* Updated: 2024/11/05 21:58:59 by rparodi ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef SED_HPP
#define SED_HPP
#include <iostream>
#include <streambuf>
#include <string>
#include <fstream>
#include "err_msg.hpp"
class Sed
{
public:
Sed(char **argv, std::ifstream *input);
~Sed();
bool line(std::ofstream output);
const char *getFilename();
private:
std::string _filename;
std::string _to_replace;
std::string _by_word;
std::ifstream *_input;
};
#endif