aboutsummaryrefslogtreecommitdiff
path: root/src/tests/archive.cpp
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2007-04-03 05:09:12 +0000
committerMike Buland <eichlan@xagasoft.com>2007-04-03 05:09:12 +0000
commitc884da672645231b5ec47706c886381dab1b391a (patch)
treef9c0a0c4fb9006c2c1aa10c8c65de2f6e42894de /src/tests/archive.cpp
parentda89e6d30e57bd6dbb10b4d36b093ce9bbf5c666 (diff)
downloadlibbu++-c884da672645231b5ec47706c886381dab1b391a.tar.gz
libbu++-c884da672645231b5ec47706c886381dab1b391a.tar.bz2
libbu++-c884da672645231b5ec47706c886381dab1b391a.tar.xz
libbu++-c884da672645231b5ec47706c886381dab1b391a.zip
The file stream is imported and works, as does our first test, and the new
tweaks to archive. The && operator is now a template function, and as such requires no special handling. It could be worth it to check this out for other types, yet dangerous, since it would let you archive anything, even a class, without writing the proper functions for it...we shall see what happens...
Diffstat (limited to 'src/tests/archive.cpp')
-rw-r--r--src/tests/archive.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/tests/archive.cpp b/src/tests/archive.cpp
index fb0d97c..5b7e285 100644
--- a/src/tests/archive.cpp
+++ b/src/tests/archive.cpp
@@ -1,7 +1,16 @@
1#include "archive.h" 1#include "archive.h"
2#include "sfile.h"
3
4using namespace Bu;
2 5
3int main() 6int main()
4{ 7{
5 //Archive 8 SFile f("test.dat", "wb");
9 Archive ar( f, Archive::save );
10
11 std::string s("Hello there");
12 ar << s;
13
14 return 0;
6} 15}
7 16