This file is indexed.

/usr/include/libkdeedu/keduvoctext.h is in libkdeedu-dev 4:15.12.3-0ubuntu1.

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
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
/***************************************************************************
    Copyright 2007-2008 Frederik Gladhorn <frederik.gladhorn@kdemail.net>
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#ifndef KEDUVOCTEXT_H
#define KEDUVOCTEXT_H

#include "libkeduvocdocument_export.h"
#include <QtCore/QDateTime>


#define KV_MAX_GRADE       7
#define KV_MIN_GRADE       0

#define KV_NORM_GRADE      0       // not practiced yet
#define KV_NORM_TEXT       I18N_NOOP("Not Practiced Yet")

#define KV_LEV1_GRADE      1
#define KV_LEV1_TEXT       I18N_NOOP("Level 1")

#define KV_LEV2_GRADE      2
#define KV_LEV2_TEXT       I18N_NOOP("Level 2")

#define KV_LEV3_GRADE      3
#define KV_LEV3_TEXT       I18N_NOOP("Level 3")

#define KV_LEV4_GRADE      4
#define KV_LEV4_TEXT       I18N_NOOP("Level 4")

#define KV_LEV5_GRADE      5
#define KV_LEV5_TEXT       I18N_NOOP("Level 5")

#define KV_LEV6_GRADE      6
#define KV_LEV6_TEXT       I18N_NOOP("Level 6")

#define KV_LEV7_GRADE      7
#define KV_LEV7_TEXT       I18N_NOOP("Level 7")


typedef unsigned short grade_t;
typedef unsigned short count_t;

class QDomElement;

/**
 * A text in vocabulary documents. Associated with it are grade and date information.
 * This should be used instead of strings for all things that can be tested and thus get a grade.
 @author Frederik Gladhorn <frederik.gladhorn@kdemail.net>
*/
class KEDUVOCDOCUMENT_EXPORT KEduVocText
{
public:
    /** default constructor */
    KEduVocText(const QString& text = QString());

    /** copy constructor
     * provides safe copy of d pointer
     * @param other object to copy from
     */
    KEduVocText( const KEduVocText &other );

    /** default destructor */
    ~KEduVocText();

    /**
     * The translation as string (the word itself)
     * @return the translation
     */
    QString text() const;

    /**
     * Sets the translation
     * @param expr
     */
    void setText( const QString & expr );

    /**
     * Equal operator to copy grades.
     * @param other grades copied
     * @return reference to the new grades
     */
    KEduVocText& operator= ( const KEduVocText &other );
    /**
     * Compare two sets of grades.
     * @param other
     * @return true if equal
     */
    bool operator== ( const KEduVocText &other ) const;


    /** returns how often this entry has been practiced as int
    * @returns total count
    */
    count_t practiceCount() const;

    /** set how often this entry has been practiced as int
    * @param count the new count
    */
    void setPracticeCount( count_t count );

    /** returns bad query count as int
    * @returns bad query count
    */
    count_t badCount() const;

    /** set bad query count as int
    * @param count the new count
    */
    void setBadCount( count_t count );

    /** increment bad query count of given translation by 1 */
    void incBadCount();

    /** increment query count of given translation by 1 */
    void incPracticeCount();

    /**
     * Clears grading and date information.
     */
    void resetGrades();

    /** sets the pregrade
    * @param grade number of knowlegde: 0=known, x=numbers not knows
    */
    void setPreGrade( grade_t grade );

    /** returns pregrade
    */
    grade_t preGrade() const;

    /** sets the grade
    * @param grade number of knowlegde: 0=known, x=numbers not knows
    */
    void setGrade( grade_t grade );

    /** returns grade as int
    * @returns number of knowlegde: 0=known, x=numbers not knows
    */
    grade_t grade() const;

    /** increments grade */
    void incGrade();

    /** decrements grade */
    void decGrade();

    /** returns last practice date as int
    */
    QDateTime practiceDate() const;

    /** Set last query date
    * @param date             the new date
    */
    void setPracticeDate( const QDateTime & date );

    /** returns interval until next practice is due
    */
    quint32 interval() const;

    /** Set interval until next practice is due.
    * @param interval   the new interval
    */
    void setInterval( quint32 interval );

    /**
     * If the string inside is empty this returns true.
     * @return 
     */
    bool isEmpty();

    void fromKVTML2(QDomElement& parent);
    void toKVTML2(QDomElement& parent);

private:
    class KEduVocTextPrivate;
    KEduVocTextPrivate * const d;
};

#endif