This file is indexed.

/usr/include/ossim/projection/ossimWktProjectionFactory.h is in libossim-dev 2.2.2-1.

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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
//*******************************************************************
//
// License:  See top level LICENSE.txt file.
// 
// Author:  Oscar Kramer
//
//*******************************************************************
//  $Id: ossimWktProjectionFactory.h 22924 2014-10-27 16:32:58Z okramer $

#ifndef ossimWktProjectionFactory_HEADER
#define ossimWktProjectionFactory_HEADER

#include <ossim/projection/ossimProjectionFactoryBase.h>
#include <ossim/base/ossimFilename.h>
#include <ossim/base/ossimRefPtr.h>

class ossimProjection;
class ossimString;
class ossimMapProjection;
class ossimDatum;

//*************************************************************************************************
//! Projection Factory for coded projections defined in database. These are projections
//! that are fully defined in database files and specified via a projection coordinate system (PCS)
//! code, such as EPSG codes.
//*************************************************************************************************
class OSSIMDLLEXPORT ossimWktProjectionFactory : public ossimProjectionFactoryBase
{
public:
   /*!
    * METHOD: instance()
    * Instantiates singleton instance of this class:
    */
   static ossimWktProjectionFactory* instance();

   virtual ossimProjection* createProjection(const ossimFilename& filename,
                                             ossim_uint32 entryIdx) const;

   //! This is the principal factory method. It accepts a WKT string, for example 
   //! "Anguilla_1957_British_West_Indies_Grid"
   virtual ossimProjection* createProjection(const ossimString& name) const;

   virtual ossim_uint32 getCode(const ossimString& name);

   //! Looks for presence of "projection" keyword with the value in WKT format,
   //! for example "Anguilla_1957_British_West_Indies_Grid" 
   virtual ossimProjection* createProjection(const ossimKeywordlist& kwl,
                                             const char* prefix = 0)const;

   virtual ossimObject* createObject(const ossimString& typeName)const;
   virtual ossimObject* createObject(const ossimKeywordlist& kwl, const char* prefix=0)const;
   
    //! This returns the type name of all objects in all factories. This is the name used to 
    //! construct the objects dynamically and this name must be unique.
   virtual void getTypeNameList(std::vector<ossimString>& typeList) const;

protected:

   //! Constructor loads the WKT CSV file specified in the ossim prefs with "wkt_database_file"
   //! keyword.
   ossimWktProjectionFactory() {}

   ossimProjection* doTransverseMercator(const ossimKeywordlist& kwl)const;
   ossimProjection* doMercator(const ossimKeywordlist& kwl)const;
   ossimProjection* doLambertConformalConic(const ossimKeywordlist& kwl) const;
   ossimProjection* doEquiDistCylindrical(const ossimKeywordlist& kwl) const;
   ossimProjection* doEquiAreaCylindrical(const ossimKeywordlist& kwl) const;

   void loadRecords() const;

   template<class T> void doMapCommon(const ossimKeywordlist& kwl, T proj) const;

   static ossimWktProjectionFactory*  m_instance; //!< Singleton implementation
   mutable std::map<std::string, ossim_uint32> m_wktProjRecords;

};

#endif