This file is indexed.

/usr/include/scim-1.0/scim_iconv.h is in libscim-dev 1.4.15-6.

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
/** @file scim_iconv.h
 *  @brief definition of IConvert related classes.
 */

/* 
 * Smart Common Input Method
 * 
 * Copyright (c) 2002-2005 James Su <suzhe@tsinghua.org.cn>
 *
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this program; if not, write to the
 * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
 * Boston, MA  02111-1307  USA
 *
 * $Id: scim_iconv.h,v 1.18 2005/08/15 12:45:46 suzhe Exp $
 */

#ifndef __SCIM_ICONVERT_H
#define __SCIM_ICONVERT_H

namespace scim {

/**
 * @addtogroup Accessories
 * @{
 */

#define SCIM_MAX_BUFSIZE    4096

/**
 * @brief A class to convert strings between UCS-4 and local encodings.
 */
class IConvert
{
    class IConvertImpl;

    IConvertImpl * m_impl;

public:
    /**
     * @brief Constructor
     * @param encoding the local encoding to be used.
     */
    IConvert (const String& encoding = String ());

    /**
     * @brief Copy constructor
     */
    IConvert (const IConvert & iconvert);

    ~IConvert ();

    /**
     * @brief Assign operator
     */
    const IConvert & operator = (const IConvert & iconvert);

    /**
     * @brief Set the working local encoding.
     * @param encoding the local encoding to be used.
     * @return whether the encoding is ok or not.
     */
    bool set_encoding (const String& encoding);

    /**
     * @brief Get the current working local encoding. 
     * @return The name of the local encoding, like "UTF-8", "GB2312" etc.
     */
    String get_encoding () const;

    /**
     * @brief Convert a UCS-4 encoded WideString into a local encoded String.
     * @param dest the result string will be stored here.
     * @param src the WideString to be converted.
     * @return true if success.
     */
    bool convert (String &dest, const WideString &src) const;

    /**
     * @brief Convert a UCS-4 encoded WideString into a local encoded String.
     * @param dest the result string will be stored here.
     * @param src the ucs-4 encoded string to be converted.
     * @param src_len the length of source string.
     * @return true if success.
     */
    bool convert (String &dest, const ucs4_t *src, int src_len) const;

    /**
     * @brief Convert a local encoded String into a UCS-4 encoded WideString.
     * @param dest the result string will be stored here.
     * @param src the local encoded string to be converted.
     * @return ture if success.
     */
    bool convert (WideString &dest, const String &src) const;

    /**
     * @brief Convert a local encoded String into a UCS-4 encoded WideString.
     * @param dest the result string will be stored here.
     * @param src the local encoded string to be converted.
     * @param src_len the length of source string.
     * @return ture if success.
     */
    bool convert (WideString &dest, const char *src, int src_len) const;

    /**
     * @brief Test if a UCS-4 encoded WideString can be converted to a local encoded String.
     * @param src the ucs-4 encoded string to be test.
     * @return true if it can be converted without any problem.
     */
    bool test_convert (const WideString &src) const;

    /**
     * @brief Test if a ucs-4 encoded string can be converted to a local encoded String.
     * @param src the ucs-4 encoded string to be test.
     * @param src_len the length of source string.
     * @return true if it can be converted without any problem.
     */
    bool test_convert (const ucs4_t *src, int src_len) const;

    /**
     * @brief Test if a local encoded string can be converted to a UCS-4 encoded WideString.
     * @param src the local encoded string to be test.
     * @return true if it can be converted without any problem.
     */
    bool test_convert (const String &src) const;

    /**
     * @brief Test if a local encoded string can be converted to a UCS-4 encoded WideString.
     * @param src the local encoded string to be test.
     * @param src_len the length of source string.
     * @return true if it can be converted without any problem.
     */
    bool test_convert (const char *src, int src_len) const;
};

/** @} */

} // namespace scim

#endif //__SCIM_ICONVERT_H

/*
vi:ts=4:nowrap:ai:expandtab
*/