summaryrefslogtreecommitdiff
path: root/libs/IO
diff options
context:
space:
mode:
Diffstat (limited to 'libs/IO')
-rw-r--r--libs/IO/File.cc181
-rw-r--r--libs/IO/File.h67
-rw-r--r--libs/IO/FileRepresentation.cc132
-rw-r--r--libs/IO/FileRepresentation.h56
-rw-r--r--libs/IO/FileSystem.cc132
-rw-r--r--libs/IO/FileSystem.h50
-rw-r--r--libs/IO/IO.cbp70
-rw-r--r--libs/IO/IO.cbp.save68
-rw-r--r--libs/IO/IO.depend1
-rw-r--r--libs/IO/IO.layout34
-rw-r--r--libs/IO/IO.layout.save34
-rw-r--r--libs/IO/Makefile128
-rw-r--r--libs/IO/nbproject/Makefile-Debug.mk120
-rw-r--r--libs/IO/nbproject/Makefile-Release.mk116
-rw-r--r--libs/IO/nbproject/Makefile-impl.mk133
-rw-r--r--libs/IO/nbproject/Makefile-variables.mk35
-rw-r--r--libs/IO/nbproject/Package-Debug.bash75
-rw-r--r--libs/IO/nbproject/Package-Release.bash75
-rw-r--r--libs/IO/nbproject/configurations.xml116
-rw-r--r--libs/IO/nbproject/private/Makefile-variables.mk7
-rw-r--r--libs/IO/nbproject/private/configurations.xml72
-rw-r--r--libs/IO/nbproject/private/private.xml8
-rw-r--r--libs/IO/nbproject/project.xml28
-rw-r--r--libs/IO/summary.txt1
24 files changed, 1739 insertions, 0 deletions
diff --git a/libs/IO/File.cc b/libs/IO/File.cc
new file mode 100644
index 0000000..477c5c8
--- /dev/null
+++ b/libs/IO/File.cc
@@ -0,0 +1,181 @@
+/**
+ * ======================== legal notice ======================
+ *
+ * File: File.cc
+ * Created: 21. Juli 2012, 12
+ * Author: <a href="mailto:geronimo013@gmx.de">Geronimo</a>
+ * Project: libfsScan: mediatypes and filesystem scanning
+ *
+ * CMP - compound media player
+ *
+ * is a client/server mediaplayer intended to play any media from any workstation
+ * without the need to export or mount shares. cmps is an easy to use backend
+ * with a (ready to use) HTML-interface. Additionally the backend supports
+ * authentication via HTTP-digest authorization.
+ * cmpc is a client with vdr-like osd-menues.
+ *
+ * Copyright (c) 2012 Reinhard Mantey, some rights reserved!
+ * published under Creative Commons by-sa
+ * For details see http://creativecommons.org/licenses/by-sa/3.0/
+ *
+ * The cmp project's homepage is at http://projects.vdr-developer.org/projects/cmp
+ *
+ * --------------------------------------------------------------
+ */
+#include <File.h>
+#include <FileSystem.h>
+#include <FileRepresentation.h>
+#include <StringBuilder.h>
+#include <sys/stat.h>
+#include <sys/dir.h>
+
+cFileSystem *cFile::fs = NULL;
+static mode_t ReadMask = S_IRUSR | S_IRGRP | S_IROTH;
+static mode_t WriteMask = S_IWUSR | S_IWGRP | S_IWOTH;
+static mode_t ExecMask = S_IXUSR | S_IXGRP | S_IXOTH;
+
+
+cFile::cFile(const char *Path)
+ : rep(NULL)
+{
+ if (!fs) fs = new cFileSystem();
+ if (!Path) {
+ Path = getcwd(NULL, 0);
+ rep = fs->representationOfFile(Path);
+ free((char *) Path);
+ }
+ else rep = fs->representationOfFile(Path);
+}
+
+cFile::cFile(const cFile &other)
+ : rep(other.rep)
+{
+ if (!fs) fs = new cFileSystem();
+}
+
+cFile::cFile(const cFile& Parent, const char* RelativePath)
+ : rep(NULL)
+{
+ if (!fs) fs = new cFileSystem();
+ rep = fs->representationOfFile(Parent, RelativePath);
+}
+
+cFile::cFile(const cFileRepresentation *fr)
+ : rep(fr)
+{
+ if (!fs) fs = new cFileSystem();
+}
+
+cFile::~cFile()
+{
+}
+
+cFile &cFile::operator =(const cFile &other)
+{
+ rep = other.rep;
+ return *this;
+}
+
+const char *cFile::AbsolutePath(void) const
+{
+ if (rep) return rep->Path();
+ return NULL;
+}
+
+bool cFile::Exists(void) const
+{
+ if (rep) return rep->exists;
+ return false;
+}
+
+bool cFile::IsDirectory(void) const
+{
+ if (rep) return (rep->mode & S_IFMT) == S_IFDIR;
+ return false;
+}
+
+bool cFile::IsFile(void) const
+{
+ if (rep) return (rep->mode & S_IFMT) == S_IFREG;
+ return false;
+}
+
+bool cFile::IsSymbolic(void) const
+{
+ if (rep) return (rep->mode & S_IFMT) == S_IFLNK;
+ return false;
+}
+
+bool cFile::CanRead(void) const
+{
+ if (rep) return rep->mode & ReadMask;
+ return false;
+}
+
+bool cFile::CanWrite(void) const
+{
+ if (rep) return rep->mode & WriteMask;
+ return false;
+}
+
+bool cFile::CanExecute(void) const
+{
+ if (rep) return rep->mode & ExecMask;
+ return false;
+}
+
+off64_t cFile::Size(void) const
+{
+ if (rep) return rep->size;
+ return 0;
+}
+
+ulong cFile::LastModified(void) const
+{
+ if (rep) return rep->lastModified;
+ return 0;
+}
+
+cFile *cFile::Parent(void) const
+{
+ if (rep) return new cFile(rep->getParent());
+ return NULL;
+}
+
+const char *cFile::Name(void) const
+{
+ if (rep) return rep->name;
+ return NULL;
+}
+
+void cFile::Cleanup(void)
+{
+ if (fs) {
+ delete fs;
+ fs = NULL;
+ }
+}
+
+void cFile::VisitFiles(int (*cb)(void *, cFile *, const char *), void *opaque)
+{
+ if (!Exists() || !IsDirectory()) return;
+ struct dirent entryBuffer, *pE;
+ DIR *dir = opendir(AbsolutePath());
+
+ while (!readdir_r(dir, &entryBuffer, &pE) && pE) {
+ if (*(pE->d_name) == '.') continue; // don't bother with hidden stuff
+ cb(opaque, this, pE->d_name);
+ }
+ closedir(dir);
+}
+
+char *cFile::toURI() const
+{
+ if (rep) return rep->toURI();
+ return NULL;
+}
+
+void cFile::SetVirtualRoot(bool isRoot)
+{
+ if (rep) ((cFileRepresentation *)rep)->SetVirtualRoot(isRoot);
+}
diff --git a/libs/IO/File.h b/libs/IO/File.h
new file mode 100644
index 0000000..587d99c
--- /dev/null
+++ b/libs/IO/File.h
@@ -0,0 +1,67 @@
+/**
+ * ======================== legal notice ======================
+ *
+ * File: File.h
+ * Created: 21. Juli 2012, 12
+ * Author: <a href="mailto:geronimo013@gmx.de">Geronimo</a>
+ * Project: libfsScan: mediatypes and filesystem scanning
+ *
+ * CMP - compound media player
+ *
+ * is a client/server mediaplayer intended to play any media from any workstation
+ * without the need to export or mount shares. cmps is an easy to use backend
+ * with a (ready to use) HTML-interface. Additionally the backend supports
+ * authentication via HTTP-digest authorization.
+ * cmpc is a client with vdr-like osd-menues.
+ *
+ * Copyright (c) 2012 Reinhard Mantey, some rights reserved!
+ * published under Creative Commons by-sa
+ * For details see http://creativecommons.org/licenses/by-sa/3.0/
+ *
+ * The cmp project's homepage is at http://projects.vdr-developer.org/projects/cmp
+ *
+ * --------------------------------------------------------------
+ */
+#ifndef FILE_H
+#define FILE_H
+
+#include <stddef.h>
+#include <sys/types.h>
+
+class cFileSystem;
+class cFileRepresentation;
+class cStringBuilder;
+class cFile {
+public:
+ cFile(const char *Path = NULL);
+ cFile(const cFile &other);
+ cFile(const cFile &Parent, const char *RelativePath);
+ virtual ~cFile();
+
+ cFile &operator =(const cFile &other);
+ bool CanRead(void) const;
+ bool CanWrite(void) const;
+ bool CanExecute(void) const;
+ bool Exists(void) const;
+ bool IsDirectory(void) const;
+ bool IsFile(void) const;
+ bool IsSymbolic(void) const;
+ off64_t Size(void) const;
+ ulong LastModified(void) const;
+ const char *Name(void) const;
+ void SetVirtualRoot(bool isRoot = true);
+ const char *AbsolutePath(void) const; ///< returns an allocated string
+ char *toURI(void) const; ///< returns an allocated string
+ cFile *Parent(void) const; ///< allocates a new file instance!
+ void VisitFiles(int (*cb)(void *, cFile *, const char *), void *opaque);
+ static void Cleanup(void);
+
+private:
+ cFile(const cFileRepresentation *);
+ const cFileRepresentation *rep;
+ static cFileSystem *fs;
+ friend class cFileSystem;
+};
+
+#endif /* FILE_H */
+
diff --git a/libs/IO/FileRepresentation.cc b/libs/IO/FileRepresentation.cc
new file mode 100644
index 0000000..81599a3
--- /dev/null
+++ b/libs/IO/FileRepresentation.cc
@@ -0,0 +1,132 @@
+/**
+ * ======================== legal notice ======================
+ *
+ * File: FileRepresentation.cc
+ * Created: 21. Juli 2012, 12
+ * Author: <a href="mailto:geronimo013@gmx.de">Geronimo</a>
+ * Project: libfsScan: mediatypes and filesystem scanning
+ *
+ * CMP - compound media player
+ *
+ * is a client/server mediaplayer intended to play any media from any workstation
+ * without the need to export or mount shares. cmps is an easy to use backend
+ * with a (ready to use) HTML-interface. Additionally the backend supports
+ * authentication via HTTP-digest authorization.
+ * cmpc is a client with vdr-like osd-menues.
+ *
+ * Copyright (c) 2012 Reinhard Mantey, some rights reserved!
+ * published under Creative Commons by-sa
+ * For details see http://creativecommons.org/licenses/by-sa/3.0/
+ *
+ * The cmp project's homepage is at http://projects.vdr-developer.org/projects/cmp
+ *
+ * --------------------------------------------------------------
+ */
+#include <FileRepresentation.h>
+#include <FileSystem.h>
+#include <StringBuilder.h>
+#include <Url.h>
+#include <Codec.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <string.h>
+#include <stdlib.h>
+#include <iostream>
+#include <stack>
+
+cFileRepresentation::cFileRepresentation(const char *Name)
+ : exists(false)
+ , isRoot(true)
+ , isVirtualRoot(true)
+ , mode(0)
+ , size(0)
+ , lastModified(0)
+ , name(NULL)
+ , path(NULL)
+ , parent(NULL)
+{
+ struct stat st;
+
+ if (!stat(Name, &st)) {
+ name = strdup(Name);
+ exists = true;
+ mode = st.st_mode;
+ size = st.st_size;
+ lastModified = st.st_mtime;
+ }
+}
+
+cFileRepresentation::cFileRepresentation(const cFileRepresentation *Parent, const char *Name)
+ : exists(false)
+ , isRoot(false)
+ , isVirtualRoot(false)
+ , mode(0)
+ , size(0)
+ , lastModified(0)
+ , name(strdup(Name))
+ , path(NULL)
+ , parent(Parent)
+{
+ struct stat st;
+
+ if (!stat(Path(), &st)) {
+ exists = true;
+ mode = st.st_mode;
+ size = st.st_size;
+ lastModified = st.st_mtime;
+ }
+}
+
+cFileRepresentation::~cFileRepresentation()
+{
+ free(name);
+ free(path);
+}
+
+const char *cFileRepresentation::Path() const
+{
+ if (!path) {
+ cStringBuilder sb;
+
+ if (parent) sb.Append(parent->Path());
+ sb.Append(cFileSystem::PathSeparator).Append(name);
+ path = sb.toString();
+ }
+ return path;
+}
+
+void cFileRepresentation::SetVirtualRoot(bool isRoot)
+{
+ isVirtualRoot = isRoot;
+}
+
+char *cFileRepresentation::toURI() const
+{
+ cStringBuilder *sb = new cStringBuilder();
+ const cFileRepresentation *f = this;
+ std::stack<const cFileRepresentation *> rev;
+ cURLEncoder *enc = cUrl::Encoder();
+ char *tmp, *chk, *rv;
+ size_t stackSize;
+
+ while (!f->isVirtualRoot) {
+ rev.push(f);
+ stackSize = rev.size();
+ f = f->parent;
+ }
+
+ for (;;) {
+ f = rev.top();
+ rev.pop();
+ chk = f->name + strlen(f->name) - 1;
+ if (*chk != cFileSystem::PathSeparator) sb->Append(cFileSystem::PathSeparator);
+ tmp = enc->Encode(f->name);
+ sb->Append(tmp);
+ free(tmp);
+ if (rev.empty()) break;
+ }
+ rv = sb->toString();
+ delete sb;
+
+ return rv;
+}
diff --git a/libs/IO/FileRepresentation.h b/libs/IO/FileRepresentation.h
new file mode 100644
index 0000000..39a3c1e
--- /dev/null
+++ b/libs/IO/FileRepresentation.h
@@ -0,0 +1,56 @@
+/**
+ * ======================== legal notice ======================
+ *
+ * File: FileRepresentation.h
+ * Created: 21. Juli 2012, 12
+ * Author: <a href="mailto:geronimo013@gmx.de">Geronimo</a>
+ * Project: libfsScan: mediatypes and filesystem scanning
+ *
+ * CMP - compound media player
+ *
+ * is a client/server mediaplayer intended to play any media from any workstation
+ * without the need to export or mount shares. cmps is an easy to use backend
+ * with a (ready to use) HTML-interface. Additionally the backend supports
+ * authentication via HTTP-digest authorization.
+ * cmpc is a client with vdr-like osd-menues.
+ *
+ * Copyright (c) 2012 Reinhard Mantey, some rights reserved!
+ * published under Creative Commons by-sa
+ * For details see http://creativecommons.org/licenses/by-sa/3.0/
+ *
+ * The cmp project's homepage is at http://projects.vdr-developer.org/projects/cmp
+ *
+ * --------------------------------------------------------------
+ */
+#ifndef FILEREPRESENTATION_H
+#define FILEREPRESENTATION_H
+
+#include <sys/types.h>
+
+class cStringBuilder;
+class cFileRepresentation {
+public:
+ virtual ~cFileRepresentation();
+
+ const char *Path(void) const;
+ const cFileRepresentation *getParent(void) const { return parent; };
+ void SetVirtualRoot(bool isRoot);
+
+private:
+ cFileRepresentation(const char *Name);
+ cFileRepresentation(const cFileRepresentation *Parent, const char *Name);
+ char *toURI(void) const;
+ bool exists;
+ bool isRoot;
+ bool isVirtualRoot;
+ mode_t mode;
+ off64_t size;
+ ulong lastModified;
+ char *name;
+ mutable char *path;
+ const cFileRepresentation *parent;
+ friend class cFileSystem;
+ friend class cFile;
+ };
+
+#endif // FILEREPRESENTATION_H
diff --git a/libs/IO/FileSystem.cc b/libs/IO/FileSystem.cc
new file mode 100644
index 0000000..3891c97
--- /dev/null
+++ b/libs/IO/FileSystem.cc
@@ -0,0 +1,132 @@
+/**
+ * ======================== legal notice ======================
+ *
+ * File: FileSystem.cc
+ * Created: 21. Juli 2012, 12
+ * Author: <a href="mailto:geronimo013@gmx.de">Geronimo</a>
+ * Project: libfsScan: mediatypes and filesystem scanning
+ *
+ * CMP - compound media player
+ *
+ * is a client/server mediaplayer intended to play any media from any workstation
+ * without the need to export or mount shares. cmps is an easy to use backend
+ * with a (ready to use) HTML-interface. Additionally the backend supports
+ * authentication via HTTP-digest authorization.
+ * cmpc is a client with vdr-like osd-menues.
+ *
+ * Copyright (c) 2012 Reinhard Mantey, some rights reserved!
+ * published under Creative Commons by-sa
+ * For details see http://creativecommons.org/licenses/by-sa/3.0/
+ *
+ * The cmp project's homepage is at http://projects.vdr-developer.org/projects/cmp
+ *
+ * --------------------------------------------------------------
+ */
+#include <FileSystem.h>
+#include <FileRepresentation.h>
+#include <File.h>
+#include <StringBuilder.h>
+#include <iostream>
+#include <stdlib.h>
+#include <string.h>
+
+char cFileSystem::PathSeparator = '/';
+char cFileSystem::RootPath[4] = { PathSeparator, 0, 0, 0 };
+
+cFileSystem::cFileSystem()
+{
+}
+
+cFileSystem::~cFileSystem()
+{
+ std::tr1::unordered_map<std::string, cFileRepresentation *>::iterator it = fileCache.begin();
+
+ while (it != fileCache.end()) {
+ if (it->second) delete it->second;
+ ++it;
+ }
+}
+
+cFileRepresentation *cFileSystem::cacheEntry(const char* Path)
+{
+ if (fileCache.empty()) return NULL;
+ std::tr1::unordered_map<std::string, cFileRepresentation *>::iterator it = fileCache.find(Path);
+
+ if (it != fileCache.end()) return it->second;
+ return NULL;
+}
+
+cFileRepresentation *cFileSystem::representationOfFile(const cFile &Parent, const char* Path)
+{
+ cFileRepresentation *parentRep = (cFileRepresentation *) Parent.rep;
+ cFileRepresentation *tmp = NULL;
+ cStringBuilder *sb = new cStringBuilder(Parent.AbsolutePath());
+ char *scratch = strdup(Path);
+ char *last = scratch + strlen(Path);
+ char *start = *scratch == PathSeparator ? scratch + 1 : scratch;
+ char *end = strchr(scratch, PathSeparator);
+ char *path;
+
+ while (start < last) {
+ end = strchr(start, PathSeparator);
+ if (!end) end = start + strlen(start);
+ *end = 0;
+ sb->Append(PathSeparator).Append(start);
+ path = sb->toString();
+ tmp = cacheEntry(path);
+ if (!tmp) {
+ tmp = new cFileRepresentation(parentRep, start);
+ fileCache[path] = tmp;
+ }
+ parentRep = tmp;
+ free(path);
+ start = end + 1;
+ }
+ free(scratch);
+ delete sb;
+
+ if (tmp) return tmp;
+ return NULL;
+}
+
+cFileRepresentation *cFileSystem::representationOfFile(const char* Path)
+{
+ cFileRepresentation *rv = cacheEntry(Path);
+
+ if (!rv) {
+ cFileRepresentation *tmp = NULL;
+ char *scratch = strdup(Path);
+ char *p;
+
+ for (p = strrchr(scratch, PathSeparator); !rv && p; p = strrchr(scratch, PathSeparator)) {
+ if (p > scratch) *p = 0;
+ else {
+ if (!(rv = cacheEntry(RootPath))) {
+ *p = 0;
+ tmp = new cFileRepresentation(RootPath);
+ fileCache[RootPath] = tmp;
+ break;
+ }
+ }
+ if ((tmp = cacheEntry(scratch))) break;
+ }
+
+ if (tmp) {
+ cFileRepresentation *parent = tmp;
+ size_t poolSize = fileCache.size();
+ const char *last = scratch + strlen(Path);
+
+ for (p = scratch + strlen(scratch) + 1; p < last; p += strlen(p) + 1) {
+ if (!*(p - 1)) *(p - 1) = PathSeparator;
+ tmp = new cFileRepresentation(parent, p);
+ fileCache[scratch] = tmp;
+ poolSize = fileCache.size();
+ parent = tmp;
+ }
+ rv = parent;
+ }
+ free(scratch);
+ }
+ return rv;
+}
+
diff --git a/libs/IO/FileSystem.h b/libs/IO/FileSystem.h
new file mode 100644
index 0000000..0cf4a2f
--- /dev/null
+++ b/libs/IO/FileSystem.h
@@ -0,0 +1,50 @@
+/**
+ * ======================== legal notice ======================
+ *
+ * File: FileSystem.h
+ * Created: 21. Juli 2012, 12
+ * Author: <a href="mailto:geronimo013@gmx.de">Geronimo</a>
+ * Project: libfsScan: mediatypes and filesystem scanning
+ *
+ * CMP - compound media player
+ *
+ * is a client/server mediaplayer intended to play any media from any workstation
+ * without the need to export or mount shares. cmps is an easy to use backend
+ * with a (ready to use) HTML-interface. Additionally the backend supports
+ * authentication via HTTP-digest authorization.
+ * cmpc is a client with vdr-like osd-menues.
+ *
+ * Copyright (c) 2012 Reinhard Mantey, some rights reserved!
+ * published under Creative Commons by-sa
+ * For details see http://creativecommons.org/licenses/by-sa/3.0/
+ *
+ * The cmp project's homepage is at http://projects.vdr-developer.org/projects/cmp
+ *
+ * --------------------------------------------------------------
+ */
+#ifndef FILESYSTEM_H
+#define FILESYSTEM_H
+
+#include <tr1/unordered_map>
+#include <string>
+
+class cFile;
+class cFileRepresentation;
+class cFileSystem {
+public:
+ cFileSystem();
+ virtual ~cFileSystem();
+
+ cFileRepresentation *representationOfFile(const char *Path);
+ cFileRepresentation *representationOfFile(const cFile &Parent, const char *Path);
+
+private:
+ cFileRepresentation *cacheEntry(const char *Path);
+ std::tr1::unordered_map<std::string, cFileRepresentation *> fileCache;
+ static char PathSeparator;
+ static char RootPath[4];
+ friend class cFileRepresentation;
+ };
+
+#endif /* FILESYSTEM_H */
+
diff --git a/libs/IO/IO.cbp b/libs/IO/IO.cbp
new file mode 100644
index 0000000..36f087a
--- /dev/null
+++ b/libs/IO/IO.cbp
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
+<CodeBlocks_project_file>
+ <FileVersion major="1" minor="6" />
+ <Project>
+ <Option title="CMP.libs.IO" />
+ <Option pch_mode="2" />
+ <Option compiler="gcc" />
+ <Build>
+ <Target title="Debug">
+ <Option output="IO" prefix_auto="1" extension_auto="1" />
+ <Option working_dir="" />
+ <Option object_output="obj/Debug/" />
+ <Option type="2" />
+ <Option compiler="gcc" />
+ <Option createDefFile="1" />
+ <Compiler>
+ <Add option="-Wall" />
+ <Add option="-g" />
+ </Compiler>
+ </Target>
+ <Target title="Release">
+ <Option output="IO" prefix_auto="1" extension_auto="1" />
+ <Option working_dir="" />
+ <Option object_output="obj/Release/" />
+ <Option type="2" />
+ <Option compiler="gcc" />
+ <Option createDefFile="1" />
+ <Compiler>
+ <Add option="-Wall" />
+ <Add option="-O2" />
+ </Compiler>
+ <Linker>
+ <Add option="-s" />
+ </Linker>
+ </Target>
+ </Build>
+ <Compiler>
+ <Add option="-std=gnu++0x -fomit-frame-pointer -fPIC -pthread -Wall -Wno-parentheses -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wwrite-strings -Wtype-limits -Wundef -fno-math-errno -fno-signed-zeros -fno-tree-vectorize -Werror=implicit-function-declaration" />
+ <Add option="-D_REENTRANT" />
+ <Add option="-D_GNU_SOURCE=1" />
+ <Add option="-D_FILE_OFFSET_BITS=64" />
+ <Add option="-D_LARGEFILE_SOURCE" />
+ <Add option="-D_LARGEFILE64_SOURCE" />
+ <Add option="-D__STDC_CONSTANT_MACROS" />
+ <Add option="-D__STDC_FORMAT_MACROS" />
+ <Add option="-D__STDC_LIMIT_MACROS" />
+ <Add directory="include" />
+ <Add directory="../util/include" />
+ <Add directory="../vdr/include" />
+ </Compiler>
+ <Unit filename="include/ConfigReader.h" />
+ <Unit filename="include/File.h" />
+ <Unit filename="include/FileReader.h" />
+ <Unit filename="include/FileRepresentation.h" />
+ <Unit filename="include/FileSystem.h" />
+ <Unit filename="include/LineReader.h" />
+ <Unit filename="src/ConfigReader.cc" />
+ <Unit filename="src/File.cc" />
+ <Unit filename="src/FileReader.cc" />
+ <Unit filename="src/FileRepresentation.cc" />
+ <Unit filename="src/FileSystem.cc" />
+ <Unit filename="src/LineReader.cc" />
+ <Extensions>
+ <code_completion />
+ <envvars />
+ <lib_finder disable_auto="1" />
+ <debugger />
+ </Extensions>
+ </Project>
+</CodeBlocks_project_file>
diff --git a/libs/IO/IO.cbp.save b/libs/IO/IO.cbp.save
new file mode 100644
index 0000000..52f0fe6
--- /dev/null
+++ b/libs/IO/IO.cbp.save
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
+<CodeBlocks_project_file>
+ <FileVersion major="1" minor="6" />
+ <Project>
+ <Option title="CMP.libs.IO" />
+ <Option pch_mode="2" />
+ <Option compiler="gcc" />
+ <Build>
+ <Target title="Debug">
+ <Option output="IO" prefix_auto="1" extension_auto="1" />
+ <Option working_dir="" />
+ <Option object_output="obj/Debug/" />
+ <Option type="2" />
+ <Option compiler="gcc" />
+ <Option createDefFile="1" />
+ <Compiler>
+ <Add option="-Wall" />
+ <Add option="-g" />
+ </Compiler>
+ </Target>
+ <Target title="Release">
+ <Option output="IO" prefix_auto="1" extension_auto="1" />
+ <Option working_dir="" />
+ <Option object_output="obj/Release/" />
+ <Option type="2" />
+ <Option compiler="gcc" />
+ <Option createDefFile="1" />
+ <Compiler>
+ <Add option="-Wall" />
+ <Add option="-O2" />
+ </Compiler>
+ <Linker>
+ <Add option="-s" />
+ </Linker>
+ </Target>
+ </Build>
+ <Compiler>
+ <Add option="-std=gnu++0x -fomit-frame-pointer -fPIC -pthread -Wall -Wno-parentheses -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wwrite-strings -Wtype-limits -Wundef -fno-math-errno -fno-signed-zeros -fno-tree-vectorize -Werror=implicit-function-declaration" />
+ <Add option="-D_REENTRANT" />
+ <Add option="-D_GNU_SOURCE=1" />
+ <Add option="-D_FILE_OFFSET_BITS=64" />
+ <Add option="-D_LARGEFILE_SOURCE" />
+ <Add option="-D_LARGEFILE64_SOURCE" />
+ <Add option="-D__STDC_CONSTANT_MACROS" />
+ <Add option="-D__STDC_FORMAT_MACROS" />
+ <Add option="-D__STDC_LIMIT_MACROS" />
+ <Add directory="include" />
+ <Add directory="../util/include" />
+ <Add directory="../vdr/include" />
+ </Compiler>
+ <Unit filename="include/File.h" />
+ <Unit filename="include/FileReader.h" />
+ <Unit filename="include/FileRepresentation.h" />
+ <Unit filename="include/FileSystem.h" />
+ <Unit filename="include/LineReader.h" />
+ <Unit filename="src/File.cc" />
+ <Unit filename="src/FileReader.cc" />
+ <Unit filename="src/FileRepresentation.cc" />
+ <Unit filename="src/FileSystem.cc" />
+ <Unit filename="src/LineReader.cc" />
+ <Extensions>
+ <code_completion />
+ <envvars />
+ <lib_finder disable_auto="1" />
+ <debugger />
+ </Extensions>
+ </Project>
+</CodeBlocks_project_file>
diff --git a/libs/IO/IO.depend b/libs/IO/IO.depend
new file mode 100644
index 0000000..c4ac310
--- /dev/null
+++ b/libs/IO/IO.depend
@@ -0,0 +1 @@
+# depslib dependency file v1.0
diff --git a/libs/IO/IO.layout b/libs/IO/IO.layout
new file mode 100644
index 0000000..f0b6b2a
--- /dev/null
+++ b/libs/IO/IO.layout
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
+<CodeBlocks_layout_file>
+ <ActiveTarget name="Debug" />
+ <File name="src/ConfigReader.cc" open="1" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="459" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="src/File.cc" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="1638" topLine="30" />
+ </Cursor>
+ </File>
+ <File name="src/FileReader.cc" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="1320" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="src/FileRepresentation.cc" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="1846" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="include/ConfigReader.h" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="475" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="src/LineReader.cc" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="854" topLine="0" />
+ </Cursor>
+ </File>
+</CodeBlocks_layout_file>
diff --git a/libs/IO/IO.layout.save b/libs/IO/IO.layout.save
new file mode 100644
index 0000000..e837daf
--- /dev/null
+++ b/libs/IO/IO.layout.save
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
+<CodeBlocks_layout_file>
+ <ActiveTarget name="Debug" />
+ <File name="src/ConfigReader.cc" open="1" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="0" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="src/File.cc" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="1638" topLine="30" />
+ </Cursor>
+ </File>
+ <File name="src/FileReader.cc" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="1320" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="src/FileRepresentation.cc" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="1846" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="include/ConfigReader.h" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="475" topLine="0" />
+ </Cursor>
+ </File>
+ <File name="src/LineReader.cc" open="0" top="0" tabpos="0" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0">
+ <Cursor>
+ <Cursor1 position="854" topLine="0" />
+ </Cursor>
+ </File>
+</CodeBlocks_layout_file>
diff --git a/libs/IO/Makefile b/libs/IO/Makefile
new file mode 100644
index 0000000..ec9de69
--- /dev/null
+++ b/libs/IO/Makefile
@@ -0,0 +1,128 @@
+#
+# There exist several targets which are by default empty and which can be
+# used for execution of your targets. These targets are usually executed
+# before and after some main targets. They are:
+#
+# .build-pre: called before 'build' target
+# .build-post: called after 'build' target
+# .clean-pre: called before 'clean' target
+# .clean-post: called after 'clean' target
+# .clobber-pre: called before 'clobber' target
+# .clobber-post: called after 'clobber' target
+# .all-pre: called before 'all' target
+# .all-post: called after 'all' target
+# .help-pre: called before 'help' target
+# .help-post: called after 'help' target
+#
+# Targets beginning with '.' are not intended to be called on their own.
+#
+# Main targets can be executed directly, and they are:
+#
+# build build a specific configuration
+# clean remove built files from a configuration
+# clobber remove all built files
+# all build all configurations
+# help print help mesage
+#
+# Targets .build-impl, .clean-impl, .clobber-impl, .all-impl, and
+# .help-impl are implemented in nbproject/makefile-impl.mk.
+#
+# Available make variables:
+#
+# CND_BASEDIR base directory for relative paths
+# CND_DISTDIR default top distribution directory (build artifacts)
+# CND_BUILDDIR default top build directory (object files, ...)
+# CONF name of current configuration
+# CND_PLATFORM_${CONF} platform name (current configuration)
+# CND_ARTIFACT_DIR_${CONF} directory of build artifact (current configuration)
+# CND_ARTIFACT_NAME_${CONF} name of build artifact (current configuration)
+# CND_ARTIFACT_PATH_${CONF} path to build artifact (current configuration)
+# CND_PACKAGE_DIR_${CONF} directory of package (current configuration)
+# CND_PACKAGE_NAME_${CONF} name of package (current configuration)
+# CND_PACKAGE_PATH_${CONF} path to package (current configuration)
+#
+# NOCDDL
+
+
+# Environment
+MKDIR=mkdir
+CP=cp
+CCADMIN=CCadmin
+
+
+# build
+build: .build-post
+
+.build-pre:
+# Add your pre 'build' code here...
+
+.build-post: .build-impl
+# Add your post 'build' code here...
+
+
+# clean
+clean: .clean-post
+
+.clean-pre:
+# Add your pre 'clean' code here...
+
+.clean-post: .clean-impl
+# Add your post 'clean' code here...
+
+
+# clobber
+clobber: .clobber-post
+
+.clobber-pre:
+# Add your pre 'clobber' code here...
+
+.clobber-post: .clobber-impl
+# Add your post 'clobber' code here...
+
+
+# all
+all: .all-post
+
+.all-pre:
+# Add your pre 'all' code here...
+
+.all-post: .all-impl
+# Add your post 'all' code here...
+
+
+# build tests
+build-tests: .build-tests-post
+
+.build-tests-pre:
+# Add your pre 'build-tests' code here...
+
+.build-tests-post: .build-tests-impl
+# Add your post 'build-tests' code here...
+
+
+# run tests
+test: .test-post
+
+.test-pre:
+# Add your pre 'test' code here...
+
+.test-post: .test-impl
+# Add your post 'test' code here...
+
+
+# help
+help: .help-post
+
+.help-pre:
+# Add your pre 'help' code here...
+
+.help-post: .help-impl
+# Add your post 'help' code here...
+
+
+
+# include project implementation makefile
+include nbproject/Makefile-impl.mk
+
+# include project make variables
+include nbproject/Makefile-variables.mk
diff --git a/libs/IO/nbproject/Makefile-Debug.mk b/libs/IO/nbproject/Makefile-Debug.mk
new file mode 100644
index 0000000..0fa73d7
--- /dev/null
+++ b/libs/IO/nbproject/Makefile-Debug.mk
@@ -0,0 +1,120 @@
+#
+# Generated Makefile - do not edit!
+#
+# Edit the Makefile in the project folder instead (../Makefile). Each target
+# has a -pre and a -post target defined where you can add customized code.
+#
+# This makefile implements configuration specific macros and targets.
+
+
+# Environment
+MKDIR=mkdir
+CP=cp
+GREP=grep
+NM=nm
+CCADMIN=CCadmin
+RANLIB=ranlib
+CC=gcc
+CCC=g++
+CXX=g++
+FC=gfortran
+AS=as
+
+# Macros
+CND_PLATFORM=GNU-Linux-x86
+CND_DLIB_EXT=so
+CND_CONF=Debug
+CND_DISTDIR=dist
+CND_BUILDDIR=build
+
+# Include project Makefile
+include Makefile
+
+# Object Directory
+OBJECTDIR=${CND_BUILDDIR}/${CND_CONF}/${CND_PLATFORM}
+
+# Object Files
+OBJECTFILES= \
+ ${OBJECTDIR}/src/FileRepresentation.o \
+ ${OBJECTDIR}/src/LineReader.o \
+ ${OBJECTDIR}/src/File.o \
+ ${OBJECTDIR}/src/ConfigReader.o \
+ ${OBJECTDIR}/src/FileReader.o \
+ ${OBJECTDIR}/src/FileSystem.o
+
+
+# C Compiler Flags
+CFLAGS=
+
+# CC Compiler Flags
+CCFLAGS=-std=gnu++0x -fomit-frame-pointer -fPIC -pthread -Wall -Wno-parentheses -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wwrite-strings -Wtype-limits -Wundef -fno-math-errno -fno-signed-zeros -fno-tree-vectorize -Werror=implicit-function-declaration
+CXXFLAGS=-std=gnu++0x -fomit-frame-pointer -fPIC -pthread -Wall -Wno-parentheses -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wwrite-strings -Wtype-limits -Wundef -fno-math-errno -fno-signed-zeros -fno-tree-vectorize -Werror=implicit-function-declaration
+
+# Fortran Compiler Flags
+FFLAGS=
+
+# Assembler Flags
+ASFLAGS=
+
+# Link Libraries and Options
+LDLIBSOPTIONS=
+
+# Build Targets
+.build-conf: ${BUILD_SUBPROJECTS}
+ "${MAKE}" -f nbproject/Makefile-${CND_CONF}.mk ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+
+${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a: ${OBJECTFILES}
+ ${MKDIR} -p ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}
+ ${RM} ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+ ${AR} -rv ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a ${OBJECTFILES}
+ $(RANLIB) ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+
+${OBJECTDIR}/src/FileRepresentation.o: src/FileRepresentation.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -g -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE=1 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_REENTRANT -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iinclude -I../util/include -I../vdr/include -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/FileRepresentation.o src/FileRepresentation.cc
+
+${OBJECTDIR}/src/LineReader.o: src/LineReader.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -g -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE=1 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_REENTRANT -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iinclude -I../util/include -I../vdr/include -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/LineReader.o src/LineReader.cc
+
+${OBJECTDIR}/src/File.o: src/File.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -g -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE=1 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_REENTRANT -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iinclude -I../util/include -I../vdr/include -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/File.o src/File.cc
+
+${OBJECTDIR}/src/ConfigReader.o: src/ConfigReader.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -g -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE=1 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_REENTRANT -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iinclude -I../util/include -I../vdr/include -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/ConfigReader.o src/ConfigReader.cc
+
+${OBJECTDIR}/src/FileReader.o: src/FileReader.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -g -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE=1 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_REENTRANT -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iinclude -I../util/include -I../vdr/include -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/FileReader.o src/FileReader.cc
+
+${OBJECTDIR}/src/FileSystem.o: src/FileSystem.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -g -Wall -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE=1 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_REENTRANT -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iinclude -I../util/include -I../vdr/include -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/FileSystem.o src/FileSystem.cc
+
+# Subprojects
+.build-subprojects:
+ cd ../vdr && ${MAKE} -f Makefile CONF=Debug
+ cd ../util && ${MAKE} -f Makefile CONF=Debug
+
+# Clean Targets
+.clean-conf: ${CLEAN_SUBPROJECTS}
+ ${RM} -r ${CND_BUILDDIR}/${CND_CONF}
+ ${RM} ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+
+# Subprojects
+.clean-subprojects:
+ cd ../vdr && ${MAKE} -f Makefile CONF=Debug clean
+ cd ../util && ${MAKE} -f Makefile CONF=Debug clean
+
+# Enable dependency checking
+.dep.inc: .depcheck-impl
+
+include .dep.inc
diff --git a/libs/IO/nbproject/Makefile-Release.mk b/libs/IO/nbproject/Makefile-Release.mk
new file mode 100644
index 0000000..853a053
--- /dev/null
+++ b/libs/IO/nbproject/Makefile-Release.mk
@@ -0,0 +1,116 @@
+#
+# Generated Makefile - do not edit!
+#
+# Edit the Makefile in the project folder instead (../Makefile). Each target
+# has a -pre and a -post target defined where you can add customized code.
+#
+# This makefile implements configuration specific macros and targets.
+
+
+# Environment
+MKDIR=mkdir
+CP=cp
+GREP=grep
+NM=nm
+CCADMIN=CCadmin
+RANLIB=ranlib
+CC=gcc
+CCC=g++
+CXX=g++
+FC=gfortran
+AS=as
+
+# Macros
+CND_PLATFORM=GNU-Linux-x86
+CND_DLIB_EXT=so
+CND_CONF=Release
+CND_DISTDIR=dist
+CND_BUILDDIR=build
+
+# Include project Makefile
+include Makefile
+
+# Object Directory
+OBJECTDIR=${CND_BUILDDIR}/${CND_CONF}/${CND_PLATFORM}
+
+# Object Files
+OBJECTFILES= \
+ ${OBJECTDIR}/src/FileRepresentation.o \
+ ${OBJECTDIR}/src/LineReader.o \
+ ${OBJECTDIR}/src/File.o \
+ ${OBJECTDIR}/src/ConfigReader.o \
+ ${OBJECTDIR}/src/FileReader.o \
+ ${OBJECTDIR}/src/FileSystem.o
+
+
+# C Compiler Flags
+CFLAGS=
+
+# CC Compiler Flags
+CCFLAGS=
+CXXFLAGS=
+
+# Fortran Compiler Flags
+FFLAGS=
+
+# Assembler Flags
+ASFLAGS=
+
+# Link Libraries and Options
+LDLIBSOPTIONS=
+
+# Build Targets
+.build-conf: ${BUILD_SUBPROJECTS}
+ "${MAKE}" -f nbproject/Makefile-${CND_CONF}.mk ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+
+${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a: ${OBJECTFILES}
+ ${MKDIR} -p ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}
+ ${RM} ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+ ${AR} -rv ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a ${OBJECTFILES}
+ $(RANLIB) ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+
+${OBJECTDIR}/src/FileRepresentation.o: src/FileRepresentation.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -O2 -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/FileRepresentation.o src/FileRepresentation.cc
+
+${OBJECTDIR}/src/LineReader.o: src/LineReader.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -O2 -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/LineReader.o src/LineReader.cc
+
+${OBJECTDIR}/src/File.o: src/File.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -O2 -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/File.o src/File.cc
+
+${OBJECTDIR}/src/ConfigReader.o: src/ConfigReader.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -O2 -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/ConfigReader.o src/ConfigReader.cc
+
+${OBJECTDIR}/src/FileReader.o: src/FileReader.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -O2 -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/FileReader.o src/FileReader.cc
+
+${OBJECTDIR}/src/FileSystem.o: src/FileSystem.cc
+ ${MKDIR} -p ${OBJECTDIR}/src
+ ${RM} $@.d
+ $(COMPILE.cc) -O2 -MMD -MP -MF $@.d -o ${OBJECTDIR}/src/FileSystem.o src/FileSystem.cc
+
+# Subprojects
+.build-subprojects:
+
+# Clean Targets
+.clean-conf: ${CLEAN_SUBPROJECTS}
+ ${RM} -r ${CND_BUILDDIR}/${CND_CONF}
+ ${RM} ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+
+# Subprojects
+.clean-subprojects:
+
+# Enable dependency checking
+.dep.inc: .depcheck-impl
+
+include .dep.inc
diff --git a/libs/IO/nbproject/Makefile-impl.mk b/libs/IO/nbproject/Makefile-impl.mk
new file mode 100644
index 0000000..41a3b3c
--- /dev/null
+++ b/libs/IO/nbproject/Makefile-impl.mk
@@ -0,0 +1,133 @@
+#
+# Generated Makefile - do not edit!
+#
+# Edit the Makefile in the project folder instead (../Makefile). Each target
+# has a pre- and a post- target defined where you can add customization code.
+#
+# This makefile implements macros and targets common to all configurations.
+#
+# NOCDDL
+
+
+# Building and Cleaning subprojects are done by default, but can be controlled with the SUB
+# macro. If SUB=no, subprojects will not be built or cleaned. The following macro
+# statements set BUILD_SUB-CONF and CLEAN_SUB-CONF to .build-reqprojects-conf
+# and .clean-reqprojects-conf unless SUB has the value 'no'
+SUB_no=NO
+SUBPROJECTS=${SUB_${SUB}}
+BUILD_SUBPROJECTS_=.build-subprojects
+BUILD_SUBPROJECTS_NO=
+BUILD_SUBPROJECTS=${BUILD_SUBPROJECTS_${SUBPROJECTS}}
+CLEAN_SUBPROJECTS_=.clean-subprojects
+CLEAN_SUBPROJECTS_NO=
+CLEAN_SUBPROJECTS=${CLEAN_SUBPROJECTS_${SUBPROJECTS}}
+
+
+# Project Name
+PROJECTNAME=IO
+
+# Active Configuration
+DEFAULTCONF=Debug
+CONF=${DEFAULTCONF}
+
+# All Configurations
+ALLCONFS=Debug Release
+
+
+# build
+.build-impl: .build-pre .validate-impl .depcheck-impl
+ @#echo "=> Running $@... Configuration=$(CONF)"
+ "${MAKE}" -f nbproject/Makefile-${CONF}.mk QMAKE=${QMAKE} SUBPROJECTS=${SUBPROJECTS} .build-conf
+
+
+# clean
+.clean-impl: .clean-pre .validate-impl .depcheck-impl
+ @#echo "=> Running $@... Configuration=$(CONF)"
+ "${MAKE}" -f nbproject/Makefile-${CONF}.mk QMAKE=${QMAKE} SUBPROJECTS=${SUBPROJECTS} .clean-conf
+
+
+# clobber
+.clobber-impl: .clobber-pre .depcheck-impl
+ @#echo "=> Running $@..."
+ for CONF in ${ALLCONFS}; \
+ do \
+ "${MAKE}" -f nbproject/Makefile-$${CONF}.mk QMAKE=${QMAKE} SUBPROJECTS=${SUBPROJECTS} .clean-conf; \
+ done
+
+# all
+.all-impl: .all-pre .depcheck-impl
+ @#echo "=> Running $@..."
+ for CONF in ${ALLCONFS}; \
+ do \
+ "${MAKE}" -f nbproject/Makefile-$${CONF}.mk QMAKE=${QMAKE} SUBPROJECTS=${SUBPROJECTS} .build-conf; \
+ done
+
+# build tests
+.build-tests-impl: .build-impl .build-tests-pre
+ @#echo "=> Running $@... Configuration=$(CONF)"
+ "${MAKE}" -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .build-tests-conf
+
+# run tests
+.test-impl: .build-tests-impl .test-pre
+ @#echo "=> Running $@... Configuration=$(CONF)"
+ "${MAKE}" -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .test-conf
+
+# dependency checking support
+.depcheck-impl:
+ @echo "# This code depends on make tool being used" >.dep.inc
+ @if [ -n "${MAKE_VERSION}" ]; then \
+ echo "DEPFILES=\$$(wildcard \$$(addsuffix .d, \$${OBJECTFILES}))" >>.dep.inc; \
+ echo "ifneq (\$${DEPFILES},)" >>.dep.inc; \
+ echo "include \$${DEPFILES}" >>.dep.inc; \
+ echo "endif" >>.dep.inc; \
+ else \
+ echo ".KEEP_STATE:" >>.dep.inc; \
+ echo ".KEEP_STATE_FILE:.make.state.\$${CONF}" >>.dep.inc; \
+ fi
+
+# configuration validation
+.validate-impl:
+ @if [ ! -f nbproject/Makefile-${CONF}.mk ]; \
+ then \
+ echo ""; \
+ echo "Error: can not find the makefile for configuration '${CONF}' in project ${PROJECTNAME}"; \
+ echo "See 'make help' for details."; \
+ echo "Current directory: " `pwd`; \
+ echo ""; \
+ fi
+ @if [ ! -f nbproject/Makefile-${CONF}.mk ]; \
+ then \
+ exit 1; \
+ fi
+
+
+# help
+.help-impl: .help-pre
+ @echo "This makefile supports the following configurations:"
+ @echo " ${ALLCONFS}"
+ @echo ""
+ @echo "and the following targets:"
+ @echo " build (default target)"
+ @echo " clean"
+ @echo " clobber"
+ @echo " all"
+ @echo " help"
+ @echo ""
+ @echo "Makefile Usage:"
+ @echo " make [CONF=<CONFIGURATION>] [SUB=no] build"
+ @echo " make [CONF=<CONFIGURATION>] [SUB=no] clean"
+ @echo " make [SUB=no] clobber"
+ @echo " make [SUB=no] all"
+ @echo " make help"
+ @echo ""
+ @echo "Target 'build' will build a specific configuration and, unless 'SUB=no',"
+ @echo " also build subprojects."
+ @echo "Target 'clean' will clean a specific configuration and, unless 'SUB=no',"
+ @echo " also clean subprojects."
+ @echo "Target 'clobber' will remove all built files from all configurations and,"
+ @echo " unless 'SUB=no', also from subprojects."
+ @echo "Target 'all' will will build all configurations and, unless 'SUB=no',"
+ @echo " also build subprojects."
+ @echo "Target 'help' prints this message."
+ @echo ""
+
diff --git a/libs/IO/nbproject/Makefile-variables.mk b/libs/IO/nbproject/Makefile-variables.mk
new file mode 100644
index 0000000..56d45ff
--- /dev/null
+++ b/libs/IO/nbproject/Makefile-variables.mk
@@ -0,0 +1,35 @@
+#
+# Generated - do not edit!
+#
+# NOCDDL
+#
+CND_BASEDIR=`pwd`
+CND_BUILDDIR=build
+CND_DISTDIR=dist
+# Debug configuration
+CND_PLATFORM_Debug=GNU-Linux-x86
+CND_ARTIFACT_DIR_Debug=dist/Debug/GNU-Linux-x86
+CND_ARTIFACT_NAME_Debug=libio.a
+CND_ARTIFACT_PATH_Debug=dist/Debug/GNU-Linux-x86/libio.a
+CND_PACKAGE_DIR_Debug=dist/Debug/GNU-Linux-x86/package
+CND_PACKAGE_NAME_Debug=IO.tar
+CND_PACKAGE_PATH_Debug=dist/Debug/GNU-Linux-x86/package/IO.tar
+# Release configuration
+CND_PLATFORM_Release=GNU-Linux-x86
+CND_ARTIFACT_DIR_Release=dist/Release/GNU-Linux-x86
+CND_ARTIFACT_NAME_Release=libio.a
+CND_ARTIFACT_PATH_Release=dist/Release/GNU-Linux-x86/libio.a
+CND_PACKAGE_DIR_Release=dist/Release/GNU-Linux-x86/package
+CND_PACKAGE_NAME_Release=IO.tar
+CND_PACKAGE_PATH_Release=dist/Release/GNU-Linux-x86/package/IO.tar
+#
+# include compiler specific variables
+#
+# dmake command
+ROOT:sh = test -f nbproject/private/Makefile-variables.mk || \
+ (mkdir -p nbproject/private && touch nbproject/private/Makefile-variables.mk)
+#
+# gmake command
+.PHONY: $(shell test -f nbproject/private/Makefile-variables.mk || (mkdir -p nbproject/private && touch nbproject/private/Makefile-variables.mk))
+#
+include nbproject/private/Makefile-variables.mk
diff --git a/libs/IO/nbproject/Package-Debug.bash b/libs/IO/nbproject/Package-Debug.bash
new file mode 100644
index 0000000..d2cdb5c
--- /dev/null
+++ b/libs/IO/nbproject/Package-Debug.bash
@@ -0,0 +1,75 @@
+#!/bin/bash -x
+
+#
+# Generated - do not edit!
+#
+
+# Macros
+TOP=`pwd`
+CND_PLATFORM=GNU-Linux-x86
+CND_CONF=Debug
+CND_DISTDIR=dist
+CND_BUILDDIR=build
+NBTMPDIR=${CND_BUILDDIR}/${CND_CONF}/${CND_PLATFORM}/tmp-packaging
+TMPDIRNAME=tmp-packaging
+OUTPUT_PATH=${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+OUTPUT_BASENAME=libio.a
+PACKAGE_TOP_DIR=IO/
+
+# Functions
+function checkReturnCode
+{
+ rc=$?
+ if [ $rc != 0 ]
+ then
+ exit $rc
+ fi
+}
+function makeDirectory
+# $1 directory path
+# $2 permission (optional)
+{
+ mkdir -p "$1"
+ checkReturnCode
+ if [ "$2" != "" ]
+ then
+ chmod $2 "$1"
+ checkReturnCode
+ fi
+}
+function copyFileToTmpDir
+# $1 from-file path
+# $2 to-file path
+# $3 permission
+{
+ cp "$1" "$2"
+ checkReturnCode
+ if [ "$3" != "" ]
+ then
+ chmod $3 "$2"
+ checkReturnCode
+ fi
+}
+
+# Setup
+cd "${TOP}"
+mkdir -p ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/package
+rm -rf ${NBTMPDIR}
+mkdir -p ${NBTMPDIR}
+
+# Copy files and create directories and links
+cd "${TOP}"
+makeDirectory "${NBTMPDIR}/IO/lib"
+copyFileToTmpDir "${OUTPUT_PATH}" "${NBTMPDIR}/${PACKAGE_TOP_DIR}lib/${OUTPUT_BASENAME}" 0644
+
+
+# Generate tar file
+cd "${TOP}"
+rm -f ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/package/IO.tar
+cd ${NBTMPDIR}
+tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/package/IO.tar *
+checkReturnCode
+
+# Cleanup
+cd "${TOP}"
+rm -rf ${NBTMPDIR}
diff --git a/libs/IO/nbproject/Package-Release.bash b/libs/IO/nbproject/Package-Release.bash
new file mode 100644
index 0000000..13f19f5
--- /dev/null
+++ b/libs/IO/nbproject/Package-Release.bash
@@ -0,0 +1,75 @@
+#!/bin/bash -x
+
+#
+# Generated - do not edit!
+#
+
+# Macros
+TOP=`pwd`
+CND_PLATFORM=GNU-Linux-x86
+CND_CONF=Release
+CND_DISTDIR=dist
+CND_BUILDDIR=build
+NBTMPDIR=${CND_BUILDDIR}/${CND_CONF}/${CND_PLATFORM}/tmp-packaging
+TMPDIRNAME=tmp-packaging
+OUTPUT_PATH=${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libio.a
+OUTPUT_BASENAME=libio.a
+PACKAGE_TOP_DIR=IO/
+
+# Functions
+function checkReturnCode
+{
+ rc=$?
+ if [ $rc != 0 ]
+ then
+ exit $rc
+ fi
+}
+function makeDirectory
+# $1 directory path
+# $2 permission (optional)
+{
+ mkdir -p "$1"
+ checkReturnCode
+ if [ "$2" != "" ]
+ then
+ chmod $2 "$1"
+ checkReturnCode
+ fi
+}
+function copyFileToTmpDir
+# $1 from-file path
+# $2 to-file path
+# $3 permission
+{
+ cp "$1" "$2"
+ checkReturnCode
+ if [ "$3" != "" ]
+ then
+ chmod $3 "$2"
+ checkReturnCode
+ fi
+}
+
+# Setup
+cd "${TOP}"
+mkdir -p ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/package
+rm -rf ${NBTMPDIR}
+mkdir -p ${NBTMPDIR}
+
+# Copy files and create directories and links
+cd "${TOP}"
+makeDirectory "${NBTMPDIR}/IO/lib"
+copyFileToTmpDir "${OUTPUT_PATH}" "${NBTMPDIR}/${PACKAGE_TOP_DIR}lib/${OUTPUT_BASENAME}" 0644
+
+
+# Generate tar file
+cd "${TOP}"
+rm -f ${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/package/IO.tar
+cd ${NBTMPDIR}
+tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/package/IO.tar *
+checkReturnCode
+
+# Cleanup
+cd "${TOP}"
+rm -rf ${NBTMPDIR}
diff --git a/libs/IO/nbproject/configurations.xml b/libs/IO/nbproject/configurations.xml
new file mode 100644
index 0000000..7cc1823
--- /dev/null
+++ b/libs/IO/nbproject/configurations.xml
@@ -0,0 +1,116 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<configurationDescriptor version="84">
+ <logicalFolder name="root" displayName="root" projectFiles="true" kind="ROOT">
+ <logicalFolder name="HeaderFiles"
+ displayName="Header Files"
+ projectFiles="true">
+ <itemPath>include/ConfigReader.h</itemPath>
+ <itemPath>include/File.h</itemPath>
+ <itemPath>include/FileReader.h</itemPath>
+ <itemPath>include/FileRepresentation.h</itemPath>
+ <itemPath>include/FileSystem.h</itemPath>
+ <itemPath>include/LineReader.h</itemPath>
+ </logicalFolder>
+ <logicalFolder name="ResourceFiles"
+ displayName="Resource Files"
+ projectFiles="true">
+ </logicalFolder>
+ <logicalFolder name="SourceFiles"
+ displayName="Source Files"
+ projectFiles="true">
+ <itemPath>src/ConfigReader.cc</itemPath>
+ <itemPath>src/File.cc</itemPath>
+ <itemPath>src/FileReader.cc</itemPath>
+ <itemPath>src/FileRepresentation.cc</itemPath>
+ <itemPath>src/FileSystem.cc</itemPath>
+ <itemPath>src/LineReader.cc</itemPath>
+ </logicalFolder>
+ <logicalFolder name="TestFiles"
+ displayName="Test Files"
+ projectFiles="false"
+ kind="TEST_LOGICAL_FOLDER">
+ </logicalFolder>
+ <logicalFolder name="ExternalFiles"
+ displayName="Important Files"
+ projectFiles="false"
+ kind="IMPORTANT_FILES_FOLDER">
+ <itemPath>Makefile</itemPath>
+ </logicalFolder>
+ </logicalFolder>
+ <projectmakefile>Makefile</projectmakefile>
+ <confs>
+ <conf name="Debug" type="3">
+ <toolsSet>
+ <remote-sources-mode>LOCAL_SOURCES</remote-sources-mode>
+ <compilerSet>default</compilerSet>
+ </toolsSet>
+ <compileType>
+ <ccTool>
+ <incDir>
+ <pElem>include</pElem>
+ <pElem>../util/include</pElem>
+ <pElem>../vdr/include</pElem>
+ </incDir>
+ <commandLine>-std=gnu++0x -fomit-frame-pointer -fPIC -pthread -Wall -Wno-parentheses -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wwrite-strings -Wtype-limits -Wundef -fno-math-errno -fno-signed-zeros -fno-tree-vectorize -Werror=implicit-function-declaration</commandLine>
+ <preprocessorList>
+ <Elem>_FILE_OFFSET_BITS=64</Elem>
+ <Elem>_GNU_SOURCE=1</Elem>
+ <Elem>_LARGEFILE64_SOURCE</Elem>
+ <Elem>_LARGEFILE_SOURCE</Elem>
+ <Elem>_REENTRANT</Elem>
+ <Elem>__STDC_CONSTANT_MACROS</Elem>
+ <Elem>__STDC_FORMAT_MACROS</Elem>
+ <Elem>__STDC_LIMIT_MACROS</Elem>
+ </preprocessorList>
+ <warningLevel>2</warningLevel>
+ </ccTool>
+ <archiverTool>
+ </archiverTool>
+ <requiredProjects>
+ <makeArtifact PL="../vdr"
+ CT="3"
+ CN="Debug"
+ AC="true"
+ BL="true"
+ WD="../vdr"
+ BC="${MAKE} -f Makefile CONF=Debug"
+ CC="${MAKE} -f Makefile CONF=Debug clean"
+ OP="${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libvdr.a">
+ </makeArtifact>
+ <makeArtifact PL="../util"
+ CT="3"
+ CN="Debug"
+ AC="true"
+ BL="true"
+ WD="../util"
+ BC="${MAKE} -f Makefile CONF=Debug"
+ CC="${MAKE} -f Makefile CONF=Debug clean"
+ OP="${CND_DISTDIR}/${CND_CONF}/${CND_PLATFORM}/libutil.a">
+ </makeArtifact>
+ </requiredProjects>
+ </compileType>
+ </conf>
+ <conf name="Release" type="3">
+ <toolsSet>
+ <remote-sources-mode>LOCAL_SOURCES</remote-sources-mode>
+ <compilerSet>default</compilerSet>
+ </toolsSet>
+ <compileType>
+ <cTool>
+ <developmentMode>5</developmentMode>
+ </cTool>
+ <ccTool>
+ <developmentMode>5</developmentMode>
+ </ccTool>
+ <fortranCompilerTool>
+ <developmentMode>5</developmentMode>
+ </fortranCompilerTool>
+ <asmTool>
+ <developmentMode>5</developmentMode>
+ </asmTool>
+ <archiverTool>
+ </archiverTool>
+ </compileType>
+ </conf>
+ </confs>
+</configurationDescriptor>
diff --git a/libs/IO/nbproject/private/Makefile-variables.mk b/libs/IO/nbproject/private/Makefile-variables.mk
new file mode 100644
index 0000000..a64183e
--- /dev/null
+++ b/libs/IO/nbproject/private/Makefile-variables.mk
@@ -0,0 +1,7 @@
+#
+# Generated - do not edit!
+#
+# NOCDDL
+#
+# Debug configuration
+# Release configuration
diff --git a/libs/IO/nbproject/private/configurations.xml b/libs/IO/nbproject/private/configurations.xml
new file mode 100644
index 0000000..616cc91
--- /dev/null
+++ b/libs/IO/nbproject/private/configurations.xml
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<configurationDescriptor version="84">
+ <projectmakefile>Makefile</projectmakefile>
+ <confs>
+ <conf name="Debug" type="3">
+ <toolsSet>
+ <developmentServer>localhost</developmentServer>
+ <platform>2</platform>
+ </toolsSet>
+ <dbx_gdbdebugger version="1">
+ <gdb_pathmaps>
+ </gdb_pathmaps>
+ <gdb_interceptlist>
+ <gdbinterceptoptions gdb_all="false" gdb_unhandled="true" gdb_unexpected="true"/>
+ </gdb_interceptlist>
+ <gdb_options>
+ <DebugOptions>
+ </DebugOptions>
+ </gdb_options>
+ <gdb_buildfirst gdb_buildfirst_overriden="false" gdb_buildfirst_old="false"/>
+ </dbx_gdbdebugger>
+ <nativedebugger version="1">
+ <engine>gdb</engine>
+ </nativedebugger>
+ <runprofile version="9">
+ <runcommandpicklist>
+ <runcommandpicklistitem>"${OUTPUT_PATH}"</runcommandpicklistitem>
+ </runcommandpicklist>
+ <runcommand>"${OUTPUT_PATH}"</runcommand>
+ <rundir></rundir>
+ <buildfirst>true</buildfirst>
+ <terminal-type>0</terminal-type>
+ <remove-instrumentation>0</remove-instrumentation>
+ <environment>
+ </environment>
+ </runprofile>
+ </conf>
+ <conf name="Release" type="3">
+ <toolsSet>
+ <developmentServer>localhost</developmentServer>
+ <platform>2</platform>
+ </toolsSet>
+ <dbx_gdbdebugger version="1">
+ <gdb_pathmaps>
+ </gdb_pathmaps>
+ <gdb_interceptlist>
+ <gdbinterceptoptions gdb_all="false" gdb_unhandled="true" gdb_unexpected="true"/>
+ </gdb_interceptlist>
+ <gdb_options>
+ <DebugOptions>
+ </DebugOptions>
+ </gdb_options>
+ <gdb_buildfirst gdb_buildfirst_overriden="false" gdb_buildfirst_old="false"/>
+ </dbx_gdbdebugger>
+ <nativedebugger version="1">
+ <engine>gdb</engine>
+ </nativedebugger>
+ <runprofile version="9">
+ <runcommandpicklist>
+ <runcommandpicklistitem>"${OUTPUT_PATH}"</runcommandpicklistitem>
+ </runcommandpicklist>
+ <runcommand>"${OUTPUT_PATH}"</runcommand>
+ <rundir></rundir>
+ <buildfirst>true</buildfirst>
+ <terminal-type>0</terminal-type>
+ <remove-instrumentation>0</remove-instrumentation>
+ <environment>
+ </environment>
+ </runprofile>
+ </conf>
+ </confs>
+</configurationDescriptor>
diff --git a/libs/IO/nbproject/private/private.xml b/libs/IO/nbproject/private/private.xml
new file mode 100644
index 0000000..3ef29a3
--- /dev/null
+++ b/libs/IO/nbproject/private/private.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project-private xmlns="http://www.netbeans.org/ns/project-private/1">
+ <data xmlns="http://www.netbeans.org/ns/make-project-private/1">
+ <activeConfTypeElem>3</activeConfTypeElem>
+ <activeConfIndexElem>0</activeConfIndexElem>
+ </data>
+ <editor-bookmarks xmlns="http://www.netbeans.org/ns/editor-bookmarks/2" lastBookmarkId="0"/>
+</project-private>
diff --git a/libs/IO/nbproject/project.xml b/libs/IO/nbproject/project.xml
new file mode 100644
index 0000000..e083e62
--- /dev/null
+++ b/libs/IO/nbproject/project.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://www.netbeans.org/ns/project/1">
+ <type>org.netbeans.modules.cnd.makeproject</type>
+ <configuration>
+ <data xmlns="http://www.netbeans.org/ns/make-project/1">
+ <name>IO</name>
+ <c-extensions/>
+ <cpp-extensions>cc</cpp-extensions>
+ <header-extensions>h</header-extensions>
+ <sourceEncoding>UTF-8</sourceEncoding>
+ <make-dep-projects>
+ <make-dep-project>../vdr</make-dep-project>
+ <make-dep-project>../util</make-dep-project>
+ </make-dep-projects>
+ <sourceRootList/>
+ <confList>
+ <confElem>
+ <name>Debug</name>
+ <type>3</type>
+ </confElem>
+ <confElem>
+ <name>Release</name>
+ <type>3</type>
+ </confElem>
+ </confList>
+ </data>
+ </configuration>
+</project>
diff --git a/libs/IO/summary.txt b/libs/IO/summary.txt
new file mode 100644
index 0000000..543fe28
--- /dev/null
+++ b/libs/IO/summary.txt
@@ -0,0 +1 @@
+libIO: classes for files, filesystem and input/output