This file is indexed.

/usr/lib/Wt/examples/wt-homepage/ExampleSourceViewer.h is in witty-examples 3.3.0-1build1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
// This may look like C code, but it's really -*- C++ -*-
/*
 * Copyright (C) 2009 Emweb bvba 
 *
 * See the LICENSE file for terms of use.
 */

#include <iostream>
#include <stdlib.h>

#include <Wt/WContainerWidget>
#include <Wt/WTreeView>
#include <Wt/WStandardItemModel>

#include "FileItem.h"
#include "SourceView.h"

/*! \class ExampleSourceViewer 
 *  \brief A simple widget to visualise a set of example source files.
 */
class ExampleSourceViewer: public Wt::WContainerWidget
{
public:
  /*! \brief Constructor.
   */
  ExampleSourceViewer(const std::string& deployPath,
		      const std::string& examplesRoot,
		      const std::string& examplesType); 

private:
  Wt::WTreeView  *exampleView_;
  SourceView *sourceView_;

  std::string deployPath_;
  std::string examplesRoot_;
  std::string examplesType_;

  Wt::WStandardItemModel *model_;

  void cppTraverseDir(Wt::WStandardItem* parent, 
		      const boost::filesystem::path& path);
  void javaTraverseDir(Wt::WStandardItem* parent, 
		       const boost::filesystem::path& path);
  void javaTraversePackages(Wt::WStandardItem *parent,
			    const boost::filesystem::path& srcPath,
			    const std::string packageName);

  /*! \brief Displayed the currently selected file.
   */
  void showFile(); 

  void handlePathChange();

  void setExample(const std::string& exampleDir,
		  const std::string& example);
};