Wt examples  4.9.1
Loading...
Searching...
No Matches
FileTreeTableNode.h
Go to the documentation of this file.
1// This may look like C code, but it's really -*- C++ -*-
2/*
3 * Copyright (C) 2008 Emweb bv, Herent, Belgium.
4 *
5 * See the LICENSE file for terms of use.
6 */
7#ifndef FILETREETABLENODE_H_
8#define FILETREETABLENODE_H_
9
10#include <Wt/WTreeTableNode.h>
11
12#include <boost/filesystem/path.hpp>
13
14using namespace Wt;
15
20
30class FileTreeTableNode : public WTreeTableNode
31{
32public:
35 FileTreeTableNode(const boost::filesystem::path& path);
36
37private:
39 boost::filesystem::path path_;
40
42 virtual void populate() override;
43
45 virtual bool expandable() override;
46
48 static std::unique_ptr<WIconPair> createIcon(const boost::filesystem::path& path);
49};
50
53#endif // FILETREETABLENODE_H_
A single node in a file tree table.
boost::filesystem::path path_
The path.
static std::unique_ptr< WIconPair > createIcon(const boost::filesystem::path &path)
Create the iconpair for representing the path.
virtual bool expandable() override
Reimplements WTreeNode::expandable.
virtual void populate() override
Reimplements WTreeNode::populate to read files within a directory.