aboutsummaryrefslogtreecommitdiff
path: root/libbutl/base64.mxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2021-09-28 19:24:31 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2021-09-28 20:29:59 +0300
commitdf1ef68cd8e8582724ce1192bfc202e0b9aeaf0c (patch)
treeb731ca4c68e60c00c7e7d499dbf4868ee7b71f44 /libbutl/base64.mxx
parent7a4fc37f264cdb67f2f83fa92703c869215bbc86 (diff)
Get rid of C++ modules related code and rename *.mxx files to *.hxx
Diffstat (limited to 'libbutl/base64.mxx')
-rw-r--r--libbutl/base64.mxx62
1 files changed, 0 insertions, 62 deletions
diff --git a/libbutl/base64.mxx b/libbutl/base64.mxx
deleted file mode 100644
index 698b7e2..0000000
--- a/libbutl/base64.mxx
+++ /dev/null
@@ -1,62 +0,0 @@
-// file : libbutl/base64.mxx -*- C++ -*-
-// license : MIT; see accompanying LICENSE file
-
-#ifndef __cpp_modules_ts
-#pragma once
-#endif
-
-// C includes.
-
-#ifndef __cpp_lib_modules_ts
-#include <iosfwd>
-#include <string>
-#include <vector>
-#endif
-
-// Other includes.
-
-#ifdef __cpp_modules_ts
-export module butl.base64;
-#ifdef __cpp_lib_modules_ts
-import std.core;
-import std.io;
-#endif
-#endif
-
-#include <libbutl/export.hxx>
-
-LIBBUTL_MODEXPORT namespace butl
-{
- // Base64-encode a stream or a buffer. Split the output into 76 char-long
- // lines (new line is the 77th). If reading from a stream, check if it has
- // badbit, failbit, or eofbit set and throw invalid_argument if that's the
- // case. Otherwise, set eofbit on completion. If writing to a stream, check
- // if it has badbit, failbit, or eofbit set and throw invalid_argument if
- // that's the case. Otherwise set badbit if the write operation fails.
- //
- LIBBUTL_SYMEXPORT void
- base64_encode (std::ostream&, std::istream&);
-
- LIBBUTL_SYMEXPORT std::string
- base64_encode (std::istream&);
-
- LIBBUTL_SYMEXPORT std::string
- base64_encode (const std::vector<char>&);
-
- // Base64-decode a stream or a string. Throw invalid_argument if the input
- // is not a valid base64 representation. If reading from a stream, check if
- // it has badbit, failbit, or eofbit set and throw invalid_argument if
- // that's the case. Otherwise, set eofbit on completion. If writing to a
- // stream, check if it has badbit, failbit, or eofbit set and throw
- // invalid_argument if that's the case. Otherwise set badbit if the write
- // operation fails.
- //
- LIBBUTL_SYMEXPORT void
- base64_decode (std::ostream&, std::istream&);
-
- LIBBUTL_SYMEXPORT void
- base64_decode (std::ostream&, const std::string&);
-
- LIBBUTL_SYMEXPORT std::vector<char>
- base64_decode (const std::string&);
-}