diff --git a/AUTHORS b/AUTHORS deleted file mode 100644 index 1a00104..0000000 --- a/AUTHORS +++ /dev/null @@ -1 +0,0 @@ -Naoaki Okazaki diff --git a/COPYING b/COPYING deleted file mode 100644 index 9611fc3..0000000 --- a/COPYING +++ /dev/null @@ -1,27 +0,0 @@ -The BSD license. - -Copyright (c) 2009,2010 Naoaki Okazaki -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - * Neither the names of the authors nor the names of its contributors - may be used to endorse or promote products derived from this - software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER -OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, -EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/ChangeLog b/ChangeLog deleted file mode 100644 index 06fd3ea..0000000 --- a/ChangeLog +++ /dev/null @@ -1,11 +0,0 @@ -2011-02-xx Naoaki Okazaki - - * SimString 1.1: - - Implemented check() member function. - - -2010-03-07 Naoaki Okazaki - - * SimString 1.0: - - Initial release. - diff --git a/Makefile.am b/Makefile.am deleted file mode 100644 index 7f1da37..0000000 --- a/Makefile.am +++ /dev/null @@ -1,14 +0,0 @@ -# $Id$ - -SUBDIRS = include frontend sample swig - -docdir = $(prefix)/share/doc/@PACKAGE@ -doc_DATA = README INSTALL COPYING AUTHORS ChangeLog - -EXTRA_DIST = \ - autogen.sh \ - win32/stdint.h \ - simstring.sln - -#AUTOMAKE_OPTIONS = foreign -#ACLOCAL_AMFLAGS = -I m4 diff --git a/NEWS b/NEWS deleted file mode 100644 index e69de29..0000000 diff --git a/README b/README deleted file mode 100644 index e93c3d2..0000000 --- a/README +++ /dev/null @@ -1,81 +0,0 @@ - SimString - Version 1.1 - http://www.chokkan.org/software/simstring/ - - - -* INTRODUCTION -SimString is an implementation of a simple and efficient algorithm -for approximate string matching. Please refer to the web site for -more information about this software. - - - -* COPYRIGHT AND LICENSING INFORMATION - -This program is distributed under the modified BSD license. Refer to -COPYING file for the precise description of the license. - - -Portions of this software are based on CDB++. - -The MIT License - -Copyright (c) 2008,2009, Naoaki Okazaki -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - * Neither the name of the authors nor the names of its contributors may - be used to endorse or promote products derived from this software - without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER -OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, -EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - -Portions of this software are based on a portable stdint.h (for MSVC). - -Copyright (c) 2005-2007 Paul Hsieh - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions -are met: - - Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - Redistributions in binary form must not misrepresent the orignal - source in the documentation and/or other materials provided - with the distribution. - - The names of the authors nor its contributors may be used to - endorse or promote products derived from this software without - specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS -FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE -COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED -OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..a0ffcf4 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# SimString Python Package + +Orginal version by [chokkan](), available [here](https://github.com/chokkan/simstring). New version (compiles under macOS) from [here](https://github.com/blinkhealth/simstring-python-package). diff --git a/autogen.sh b/autogen.sh deleted file mode 100755 index 810e46f..0000000 --- a/autogen.sh +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -# $Id$ - -if [ "$1" = "--force" ]; -then - FORCE=--force - NOFORCE= - FORCE_MISSING=--force-missing -else - FORCE= - NOFORCE=--no-force - FORCE_MISSING= -fi - -#libtoolize --copy $FORCE 2>&1 | sed '/^You should/d' || { -# echo "libtoolize failed!" -# exit 1 -#} - -aclocal $FORCE || { - echo "aclocal failed!" - exit 1 -} - -autoheader $FORCE || { - echo "autoheader failed!" - exit 1 -} - -automake -a -c $NOFORCE || { - echo "automake failed!" - exit 1 -} - -autoconf $FORCE || { - echo "autoconf failed!" - exit 1 -} diff --git a/configure.in b/configure.in deleted file mode 100644 index 1ff6c7c..0000000 --- a/configure.in +++ /dev/null @@ -1,116 +0,0 @@ -dnl $Id: configure.in 102 2009-06-23 15:50:57Z naoaki $ -dnl -dnl -dnl Exported and configured variables: -dnl CXXFLAGS -dnl LDFLAGS -dnl INCLUDES - - -dnl ------------------------------------------------------------------ -dnl Initialization for autoconf -dnl ------------------------------------------------------------------ -AC_PREREQ(2.59) -AC_INIT -AC_CONFIG_SRCDIR([frontend/main.cpp]) - - -dnl ------------------------------------------------------------------ -dnl Checks for system -dnl ------------------------------------------------------------------ -AC_CANONICAL_HOST -AC_AIX -AC_GNU_SOURCE -AC_ISC_POSIX -AC_MINIX - - -dnl ------------------------------------------------------------------ -dnl Initialization for automake -dnl ------------------------------------------------------------------ -AM_INIT_AUTOMAKE(simstring, 1.1) -AC_CONFIG_HEADERS(config.h) -AM_MAINTAINER_MODE - - -dnl ------------------------------------------------------------------ -dnl Checks for program -dnl ------------------------------------------------------------------ -AC_PROG_CXX -AC_PROG_INSTALL -AC_PROG_LN_S - - -dnl ------------------------------------------------------------------ -dnl Initialization for variables -dnl ------------------------------------------------------------------ -CXXFLAGS="${ac_save_CXXFLAGS}" -LDFLAGS="${ac_save_LDFLAGS}" -INCLUDES="${ac_save_INCLUDES}" - -dnl ------------------------------------------------------------------ -dnl Checks for header files. -dnl ------------------------------------------------------------------ -AC_HEADER_STDC -AC_CHECK_HEADERS(stdint.h) -AC_CHECK_HEADERS(sys/mman.h) - - -dnl ------------------------------------------------------------------ -dnl Checks for typedefs, structures, and compiler characteristics. -dnl ------------------------------------------------------------------ -AC_C_CONST -AC_CHECK_SIZEOF -AC_TYPE_SIZE_T -AC_STRUCT_TM -AC_CHECK_TYPES([uint32_t]) - -dnl ------------------------------------------------------------------ -dnl Checks for debugging mode -dnl ------------------------------------------------------------------ -AC_ARG_ENABLE( - debug, - [AS_HELP_STRING([--enable-debug],[Turn on debugging])] -) - -if test "x$enable_debug" = "xyes"; then - CXXFLAGS="-DDEBUG -O -g ${CXXFLAGS}" -else - CXXFLAGS="-O3 ${CXXFLAGS}" -fi - -dnl ------------------------------------------------------------------ -dnl Checks for profiling mode -dnl ------------------------------------------------------------------ -AC_ARG_ENABLE( - profile, - [AS_HELP_STRING([--enable-profile],[Turn on profiling])] -) - -if test "x$enable_profile" = "xyes"; then - CXXFLAGS="-DPROFILE -pg ${CXXFLAGS}" -fi - - -dnl ------------------------------------------------------------------ -dnl Checks for library functions. -dnl ------------------------------------------------------------------ - -dnl Check for math library -AC_CHECK_LIB(m, sqrt) -AC_CHECK_LIB(mmap, mmap) - -INCLUDES="-I\$(top_srcdir) -I\$(top_srcdir)/include" - -dnl ------------------------------------------------------------------ -dnl Export variables -dnl ------------------------------------------------------------------ -AC_SUBST(CXXFLAGS) -AC_SUBST(LDFLAGS) -AC_SUBST(INCLUDES) - -dnl ------------------------------------------------------------------ -dnl Output the configure results. -dnl ------------------------------------------------------------------ -AC_CONFIG_FILES(Makefile include/Makefile frontend/Makefile sample/Makefile swig/Makefile swig/python/setup.py swig/ruby/extconf.rb swig/perl/Makefile.PL) -AC_OUTPUT diff --git a/doc/doxyfile b/doc/doxyfile deleted file mode 100644 index 1bb9148..0000000 --- a/doc/doxyfile +++ /dev/null @@ -1,1252 +0,0 @@ -# Doxyfile 1.5.1 - -# This file describes the settings to be used by the documentation system -# doxygen (www.doxygen.org) for a project -# -# All text after a hash (#) is considered a comment and will be ignored -# The format is: -# TAG = value [value, ...] -# For lists items can also be appended using: -# TAG += value [value, ...] -# Values that contain spaces should be placed between quotes (" ") - -#--------------------------------------------------------------------------- -# Project related configuration options -#--------------------------------------------------------------------------- - -# The PROJECT_NAME tag is a single word (or a sequence of words surrounded -# by quotes) that should identify the project. - -PROJECT_NAME = SimString - -# The PROJECT_NUMBER tag can be used to enter a project or revision number. -# This could be handy for archiving the generated documentation or -# if some version control system is used. - -PROJECT_NUMBER = - -# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) -# base path where the generated documentation will be put. -# If a relative path is entered, it will be relative to the location -# where doxygen was started. If left blank the current directory will be used. - -OUTPUT_DIRECTORY = - -# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create -# 4096 sub-directories (in 2 levels) under the output directory of each output -# format and will distribute the generated files over these directories. -# Enabling this option can be useful when feeding doxygen a huge amount of -# source files, where putting all generated files in the same directory would -# otherwise cause performance problems for the file system. - -CREATE_SUBDIRS = NO - -# The OUTPUT_LANGUAGE tag is used to specify the language in which all -# documentation generated by doxygen is written. Doxygen will use this -# information to generate all constant output in the proper language. -# The default language is English, other supported languages are: -# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional, -# Croatian, Czech, Danish, Dutch, Finnish, French, German, Greek, Hungarian, -# Italian, Japanese, Japanese-en (Japanese with English messages), Korean, -# Korean-en, Lithuanian, Norwegian, Polish, Portuguese, Romanian, Russian, -# Serbian, Slovak, Slovene, Spanish, Swedish, and Ukrainian. - -OUTPUT_LANGUAGE = English - -# This tag can be used to specify the encoding used in the generated output. -# The encoding is not always determined by the language that is chosen, -# but also whether or not the output is meant for Windows or non-Windows users. -# In case there is a difference, setting the USE_WINDOWS_ENCODING tag to YES -# forces the Windows encoding (this is the default for the Windows binary), -# whereas setting the tag to NO uses a Unix-style encoding (the default for -# all platforms other than Windows). - -USE_WINDOWS_ENCODING = YES - -# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will -# include brief member descriptions after the members that are listed in -# the file and class documentation (similar to JavaDoc). -# Set to NO to disable this. - -BRIEF_MEMBER_DESC = YES - -# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend -# the brief description of a member or function before the detailed description. -# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the -# brief descriptions will be completely suppressed. - -REPEAT_BRIEF = YES - -# This tag implements a quasi-intelligent brief description abbreviator -# that is used to form the text in various listings. Each string -# in this list, if found as the leading text of the brief description, will be -# stripped from the text and the result after processing the whole list, is -# used as the annotated text. Otherwise, the brief description is used as-is. -# If left blank, the following values are used ("$name" is automatically -# replaced with the name of the entity): "The $name class" "The $name widget" -# "The $name file" "is" "provides" "specifies" "contains" -# "represents" "a" "an" "the" - -ABBREVIATE_BRIEF = - -# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then -# Doxygen will generate a detailed section even if there is only a brief -# description. - -ALWAYS_DETAILED_SEC = NO - -# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all -# inherited members of a class in the documentation of that class as if those -# members were ordinary class members. Constructors, destructors and assignment -# operators of the base classes will not be shown. - -INLINE_INHERITED_MEMB = NO - -# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full -# path before files name in the file list and in the header files. If set -# to NO the shortest path that makes the file name unique will be used. - -FULL_PATH_NAMES = NO - -# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag -# can be used to strip a user-defined part of the path. Stripping is -# only done if one of the specified strings matches the left-hand part of -# the path. The tag can be used to show relative paths in the file list. -# If left blank the directory from which doxygen is run is used as the -# path to strip. - -STRIP_FROM_PATH = - -# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of -# the path mentioned in the documentation of a class, which tells -# the reader which header file to include in order to use a class. -# If left blank only the name of the header file containing the class -# definition is used. Otherwise one should specify the include paths that -# are normally passed to the compiler using the -I flag. - -STRIP_FROM_INC_PATH = - -# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter -# (but less readable) file names. This can be useful is your file systems -# doesn't support long names like on DOS, Mac, or CD-ROM. - -SHORT_NAMES = NO - -# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen -# will interpret the first line (until the first dot) of a JavaDoc-style -# comment as the brief description. If set to NO, the JavaDoc -# comments will behave just like the Qt-style comments (thus requiring an -# explicit @brief command for a brief description. - -JAVADOC_AUTOBRIEF = YES - -# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen -# treat a multi-line C++ special comment block (i.e. a block of //! or /// -# comments) as a brief description. This used to be the default behaviour. -# The new default is to treat a multi-line C++ comment block as a detailed -# description. Set this tag to YES if you prefer the old behaviour instead. - -MULTILINE_CPP_IS_BRIEF = NO - -# If the DETAILS_AT_TOP tag is set to YES then Doxygen -# will output the detailed description near the top, like JavaDoc. -# If set to NO, the detailed description appears after the member -# documentation. - -DETAILS_AT_TOP = YES - -# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented -# member inherits the documentation from any documented member that it -# re-implements. - -INHERIT_DOCS = NO - -# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce -# a new page for each member. If set to NO, the documentation of a member will -# be part of the file/class/namespace that contains it. - -SEPARATE_MEMBER_PAGES = NO - -# The TAB_SIZE tag can be used to set the number of spaces in a tab. -# Doxygen uses this value to replace tabs by spaces in code fragments. - -TAB_SIZE = 4 - -# This tag can be used to specify a number of aliases that acts -# as commands in the documentation. An alias has the form "name=value". -# For example adding "sideeffect=\par Side Effects:\n" will allow you to -# put the command \sideeffect (or @sideeffect) in the documentation, which -# will result in a user-defined paragraph with heading "Side Effects:". -# You can put \n's in the value part of an alias to insert newlines. - -ALIASES = - -# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C -# sources only. Doxygen will then generate output that is more tailored for C. -# For instance, some of the names that are used will be different. The list -# of all members will be omitted, etc. - -OPTIMIZE_OUTPUT_FOR_C = YES - -# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java -# sources only. Doxygen will then generate output that is more tailored for Java. -# For instance, namespaces will be presented as packages, qualified scopes -# will look different, etc. - -OPTIMIZE_OUTPUT_JAVA = NO - -# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want to -# include (a tag file for) the STL sources as input, then you should -# set this tag to YES in order to let doxygen match functions declarations and -# definitions whose arguments contain STL classes (e.g. func(std::string); v.s. -# func(std::string) {}). This also make the inheritance and collaboration -# diagrams that involve STL classes more complete and accurate. - -BUILTIN_STL_SUPPORT = NO - -# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC -# tag is set to YES, then doxygen will reuse the documentation of the first -# member in the group (if any) for the other members of the group. By default -# all members of a group must be documented explicitly. - -DISTRIBUTE_GROUP_DOC = NO - -# Set the SUBGROUPING tag to YES (the default) to allow class member groups of -# the same type (for instance a group of public functions) to be put as a -# subgroup of that type (e.g. under the Public Functions section). Set it to -# NO to prevent subgrouping. Alternatively, this can be done per class using -# the \nosubgrouping command. - -SUBGROUPING = YES - -#--------------------------------------------------------------------------- -# Build related configuration options -#--------------------------------------------------------------------------- - -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. -# Private class members and static file members will be hidden unless -# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES - -EXTRACT_ALL = NO - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class -# will be included in the documentation. - -EXTRACT_PRIVATE = NO - -# If the EXTRACT_STATIC tag is set to YES all static members of a file -# will be included in the documentation. - -EXTRACT_STATIC = NO - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) -# defined locally in source files will be included in the documentation. -# If set to NO only classes defined in header files are included. - -EXTRACT_LOCAL_CLASSES = YES - -# This flag is only useful for Objective-C code. When set to YES local -# methods, which are defined in the implementation section but not in -# the interface are included in the documentation. -# If set to NO (the default) only methods in the interface are included. - -EXTRACT_LOCAL_METHODS = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all -# undocumented members of documented classes, files or namespaces. -# If set to NO (the default) these members will be included in the -# various overviews, but no documentation section is generated. -# This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_MEMBERS = YES - -# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. -# If set to NO (the default) these classes will be included in the various -# overviews. This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_CLASSES = YES - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all -# friend (class|struct|union) declarations. -# If set to NO (the default) these declarations will be included in the -# documentation. - -HIDE_FRIEND_COMPOUNDS = YES - -# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any -# documentation blocks found inside the body of a function. -# If set to NO (the default) these blocks will be appended to the -# function's detailed documentation block. - -HIDE_IN_BODY_DOCS = NO - -# The INTERNAL_DOCS tag determines if documentation -# that is typed after a \internal command is included. If the tag is set -# to NO (the default) then the documentation will be excluded. -# Set it to YES to include the internal documentation. - -INTERNAL_DOCS = NO - -# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate -# file names in lower-case letters. If set to YES upper-case letters are also -# allowed. This is useful if you have classes or files whose names only differ -# in case and if your file system supports case sensitive file names. Windows -# and Mac users are advised to set this option to NO. - -CASE_SENSE_NAMES = YES - -# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen -# will show members with their full class and namespace scopes in the -# documentation. If set to YES the scope will be hidden. - -HIDE_SCOPE_NAMES = NO - -# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen -# will put a list of the files that are included by a file in the documentation -# of that file. - -SHOW_INCLUDE_FILES = NO - -# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] -# is inserted in the documentation for inline members. - -INLINE_INFO = YES - -# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen -# will sort the (detailed) documentation of file and class members -# alphabetically by member name. If set to NO the members will appear in -# declaration order. - -SORT_MEMBER_DOCS = YES - -# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the -# brief documentation of file, namespace and class members alphabetically -# by member name. If set to NO (the default) the members will appear in -# declaration order. - -SORT_BRIEF_DOCS = NO - -# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be -# sorted by fully-qualified names, including namespaces. If set to -# NO (the default), the class list will be sorted only by class name, -# not including the namespace part. -# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. -# Note: This option applies only to the class list, not to the -# alphabetical list. - -SORT_BY_SCOPE_NAME = NO - -# The GENERATE_TODOLIST tag can be used to enable (YES) or -# disable (NO) the todo list. This list is created by putting \todo -# commands in the documentation. - -GENERATE_TODOLIST = YES - -# The GENERATE_TESTLIST tag can be used to enable (YES) or -# disable (NO) the test list. This list is created by putting \test -# commands in the documentation. - -GENERATE_TESTLIST = YES - -# The GENERATE_BUGLIST tag can be used to enable (YES) or -# disable (NO) the bug list. This list is created by putting \bug -# commands in the documentation. - -GENERATE_BUGLIST = YES - -# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or -# disable (NO) the deprecated list. This list is created by putting -# \deprecated commands in the documentation. - -GENERATE_DEPRECATEDLIST= YES - -# The ENABLED_SECTIONS tag can be used to enable conditional -# documentation sections, marked by \if sectionname ... \endif. - -ENABLED_SECTIONS = - -# The MAX_INITIALIZER_LINES tag determines the maximum number of lines -# the initial value of a variable or define consists of for it to appear in -# the documentation. If the initializer consists of more lines than specified -# here it will be hidden. Use a value of 0 to hide initializers completely. -# The appearance of the initializer of individual variables and defines in the -# documentation can be controlled using \showinitializer or \hideinitializer -# command in the documentation regardless of this setting. - -MAX_INITIALIZER_LINES = 30 - -# Set the SHOW_USED_FILES tag to NO to disable the list of files generated -# at the bottom of the documentation of classes and structs. If set to YES the -# list will mention the files that were used to generate the documentation. - -SHOW_USED_FILES = NO - -# If the sources in your project are distributed over multiple directories -# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy -# in the documentation. The default is NO. - -SHOW_DIRECTORIES = NO - -# The FILE_VERSION_FILTER tag can be used to specify a program or script that -# doxygen should invoke to get the current version for each file (typically from the -# version control system). Doxygen will invoke the program by executing (via -# popen()) the command , where is the value of -# the FILE_VERSION_FILTER tag, and is the name of an input file -# provided by doxygen. Whatever the program writes to standard output -# is used as the file version. See the manual for examples. - -FILE_VERSION_FILTER = - -#--------------------------------------------------------------------------- -# configuration options related to warning and progress messages -#--------------------------------------------------------------------------- - -# The QUIET tag can be used to turn on/off the messages that are generated -# by doxygen. Possible values are YES and NO. If left blank NO is used. - -QUIET = NO - -# The WARNINGS tag can be used to turn on/off the warning messages that are -# generated by doxygen. Possible values are YES and NO. If left blank -# NO is used. - -WARNINGS = YES - -# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings -# for undocumented members. If EXTRACT_ALL is set to YES then this flag will -# automatically be disabled. - -WARN_IF_UNDOCUMENTED = YES - -# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for -# potential errors in the documentation, such as not documenting some -# parameters in a documented function, or documenting parameters that -# don't exist or using markup commands wrongly. - -WARN_IF_DOC_ERROR = YES - -# This WARN_NO_PARAMDOC option can be abled to get warnings for -# functions that are documented, but have no documentation for their parameters -# or return value. If set to NO (the default) doxygen will only warn about -# wrong or incomplete parameter documentation, but not about the absence of -# documentation. - -WARN_NO_PARAMDOC = NO - -# The WARN_FORMAT tag determines the format of the warning messages that -# doxygen can produce. The string should contain the $file, $line, and $text -# tags, which will be replaced by the file and line number from which the -# warning originated and the warning text. Optionally the format may contain -# $version, which will be replaced by the version of the file (if it could -# be obtained via FILE_VERSION_FILTER) - -WARN_FORMAT = "$file:$line: $text" - -# The WARN_LOGFILE tag can be used to specify a file to which warning -# and error messages should be written. If left blank the output is written -# to stderr. - -WARN_LOGFILE = - -#--------------------------------------------------------------------------- -# configuration options related to the input files -#--------------------------------------------------------------------------- - -# The INPUT tag can be used to specify the files and/or directories that contain -# documented source files. You may enter file names like "myfile.cpp" or -# directories like "/usr/src/myproject". Separate the files or directories -# with spaces. - -INPUT = ../include/simstring/simstring.h ../include/simstring/measure.h - -# If the value of the INPUT tag contains directories, you can use the -# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank the following patterns are tested: -# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx -# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py - -FILE_PATTERNS = - -# The RECURSIVE tag can be used to turn specify whether or not subdirectories -# should be searched for input files as well. Possible values are YES and NO. -# If left blank NO is used. - -RECURSIVE = YES - -# The EXCLUDE tag can be used to specify files and/or directories that should -# excluded from the INPUT source files. This way you can easily exclude a -# subdirectory from a directory tree whose root is specified with the INPUT tag. - -EXCLUDE = - -# The EXCLUDE_SYMLINKS tag can be used select whether or not files or -# directories that are symbolic links (a Unix filesystem feature) are excluded -# from the input. - -EXCLUDE_SYMLINKS = NO - -# If the value of the INPUT tag contains directories, you can use the -# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude -# certain files from those directories. Note that the wildcards are matched -# against the file with absolute path, so to exclude all test directories -# for example use the pattern */test/* - -EXCLUDE_PATTERNS = - -# The EXAMPLE_PATH tag can be used to specify one or more files or -# directories that contain example code fragments that are included (see -# the \include command). - -EXAMPLE_PATH = ../sample - -# If the value of the EXAMPLE_PATH tag contains directories, you can use the -# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank all files are included. - -EXAMPLE_PATTERNS = - -# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be -# searched for input files to be used with the \include or \dontinclude -# commands irrespective of the value of the RECURSIVE tag. -# Possible values are YES and NO. If left blank NO is used. - -EXAMPLE_RECURSIVE = NO - -# The IMAGE_PATH tag can be used to specify one or more files or -# directories that contain image that are included in the documentation (see -# the \image command). - -IMAGE_PATH = - -# The INPUT_FILTER tag can be used to specify a program that doxygen should -# invoke to filter for each input file. Doxygen will invoke the filter program -# by executing (via popen()) the command , where -# is the value of the INPUT_FILTER tag, and is the name of an -# input file. Doxygen will then use the output that the filter program writes -# to standard output. If FILTER_PATTERNS is specified, this tag will be -# ignored. - -INPUT_FILTER = - -# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern -# basis. Doxygen will compare the file name with each pattern and apply the -# filter if there is a match. The filters are a list of the form: -# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further -# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER -# is applied to all files. - -FILTER_PATTERNS = - -# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using -# INPUT_FILTER) will be used to filter the input files when producing source -# files to browse (i.e. when SOURCE_BROWSER is set to YES). - -FILTER_SOURCE_FILES = NO - -#--------------------------------------------------------------------------- -# configuration options related to source browsing -#--------------------------------------------------------------------------- - -# If the SOURCE_BROWSER tag is set to YES then a list of source files will -# be generated. Documented entities will be cross-referenced with these sources. -# Note: To get rid of all source code in the generated output, make sure also -# VERBATIM_HEADERS is set to NO. - -SOURCE_BROWSER = NO - -# Setting the INLINE_SOURCES tag to YES will include the body -# of functions and classes directly in the documentation. - -INLINE_SOURCES = NO - -# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct -# doxygen to hide any special comment blocks from generated source code -# fragments. Normal C and C++ comments will always remain visible. - -STRIP_CODE_COMMENTS = YES - -# If the REFERENCED_BY_RELATION tag is set to YES (the default) -# then for each documented function all documented -# functions referencing it will be listed. - -REFERENCED_BY_RELATION = YES - -# If the REFERENCES_RELATION tag is set to YES (the default) -# then for each documented function all documented entities -# called/used by that function will be listed. - -REFERENCES_RELATION = YES - -# If the REFERENCES_LINK_SOURCE tag is set to YES (the default) -# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from -# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will -# link to the source code. Otherwise they will link to the documentstion. - -REFERENCES_LINK_SOURCE = YES - -# If the USE_HTAGS tag is set to YES then the references to source code -# will point to the HTML generated by the htags(1) tool instead of doxygen -# built-in source browser. The htags tool is part of GNU's global source -# tagging system (see http://www.gnu.org/software/global/global.html). You -# will need version 4.8.6 or higher. - -USE_HTAGS = NO - -# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen -# will generate a verbatim copy of the header file for each class for -# which an include is specified. Set to NO to disable this. - -VERBATIM_HEADERS = NO - -#--------------------------------------------------------------------------- -# configuration options related to the alphabetical class index -#--------------------------------------------------------------------------- - -# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index -# of all compounds will be generated. Enable this if the project -# contains a lot of classes, structs, unions or interfaces. - -ALPHABETICAL_INDEX = NO - -# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then -# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns -# in which this list will be split (can be a number in the range [1..20]) - -COLS_IN_ALPHA_INDEX = 5 - -# In case all classes in a project start with a common prefix, all -# classes will be put under the same header in the alphabetical index. -# The IGNORE_PREFIX tag can be used to specify one or more prefixes that -# should be ignored while generating the index headers. - -IGNORE_PREFIX = - -#--------------------------------------------------------------------------- -# configuration options related to the HTML output -#--------------------------------------------------------------------------- - -# If the GENERATE_HTML tag is set to YES (the default) Doxygen will -# generate HTML output. - -GENERATE_HTML = YES - -# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `html' will be used as the default path. - -HTML_OUTPUT = html - -# The HTML_FILE_EXTENSION tag can be used to specify the file extension for -# each generated HTML page (for example: .htm,.php,.asp). If it is left blank -# doxygen will generate files with .html extension. - -HTML_FILE_EXTENSION = .html - -# The HTML_HEADER tag can be used to specify a personal HTML header for -# each generated HTML page. If it is left blank doxygen will generate a -# standard header. - -HTML_HEADER = header.html - -# The HTML_FOOTER tag can be used to specify a personal HTML footer for -# each generated HTML page. If it is left blank doxygen will generate a -# standard footer. - -HTML_FOOTER = footer.html - -# The HTML_STYLESHEET tag can be used to specify a user-defined cascading -# style sheet that is used by each HTML page. It can be used to -# fine-tune the look of the HTML output. If the tag is left blank doxygen -# will generate a default style sheet. Note that doxygen will try to copy -# the style sheet file to the HTML output directory, so don't put your own -# stylesheet in the HTML output directory as well, or it will be erased! - -HTML_STYLESHEET = - -# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, -# files or namespaces will be aligned in HTML using tables. If set to -# NO a bullet list will be used. - -HTML_ALIGN_MEMBERS = YES - -# If the GENERATE_HTMLHELP tag is set to YES, additional index files -# will be generated that can be used as input for tools like the -# Microsoft HTML help workshop to generate a compressed HTML help file (.chm) -# of the generated HTML documentation. - -GENERATE_HTMLHELP = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can -# be used to specify the file name of the resulting .chm file. You -# can add a path in front of the file if the result should not be -# written to the html output directory. - -CHM_FILE = - -# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can -# be used to specify the location (absolute path including file name) of -# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run -# the HTML help compiler on the generated index.hhp. - -HHC_LOCATION = - -# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag -# controls if a separate .chi index file is generated (YES) or that -# it should be included in the master .chm file (NO). - -GENERATE_CHI = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag -# controls whether a binary table of contents is generated (YES) or a -# normal table of contents (NO) in the .chm file. - -BINARY_TOC = NO - -# The TOC_EXPAND flag can be set to YES to add extra items for group members -# to the contents of the HTML help documentation and to the tree view. - -TOC_EXPAND = NO - -# The DISABLE_INDEX tag can be used to turn on/off the condensed index at -# top of each HTML page. The value NO (the default) enables the index and -# the value YES disables it. - -DISABLE_INDEX = NO - -# This tag can be used to set the number of enum values (range [1..20]) -# that doxygen will group on one line in the generated HTML documentation. - -ENUM_VALUES_PER_LINE = 4 - -# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be -# generated containing a tree-like index structure (just like the one that -# is generated for HTML Help). For this to work a browser that supports -# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, -# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are -# probably better off using the HTML help feature. - -GENERATE_TREEVIEW = NO - -# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be -# used to set the initial width (in pixels) of the frame in which the tree -# is shown. - -TREEVIEW_WIDTH = 250 - -#--------------------------------------------------------------------------- -# configuration options related to the LaTeX output -#--------------------------------------------------------------------------- - -# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will -# generate Latex output. - -GENERATE_LATEX = NO - -# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `latex' will be used as the default path. - -LATEX_OUTPUT = latex - -# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be -# invoked. If left blank `latex' will be used as the default command name. - -LATEX_CMD_NAME = latex - -# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to -# generate index for LaTeX. If left blank `makeindex' will be used as the -# default command name. - -MAKEINDEX_CMD_NAME = makeindex - -# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact -# LaTeX documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_LATEX = NO - -# The PAPER_TYPE tag can be used to set the paper type that is used -# by the printer. Possible values are: a4, a4wide, letter, legal and -# executive. If left blank a4wide will be used. - -PAPER_TYPE = a4wide - -# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX -# packages that should be included in the LaTeX output. - -EXTRA_PACKAGES = - -# The LATEX_HEADER tag can be used to specify a personal LaTeX header for -# the generated latex document. The header should contain everything until -# the first chapter. If it is left blank doxygen will generate a -# standard header. Notice: only use this tag if you know what you are doing! - -LATEX_HEADER = - -# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated -# is prepared for conversion to pdf (using ps2pdf). The pdf file will -# contain links (just like the HTML output) instead of page references -# This makes the output suitable for online browsing using a pdf viewer. - -PDF_HYPERLINKS = NO - -# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of -# plain latex in the generated Makefile. Set this option to YES to get a -# higher quality PDF documentation. - -USE_PDFLATEX = NO - -# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. -# command to the generated LaTeX files. This will instruct LaTeX to keep -# running if errors occur, instead of asking the user for help. -# This option is also used when generating formulas in HTML. - -LATEX_BATCHMODE = NO - -# If LATEX_HIDE_INDICES is set to YES then doxygen will not -# include the index chapters (such as File Index, Compound Index, etc.) -# in the output. - -LATEX_HIDE_INDICES = NO - -#--------------------------------------------------------------------------- -# configuration options related to the RTF output -#--------------------------------------------------------------------------- - -# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output -# The RTF output is optimized for Word 97 and may not look very pretty with -# other RTF readers or editors. - -GENERATE_RTF = NO - -# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `rtf' will be used as the default path. - -RTF_OUTPUT = rtf - -# If the COMPACT_RTF tag is set to YES Doxygen generates more compact -# RTF documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_RTF = NO - -# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated -# will contain hyperlink fields. The RTF file will -# contain links (just like the HTML output) instead of page references. -# This makes the output suitable for online browsing using WORD or other -# programs which support those fields. -# Note: wordpad (write) and others do not support links. - -RTF_HYPERLINKS = NO - -# Load stylesheet definitions from file. Syntax is similar to doxygen's -# config file, i.e. a series of assignments. You only have to provide -# replacements, missing definitions are set to their default value. - -RTF_STYLESHEET_FILE = - -# Set optional variables used in the generation of an rtf document. -# Syntax is similar to doxygen's config file. - -RTF_EXTENSIONS_FILE = - -#--------------------------------------------------------------------------- -# configuration options related to the man page output -#--------------------------------------------------------------------------- - -# If the GENERATE_MAN tag is set to YES (the default) Doxygen will -# generate man pages - -GENERATE_MAN = NO - -# The MAN_OUTPUT tag is used to specify where the man pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `man' will be used as the default path. - -MAN_OUTPUT = man - -# The MAN_EXTENSION tag determines the extension that is added to -# the generated man pages (default is the subroutine's section .3) - -MAN_EXTENSION = .3 - -# If the MAN_LINKS tag is set to YES and Doxygen generates man output, -# then it will generate one additional man file for each entity -# documented in the real man page(s). These additional files -# only source the real man page, but without them the man command -# would be unable to find the correct page. The default is NO. - -MAN_LINKS = NO - -#--------------------------------------------------------------------------- -# configuration options related to the XML output -#--------------------------------------------------------------------------- - -# If the GENERATE_XML tag is set to YES Doxygen will -# generate an XML file that captures the structure of -# the code including all documentation. - -GENERATE_XML = NO - -# The XML_OUTPUT tag is used to specify where the XML pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `xml' will be used as the default path. - -XML_OUTPUT = xml - -# The XML_SCHEMA tag can be used to specify an XML schema, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_SCHEMA = - -# The XML_DTD tag can be used to specify an XML DTD, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_DTD = - -# If the XML_PROGRAMLISTING tag is set to YES Doxygen will -# dump the program listings (including syntax highlighting -# and cross-referencing information) to the XML output. Note that -# enabling this will significantly increase the size of the XML output. - -XML_PROGRAMLISTING = YES - -#--------------------------------------------------------------------------- -# configuration options for the AutoGen Definitions output -#--------------------------------------------------------------------------- - -# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will -# generate an AutoGen Definitions (see autogen.sf.net) file -# that captures the structure of the code including all -# documentation. Note that this feature is still experimental -# and incomplete at the moment. - -GENERATE_AUTOGEN_DEF = NO - -#--------------------------------------------------------------------------- -# configuration options related to the Perl module output -#--------------------------------------------------------------------------- - -# If the GENERATE_PERLMOD tag is set to YES Doxygen will -# generate a Perl module file that captures the structure of -# the code including all documentation. Note that this -# feature is still experimental and incomplete at the -# moment. - -GENERATE_PERLMOD = NO - -# If the PERLMOD_LATEX tag is set to YES Doxygen will generate -# the necessary Makefile rules, Perl scripts and LaTeX code to be able -# to generate PDF and DVI output from the Perl module output. - -PERLMOD_LATEX = NO - -# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be -# nicely formatted so it can be parsed by a human reader. This is useful -# if you want to understand what is going on. On the other hand, if this -# tag is set to NO the size of the Perl module output will be much smaller -# and Perl will parse it just the same. - -PERLMOD_PRETTY = YES - -# The names of the make variables in the generated doxyrules.make file -# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. -# This is useful so different doxyrules.make files included by the same -# Makefile don't overwrite each other's variables. - -PERLMOD_MAKEVAR_PREFIX = - -#--------------------------------------------------------------------------- -# Configuration options related to the preprocessor -#--------------------------------------------------------------------------- - -# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will -# evaluate all C-preprocessor directives found in the sources and include -# files. - -ENABLE_PREPROCESSING = YES - -# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro -# names in the source code. If set to NO (the default) only conditional -# compilation will be performed. Macro expansion can be done in a controlled -# way by setting EXPAND_ONLY_PREDEF to YES. - -MACRO_EXPANSION = NO - -# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES -# then the macro expansion is limited to the macros specified with the -# PREDEFINED and EXPAND_AS_DEFINED tags. - -EXPAND_ONLY_PREDEF = NO - -# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files -# in the INCLUDE_PATH (see below) will be search if a #include is found. - -SEARCH_INCLUDES = YES - -# The INCLUDE_PATH tag can be used to specify one or more directories that -# contain include files that are not input files but should be processed by -# the preprocessor. - -INCLUDE_PATH = - -# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard -# patterns (like *.h and *.hpp) to filter out the header-files in the -# directories. If left blank, the patterns specified with FILE_PATTERNS will -# be used. - -INCLUDE_FILE_PATTERNS = - -# The PREDEFINED tag can be used to specify one or more macro names that -# are defined before the preprocessor is started (similar to the -D option of -# gcc). The argument of the tag is a list of macros of the form: name -# or name=definition (no spaces). If the definition and the = are -# omitted =1 is assumed. To prevent a macro definition from being -# undefined via #undef or recursively expanded use the := operator -# instead of the = operator. - -PREDEFINED = DOXYGEN_SHOULD_SKIP_THIS - -# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then -# this tag can be used to specify a list of macro names that should be expanded. -# The macro definition that is found in the sources will be used. -# Use the PREDEFINED tag if you want to use a different macro definition. - -EXPAND_AS_DEFINED = - -# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then -# doxygen's preprocessor will remove all function-like macros that are alone -# on a line, have an all uppercase name, and do not end with a semicolon. Such -# function macros are typically used for boiler-plate code, and will confuse -# the parser if not removed. - -SKIP_FUNCTION_MACROS = YES - -#--------------------------------------------------------------------------- -# Configuration::additions related to external references -#--------------------------------------------------------------------------- - -# The TAGFILES option can be used to specify one or more tagfiles. -# Optionally an initial location of the external documentation -# can be added for each tagfile. The format of a tag file without -# this location is as follows: -# TAGFILES = file1 file2 ... -# Adding location for the tag files is done as follows: -# TAGFILES = file1=loc1 "file2 = loc2" ... -# where "loc1" and "loc2" can be relative or absolute paths or -# URLs. If a location is present for each tag, the installdox tool -# does not have to be run to correct the links. -# Note that each tag file must have a unique name -# (where the name does NOT include the path) -# If a tag file is not located in the directory in which doxygen -# is run, you must also specify the path to the tagfile here. - -TAGFILES = - -# When a file name is specified after GENERATE_TAGFILE, doxygen will create -# a tag file that is based on the input files it reads. - -GENERATE_TAGFILE = - -# If the ALLEXTERNALS tag is set to YES all external classes will be listed -# in the class index. If set to NO only the inherited external classes -# will be listed. - -ALLEXTERNALS = NO - -# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed -# in the modules index. If set to NO, only the current project's groups will -# be listed. - -EXTERNAL_GROUPS = YES - -# The PERL_PATH should be the absolute path and name of the perl script -# interpreter (i.e. the result of `which perl'). - -PERL_PATH = /usr/bin/perl - -#--------------------------------------------------------------------------- -# Configuration options related to the dot tool -#--------------------------------------------------------------------------- - -# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will -# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base -# or super classes. Setting the tag to NO turns the diagrams off. Note that -# this option is superseded by the HAVE_DOT option below. This is only a -# fallback. It is recommended to install and use dot, since it yields more -# powerful graphs. - -CLASS_DIAGRAMS = YES - -# If set to YES, the inheritance and collaboration graphs will hide -# inheritance and usage relations if the target is undocumented -# or is not a class. - -HIDE_UNDOC_RELATIONS = YES - -# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is -# available from the path. This tool is part of Graphviz, a graph visualization -# toolkit from AT&T and Lucent Bell Labs. The other options in this section -# have no effect if this option is set to NO (the default) - -HAVE_DOT = NO - -# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect inheritance relations. Setting this tag to YES will force the -# the CLASS_DIAGRAMS tag to NO. - -CLASS_GRAPH = YES - -# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect implementation dependencies (inheritance, containment, and -# class references variables) of the class with other documented classes. - -COLLABORATION_GRAPH = YES - -# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for groups, showing the direct groups dependencies - -GROUP_GRAPHS = YES - -# If the UML_LOOK tag is set to YES doxygen will generate inheritance and -# collaboration diagrams in a style similar to the OMG's Unified Modeling -# Language. - -UML_LOOK = NO - -# If set to YES, the inheritance and collaboration graphs will show the -# relations between templates and their instances. - -TEMPLATE_RELATIONS = NO - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT -# tags are set to YES then doxygen will generate a graph for each documented -# file showing the direct and indirect include dependencies of the file with -# other documented files. - -INCLUDE_GRAPH = YES - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and -# HAVE_DOT tags are set to YES then doxygen will generate a graph for each -# documented header file showing the documented files that directly or -# indirectly include this file. - -INCLUDED_BY_GRAPH = YES - -# If the CALL_GRAPH and HAVE_DOT tags are set to YES then doxygen will -# generate a call dependency graph for every global function or class method. -# Note that enabling this option will significantly increase the time of a run. -# So in most cases it will be better to enable call graphs for selected -# functions only using the \callgraph command. - -CALL_GRAPH = NO - -# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then doxygen will -# generate a caller dependency graph for every global function or class method. -# Note that enabling this option will significantly increase the time of a run. -# So in most cases it will be better to enable caller graphs for selected -# functions only using the \callergraph command. - -CALLER_GRAPH = NO - -# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen -# will graphical hierarchy of all classes instead of a textual one. - -GRAPHICAL_HIERARCHY = YES - -# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES -# then doxygen will show the dependencies a directory has on other directories -# in a graphical way. The dependency relations are determined by the #include -# relations between the files in the directories. - -DIRECTORY_GRAPH = YES - -# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images -# generated by dot. Possible values are png, jpg, or gif -# If left blank png will be used. - -DOT_IMAGE_FORMAT = png - -# The tag DOT_PATH can be used to specify the path where the dot tool can be -# found. If left blank, it is assumed the dot tool can be found in the path. - -DOT_PATH = - -# The DOTFILE_DIRS tag can be used to specify one or more directories that -# contain dot files that are included in the documentation (see the -# \dotfile command). - -DOTFILE_DIRS = - -# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width -# (in pixels) of the graphs generated by dot. If a graph becomes larger than -# this value, doxygen will try to truncate the graph, so that it fits within -# the specified constraint. Beware that most browsers cannot cope with very -# large images. - -MAX_DOT_GRAPH_WIDTH = 1024 - -# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height -# (in pixels) of the graphs generated by dot. If a graph becomes larger than -# this value, doxygen will try to truncate the graph, so that it fits within -# the specified constraint. Beware that most browsers cannot cope with very -# large images. - -MAX_DOT_GRAPH_HEIGHT = 1024 - -# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the -# graphs generated by dot. A depth value of 3 means that only nodes reachable -# from the root by following a path via at most 3 edges will be shown. Nodes -# that lay further from the root node will be omitted. Note that setting this -# option to 1 or 2 may greatly reduce the computation time needed for large -# code bases. Also note that a graph may be further truncated if the graph's -# image dimensions are not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH -# and MAX_DOT_GRAPH_HEIGHT). If 0 is used for the depth value (the default), -# the graph is not depth-constrained. - -MAX_DOT_GRAPH_DEPTH = 0 - -# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent -# background. This is disabled by default, which results in a white background. -# Warning: Depending on the platform used, enabling this option may lead to -# badly anti-aliased labels on the edges of a graph (i.e. they become hard to -# read). - -DOT_TRANSPARENT = NO - -# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output -# files in one run (i.e. multiple -o and -T options on the command line). This -# makes dot run faster, but since only newer versions of dot (>1.8.10) -# support this, this feature is disabled by default. - -DOT_MULTI_TARGETS = NO - -# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will -# generate a legend page explaining the meaning of the various boxes and -# arrows in the dot generated graphs. - -GENERATE_LEGEND = YES - -# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will -# remove the intermediate dot files that are used to generate -# the various graphs. - -DOT_CLEANUP = YES - -#--------------------------------------------------------------------------- -# Configuration::additions related to the search engine -#--------------------------------------------------------------------------- - -# The SEARCHENGINE tag specifies whether or not a search engine should be -# used. If set to NO the values of all tags below this one will be ignored. - -SEARCHENGINE = YES diff --git a/doc/footer.html b/doc/footer.html deleted file mode 100644 index 834ec63..0000000 --- a/doc/footer.html +++ /dev/null @@ -1,7 +0,0 @@ -
-
-Copyright (c) 2002-2010 by Naoaki Okazaki -
$datetime -
- - diff --git a/doc/header.html b/doc/header.html deleted file mode 100644 index fca500e..0000000 --- a/doc/header.html +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - -SimString: A fast and efficient implementation of approximate string matching - - - - diff --git a/swig/export.cpp b/export.cpp similarity index 91% rename from swig/export.cpp rename to export.cpp index 776c3d8..3dcda26 100644 --- a/swig/export.cpp +++ b/export.cpp @@ -269,6 +269,10 @@ void retrieve_iconv( iconv_close(bwd); } +#ifdef __APPLE__ +#include +#endif + std::vector reader::retrieve(const char *query) { reader_type& dbr = *reinterpret_cast(m_dbr); @@ -279,10 +283,26 @@ std::vector reader::retrieve(const char *query) retrieve_thru(dbr, query, this->measure, this->threshold, std::back_inserter(ret)); break; case 2: +#ifdef __APPLE__ +#if __SIZEOF_WCHAR_T__ == 2 + retrieve_iconv(dbr, query, UTF16, this->measure, this->threshold, std::back_inserter(ret)); +#else +assert(0); +#endif +#else retrieve_iconv(dbr, query, UTF16, this->measure, this->threshold, std::back_inserter(ret)); +#endif break; case 4: +#ifdef __APPLE__ +#if __SIZEOF_WCHAR_T__ == 4 + retrieve_iconv(dbr, query, UTF32, this->measure, this->threshold, std::back_inserter(ret)); +#else +assert(0); +#endif +#else retrieve_iconv(dbr, query, UTF32, this->measure, this->threshold, std::back_inserter(ret)); +#endif break; } @@ -297,13 +317,33 @@ bool reader::check(const char *query) std::string qstr = query; return dbr.check(qstr, translate_measure(this->measure), this->threshold); } else if (dbr.char_size() == 2) { +#ifdef __APPLE__ +#if __SIZEOF_WCHAR_T__ == 2 + std::basic_string qstr; +#else +assert(0); + // bogus declaration to keep compiler happy + std::basic_string qstr; +#endif +#else std::basic_string qstr; +#endif iconv_t fwd = iconv_open(UTF16, "UTF-8"); iconv_convert(fwd, std::string(query), qstr); iconv_close(fwd); return dbr.check(qstr, translate_measure(this->measure), this->threshold); } else if (dbr.char_size() == 4) { +#ifdef __APPLE__ +#if __SIZEOF_WCHAR_T__ == 4 + std::basic_string qstr; +#else +assert(0); + // bogus declaration to keep compiler happy + std::basic_string qstr; +#endif +#else std::basic_string qstr; +#endif iconv_t fwd = iconv_open(UTF32, "UTF-8"); iconv_convert(fwd, std::string(query), qstr); iconv_close(fwd); diff --git a/swig/export.h b/export.h similarity index 100% rename from swig/export.h rename to export.h diff --git a/swig/python/export_wrap.cpp b/export_wrap.cpp similarity index 93% rename from swig/python/export_wrap.cpp rename to export_wrap.cpp index 97cebca..2418b97 100644 --- a/swig/python/export_wrap.cpp +++ b/export_wrap.cpp @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.10 + * Version 2.0.11 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -8,11 +8,7 @@ * interface file instead. * ----------------------------------------------------------------------------- */ - -#ifndef SWIGPYTHON #define SWIGPYTHON -#endif - #define SWIG_PYTHON_DIRECTOR_NO_VTABLE @@ -106,11 +102,9 @@ template T SwigValueInit() { #endif /* exporting methods */ -#if defined(__GNUC__) -# if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) -# ifndef GCC_HASCLASSVISIBILITY -# define GCC_HASCLASSVISIBILITY -# endif +#if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) +# ifndef GCC_HASCLASSVISIBILITY +# define GCC_HASCLASSVISIBILITY # endif #endif @@ -149,19 +143,6 @@ template T SwigValueInit() { # define _SCL_SECURE_NO_DEPRECATE #endif -/* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */ -#if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES) -# define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0 -#endif - -/* Intel's compiler complains if a variable which was never initialised is - * cast to void, which is a common idiom which we use to indicate that we - * are aware a variable isn't used. So we just silence that warning. - * See: https://github.com/swig/swig/issues/192 for more discussion. - */ -#ifdef __INTEL_COMPILER -# pragma warning disable 592 -#endif #if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG) @@ -579,14 +560,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start, swig_module_info *iter = start; do { if (iter->size) { - size_t l = 0; - size_t r = iter->size - 1; + register size_t l = 0; + register size_t r = iter->size - 1; do { /* since l+r >= 0, we can (>> 1) instead (/ 2) */ - size_t i = (l + r) >> 1; + register size_t i = (l + r) >> 1; const char *iname = iter->types[i]->name; if (iname) { - int compare = strcmp(name, iname); + register int compare = strcmp(name, iname); if (compare == 0) { return iter->types[i]; } else if (compare < 0) { @@ -630,7 +611,7 @@ SWIG_TypeQueryModule(swig_module_info *start, of the str field (the human readable name) */ swig_module_info *iter = start; do { - size_t i = 0; + register size_t i = 0; for (; i < iter->size; ++i) { if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name))) return iter->types[i]; @@ -649,10 +630,10 @@ SWIG_TypeQueryModule(swig_module_info *start, SWIGRUNTIME char * SWIG_PackData(char *c, void *ptr, size_t sz) { static const char hex[17] = "0123456789abcdef"; - const unsigned char *u = (unsigned char *) ptr; - const unsigned char *eu = u + sz; + register const unsigned char *u = (unsigned char *) ptr; + register const unsigned char *eu = u + sz; for (; u != eu; ++u) { - unsigned char uu = *u; + register unsigned char uu = *u; *(c++) = hex[(uu & 0xf0) >> 4]; *(c++) = hex[uu & 0xf]; } @@ -664,22 +645,22 @@ SWIG_PackData(char *c, void *ptr, size_t sz) { */ SWIGRUNTIME const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz) { - unsigned char *u = (unsigned char *) ptr; - const unsigned char *eu = u + sz; + register unsigned char *u = (unsigned char *) ptr; + register const unsigned char *eu = u + sz; for (; u != eu; ++u) { - char d = *(c++); - unsigned char uu; + register char d = *(c++); + register unsigned char uu; if ((d >= '0') && (d <= '9')) - uu = (unsigned char)((d - '0') << 4); + uu = ((d - '0') << 4); else if ((d >= 'a') && (d <= 'f')) - uu = (unsigned char)((d - ('a'-10)) << 4); + uu = ((d - ('a'-10)) << 4); else return (char *) 0; d = *(c++); if ((d >= '0') && (d <= '9')) - uu |= (unsigned char)(d - '0'); + uu |= (d - '0'); else if ((d >= 'a') && (d <= 'f')) - uu |= (unsigned char)(d - ('a'-10)); + uu |= (d - ('a'-10)); else return (char *) 0; *u = uu; @@ -862,6 +843,10 @@ PyString_FromFormat(const char *fmt, ...) { } #endif +/* Add PyObject_Del for old Pythons */ +#if PY_VERSION_HEX < 0x01060000 +# define PyObject_Del(op) PyMem_DEL((op)) +#endif #ifndef PyObject_DEL # define PyObject_DEL PyObject_Del #endif @@ -1327,7 +1312,7 @@ SWIG_Python_AppendOutput(PyObject* result, PyObject* obj) { /* Unpack the argument tuple */ -SWIGINTERN Py_ssize_t +SWIGINTERN int SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssize_t max, PyObject **objs) { if (!args) { @@ -1341,7 +1326,7 @@ SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssi } if (!PyTuple_Check(args)) { if (min <= 1 && max >= 1) { - Py_ssize_t i; + register int i; objs[0] = args; for (i = 1; i < max; ++i) { objs[i] = 0; @@ -1351,7 +1336,7 @@ SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssi PyErr_SetString(PyExc_SystemError, "UnpackTuple() argument list is not a tuple"); return 0; } else { - Py_ssize_t l = PyTuple_GET_SIZE(args); + register Py_ssize_t l = PyTuple_GET_SIZE(args); if (l < min) { PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", name, (min == max ? "" : "at least "), (int)min, (int)l); @@ -1361,7 +1346,7 @@ SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssi name, (min == max ? "" : "at most "), (int)max, (int)l); return 0; } else { - Py_ssize_t i; + register int i; for (i = 0; i < l; ++i) { objs[i] = PyTuple_GET_ITEM(args, i); } @@ -1547,23 +1532,6 @@ typedef struct { #endif } SwigPyObject; - -#ifdef SWIGPYTHON_BUILTIN - -SWIGRUNTIME PyObject * -SwigPyObject_get___dict__(PyObject *v, PyObject *SWIGUNUSEDPARM(args)) -{ - SwigPyObject *sobj = (SwigPyObject *)v; - - if (!sobj->dict) - sobj->dict = PyDict_New(); - - Py_INCREF(sobj->dict); - return sobj->dict; -} - -#endif - SWIGRUNTIME PyObject * SwigPyObject_long(SwigPyObject *v) { @@ -1702,32 +1670,16 @@ SwigPyObject_dealloc(PyObject *v) if (destroy) { /* destroy is always a VARARGS method */ PyObject *res; - - /* PyObject_CallFunction() has the potential to silently drop - the active active exception. In cases of unnamed temporary - variable or where we just finished iterating over a generator - StopIteration will be active right now, and this needs to - remain true upon return from SwigPyObject_dealloc. So save - and restore. */ - - PyObject *val = NULL, *type = NULL, *tb = NULL; - PyErr_Fetch(&val, &type, &tb); - if (data->delargs) { - /* we need to create a temporary object to carry the destroy operation */ - PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0); - res = SWIG_Python_CallFunctor(destroy, tmp); - Py_DECREF(tmp); + /* we need to create a temporary object to carry the destroy operation */ + PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0); + res = SWIG_Python_CallFunctor(destroy, tmp); + Py_DECREF(tmp); } else { - PyCFunction meth = PyCFunction_GET_FUNCTION(destroy); - PyObject *mself = PyCFunction_GET_SELF(destroy); - res = ((*meth)(mself, v)); + PyCFunction meth = PyCFunction_GET_FUNCTION(destroy); + PyObject *mself = PyCFunction_GET_SELF(destroy); + res = ((*meth)(mself, v)); } - if (!res) - PyErr_WriteUnraisable(destroy); - - PyErr_Restore(val, type, tb); - Py_XDECREF(res); } #if !defined(SWIG_PYTHON_SILENT_MEMLEAK) @@ -1751,7 +1703,6 @@ SwigPyObject_append(PyObject* v, PyObject* next) next = tmp; #endif if (!SwigPyObject_Check(next)) { - PyErr_SetString(PyExc_TypeError, "Attempt to append a non SwigPyObject"); return NULL; } sobj->next = next; @@ -1851,7 +1802,7 @@ swigobject_methods[] = { static PyMethodDef swigobject_methods[] = { {(char *)"disown", (PyCFunction)SwigPyObject_disown, METH_VARARGS, (char *)"releases ownership of the pointer"}, - {(char *)"acquire", (PyCFunction)SwigPyObject_acquire, METH_VARARGS, (char *)"acquires ownership of the pointer"}, + {(char *)"acquire", (PyCFunction)SwigPyObject_acquire, METH_VARARGS, (char *)"aquires ownership of the pointer"}, {(char *)"own", (PyCFunction)SwigPyObject_own, METH_VARARGS, (char *)"returns/sets ownership of the pointer"}, {(char *)"append", (PyCFunction)SwigPyObject_append, METH_VARARGS, (char *)"appends another 'this' object"}, {(char *)"next", (PyCFunction)SwigPyObject_next, METH_VARARGS, (char *)"returns the next 'this' object"}, @@ -1907,9 +1858,7 @@ SwigPyObject_TypeOnce(void) { (unaryfunc)SwigPyObject_oct, /*nb_oct*/ (unaryfunc)SwigPyObject_hex, /*nb_hex*/ #endif -#if PY_VERSION_HEX >= 0x03050000 /* 3.5 */ - 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_matrix_multiply */ -#elif PY_VERSION_HEX >= 0x03000000 /* 3.0 */ +#if PY_VERSION_HEX >= 0x03000000 /* 3.0 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index, nb_inplace_divide removed */ #elif PY_VERSION_HEX >= 0x02050000 /* 2.5.0 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index */ @@ -1989,19 +1938,10 @@ SwigPyObject_TypeOnce(void) { 0, /* tp_del */ #endif #if PY_VERSION_HEX >= 0x02060000 - 0, /* tp_version_tag */ -#endif -#if PY_VERSION_HEX >= 0x03040000 - 0, /* tp_finalize */ + 0, /* tp_version */ #endif #ifdef COUNT_ALLOCS - 0, /* tp_allocs */ - 0, /* tp_frees */ - 0, /* tp_maxalloc */ -#if PY_VERSION_HEX >= 0x02050000 - 0, /* tp_prev */ -#endif - 0 /* tp_next */ + 0,0,0,0 /* tp_alloc -> tp_next */ #endif }; swigpyobject_type = tmp; @@ -2177,19 +2117,10 @@ SwigPyPacked_TypeOnce(void) { 0, /* tp_del */ #endif #if PY_VERSION_HEX >= 0x02060000 - 0, /* tp_version_tag */ -#endif -#if PY_VERSION_HEX >= 0x03040000 - 0, /* tp_finalize */ + 0, /* tp_version */ #endif #ifdef COUNT_ALLOCS - 0, /* tp_allocs */ - 0, /* tp_frees */ - 0, /* tp_maxalloc */ -#if PY_VERSION_HEX >= 0x02050000 - 0, /* tp_prev */ -#endif - 0 /* tp_next */ + 0,0,0,0 /* tp_alloc -> tp_next */ #endif }; swigpypacked_type = tmp; @@ -2530,7 +2461,7 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this) } } else { #if PY_VERSION_HEX >= 0x03000000 - inst = ((PyTypeObject*) data->newargs)->tp_new((PyTypeObject*) data->newargs, Py_None, Py_None); + inst = PyBaseObject_Type.tp_new((PyTypeObject*) data->newargs, Py_None, Py_None); if (inst) { PyObject_SetAttr(inst, SWIG_This(), swig_this); Py_TYPE(inst)->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG; @@ -2640,21 +2571,18 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f newobj = (SwigPyObject *) newobj->next; newobj->next = next_self; newobj = (SwigPyObject *)next_self; -#ifdef SWIGPYTHON_BUILTIN - newobj->dict = 0; -#endif } } else { newobj = PyObject_New(SwigPyObject, clientdata->pytype); -#ifdef SWIGPYTHON_BUILTIN - newobj->dict = 0; -#endif } if (newobj) { newobj->ptr = ptr; newobj->ty = type; newobj->own = own; newobj->next = 0; +#ifdef SWIGPYTHON_BUILTIN + newobj->dict = 0; +#endif return (PyObject*) newobj; } return SWIG_Py_Void(); @@ -2717,11 +2645,13 @@ PyModule_AddObject(PyObject *m, char *name, PyObject *o) { PyObject *dict; if (!PyModule_Check(m)) { - PyErr_SetString(PyExc_TypeError, "PyModule_AddObject() needs module as first arg"); + PyErr_SetString(PyExc_TypeError, + "PyModule_AddObject() needs module as first arg"); return SWIG_ERROR; } if (!o) { - PyErr_SetString(PyExc_TypeError, "PyModule_AddObject() needs non-NULL value"); + PyErr_SetString(PyExc_TypeError, + "PyModule_AddObject() needs non-NULL value"); return SWIG_ERROR; } @@ -3015,12 +2945,13 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) { #define SWIGTYPE_p_size_type swig_types[5] #define SWIGTYPE_p_std__allocatorT_std__string_t swig_types[6] #define SWIGTYPE_p_std__invalid_argument swig_types[7] -#define SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t swig_types[8] -#define SWIGTYPE_p_swig__SwigPyIterator swig_types[9] -#define SWIGTYPE_p_value_type swig_types[10] -#define SWIGTYPE_p_writer swig_types[11] -static swig_type_info *swig_types[13]; -static swig_module_info swig_module = {swig_types, 12, 0, 0, 0, 0}; +#define SWIGTYPE_p_std__vectorT__Tp__Alloc_t swig_types[8] +#define SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t swig_types[9] +#define SWIGTYPE_p_swig__SwigPyIterator swig_types[10] +#define SWIGTYPE_p_value_type swig_types[11] +#define SWIGTYPE_p_writer swig_types[12] +static swig_type_info *swig_types[14]; +static swig_module_info swig_module = {swig_types, 13, 0, 0, 0, 0}; #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name) #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name) @@ -3044,7 +2975,7 @@ static swig_module_info swig_module = {swig_types, 12, 0, 0, 0, 0}; #endif #define SWIG_name "_simstring" -#define SWIGVERSION 0x030010 +#define SWIGVERSION 0x020011 #define SWIG_VERSION SWIGVERSION @@ -3067,35 +2998,27 @@ namespace swig { SwigPtr_PyObject(const SwigPtr_PyObject& item) : _obj(item._obj) { - SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XINCREF(_obj); - SWIG_PYTHON_THREAD_END_BLOCK; } SwigPtr_PyObject(PyObject *obj, bool initial_ref = true) :_obj(obj) { if (initial_ref) { - SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XINCREF(_obj); - SWIG_PYTHON_THREAD_END_BLOCK; } } SwigPtr_PyObject & operator=(const SwigPtr_PyObject& item) { - SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XINCREF(item._obj); Py_XDECREF(_obj); _obj = item._obj; - SWIG_PYTHON_THREAD_END_BLOCK; return *this; } ~SwigPtr_PyObject() { - SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XDECREF(_obj); - SWIG_PYTHON_THREAD_END_BLOCK; } operator PyObject *() const @@ -3150,9 +3073,14 @@ namespace swig { #endif +#include +#include #include + #include + + namespace swig { struct stop_iteration { }; @@ -3287,11 +3215,9 @@ SWIG_AsVal_double (PyObject *obj, double *val) if (PyFloat_Check(obj)) { if (val) *val = PyFloat_AsDouble(obj); return SWIG_OK; -#if PY_VERSION_HEX < 0x03000000 } else if (PyInt_Check(obj)) { if (val) *val = PyInt_AsLong(obj); return SWIG_OK; -#endif } else if (PyLong_Check(obj)) { double v = PyLong_AsDouble(obj); if (!PyErr_Occurred()) { @@ -3383,7 +3309,18 @@ SWIG_AsVal_unsigned_SS_long (PyObject *obj, unsigned long *val) return SWIG_OK; } else { PyErr_Clear(); - return SWIG_OverflowError; +#if PY_VERSION_HEX >= 0x03000000 + { + long v = PyLong_AsLong(obj); + if (!PyErr_Occurred()) { + if (v < 0) { + return SWIG_OverflowError; + } + } else { + PyErr_Clear(); + } + } +#endif } } #ifdef SWIG_PYTHON_CAST_MODE @@ -3410,107 +3347,23 @@ SWIG_AsVal_unsigned_SS_long (PyObject *obj, unsigned long *val) } -#include -#if !defined(SWIG_NO_LLONG_MAX) -# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__) -# define LLONG_MAX __LONG_LONG_MAX__ -# define LLONG_MIN (-LLONG_MAX - 1LL) -# define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL) -# endif -#endif - - -#if defined(LLONG_MAX) && !defined(SWIG_LONG_LONG_AVAILABLE) -# define SWIG_LONG_LONG_AVAILABLE -#endif - - -#ifdef SWIG_LONG_LONG_AVAILABLE -SWIGINTERN int -SWIG_AsVal_unsigned_SS_long_SS_long (PyObject *obj, unsigned long long *val) -{ - int res = SWIG_TypeError; - if (PyLong_Check(obj)) { - unsigned long long v = PyLong_AsUnsignedLongLong(obj); - if (!PyErr_Occurred()) { - if (val) *val = v; - return SWIG_OK; - } else { - PyErr_Clear(); - res = SWIG_OverflowError; - } - } else { - unsigned long v; - res = SWIG_AsVal_unsigned_SS_long (obj,&v); - if (SWIG_IsOK(res)) { - if (val) *val = v; - return res; - } - } -#ifdef SWIG_PYTHON_CAST_MODE - { - const double mant_max = 1LL << DBL_MANT_DIG; - double d; - res = SWIG_AsVal_double (obj,&d); - if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, mant_max)) { - if (val) *val = (unsigned long long)(d); - return SWIG_AddCast(res); - } - res = SWIG_TypeError; - } -#endif - return res; -} -#endif - - SWIGINTERNINLINE int SWIG_AsVal_size_t (PyObject * obj, size_t *val) { - int res = SWIG_TypeError; -#ifdef SWIG_LONG_LONG_AVAILABLE - if (sizeof(size_t) <= sizeof(unsigned long)) { -#endif - unsigned long v; - res = SWIG_AsVal_unsigned_SS_long (obj, val ? &v : 0); - if (SWIG_IsOK(res) && val) *val = static_cast< size_t >(v); -#ifdef SWIG_LONG_LONG_AVAILABLE - } else if (sizeof(size_t) <= sizeof(unsigned long long)) { - unsigned long long v; - res = SWIG_AsVal_unsigned_SS_long_SS_long (obj, val ? &v : 0); - if (SWIG_IsOK(res) && val) *val = static_cast< size_t >(v); - } -#endif + unsigned long v; + int res = SWIG_AsVal_unsigned_SS_long (obj, val ? &v : 0); + if (SWIG_IsOK(res) && val) *val = static_cast< size_t >(v); return res; } - #define SWIG_From_long PyInt_FromLong - - -#ifdef SWIG_LONG_LONG_AVAILABLE -SWIGINTERNINLINE PyObject* -SWIG_From_long_SS_long (long long value) -{ - return ((value < LONG_MIN) || (value > LONG_MAX)) ? - PyLong_FromLongLong(value) : PyInt_FromLong(static_cast< long >(value)); -} -#endif + #define SWIG_From_long PyLong_FromLong SWIGINTERNINLINE PyObject * SWIG_From_ptrdiff_t (ptrdiff_t value) { -#ifdef SWIG_LONG_LONG_AVAILABLE - if (sizeof(ptrdiff_t) <= sizeof(long)) { -#endif - return SWIG_From_long (static_cast< long >(value)); -#ifdef SWIG_LONG_LONG_AVAILABLE - } else { - /* assume sizeof(ptrdiff_t) <= sizeof(long long) */ - return SWIG_From_long_SS_long (static_cast< long long >(value)); - } -#endif + return SWIG_From_long (static_cast< long >(value)); } @@ -3524,20 +3377,16 @@ SWIGINTERNINLINE PyObject* SWIGINTERN int SWIG_AsVal_long (PyObject *obj, long* val) { -#if PY_VERSION_HEX < 0x03000000 if (PyInt_Check(obj)) { if (val) *val = PyInt_AsLong(obj); return SWIG_OK; - } else -#endif - if (PyLong_Check(obj)) { + } else if (PyLong_Check(obj)) { long v = PyLong_AsLong(obj); if (!PyErr_Occurred()) { if (val) *val = v; return SWIG_OK; } else { PyErr_Clear(); - return SWIG_OverflowError; } } #ifdef SWIG_PYTHON_CAST_MODE @@ -3564,74 +3413,26 @@ SWIG_AsVal_long (PyObject *obj, long* val) } -#ifdef SWIG_LONG_LONG_AVAILABLE -SWIGINTERN int -SWIG_AsVal_long_SS_long (PyObject *obj, long long *val) -{ - int res = SWIG_TypeError; - if (PyLong_Check(obj)) { - long long v = PyLong_AsLongLong(obj); - if (!PyErr_Occurred()) { - if (val) *val = v; - return SWIG_OK; - } else { - PyErr_Clear(); - res = SWIG_OverflowError; - } - } else { - long v; - res = SWIG_AsVal_long (obj,&v); - if (SWIG_IsOK(res)) { - if (val) *val = v; - return res; - } - } -#ifdef SWIG_PYTHON_CAST_MODE - { - const double mant_max = 1LL << DBL_MANT_DIG; - const double mant_min = -mant_max; - double d; - res = SWIG_AsVal_double (obj,&d); - if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, mant_min, mant_max)) { - if (val) *val = (long long)(d); - return SWIG_AddCast(res); - } - res = SWIG_TypeError; - } -#endif - return res; -} -#endif - - SWIGINTERNINLINE int SWIG_AsVal_ptrdiff_t (PyObject * obj, ptrdiff_t *val) { - int res = SWIG_TypeError; -#ifdef SWIG_LONG_LONG_AVAILABLE - if (sizeof(ptrdiff_t) <= sizeof(long)) { -#endif - long v; - res = SWIG_AsVal_long (obj, val ? &v : 0); - if (SWIG_IsOK(res) && val) *val = static_cast< ptrdiff_t >(v); -#ifdef SWIG_LONG_LONG_AVAILABLE - } else if (sizeof(ptrdiff_t) <= sizeof(long long)) { - long long v; - res = SWIG_AsVal_long_SS_long (obj, val ? &v : 0); - if (SWIG_IsOK(res) && val) *val = static_cast< ptrdiff_t >(v); - } -#endif + long v; + int res = SWIG_AsVal_long (obj, val ? &v : 0); + if (SWIG_IsOK(res) && val) *val = static_cast< ptrdiff_t >(v); return res; } +#include + + #include #include -namespace swig { +namespace swig { template struct noconst_traits { typedef Type noconst_type; @@ -3645,7 +3446,7 @@ namespace swig { /* type categories */ - struct pointer_category { }; + struct pointer_category { }; struct value_category { }; /* @@ -3658,12 +3459,12 @@ namespace swig { return traits::noconst_type >::type_name(); } - template + template struct traits_info { static swig_type_info *type_query(std::string name) { name += " *"; return SWIG_TypeQuery(name.c_str()); - } + } static swig_type_info *type_info() { static swig_type_info *info = type_query(type_name()); return info; @@ -3684,17 +3485,17 @@ namespace swig { std::string ptrname = name; ptrname += " *"; return ptrname; - } + } static const char* type_name() { static std::string name = make_ptr_name(swig::type_name()); return name.c_str(); } }; - template + template struct traits_as { }; - - template + + template struct traits_check { }; } @@ -4038,12 +3839,6 @@ namespace swig { return pos; } - template - inline void - erase(Sequence* seq, const typename Sequence::iterator& position) { - seq->erase(position); - } - template inline Sequence* getslice(const Sequence* self, Difference i, Difference j, Py_ssize_t step) { @@ -4418,7 +4213,7 @@ namespace swig template struct SwigPySequence_Ref { - SwigPySequence_Ref(PyObject* seq, Py_ssize_t index) + SwigPySequence_Ref(PyObject* seq, int index) : _seq(seq), _index(index) { } @@ -4430,7 +4225,7 @@ namespace swig return swig::as(item, true); } catch (std::exception& e) { char msg[1024]; - sprintf(msg, "in sequence element %d ", (int)_index); + sprintf(msg, "in sequence element %d ", _index); if (!PyErr_Occurred()) { ::SWIG_Error(SWIG_TypeError, swig::type_name()); } @@ -4448,7 +4243,7 @@ namespace swig private: PyObject* _seq; - Py_ssize_t _index; + int _index; }; template @@ -4469,13 +4264,13 @@ namespace swig typedef Reference reference; typedef T value_type; typedef T* pointer; - typedef Py_ssize_t difference_type; + typedef int difference_type; SwigPySequence_InputIterator() { } - SwigPySequence_InputIterator(PyObject* seq, Py_ssize_t index) + SwigPySequence_InputIterator(PyObject* seq, int index) : _seq(seq), _index(index) { } @@ -4555,7 +4350,6 @@ namespace swig difference_type _index; }; - // STL container wrapper around a Python sequence template struct SwigPySequence_Cont { @@ -4563,8 +4357,8 @@ namespace swig typedef const SwigPySequence_Ref const_reference; typedef T value_type; typedef T* pointer; - typedef Py_ssize_t difference_type; - typedef size_t size_type; + typedef int difference_type; + typedef int size_type; typedef const pointer const_pointer; typedef SwigPySequence_InputIterator iterator; typedef SwigPySequence_InputIterator const_iterator; @@ -4625,13 +4419,13 @@ namespace swig bool check(bool set_err = true) const { - Py_ssize_t s = size(); - for (Py_ssize_t i = 0; i < s; ++i) { + int s = size(); + for (int i = 0; i < s; ++i) { swig::SwigVar_PyObject item = PySequence_GetItem(_seq, i); if (!swig::check(item)) { if (set_err) { char msg[1024]; - sprintf(msg, "in sequence element %d", (int)i); + sprintf(msg, "in sequence element %d", i); SWIG_Error(SWIG_RuntimeError, msg); } return false; @@ -4664,18 +4458,13 @@ SWIGINTERN int SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc) { #if PY_VERSION_HEX>=0x03000000 -#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - if (PyBytes_Check(obj)) -#else if (PyUnicode_Check(obj)) -#endif #else if (PyString_Check(obj)) #endif { char *cstr; Py_ssize_t len; #if PY_VERSION_HEX>=0x03000000 -#if !defined(SWIG_PYTHON_STRICT_BYTE_CHAR) if (!alloc && cptr) { /* We can't allow converting without allocation, since the internal representation of string in Python 3 is UCS-2/UCS-4 but we require @@ -4684,9 +4473,8 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc) return SWIG_RuntimeError; } obj = PyUnicode_AsUTF8String(obj); - if(alloc) *alloc = SWIG_NEWOBJ; -#endif PyBytes_AsStringAndSize(obj, &cstr, &len); + if(alloc) *alloc = SWIG_NEWOBJ; #else PyString_AsStringAndSize(obj, &cstr, &len); #endif @@ -4706,58 +4494,27 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc) #else if (*alloc == SWIG_NEWOBJ) #endif - { - *cptr = reinterpret_cast< char* >(memcpy((new char[len + 1]), cstr, sizeof(char)*(len + 1))); - *alloc = SWIG_NEWOBJ; - } else { + { + *cptr = reinterpret_cast< char* >(memcpy((new char[len + 1]), cstr, sizeof(char)*(len + 1))); + *alloc = SWIG_NEWOBJ; + } + else { *cptr = cstr; *alloc = SWIG_OLDOBJ; } } else { -#if PY_VERSION_HEX>=0x03000000 -#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - *cptr = PyBytes_AsString(obj); -#else - assert(0); /* Should never reach here with Unicode strings in Python 3 */ -#endif -#else + #if PY_VERSION_HEX>=0x03000000 + assert(0); /* Should never reach here in Python 3 */ + #endif *cptr = SWIG_Python_str_AsChar(obj); -#endif } } if (psize) *psize = len + 1; -#if PY_VERSION_HEX>=0x03000000 && !defined(SWIG_PYTHON_STRICT_BYTE_CHAR) +#if PY_VERSION_HEX>=0x03000000 Py_XDECREF(obj); #endif return SWIG_OK; } else { -#if defined(SWIG_PYTHON_2_UNICODE) -#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) -#error "Cannot use both SWIG_PYTHON_2_UNICODE and SWIG_PYTHON_STRICT_BYTE_CHAR at once" -#endif -#if PY_VERSION_HEX<0x03000000 - if (PyUnicode_Check(obj)) { - char *cstr; Py_ssize_t len; - if (!alloc && cptr) { - return SWIG_RuntimeError; - } - obj = PyUnicode_AsUTF8String(obj); - if (PyString_AsStringAndSize(obj, &cstr, &len) != -1) { - if (cptr) { - if (alloc) *alloc = SWIG_NEWOBJ; - *cptr = reinterpret_cast< char* >(memcpy((new char[len + 1]), cstr, sizeof(char)*(len + 1))); - } - if (psize) *psize = len + 1; - - Py_XDECREF(obj); - return SWIG_OK; - } else { - Py_XDECREF(obj); - } - } -#endif -#endif - swig_type_info* pchar_descriptor = SWIG_pchar_descriptor(); if (pchar_descriptor) { void* vptr = 0; @@ -4832,17 +4589,9 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size) SWIG_InternalNewPointerObj(const_cast< char * >(carray), pchar_descriptor, 0) : SWIG_Py_Void(); } else { #if PY_VERSION_HEX >= 0x03000000 -#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR) - return PyBytes_FromStringAndSize(carray, static_cast< Py_ssize_t >(size)); -#else -#if PY_VERSION_HEX >= 0x03010000 - return PyUnicode_DecodeUTF8(carray, static_cast< Py_ssize_t >(size), "surrogateescape"); -#else - return PyUnicode_FromStringAndSize(carray, static_cast< Py_ssize_t >(size)); -#endif -#endif + return PyUnicode_FromStringAndSize(carray, static_cast< int >(size)); #else - return PyString_FromStringAndSize(carray, static_cast< Py_ssize_t >(size)); + return PyString_FromStringAndSize(carray, static_cast< int >(size)); #endif } } else { @@ -4859,17 +4608,17 @@ SWIG_From_std_string (const std::string& s) namespace swig { - template <> struct traits< std::string > { + template <> struct traits { typedef value_category category; static const char* type_name() { return"std::string"; } - }; - template <> struct traits_asval< std::string > { + }; + template <> struct traits_asval { typedef std::string value_type; - static int asval(PyObject *obj, value_type *val) { + static int asval(PyObject *obj, value_type *val) { return SWIG_AsVal_std_string (obj, val); } }; - template <> struct traits_from< std::string > { + template <> struct traits_from { typedef std::string value_type; static PyObject *from(const value_type& val) { return SWIG_From_std_string (val); @@ -4943,9 +4692,10 @@ namespace swig { #endif size_type size = seq.size(); if (size <= (size_type)INT_MAX) { - PyObject *obj = PyTuple_New((Py_ssize_t)size); - Py_ssize_t i = 0; - for (const_iterator it = seq.begin(); it != seq.end(); ++it, ++i) { + PyObject *obj = PyTuple_New((int)size); + int i = 0; + for (const_iterator it = seq.begin(); + it != seq.end(); ++it, ++i) { PyTuple_SetItem(obj,i,swig::from(*it)); } return obj; @@ -4976,7 +4726,7 @@ namespace swig { namespace swig { - template <> struct traits > > { + template <> struct traits > > { typedef pointer_category category; static const char* type_name() { return "std::vector<" "std::string" "," "std::allocator< std::string >" " >"; @@ -5001,49 +4751,34 @@ SWIGINTERNINLINE PyObject* SWIG_From_unsigned_SS_long (unsigned long value) { return (value > LONG_MAX) ? - PyLong_FromUnsignedLong(value) : PyInt_FromLong(static_cast< long >(value)); -} - - -#ifdef SWIG_LONG_LONG_AVAILABLE -SWIGINTERNINLINE PyObject* -SWIG_From_unsigned_SS_long_SS_long (unsigned long long value) -{ - return (value > LONG_MAX) ? - PyLong_FromUnsignedLongLong(value) : PyInt_FromLong(static_cast< long >(value)); + PyLong_FromUnsignedLong(value) : PyLong_FromLong(static_cast< long >(value)); } -#endif SWIGINTERNINLINE PyObject * SWIG_From_size_t (size_t value) { -#ifdef SWIG_LONG_LONG_AVAILABLE - if (sizeof(size_t) <= sizeof(unsigned long)) { -#endif - return SWIG_From_unsigned_SS_long (static_cast< unsigned long >(value)); -#ifdef SWIG_LONG_LONG_AVAILABLE - } else { - /* assume sizeof(size_t) <= sizeof(unsigned long long) */ - return SWIG_From_unsigned_SS_long_SS_long (static_cast< unsigned long long >(value)); - } -#endif + return SWIG_From_unsigned_SS_long (static_cast< unsigned long >(value)); } +SWIGINTERN std::vector< std::string >::value_type std_vector_Sl_std_string_Sg__pop(std::vector< std::string > *self){ + if (self->size() == 0) + throw std::out_of_range("pop from empty container"); + std::vector >::value_type x = self->back(); + self->pop_back(); + return x; + } SWIGINTERN std::vector< std::string,std::allocator< std::string > > *std_vector_Sl_std_string_Sg____getslice__(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j){ return swig::getslice(self, i, j, 1); } -SWIGINTERN void std_vector_Sl_std_string_Sg____setslice____SWIG_0(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j){ - swig::setslice(self, i, j, 1, std::vector< std::string,std::allocator< std::string > >()); - } -SWIGINTERN void std_vector_Sl_std_string_Sg____setslice____SWIG_1(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j,std::vector< std::string,std::allocator< std::string > > const &v){ +SWIGINTERN void std_vector_Sl_std_string_Sg____setslice____SWIG_0(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j,std::vector< std::string,std::allocator< std::string > > const &v=std::vector< std::string,std::allocator< std::string > >()){ swig::setslice(self, i, j, 1, v); } SWIGINTERN void std_vector_Sl_std_string_Sg____delslice__(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j){ swig::delslice(self, i, j, 1); } SWIGINTERN void std_vector_Sl_std_string_Sg____delitem____SWIG_0(std::vector< std::string > *self,std::vector< std::string >::difference_type i){ - swig::erase(self, swig::getpos(self, i)); + self->erase(swig::getpos(self,i)); } SWIGINTERN std::vector< std::string,std::allocator< std::string > > *std_vector_Sl_std_string_Sg____getitem____SWIG_0(std::vector< std::string > *self,PySliceObject *slice){ Py_ssize_t i, j, step; @@ -5052,8 +4787,8 @@ SWIGINTERN std::vector< std::string,std::allocator< std::string > > *std_vector_ return NULL; } PySlice_GetIndices(SWIGPY_SLICE_ARG(slice), (Py_ssize_t)self->size(), &i, &j, &step); - std::vector< std::string,std::allocator< std::string > >::difference_type id = i; - std::vector< std::string,std::allocator< std::string > >::difference_type jd = j; + std::vector >::difference_type id = i; + std::vector >::difference_type jd = j; return swig::getslice(self, id, jd, step); } SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_0(std::vector< std::string > *self,PySliceObject *slice,std::vector< std::string,std::allocator< std::string > > const &v){ @@ -5063,8 +4798,8 @@ SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_0(std::vector< st return; } PySlice_GetIndices(SWIGPY_SLICE_ARG(slice), (Py_ssize_t)self->size(), &i, &j, &step); - std::vector< std::string,std::allocator< std::string > >::difference_type id = i; - std::vector< std::string,std::allocator< std::string > >::difference_type jd = j; + std::vector >::difference_type id = i; + std::vector >::difference_type jd = j; swig::setslice(self, id, jd, step, v); } SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_1(std::vector< std::string > *self,PySliceObject *slice){ @@ -5074,8 +4809,8 @@ SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_1(std::vector< st return; } PySlice_GetIndices(SWIGPY_SLICE_ARG(slice), (Py_ssize_t)self->size(), &i, &j, &step); - std::vector< std::string,std::allocator< std::string > >::difference_type id = i; - std::vector< std::string,std::allocator< std::string > >::difference_type jd = j; + std::vector >::difference_type id = i; + std::vector >::difference_type jd = j; swig::delslice(self, id, jd, step); } SWIGINTERN void std_vector_Sl_std_string_Sg____delitem____SWIG_1(std::vector< std::string > *self,PySliceObject *slice){ @@ -5085,8 +4820,8 @@ SWIGINTERN void std_vector_Sl_std_string_Sg____delitem____SWIG_1(std::vector< st return; } PySlice_GetIndices(SWIGPY_SLICE_ARG(slice), (Py_ssize_t)self->size(), &i, &j, &step); - std::vector< std::string,std::allocator< std::string > >::difference_type id = i; - std::vector< std::string,std::allocator< std::string > >::difference_type jd = j; + std::vector >::difference_type id = i; + std::vector >::difference_type jd = j; swig::delslice(self, id, jd, step); } SWIGINTERN std::vector< std::string >::value_type const &std_vector_Sl_std_string_Sg____getitem____SWIG_1(std::vector< std::string > const *self,std::vector< std::string >::difference_type i){ @@ -5095,20 +4830,9 @@ SWIGINTERN std::vector< std::string >::value_type const &std_vector_Sl_std_strin SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_2(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::value_type const &x){ *(swig::getpos(self,i)) = x; } -SWIGINTERN std::vector< std::string >::value_type std_vector_Sl_std_string_Sg__pop(std::vector< std::string > *self){ - if (self->size() == 0) - throw std::out_of_range("pop from empty container"); - std::vector< std::string,std::allocator< std::string > >::value_type x = self->back(); - self->pop_back(); - return x; - } SWIGINTERN void std_vector_Sl_std_string_Sg__append(std::vector< std::string > *self,std::vector< std::string >::value_type const &x){ self->push_back(x); } -SWIGINTERN std::vector< std::string >::iterator std_vector_Sl_std_string_Sg__erase__SWIG_0(std::vector< std::string > *self,std::vector< std::string >::iterator pos){ return self->erase(pos); } -SWIGINTERN std::vector< std::string >::iterator std_vector_Sl_std_string_Sg__erase__SWIG_1(std::vector< std::string > *self,std::vector< std::string >::iterator first,std::vector< std::string >::iterator last){ return self->erase(first, last); } -SWIGINTERN std::vector< std::string >::iterator std_vector_Sl_std_string_Sg__insert__SWIG_0(std::vector< std::string > *self,std::vector< std::string >::iterator pos,std::vector< std::string >::value_type const &x){ return self->insert(pos, x); } -SWIGINTERN void std_vector_Sl_std_string_Sg__insert__SWIG_1(std::vector< std::string > *self,std::vector< std::string >::iterator pos,std::vector< std::string >::size_type n,std::vector< std::string >::value_type const &x){ self->insert(pos, n, x); } SWIGINTERNINLINE PyObject* SWIG_From_int (int value) @@ -5120,6 +4844,16 @@ SWIGINTERNINLINE PyObject* +#include +#if !defined(SWIG_NO_LLONG_MAX) +# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__) +# define LLONG_MAX __LONG_LONG_MAX__ +# define LLONG_MIN (-LLONG_MAX - 1LL) +# define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL) +# endif +#endif + + SWIGINTERN int SWIG_AsVal_int (PyObject * obj, int *val) { @@ -5139,10 +4873,7 @@ SWIG_AsVal_int (PyObject * obj, int *val) SWIGINTERN int SWIG_AsVal_bool (PyObject *obj, bool *val) { - int r; - if (!PyBool_Check(obj)) - return SWIG_ERROR; - r = PyObject_IsTrue(obj); + int r = PyObject_IsTrue(obj); if (r == -1) return SWIG_ERROR; if (val) *val = r ? true : false; @@ -5282,14 +5013,12 @@ SWIGINTERN PyObject *_wrap_SwigPyIterator_incr__SWIG_1(PyObject *SWIGUNUSEDPARM( SWIGINTERN PyObject *_wrap_SwigPyIterator_incr(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[3] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[3]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 2) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } @@ -5401,14 +5130,12 @@ SWIGINTERN PyObject *_wrap_SwigPyIterator_decr__SWIG_1(PyObject *SWIGUNUSEDPARM( SWIGINTERN PyObject *_wrap_SwigPyIterator_decr(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[3] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[3]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 2) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } @@ -5952,14 +5679,12 @@ SWIGINTERN PyObject *_wrap_SwigPyIterator___sub____SWIG_1(PyObject *SWIGUNUSEDPA SWIGINTERN PyObject *_wrap_SwigPyIterator___sub__(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[3] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[3]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 2) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } @@ -6095,6 +5820,34 @@ SWIGINTERN PyObject *_wrap_StringVector___len__(PyObject *SWIGUNUSEDPARM(self), } +SWIGINTERN PyObject *_wrap_StringVector_pop(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { + PyObject *resultobj = 0; + std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + PyObject * obj0 = 0 ; + std::vector< std::string >::value_type result; + + if (!PyArg_ParseTuple(args,(char *)"O:StringVector_pop",&obj0)) SWIG_fail; + res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_pop" "', argument " "1"" of type '" "std::vector< std::string > *""'"); + } + arg1 = reinterpret_cast< std::vector< std::string > * >(argp1); + try { + result = std_vector_Sl_std_string_Sg__pop(arg1); + } + catch(std::out_of_range &_e) { + SWIG_exception_fail(SWIG_IndexError, (&_e)->what()); + } + + resultobj = SWIG_From_std_string(static_cast< std::string >(result)); + return resultobj; +fail: + return NULL; +} + + SWIGINTERN PyObject *_wrap_StringVector___getslice__(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { PyObject *resultobj = 0; std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; @@ -6149,17 +5902,20 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_0(PyObject *SWIGUNUSE std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; std::vector< std::string >::difference_type arg2 ; std::vector< std::string >::difference_type arg3 ; + std::vector< std::string,std::allocator< std::string > > *arg4 = 0 ; void *argp1 = 0 ; int res1 = 0 ; ptrdiff_t val2 ; int ecode2 = 0 ; ptrdiff_t val3 ; int ecode3 = 0 ; + int res4 = SWIG_OLDOBJ ; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; PyObject * obj2 = 0 ; + PyObject * obj3 = 0 ; - if (!PyArg_ParseTuple(args,(char *)"OOO:StringVector___setslice__",&obj0,&obj1,&obj2)) SWIG_fail; + if (!PyArg_ParseTuple(args,(char *)"OOOO:StringVector___setslice__",&obj0,&obj1,&obj2,&obj3)) SWIG_fail; res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___setslice__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); @@ -6175,8 +5931,19 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_0(PyObject *SWIGUNUSE SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "StringVector___setslice__" "', argument " "3"" of type '" "std::vector< std::string >::difference_type""'"); } arg3 = static_cast< std::vector< std::string >::difference_type >(val3); + { + std::vector > *ptr = (std::vector > *)0; + res4 = swig::asptr(obj3, &ptr); + if (!SWIG_IsOK(res4)) { + SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "StringVector___setslice__" "', argument " "4"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); + } + if (!ptr) { + SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector___setslice__" "', argument " "4"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); + } + arg4 = ptr; + } try { - std_vector_Sl_std_string_Sg____setslice____SWIG_0(arg1,arg2,arg3); + std_vector_Sl_std_string_Sg____setslice____SWIG_0(arg1,arg2,arg3,(std::vector< std::string,std::allocator< std::string > > const &)*arg4); } catch(std::out_of_range &_e) { SWIG_exception_fail(SWIG_IndexError, (&_e)->what()); @@ -6186,8 +5953,10 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_0(PyObject *SWIGUNUSE } resultobj = SWIG_Py_Void(); + if (SWIG_IsNewObj(res4)) delete arg4; return resultobj; fail: + if (SWIG_IsNewObj(res4)) delete arg4; return NULL; } @@ -6197,20 +5966,17 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_1(PyObject *SWIGUNUSE std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; std::vector< std::string >::difference_type arg2 ; std::vector< std::string >::difference_type arg3 ; - std::vector< std::string,std::allocator< std::string > > *arg4 = 0 ; void *argp1 = 0 ; int res1 = 0 ; ptrdiff_t val2 ; int ecode2 = 0 ; ptrdiff_t val3 ; int ecode3 = 0 ; - int res4 = SWIG_OLDOBJ ; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; PyObject * obj2 = 0 ; - PyObject * obj3 = 0 ; - if (!PyArg_ParseTuple(args,(char *)"OOOO:StringVector___setslice__",&obj0,&obj1,&obj2,&obj3)) SWIG_fail; + if (!PyArg_ParseTuple(args,(char *)"OOO:StringVector___setslice__",&obj0,&obj1,&obj2)) SWIG_fail; res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___setslice__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); @@ -6226,19 +5992,8 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_1(PyObject *SWIGUNUSE SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "StringVector___setslice__" "', argument " "3"" of type '" "std::vector< std::string >::difference_type""'"); } arg3 = static_cast< std::vector< std::string >::difference_type >(val3); - { - std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0; - res4 = swig::asptr(obj3, &ptr); - if (!SWIG_IsOK(res4)) { - SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "StringVector___setslice__" "', argument " "4"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); - } - if (!ptr) { - SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector___setslice__" "', argument " "4"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); - } - arg4 = ptr; - } try { - std_vector_Sl_std_string_Sg____setslice____SWIG_1(arg1,arg2,arg3,(std::vector< std::string,std::allocator< std::string > > const &)*arg4); + std_vector_Sl_std_string_Sg____setslice____SWIG_0(arg1,arg2,arg3); } catch(std::out_of_range &_e) { SWIG_exception_fail(SWIG_IndexError, (&_e)->what()); @@ -6248,29 +6003,25 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_1(PyObject *SWIGUNUSE } resultobj = SWIG_Py_Void(); - if (SWIG_IsNewObj(res4)) delete arg4; return resultobj; fail: - if (SWIG_IsNewObj(res4)) delete arg4; return NULL; } SWIGINTERN PyObject *_wrap_StringVector___setslice__(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[5] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[5]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 4) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } if (argc == 3) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6283,14 +6034,14 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice__(PyObject *self, PyObject *a _v = SWIG_CheckState(res); } if (_v) { - return _wrap_StringVector___setslice____SWIG_0(self, args); + return _wrap_StringVector___setslice____SWIG_1(self, args); } } } } if (argc == 4) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6303,10 +6054,10 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice__(PyObject *self, PyObject *a _v = SWIG_CheckState(res); } if (_v) { - int res = swig::asptr(argv[3], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[3], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { - return _wrap_StringVector___setslice____SWIG_1(self, args); + return _wrap_StringVector___setslice____SWIG_0(self, args); } } } @@ -6316,8 +6067,8 @@ SWIGINTERN PyObject *_wrap_StringVector___setslice__(PyObject *self, PyObject *a fail: SWIG_SetErrorMsg(PyExc_NotImplementedError,"Wrong number or type of arguments for overloaded function 'StringVector___setslice__'.\n" " Possible C/C++ prototypes are:\n" - " std::vector< std::string >::__setslice__(std::vector< std::string >::difference_type,std::vector< std::string >::difference_type)\n" - " std::vector< std::string >::__setslice__(std::vector< std::string >::difference_type,std::vector< std::string >::difference_type,std::vector< std::string,std::allocator< std::string > > const &)\n"); + " std::vector< std::string >::__setslice__(std::vector< std::string >::difference_type,std::vector< std::string >::difference_type,std::vector< std::string,std::allocator< std::string > > const &)\n" + " std::vector< std::string >::__setslice__(std::vector< std::string >::difference_type,std::vector< std::string >::difference_type)\n"); return 0; } @@ -6398,9 +6149,6 @@ SWIGINTERN PyObject *_wrap_StringVector___delitem____SWIG_0(PyObject *SWIGUNUSED catch(std::out_of_range &_e) { SWIG_exception_fail(SWIG_IndexError, (&_e)->what()); } - catch(std::invalid_argument &_e) { - SWIG_exception_fail(SWIG_ValueError, (&_e)->what()); - } resultobj = SWIG_Py_Void(); return resultobj; @@ -6473,7 +6221,7 @@ SWIGINTERN PyObject *_wrap_StringVector___setitem____SWIG_0(PyObject *SWIGUNUSED arg2 = (PySliceObject *) obj1; } { - std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0; + std::vector > *ptr = (std::vector > *)0; res3 = swig::asptr(obj2, &ptr); if (!SWIG_IsOK(res3)) { SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "StringVector___setitem__" "', argument " "3"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); @@ -6579,20 +6327,18 @@ SWIGINTERN PyObject *_wrap_StringVector___delitem____SWIG_1(PyObject *SWIGUNUSED SWIGINTERN PyObject *_wrap_StringVector___delitem__(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[3] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[3]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 2) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } if (argc == 2) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6605,7 +6351,7 @@ SWIGINTERN PyObject *_wrap_StringVector___delitem__(PyObject *self, PyObject *ar } if (argc == 2) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6665,20 +6411,18 @@ SWIGINTERN PyObject *_wrap_StringVector___getitem____SWIG_1(PyObject *SWIGUNUSED SWIGINTERN PyObject *_wrap_StringVector___getitem__(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[3] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[3]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 2) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } if (argc == 2) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6691,7 +6435,7 @@ SWIGINTERN PyObject *_wrap_StringVector___getitem__(PyObject *self, PyObject *ar } if (argc == 2) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6766,20 +6510,18 @@ SWIGINTERN PyObject *_wrap_StringVector___setitem____SWIG_2(PyObject *SWIGUNUSED SWIGINTERN PyObject *_wrap_StringVector___setitem__(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[4] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[4]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 3) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } if (argc == 2) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6792,14 +6534,14 @@ SWIGINTERN PyObject *_wrap_StringVector___setitem__(PyObject *self, PyObject *ar } if (argc == 3) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { _v = PySlice_Check(argv[1]); } if (_v) { - int res = swig::asptr(argv[2], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[2], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { return _wrap_StringVector___setitem____SWIG_0(self, args); @@ -6809,7 +6551,7 @@ SWIGINTERN PyObject *_wrap_StringVector___setitem__(PyObject *self, PyObject *ar } if (argc == 3) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -6836,34 +6578,6 @@ SWIGINTERN PyObject *_wrap_StringVector___setitem__(PyObject *self, PyObject *ar } -SWIGINTERN PyObject *_wrap_StringVector_pop(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { - PyObject *resultobj = 0; - std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - PyObject * obj0 = 0 ; - std::vector< std::string >::value_type result; - - if (!PyArg_ParseTuple(args,(char *)"O:StringVector_pop",&obj0)) SWIG_fail; - res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_pop" "', argument " "1"" of type '" "std::vector< std::string > *""'"); - } - arg1 = reinterpret_cast< std::vector< std::string > * >(argp1); - try { - result = std_vector_Sl_std_string_Sg__pop(arg1); - } - catch(std::out_of_range &_e) { - SWIG_exception_fail(SWIG_IndexError, (&_e)->what()); - } - - resultobj = SWIG_From_std_string(static_cast< std::string >(result)); - return resultobj; -fail: - return NULL; -} - - SWIGINTERN PyObject *_wrap_StringVector_append(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { PyObject *resultobj = 0; std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; @@ -6923,7 +6637,7 @@ SWIGINTERN PyObject *_wrap_new_StringVector__SWIG_1(PyObject *SWIGUNUSEDPARM(sel if (!PyArg_ParseTuple(args,(char *)"O:new_StringVector",&obj0)) SWIG_fail; { - std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0; + std::vector > *ptr = (std::vector > *)0; res1 = swig::asptr(obj0, &ptr); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_StringVector" "', argument " "1"" of type '" "std::vector< std::string > const &""'"); @@ -6987,6 +6701,27 @@ SWIGINTERN PyObject *_wrap_StringVector_size(PyObject *SWIGUNUSEDPARM(self), PyO } +SWIGINTERN PyObject *_wrap_StringVector_clear(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { + PyObject *resultobj = 0; + std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + PyObject * obj0 = 0 ; + + if (!PyArg_ParseTuple(args,(char *)"O:StringVector_clear",&obj0)) SWIG_fail; + res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_clear" "', argument " "1"" of type '" "std::vector< std::string > *""'"); + } + arg1 = reinterpret_cast< std::vector< std::string > * >(argp1); + (arg1)->clear(); + resultobj = SWIG_Py_Void(); + return resultobj; +fail: + return NULL; +} + + SWIGINTERN PyObject *_wrap_StringVector_swap(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { PyObject *resultobj = 0; std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; @@ -7020,6 +6755,28 @@ SWIGINTERN PyObject *_wrap_StringVector_swap(PyObject *SWIGUNUSEDPARM(self), PyO } +SWIGINTERN PyObject *_wrap_StringVector_get_allocator(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { + PyObject *resultobj = 0; + std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + PyObject * obj0 = 0 ; + SwigValueWrapper< std::allocator< std::string > > result; + + if (!PyArg_ParseTuple(args,(char *)"O:StringVector_get_allocator",&obj0)) SWIG_fail; + res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_get_allocator" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); + } + arg1 = reinterpret_cast< std::vector< std::string > * >(argp1); + result = ((std::vector< std::string > const *)arg1)->get_allocator(); + resultobj = SWIG_NewPointerObj((new std::vector< std::string >::allocator_type(static_cast< const std::vector< std::string >::allocator_type& >(result))), SWIGTYPE_p_std__allocatorT_std__string_t, SWIG_POINTER_OWN | 0 ); + return resultobj; +fail: + return NULL; +} + + SWIGINTERN PyObject *_wrap_StringVector_begin(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { PyObject *resultobj = 0; std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; @@ -7112,49 +6869,6 @@ SWIGINTERN PyObject *_wrap_StringVector_rend(PyObject *SWIGUNUSEDPARM(self), PyO } -SWIGINTERN PyObject *_wrap_StringVector_clear(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { - PyObject *resultobj = 0; - std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - PyObject * obj0 = 0 ; - - if (!PyArg_ParseTuple(args,(char *)"O:StringVector_clear",&obj0)) SWIG_fail; - res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_clear" "', argument " "1"" of type '" "std::vector< std::string > *""'"); - } - arg1 = reinterpret_cast< std::vector< std::string > * >(argp1); - (arg1)->clear(); - resultobj = SWIG_Py_Void(); - return resultobj; -fail: - return NULL; -} - - -SWIGINTERN PyObject *_wrap_StringVector_get_allocator(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { - PyObject *resultobj = 0; - std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - PyObject * obj0 = 0 ; - SwigValueWrapper< std::allocator< std::string > > result; - - if (!PyArg_ParseTuple(args,(char *)"O:StringVector_get_allocator",&obj0)) SWIG_fail; - res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_get_allocator" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); - } - arg1 = reinterpret_cast< std::vector< std::string > * >(argp1); - result = ((std::vector< std::string > const *)arg1)->get_allocator(); - resultobj = SWIG_NewPointerObj((new std::vector< std::string >::allocator_type(static_cast< const std::vector< std::string >::allocator_type& >(result))), SWIGTYPE_p_std__allocatorT_std__string_t, SWIG_POINTER_OWN | 0 ); - return resultobj; -fail: - return NULL; -} - - SWIGINTERN PyObject *_wrap_new_StringVector__SWIG_2(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { PyObject *resultobj = 0; std::vector< std::string >::size_type arg1 ; @@ -7257,7 +6971,7 @@ SWIGINTERN PyObject *_wrap_StringVector_erase__SWIG_0(PyObject *SWIGUNUSEDPARM(s SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'"); } } - result = std_vector_Sl_std_string_Sg__erase__SWIG_0(arg1,arg2); + result = (arg1)->erase(arg2); resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)), swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN); return resultobj; @@ -7310,7 +7024,7 @@ SWIGINTERN PyObject *_wrap_StringVector_erase__SWIG_1(PyObject *SWIGUNUSEDPARM(s SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "3"" of type '" "std::vector< std::string >::iterator""'"); } } - result = std_vector_Sl_std_string_Sg__erase__SWIG_1(arg1,arg2,arg3); + result = (arg1)->erase(arg2,arg3); resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)), swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN); return resultobj; @@ -7320,20 +7034,18 @@ SWIGINTERN PyObject *_wrap_StringVector_erase__SWIG_1(PyObject *SWIGUNUSEDPARM(s SWIGINTERN PyObject *_wrap_StringVector_erase(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[4] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[4]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 3) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } if (argc == 2) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { swig::SwigPyIterator *iter = 0; @@ -7346,7 +7058,7 @@ SWIGINTERN PyObject *_wrap_StringVector_erase(PyObject *self, PyObject *args) { } if (argc == 3) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { swig::SwigPyIterator *iter = 0; @@ -7411,14 +7123,12 @@ SWIGINTERN PyObject *_wrap_new_StringVector__SWIG_3(PyObject *SWIGUNUSEDPARM(sel SWIGINTERN PyObject *_wrap_new_StringVector(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[3] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[3]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 2) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } @@ -7437,7 +7147,7 @@ SWIGINTERN PyObject *_wrap_new_StringVector(PyObject *self, PyObject *args) { } if (argc == 1) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { return _wrap_new_StringVector__SWIG_1(self, args); @@ -7643,20 +7353,18 @@ SWIGINTERN PyObject *_wrap_StringVector_resize__SWIG_1(PyObject *SWIGUNUSEDPARM( SWIGINTERN PyObject *_wrap_StringVector_resize(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[4] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[4]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 3) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } if (argc == 2) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -7670,7 +7378,7 @@ SWIGINTERN PyObject *_wrap_StringVector_resize(PyObject *self, PyObject *args) { } if (argc == 3) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { { @@ -7739,7 +7447,7 @@ SWIGINTERN PyObject *_wrap_StringVector_insert__SWIG_0(PyObject *SWIGUNUSEDPARM( } arg3 = ptr; } - result = std_vector_Sl_std_string_Sg__insert__SWIG_0(arg1,arg2,(std::string const &)*arg3); + result = (arg1)->insert(arg2,(std::vector< std::string >::value_type const &)*arg3); resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)), swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN); if (SWIG_IsNewObj(res3)) delete arg3; @@ -7801,7 +7509,7 @@ SWIGINTERN PyObject *_wrap_StringVector_insert__SWIG_1(PyObject *SWIGUNUSEDPARM( } arg4 = ptr; } - std_vector_Sl_std_string_Sg__insert__SWIG_1(arg1,arg2,arg3,(std::string const &)*arg4); + (arg1)->insert(arg2,arg3,(std::vector< std::string >::value_type const &)*arg4); resultobj = SWIG_Py_Void(); if (SWIG_IsNewObj(res4)) delete arg4; return resultobj; @@ -7812,20 +7520,18 @@ SWIGINTERN PyObject *_wrap_StringVector_insert__SWIG_1(PyObject *SWIGUNUSEDPARM( SWIGINTERN PyObject *_wrap_StringVector_insert(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[5] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[5]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 4) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } if (argc == 3) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { swig::SwigPyIterator *iter = 0; @@ -7842,7 +7548,7 @@ SWIGINTERN PyObject *_wrap_StringVector_insert(PyObject *self, PyObject *args) { } if (argc == 4) { int _v; - int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0)); + int res = swig::asptr(argv[0], (std::vector >**)(0)); _v = SWIG_CheckState(res); if (_v) { swig::SwigPyIterator *iter = 0; @@ -8168,14 +7874,12 @@ SWIGINTERN PyObject *_wrap_new_writer__SWIG_3(PyObject *SWIGUNUSEDPARM(self), Py SWIGINTERN PyObject *_wrap_new_writer(PyObject *self, PyObject *args) { - Py_ssize_t argc; - PyObject *argv[5] = { - 0 - }; - Py_ssize_t ii; + int argc; + PyObject *argv[5]; + int ii; if (!PyTuple_Check(args)) SWIG_fail; - argc = args ? PyObject_Length(args) : 0; + argc = args ? (int)PyObject_Length(args) : 0; for (ii = 0; (ii < 4) && (ii < argc); ii++) { argv[ii] = PyTuple_GET_ITEM(args,ii); } @@ -8484,7 +8188,7 @@ SWIGINTERN PyObject *_wrap_reader_retrieve(PyObject *SWIGUNUSEDPARM(self), PyObj SWIG_exception(SWIG_RuntimeError,"Unknown exception"); } } - resultobj = swig::from(static_cast< std::vector< std::string,std::allocator< std::string > > >(result)); + resultobj = swig::from(static_cast< std::vector > >(result)); if (alloc2 == SWIG_NEWOBJ) delete[] buf2; return resultobj; fail: @@ -8707,23 +8411,23 @@ static PyMethodDef SwigMethods[] = { { (char *)"StringVector___nonzero__", _wrap_StringVector___nonzero__, METH_VARARGS, NULL}, { (char *)"StringVector___bool__", _wrap_StringVector___bool__, METH_VARARGS, NULL}, { (char *)"StringVector___len__", _wrap_StringVector___len__, METH_VARARGS, NULL}, + { (char *)"StringVector_pop", _wrap_StringVector_pop, METH_VARARGS, NULL}, { (char *)"StringVector___getslice__", _wrap_StringVector___getslice__, METH_VARARGS, NULL}, { (char *)"StringVector___setslice__", _wrap_StringVector___setslice__, METH_VARARGS, NULL}, { (char *)"StringVector___delslice__", _wrap_StringVector___delslice__, METH_VARARGS, NULL}, { (char *)"StringVector___delitem__", _wrap_StringVector___delitem__, METH_VARARGS, NULL}, { (char *)"StringVector___getitem__", _wrap_StringVector___getitem__, METH_VARARGS, NULL}, { (char *)"StringVector___setitem__", _wrap_StringVector___setitem__, METH_VARARGS, NULL}, - { (char *)"StringVector_pop", _wrap_StringVector_pop, METH_VARARGS, NULL}, { (char *)"StringVector_append", _wrap_StringVector_append, METH_VARARGS, NULL}, { (char *)"StringVector_empty", _wrap_StringVector_empty, METH_VARARGS, NULL}, { (char *)"StringVector_size", _wrap_StringVector_size, METH_VARARGS, NULL}, + { (char *)"StringVector_clear", _wrap_StringVector_clear, METH_VARARGS, NULL}, { (char *)"StringVector_swap", _wrap_StringVector_swap, METH_VARARGS, NULL}, + { (char *)"StringVector_get_allocator", _wrap_StringVector_get_allocator, METH_VARARGS, NULL}, { (char *)"StringVector_begin", _wrap_StringVector_begin, METH_VARARGS, NULL}, { (char *)"StringVector_end", _wrap_StringVector_end, METH_VARARGS, NULL}, { (char *)"StringVector_rbegin", _wrap_StringVector_rbegin, METH_VARARGS, NULL}, { (char *)"StringVector_rend", _wrap_StringVector_rend, METH_VARARGS, NULL}, - { (char *)"StringVector_clear", _wrap_StringVector_clear, METH_VARARGS, NULL}, - { (char *)"StringVector_get_allocator", _wrap_StringVector_get_allocator, METH_VARARGS, NULL}, { (char *)"StringVector_pop_back", _wrap_StringVector_pop_back, METH_VARARGS, NULL}, { (char *)"StringVector_erase", _wrap_StringVector_erase, METH_VARARGS, NULL}, { (char *)"new_StringVector", _wrap_new_StringVector, METH_VARARGS, NULL}, @@ -8766,6 +8470,7 @@ static swig_type_info _swigt__p_reader = {"_p_reader", "reader *", 0, 0, (void*) static swig_type_info _swigt__p_size_type = {"_p_size_type", "size_type *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_std__allocatorT_std__string_t = {"_p_std__allocatorT_std__string_t", "std::vector< std::string >::allocator_type *|std::allocator< std::string > *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_std__invalid_argument = {"_p_std__invalid_argument", "std::invalid_argument *", 0, 0, (void*)0, 0}; +static swig_type_info _swigt__p_std__vectorT__Tp__Alloc_t = {"_p_std__vectorT__Tp__Alloc_t", "std::vector< _Tp,_Alloc > *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_std__vectorT_std__string_std__allocatorT_std__string_t_t = {"_p_std__vectorT_std__string_std__allocatorT_std__string_t_t", "std::vector< std::string,std::allocator< std::string > > *|std::vector< std::string > *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_swig__SwigPyIterator = {"_p_swig__SwigPyIterator", "swig::SwigPyIterator *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_value_type = {"_p_value_type", "value_type *", 0, 0, (void*)0, 0}; @@ -8780,6 +8485,7 @@ static swig_type_info *swig_type_initial[] = { &_swigt__p_size_type, &_swigt__p_std__allocatorT_std__string_t, &_swigt__p_std__invalid_argument, + &_swigt__p_std__vectorT__Tp__Alloc_t, &_swigt__p_std__vectorT_std__string_std__allocatorT_std__string_t_t, &_swigt__p_swig__SwigPyIterator, &_swigt__p_value_type, @@ -8794,6 +8500,7 @@ static swig_cast_info _swigc__p_reader[] = { {&_swigt__p_reader, 0, 0, 0},{0, 0 static swig_cast_info _swigc__p_size_type[] = { {&_swigt__p_size_type, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_std__allocatorT_std__string_t[] = { {&_swigt__p_std__allocatorT_std__string_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_std__invalid_argument[] = { {&_swigt__p_std__invalid_argument, 0, 0, 0},{0, 0, 0, 0}}; +static swig_cast_info _swigc__p_std__vectorT__Tp__Alloc_t[] = { {&_swigt__p_std__vectorT__Tp__Alloc_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_std__vectorT_std__string_std__allocatorT_std__string_t_t[] = { {&_swigt__p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_swig__SwigPyIterator[] = { {&_swigt__p_swig__SwigPyIterator, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_value_type[] = { {&_swigt__p_value_type, 0, 0, 0},{0, 0, 0, 0}}; @@ -8808,6 +8515,7 @@ static swig_cast_info *swig_cast_initial[] = { _swigc__p_size_type, _swigc__p_std__allocatorT_std__string_t, _swigc__p_std__invalid_argument, + _swigc__p_std__vectorT__Tp__Alloc_t, _swigc__p_std__vectorT_std__string_std__allocatorT_std__string_t_t, _swigc__p_swig__SwigPyIterator, _swigc__p_value_type, @@ -8836,7 +8544,7 @@ static swig_const_info swig_const_table[] = { * array with the correct data and linking the correct swig_cast_info * structures together. * - * The generated swig_type_info structures are assigned statically to an initial + * The generated swig_type_info structures are assigned staticly to an initial * array. We just loop through that array, and handle each type individually. * First we lookup if this type has been already loaded, and if so, use the * loaded structure instead of the generated one. Then we have to fill in the @@ -8880,7 +8588,7 @@ SWIGRUNTIME void SWIG_InitializeModule(void *clientdata) { size_t i; swig_module_info *module_head, *iter; - int init; + int found, init; /* check to see if the circular list has been setup, if not, set it up */ if (swig_module.next==0) { @@ -8899,18 +8607,22 @@ SWIG_InitializeModule(void *clientdata) { /* This is the first module loaded for this interpreter */ /* so set the swig module into the interpreter */ SWIG_SetModule(clientdata, &swig_module); + module_head = &swig_module; } else { /* the interpreter has loaded a SWIG module, but has it loaded this one? */ + found=0; iter=module_head; do { if (iter==&swig_module) { - /* Our module is already in the list, so there's nothing more to do. */ - return; + found=1; + break; } iter=iter->next; } while (iter!= module_head); - /* otherwise we must add our module into the list */ + /* if the is found in the list, then all is done and we may leave */ + if (found) return; + /* otherwise we must add out module into the list */ swig_module.next = module_head->next; module_head->next = &swig_module; } @@ -9162,7 +8874,7 @@ extern "C" { var = var->next; } if (res == NULL && !PyErr_Occurred()) { - PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); + PyErr_SetString(PyExc_NameError,"Unknown C global variable"); } return res; } @@ -9179,7 +8891,7 @@ extern "C" { var = var->next; } if (res == 1 && !PyErr_Occurred()) { - PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n); + PyErr_SetString(PyExc_NameError,"Unknown C global variable"); } return res; } @@ -9229,19 +8941,10 @@ extern "C" { 0, /* tp_del */ #endif #if PY_VERSION_HEX >= 0x02060000 - 0, /* tp_version_tag */ -#endif -#if PY_VERSION_HEX >= 0x03040000 - 0, /* tp_finalize */ + 0, /* tp_version */ #endif #ifdef COUNT_ALLOCS - 0, /* tp_allocs */ - 0, /* tp_frees */ - 0, /* tp_maxalloc */ -#if PY_VERSION_HEX >= 0x02050000 - 0, /* tp_prev */ -#endif - 0 /* tp_next */ + 0,0,0,0 /* tp_alloc -> tp_next */ #endif }; varlink_type = tmp; @@ -9330,9 +9033,7 @@ extern "C" { size_t i; for (i = 0; methods[i].ml_name; ++i) { const char *c = methods[i].ml_doc; - if (!c) continue; - c = strstr(c, "swig_ptr: "); - if (c) { + if (c && (c = strstr(c, "swig_ptr: "))) { int j; swig_const_info *ci = 0; const char *name = c + 10; @@ -9434,7 +9135,6 @@ SWIG_init(void) { PyObject *public_interface, *public_symbol; PyObject *this_descr; PyObject *thisown_descr; - PyObject *self = 0; int i; (void)builtin_pytype; @@ -9442,7 +9142,6 @@ SWIG_init(void) { (void)builtin_basetype; (void)tuple; (void)static_getset; - (void)self; /* metatype is used to implement static member variables. */ metatype_args = Py_BuildValue("(s(O){})", "SwigPyObjectType", &PyType_Type); @@ -9462,7 +9161,6 @@ SWIG_init(void) { #else m = Py_InitModule((char *) SWIG_name, SwigMethods); #endif - md = d = PyModule_GetDict(m); (void)md; diff --git a/frontend/Makefile.am b/frontend/Makefile.am deleted file mode 100644 index a19a5e3..0000000 --- a/frontend/Makefile.am +++ /dev/null @@ -1,14 +0,0 @@ -# $Id$ - -bin_PROGRAMS = simstring -#man_MANS = simstring.1 -EXTRA_DIST = \ - frontend.vcproj - -simstring_SOURCES = \ - optparse.h \ - main.cpp - -AM_CXXFLAGS = @CXXFLAGS@ -INCLUDES = @INCLUDES@ -AM_LDFLAGS = @LDFLAGS@ diff --git a/frontend/frontend.vcproj b/frontend/frontend.vcproj deleted file mode 100644 index f10ee2d..0000000 --- a/frontend/frontend.vcproj +++ /dev/null @@ -1,225 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/frontend/main.cpp b/frontend/main.cpp deleted file mode 100644 index d616a8f..0000000 --- a/frontend/main.cpp +++ /dev/null @@ -1,403 +0,0 @@ -/* - * SimString frontend. - * - * Copyright (c) 2009,2010 Naoaki Okazaki - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * * Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * * Neither the name of the authors nor the names of its contributors may - * be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER - * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, - * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, - * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR - * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF - * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ - -/* $Id$ */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "optparse.h" - -class option -{ -public: - enum { - MODE_RETRIEVE = 0, - MODE_BUILD, - MODE_HELP, - MODE_VERSION, - }; - - enum { - CC_CHAR = 0, // char - CC_WCHAR, // wchar_t - }; - - int mode; - int code; - std::string name; - - int ngram_size; - bool be; - int measure; - double threshold; - bool echo_back; - bool quiet; - bool benchmark; - -public: - option() : - mode(MODE_RETRIEVE), - code(CC_CHAR), - name(""), - ngram_size(3), - be(false), - measure(simstring::cosine), - threshold(0.7), - echo_back(false), - quiet(false), - benchmark(false) - { - } -}; - -class option_parser : - public option, - public optparse -{ - BEGIN_OPTION_MAP_INLINE() - ON_OPTION(SHORTOPT('b') || LONGOPT("build")) - mode = MODE_BUILD; - - ON_OPTION_WITH_ARG(SHORTOPT('d') || LONGOPT("database")) - name = arg; - - ON_OPTION(SHORTOPT('u') || LONGOPT("unicode")) - code = CC_WCHAR; - - ON_OPTION_WITH_ARG(SHORTOPT('n') || LONGOPT("ngram")) - ngram_size = std::atoi(arg); - - ON_OPTION(SHORTOPT('m') || LONGOPT("mark")) - be = true; - - ON_OPTION_WITH_ARG(SHORTOPT('s') || LONGOPT("similarity")) - if (std::strcmp(arg, "exact") == 0) { - measure = simstring::exact; - } else if (std::strcmp(arg, "dice") == 0) { - measure = simstring::dice; - } else if (std::strcmp(arg, "cosine") == 0) { - measure = simstring::cosine; - } else if (std::strcmp(arg, "jaccard") == 0) { - measure = simstring::jaccard; - } else if (std::strcmp(arg, "overlap") == 0) { - measure = simstring::overlap; - } - - ON_OPTION_WITH_ARG(SHORTOPT('t') || LONGOPT("threshold")) - threshold = std::atof(arg); - - ON_OPTION(SHORTOPT('e') || LONGOPT("echo")) - echo_back = true; - - ON_OPTION(SHORTOPT('q') || LONGOPT("quiet")) - quiet = true; - - ON_OPTION(SHORTOPT('p') || LONGOPT("benchmark")) - benchmark = true; - - ON_OPTION(SHORTOPT('v') || LONGOPT("version")) - mode = MODE_VERSION; - - ON_OPTION(SHORTOPT('h') || LONGOPT("help")) - mode = MODE_HELP; - - END_OPTION_MAP() -}; - -int usage(std::ostream& os, const char *argv0) -{ - os << "USAGE: " << argv0 << " [OPTIONS]" << std::endl; - os << "This utility finds strings in the database (DB) such that they have similarity," << std::endl; - os << "in the similarity measure (SIM), no smaller than the threshold (TH) with" << std::endl; - os << "queries read from STDIN. When -b (--build) option is specified, this utility" << std::endl; - os << "builds a database (DB) for strings read from STDIN." << std::endl; - os << std::endl; - os << "OPTIONS:" << std::endl; - os << " -b, --build build a database for strings read from STDIN" << std::endl; - os << " -d, --database=DB specify a database file" << std::endl; - os << " -u, --unicode use Unicode (wchar_t) for representing characters" << std::endl; - os << " -n, --ngram=N specify the unit of n-grams (DEFAULT=3)" << std::endl; - os << " -m, --mark include marks for begins and ends of strings" << std::endl; - os << " -s, --similarity=SIM specify a similarity measure (DEFAULT='cosine'):" << std::endl; - os << " exact exact match" << std::endl; - os << " dice dice coefficient" << std::endl; - os << " cosine cosine coefficient" << std::endl; - os << " jaccard jaccard coefficient" << std::endl; - os << " overlap overlap coefficient" << std::endl; - os << " -t, --threshold=TH specify the threshold (DEFAULT=0.7)" << std::endl; - os << " -e, --echo-back echo back query strings to the output" << std::endl; - os << " -q, --quiet suppress supplemental information from the output" << std::endl; - os << " -p, --benchmark show benchmark result (retrieved strings are suppressed)" << std::endl; - os << " -v, --version show this version information and exit" << std::endl; - os << " -h, --help show this help message and exit" << std::endl; - os << std::endl; - return 0; -} - -int version(std::ostream& os) -{ - os << SIMSTRING_NAME " "; - os << SIMSTRING_MAJOR_VERSION << "." << SIMSTRING_MINOR_VERSION << " "; - os << SIMSTRING_COPYRIGHT << std::endl; - os << std::endl; - return 0; -} - -template -int build(option& opt, istream_type& is) -{ - typedef std::basic_string string_type; - typedef simstring::ngram_generator ngram_generator_type; - typedef simstring::writer_base writer_type; - - std::ostream& os = std::cout; - std::ostream& es = std::cerr; - - // Show the copyright information. - version(os); - - // Show parameters for database construction. - os << "Constructing the database" << std::endl; - os << "Database name: " << opt.name << std::endl; - os << "N-gram length: " << opt.ngram_size << std::endl; - os << "Begin/end marks: " << std::boolalpha << opt.be << std::endl; - os << "Char type: " << typeid(char_type).name() << " (" << sizeof(char_type) << ")" << std::endl; - os.flush(); - - // Open the database for construction. - clock_t clk = std::clock(); - ngram_generator_type gen(opt.ngram_size, opt.be); - writer_type db(gen, opt.name); - if (db.fail()) { - es << "ERROR: " << db.error() << std::endl; - return 1; - } - - // Insert every string from STDIN into the database. - int n = 0; - for (;;) { - // Read a line. - string_type line; - std::getline(is, line); - if (is.eof()) { - break; - } - - // Insert the string. - if (!db.insert(line)) { - es << "ERROR: " << db.error() << std::endl; - return 1; - } - - // Progress report. - if (!opt.quiet && ++n % 10000 == 0) { - os << "Number of strings: " << n << std::endl; - os.flush(); - } - } - os << "Number of strings: " << n << std::endl; - os << std::endl; - os.flush(); - - // Finalize the database. - os << "Flushing the database" << std::endl; - if (!db.close()) { - es << "ERROR: " << db.error() << std::endl; - return 1; - } - os << std::endl; - - // Report the elaped time for construction. - os << "Total number of strings: " << n << std::endl; - os << "Seconds required: " - << (std::clock() - clk) / (double)CLOCKS_PER_SEC << std::endl; - os << std::endl; - os.flush(); - - return 0; -} - -// widen for strings only with ASCII characters. -template -std::basic_string widen(const std::string& str) -{ - std::basic_string dst; - std::string::const_iterator it; - for (it = str.begin();it != str.end();++it) { - dst += static_cast(*it); - } - return dst; -} - -template -int retrieve(option& opt, istream_type& is, ostream_type& os) -{ - typedef std::basic_string string_type; - typedef std::vector strings_type; - typedef simstring::reader reader_type; - - std::ostream& es = std::cerr; - - // Open the database. - reader_type db; - if (!db.open(opt.name)) { - es << "ERROR: " << db.error() << std::endl; - return 1; - } - - // Check the size of characters. - if (db.char_size() != sizeof(char_type)) { - es << "ERROR: Inconsistent character encoding " << - "(DB:" << db.char_size() << ", " << - "CUR:" << sizeof(char_type) << "): " << std::endl; - es << "This problem may be solved by specifying -u (--unicode) option." << std::endl; - return 1; - } - - int num_queries = 0; - int num_retrieved = 0; - clock_t clk_total = 0; - for (;;) { - // Read a line. - string_type line; - std::getline(is, line); - if (is.eof()) { - break; - } - - // Issue a query. - strings_type xstrs; - clock_t clk = std::clock(); - db.retrieve(line, opt.measure, opt.threshold, std::back_inserter(xstrs)); - clock_t elapsed = (std::clock() - clk); - - // Update stats. - clk_total += elapsed; - num_retrieved += (int)xstrs.size(); - ++num_queries; - - // Do not output results when the benchmarking flag is on. - if (!opt.benchmark) { - // Output the query string if necessary. - if (opt.echo_back) { - os << line << std::endl; - } - - // Output the retrieved strings. - typename strings_type::const_iterator it; - for (it = xstrs.begin();it != xstrs.end();++it) { - os << os.widen('\t') << *it << std::endl; - } - os.flush(); - } - - // Do not output information when the quiet flag is on. - if (!opt.quiet) { - os << - xstrs.size() << - widen(" strings retrieved (") << - (std::clock() - clk) / (double)CLOCKS_PER_SEC << - widen(" sec)") << std::endl; - } - } - - // Output the benchmark information if necessary. - if (opt.benchmark) { - os << - widen("Total number of queries: ") << - num_queries << std::endl; - os << - widen("Seconds per query: ") << - clk_total / (double)CLOCKS_PER_SEC / num_queries << std::endl; - os << - widen("Number of retrieved strings per query: ") << - num_retrieved / (double)num_queries << std::endl; - } - - return 0; -} - -int main(int argc, char *argv[]) -{ - // Parse the command-line options. - option_parser opt; - try { - int arg_used = opt.parse(argv, argc); - } catch (const optparse::unrecognized_option& e) { - std::cerr << "ERROR: unrecognized option: " << e.what() << std::endl; - return 1; - } catch (const optparse::invalid_value& e) { - std::cerr << "ERROR: " << e.what() << std::endl; - return 1; - } - - // Change the locale of wcin and wcout if necessary. - if (opt.code == option::CC_WCHAR) { - std::ios_base::sync_with_stdio(false); - std::locale::global(std::locale("")); - std::wcout.imbue(std::locale("")); - std::wcin.imbue(std::locale("")); - } - - // Branches for the processing mode. - switch (opt.mode) { - case option::MODE_HELP: - return usage(std::cout, argv[0]); - case option::MODE_VERSION: - return version(std::cout); - case option::MODE_BUILD: - if (opt.code == option::CC_CHAR) { - return build(opt, std::cin); - } else if (opt.code == option::CC_WCHAR) { - return build(opt, std::wcin); - } - break; - case option::MODE_RETRIEVE: - if (opt.code == option::CC_CHAR) { - return retrieve(opt, std::cin, std::cout); - } else if (opt.code == option::CC_WCHAR) { - return retrieve(opt, std::wcin, std::wcout); - } - break; - } - - // An unknown processing mode. - return 1; -} diff --git a/frontend/optparse.h b/frontend/optparse.h deleted file mode 100644 index d769357..0000000 --- a/frontend/optparse.h +++ /dev/null @@ -1,273 +0,0 @@ -/* - * An event-driven parser for command-line arguments. - * - * Copyright (c) 2004-2005 by Naoaki Okazaki - * - * This software is provided 'as-is', without any express or implied - * warranty. In no event will the authors be held liable for any damages - * arising from the use of this software. - * - * Permission is granted to anyone to use this software for any purpose, - * including commercial applications, and to alter it and redistribute it - * freely, subject to the following restrictions (known as zlib license): - * - * 1. The origin of this software must not be misrepresented; you must not - * claim that you wrote the original software. If you use this software - * in a product, an acknowledgment in the product documentation would be - * appreciated but is not required. - * 2. Altered source versions must be plainly marked as such, and must not be - * misrepresented as being the original software. - * 3. This notice may not be removed or altered from any source distribution. - * - * Naoaki Okazaki - * - */ - -/* $Id$ */ - -/* - * Class 'optparse' implements a parser for GNU-style command-line arguments. - * Inherit this class to define your own option variables and to implement an - * option handler with macros, BEGIN_OPTION_MAP, ON_OPTION(_WITH_ARG), and - * END_OPTION_MAP. Consult the sample program attached at the bottom of this - * source code. - * - * This code was comfirmed to be compiled with MCVC++ 2003 and gcc 3.3. - * Define _BUILD_NCL_SAMPLE if you want to build a sample program. - * $ g++ -D_BUILD_NCL_SAMPLE -xc++ optparse.h - */ - -#ifndef __NCL_OPTPRASE_H__ -#define __NCL_OPTPRASE_H__ - -#include -#include -#include -#include - - -#ifdef USE_NCL_NAMESPACE -namespace ncl { -#endif/*USE_NCL_NAMESPACE*/ - - -/** - * An event-driven parser for command-line arguments. - * @author Naoaki Okazaki - */ -class optparse { -public: - /** - * Exception class for unrecognized options. - */ - class unrecognized_option : public std::invalid_argument { - public: - unrecognized_option(char shortopt) - : std::invalid_argument(std::string("-") + shortopt) {} - unrecognized_option(const std::string& longopt) - : std::invalid_argument(std::string("--") + longopt) {} - }; - /** - * Exception class for invalid values. - */ - class invalid_value : public std::invalid_argument { - public: - invalid_value(const std::string& message) - : std::invalid_argument(message) {} - }; - -public: - /** Construct. */ - optparse() {} - /** Destruct. */ - virtual ~optparse() {} - - /** - * Parse options. - * @param argv array of null-terminated strings to be parsed - * @param num_argv specifies the number, in strings, of the array - * @return the number of used arguments - * @throws optparse_exception - */ - int parse(char * const argv[], int num_argv) - { - int i; - for (i = 1;i < num_argv;++i) { - const char *token = argv[i]; - if (*token++ == '-') { - const char *next_token = (i+1 < num_argv) ? argv[i+1] : ""; - if (!*token) { - break; // only '-' was found. - } else if (*token == '-') { - const char *arg = std::strchr(++token, '='); - if (arg) { - arg++; - } else { - arg = next_token; - } - int ret = handle_option(0, token, arg); - if (ret < 0) { - throw unrecognized_option(token); - } - if (arg == next_token) { - i += ret; - } - } else { - char c; - while ((c = *token++) != '\0') { - const char *arg = *token ? token : next_token; - int ret = handle_option(c, token, arg); - if (ret < 0) { - throw unrecognized_option(c); - } - if (ret > 0) { - if (arg == token) { - token = ""; - } else { - i++; - } - } - } // while - } // else (*token == '-') - } else { - break; // a non-option argument was fonud. - } - } // for (i) - - return i; - } - -protected: - /** - * Option handler - * This function should be overridden by inheritance class. - * @param c short option character, 0 for long option - * @param longname long option name - * @param arg an argument for the option - * @return 0 (success); - 1 (success with use of an argument); - -1 (failed, unrecognized option) - * @throws option_parser_exception - */ - virtual int handle_option(char c, const char *longname, const char *arg) - { - return 0; - } - - int __optstrcmp(const char *option, const char *longname) - { - const char *p = std::strchr(option, '='); - return p ? - std::strncmp(option, longname, p-option) : - std::strcmp(option, longname); - } -}; - - -/** The begin of inline option map. */ -#define BEGIN_OPTION_MAP_INLINE() \ - virtual int handle_option(char __c, const char *__longname, const char *arg) \ - { \ - int used_args = 0; \ - if (0) { \ - -/** Define of option map. */ -#define DEFINE_OPTION_MAP() \ - virtual int handle_option(char __c, const char *__longname, const char *arg); - -/** Begin of option map implimentation. */ -#define BEGIN_OPTION_MAP(_Class) \ - int _Class::handle_option(char __c, const char *__longname, const char *arg) \ - { \ - int used_args = 0; \ - if (0) { \ - -/** An entry of option map */ -#define ON_OPTION(test) \ - return used_args; \ - } else if (test) { \ - used_args = 0; \ - -#define ON_OPTION_WITH_ARG(test) \ - return used_args; \ - } else if (test) { \ - used_args = 1; \ - -/** The end of option map implementation */ -#define END_OPTION_MAP() \ - return used_args; \ - } \ - return -1; \ - } \ - -/** A predicator for short options */ -#define SHORTOPT(x) (__c == x) -/** A predicator for long options */ -#define LONGOPT(x) (!__c && __optstrcmp(__longname, x) == 0) - - -#ifdef USE_NCL_NAMESPACE -}; -#endif/*USE_NCL_NAMESPACE*/ - - - - - - -#ifdef _BUILD_NCL_SAMPLE - -#include -#include - -/** - * A class to store parameters specified by command-line arguments - */ -class option : public optparse { -public: - int bytes; - int lines; - bool quiet; - - option() : bytes(0), lines(0), quiet(false) {} - - BEGIN_OPTION_MAP_INLINE() - ON_OPTION(SHORTOPT('b') || LONGOPT("bytes")) - bytes = std::atoi(arg); - used_args = 1; // Notify the parser of a consumption of argument. - - ON_OPTION_WITH_ARG(SHORTOPT('l') || LONGOPT("lines")) - lines = std::atoi(arg); - // no need of the notification: used_args variable will be set to 1. - - ON_OPTION(SHORTOPT('q') || LONGOPT("quiet") || LONGOPT("silent")) - quiet = true; - - END_OPTION_MAP() -}; - -int main(int argc, char *argv[]) -{ - try { - option opt; - int argused = opt.parse(&argv[1], argc-1); // Skip argv[0]. - - std::cout << "used argv: " << argused << std::endl; - std::cout << "bytes: " << opt.bytes << std::endl; - std::cout << "lines: " << opt.lines << std::endl; - std::cout << "quiet: " << opt.quiet << std::endl; - } catch (const optparse::unrecognized_option& e) { - std::cout << "unrecognized option: " << e.what() << std::endl; - return 1; - } catch (const optparse::invalid_value& e) { - std::cout << "invalid value: " << e.what() << std::endl; - return 1; - } - - return 0; -} - -#endif/*_BUILD_NCL_SAMPLE*/ - - -#endif/*__NCL_OPTPRASE_H__*/ diff --git a/include/Makefile.am b/include/Makefile.am deleted file mode 100644 index a47159d..0000000 --- a/include/Makefile.am +++ /dev/null @@ -1,14 +0,0 @@ -# $Id$ - -simstringincludedir = $(includedir)/simstring - -simstringinclude_HEADERS = \ - simstring/cdbpp.h \ - simstring/memory_mapped_file.h \ - simstring/memory_mapped_file_posix.h \ - simstring/ngram.h \ - simstring/measure.h \ - simstring/simstring.h - -EXTRA_DIST = \ - simstring/memory_mapped_file_win32.h diff --git a/install_python.sh b/install_python.sh deleted file mode 100755 index affc4bf..0000000 --- a/install_python.sh +++ /dev/null @@ -1,25 +0,0 @@ -CURRENT_DIR=`pwd` - -# get the directory of the script (from: http://stackoverflow.com/a/246128) -SOURCE="${BASH_SOURCE[0]}" -while [ -h "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink - DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" - SOURCE="$(readlink "$SOURCE")" - [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE" # if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located -done -SCRIPT_DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" - -cd $SCRIPT_DIR/swig/python - -# remove symbolic links and build folder (they will be recreated) -rm -rf build export.* - -sh prepare.sh -python setup.py.in build_ext --inplace - -rm -rf $SCRIPT_DIR/release -mkdir $SCRIPT_DIR/release -cp simstring.py $SCRIPT_DIR/release/ -cp _simstring*.so $SCRIPT_DIR/release/ - -cd $CURRENT_DIR diff --git a/install_python3.sh b/install_python3.sh deleted file mode 100755 index caf661a..0000000 --- a/install_python3.sh +++ /dev/null @@ -1,25 +0,0 @@ -CURRENT_DIR=`pwd` - -# get the directory of the script (from: http://stackoverflow.com/a/246128) -SOURCE="${BASH_SOURCE[0]}" -while [ -h "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink - DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" - SOURCE="$(readlink "$SOURCE")" - [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE" # if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located -done -SCRIPT_DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" - -cd $SCRIPT_DIR/swig/python - -# remove symbolic links and build folder (they will be recreated) -rm -rf build export.* - -sh prepare.sh -python3 setup.py.in build_ext --inplace - -rm -rf $SCRIPT_DIR/release -mkdir $SCRIPT_DIR/release -cp simstring.py $SCRIPT_DIR/release/ -cp _simstring*.so $SCRIPT_DIR/release/ - -cd $CURRENT_DIR diff --git a/swig/python/sample.py b/sample.py similarity index 100% rename from swig/python/sample.py rename to sample.py diff --git a/sample/Makefile.am b/sample/Makefile.am deleted file mode 100644 index c5fc155..0000000 --- a/sample/Makefile.am +++ /dev/null @@ -1,11 +0,0 @@ -# $Id: Makefile.am 3 2009-07-08 06:14:45Z naoaki $ - -noinst_PROGRAMS = sample sample_unicode - -sample_SOURCES = sample.cpp - -sample_unicode_SOURCES = sample_unicode.cpp - -AM_CXXFLAGS = @CXXFLAGS@ -INCLUDES = @INCLUDES@ -AM_LDFLAGS = @LDFLAGS@ diff --git a/sample/sample.cpp b/sample/sample.cpp deleted file mode 100644 index 7b6c8c0..0000000 --- a/sample/sample.cpp +++ /dev/null @@ -1,43 +0,0 @@ -#include -#include -#include - -void retrieve( - simstring::reader& dbr, - const std::string& query, - int measure, - double threshold - ) -{ - // Retrieve similar strings into a string vector. - std::vector xstrs; - dbr.retrieve(query, measure, threshold, std::back_inserter(xstrs)); - - // Output the retrieved strings separated by ", ". - for (int i = 0;i < (int)xstrs.size();++i) { - std::cout << (i != 0 ? ", " : "") << xstrs[i]; - } - std::cout << std::endl; -} - -int main(int argc, char *argv[]) -{ - // Create a SimString database with two person names. - simstring::ngram_generator gen(3, false); - simstring::writer_base dbw(gen, "sample.db"); - - dbw.insert("Barack Hussein Obama II"); - dbw.insert("James Gordon Brown"); - dbw.close(); - - // Open the database for reading. - simstring::reader dbr; - - dbr.open("sample.db"); - retrieve(dbr, "Barack Obama", simstring::cosine, 0.6); - retrieve(dbr, "Gordon Brown", simstring::cosine, 0.6); - retrieve(dbr, "Obama", simstring::cosine, 0.6); - retrieve(dbr, "Obama", simstring::overlap, 1.0); - - return 0; -} diff --git a/sample/sample_unicode.cpp b/sample/sample_unicode.cpp deleted file mode 100644 index 95141e1..0000000 --- a/sample/sample_unicode.cpp +++ /dev/null @@ -1,44 +0,0 @@ -#include -#include -#include -#include - -void retrieve( - simstring::reader& dbr, - const std::wstring& query, - int measure, - double threshold - ) -{ - // Retrieve similar strings into a string vector. - std::vector xstrs; - dbr.retrieve(query, measure, threshold, std::back_inserter(xstrs)); - - // Output the retrieved strings separated by ", ". - for (int i = 0;i < (int)xstrs.size();++i) { - std::wcout << (i != 0 ? L", " : L"") << xstrs[i]; - } - std::wcout << std::endl; -} - -int main(int argc, char *argv[]) -{ - // Activate std::wcout. - std::locale::global(std::locale("")); - std::wcout.imbue(std::locale("")); - - // Open a SimString database for writing (with std::wstring). - simstring::ngram_generator gen(3, false); - simstring::writer_base dbw(gen, "sample_unicode.db"); - dbw.insert(L"スパゲティ"); - dbw.close(); - - // Open the database for reading. - simstring::reader dbr; - dbr.open("sample_unicode.db"); - - // Output similar strings from Unicode queries. - retrieve(dbr, L"スパゲティー", simstring::cosine, 0.6); - - return 0; -} diff --git a/swig/python/sample_unicode.py b/sample_unicode.py similarity index 69% rename from swig/python/sample_unicode.py rename to sample_unicode.py index 2e3c6f1..a3ecac4 100644 --- a/swig/python/sample_unicode.py +++ b/sample_unicode.py @@ -9,7 +9,6 @@ with SimString. """ -import sys import simstring # Open a SimString database for writing with Unicode mode. @@ -27,10 +26,9 @@ db.measure = simstring.cosine db.threshold = 0.6 -if sys.version_info.major > 2: - # Use an 8-bit string encoded in UTF-8. - print(' '.join(db.retrieve('スパゲティー'))) -else: - # Convert a Unicode object into an UTF-8 query string. - print(' '.join(db.retrieve(u'スパゲティー'.encode('utf-8')))) +# Use an 8-bit string encoded in UTF-8. +print ' '.join(db.retrieve('スパゲティー')) + +# Convert a Unicode object into an UTF-8 query string. +print ' '.join(db.retrieve(u'スパゲティー'.encode('utf-8'))) diff --git a/swig/python/setup.py.in b/setup.py old mode 100755 new mode 100644 similarity index 64% rename from swig/python/setup.py.in rename to setup.py index a3a8521..d9b155f --- a/swig/python/setup.py.in +++ b/setup.py @@ -10,16 +10,22 @@ def get_rootdir(): return os.path.abspath(os.path.join(os.path.dirname(__file__), '../..')) def get_includedir(): - return os.path.join(get_rootdir(), 'include') + return '.' def get_swigdir(): return os.path.join(get_rootdir(), 'swig') -import os; os.environ['CC'] = 'g++'; os.environ['CXX'] = 'g++'; -os.environ['CPP'] = 'g++'; os.environ['LDSHARED'] = 'g++' +#import os; os.environ['CC'] = 'g++'; os.environ['CXX'] = 'g++'; +#os.environ['CPP'] = 'g++'; os.environ['LDSHARED'] = 'g++' from distutils.core import setup, Extension +if sys.platform.startswith("darwin"): + libs = ['-liconv'] +else: + # need iconv too but without proper -L adding -liconv here won't always work + libs = [] + simstring_module = Extension( '_simstring', sources = [ @@ -27,13 +33,13 @@ def get_swigdir(): 'export_wrap.cpp', ], include_dirs=[get_includedir(),], - extra_link_args=['-shared'], + extra_link_args=libs, language='c++', ) setup( - name = '@PACKAGE@', - version = '@VERSION@', + name = 'simstring', + version = '1.1', author = 'Naoaki Okazaki', description = """SimString Python module""", ext_modules = [simstring_module], diff --git a/simstring.py b/simstring.py new file mode 100644 index 0000000..14a5ae4 --- /dev/null +++ b/simstring.py @@ -0,0 +1,196 @@ +# This file was automatically generated by SWIG (http://www.swig.org). +# Version 2.0.11 +# +# Do not make changes to this file unless you know what you are doing--modify +# the SWIG interface file instead. + + + + + +from sys import version_info +if version_info >= (2,6,0): + def swig_import_helper(): + from os.path import dirname + import imp + fp = None + try: + fp, pathname, description = imp.find_module('_simstring', [dirname(__file__)]) + except ImportError: + import _simstring + return _simstring + if fp is not None: + try: + _mod = imp.load_module('_simstring', fp, pathname, description) + finally: + fp.close() + return _mod + _simstring = swig_import_helper() + del swig_import_helper +else: + import _simstring +del version_info +try: + _swig_property = property +except NameError: + pass # Python < 2.2 doesn't have 'property'. +def _swig_setattr_nondynamic(self,class_type,name,value,static=1): + if (name == "thisown"): return self.this.own(value) + if (name == "this"): + if type(value).__name__ == 'SwigPyObject': + self.__dict__[name] = value + return + method = class_type.__swig_setmethods__.get(name,None) + if method: return method(self,value) + if (not static): + self.__dict__[name] = value + else: + raise AttributeError("You cannot add attributes to %s" % self) + +def _swig_setattr(self,class_type,name,value): + return _swig_setattr_nondynamic(self,class_type,name,value,0) + +def _swig_getattr(self,class_type,name): + if (name == "thisown"): return self.this.own() + method = class_type.__swig_getmethods__.get(name,None) + if method: return method(self) + raise AttributeError(name) + +def _swig_repr(self): + try: strthis = "proxy of " + self.this.__repr__() + except: strthis = "" + return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) + +try: + _object = object + _newclass = 1 +except AttributeError: + class _object : pass + _newclass = 0 + + +class SwigPyIterator(_object): + __swig_setmethods__ = {} + __setattr__ = lambda self, name, value: _swig_setattr(self, SwigPyIterator, name, value) + __swig_getmethods__ = {} + __getattr__ = lambda self, name: _swig_getattr(self, SwigPyIterator, name) + def __init__(self, *args, **kwargs): raise AttributeError("No constructor defined - class is abstract") + __repr__ = _swig_repr + __swig_destroy__ = _simstring.delete_SwigPyIterator + __del__ = lambda self : None; + def value(self): return _simstring.SwigPyIterator_value(self) + def incr(self, n=1): return _simstring.SwigPyIterator_incr(self, n) + def decr(self, n=1): return _simstring.SwigPyIterator_decr(self, n) + def distance(self, *args): return _simstring.SwigPyIterator_distance(self, *args) + def equal(self, *args): return _simstring.SwigPyIterator_equal(self, *args) + def copy(self): return _simstring.SwigPyIterator_copy(self) + def next(self): return _simstring.SwigPyIterator_next(self) + def __next__(self): return _simstring.SwigPyIterator___next__(self) + def previous(self): return _simstring.SwigPyIterator_previous(self) + def advance(self, *args): return _simstring.SwigPyIterator_advance(self, *args) + def __eq__(self, *args): return _simstring.SwigPyIterator___eq__(self, *args) + def __ne__(self, *args): return _simstring.SwigPyIterator___ne__(self, *args) + def __iadd__(self, *args): return _simstring.SwigPyIterator___iadd__(self, *args) + def __isub__(self, *args): return _simstring.SwigPyIterator___isub__(self, *args) + def __add__(self, *args): return _simstring.SwigPyIterator___add__(self, *args) + def __sub__(self, *args): return _simstring.SwigPyIterator___sub__(self, *args) + def __iter__(self): return self +SwigPyIterator_swigregister = _simstring.SwigPyIterator_swigregister +SwigPyIterator_swigregister(SwigPyIterator) + +class StringVector(_object): + __swig_setmethods__ = {} + __setattr__ = lambda self, name, value: _swig_setattr(self, StringVector, name, value) + __swig_getmethods__ = {} + __getattr__ = lambda self, name: _swig_getattr(self, StringVector, name) + __repr__ = _swig_repr + def iterator(self): return _simstring.StringVector_iterator(self) + def __iter__(self): return self.iterator() + def __nonzero__(self): return _simstring.StringVector___nonzero__(self) + def __bool__(self): return _simstring.StringVector___bool__(self) + def __len__(self): return _simstring.StringVector___len__(self) + def pop(self): return _simstring.StringVector_pop(self) + def __getslice__(self, *args): return _simstring.StringVector___getslice__(self, *args) + def __setslice__(self, *args): return _simstring.StringVector___setslice__(self, *args) + def __delslice__(self, *args): return _simstring.StringVector___delslice__(self, *args) + def __delitem__(self, *args): return _simstring.StringVector___delitem__(self, *args) + def __getitem__(self, *args): return _simstring.StringVector___getitem__(self, *args) + def __setitem__(self, *args): return _simstring.StringVector___setitem__(self, *args) + def append(self, *args): return _simstring.StringVector_append(self, *args) + def empty(self): return _simstring.StringVector_empty(self) + def size(self): return _simstring.StringVector_size(self) + def clear(self): return _simstring.StringVector_clear(self) + def swap(self, *args): return _simstring.StringVector_swap(self, *args) + def get_allocator(self): return _simstring.StringVector_get_allocator(self) + def begin(self): return _simstring.StringVector_begin(self) + def end(self): return _simstring.StringVector_end(self) + def rbegin(self): return _simstring.StringVector_rbegin(self) + def rend(self): return _simstring.StringVector_rend(self) + def pop_back(self): return _simstring.StringVector_pop_back(self) + def erase(self, *args): return _simstring.StringVector_erase(self, *args) + def __init__(self, *args): + this = _simstring.new_StringVector(*args) + try: self.this.append(this) + except: self.this = this + def push_back(self, *args): return _simstring.StringVector_push_back(self, *args) + def front(self): return _simstring.StringVector_front(self) + def back(self): return _simstring.StringVector_back(self) + def assign(self, *args): return _simstring.StringVector_assign(self, *args) + def resize(self, *args): return _simstring.StringVector_resize(self, *args) + def insert(self, *args): return _simstring.StringVector_insert(self, *args) + def reserve(self, *args): return _simstring.StringVector_reserve(self, *args) + def capacity(self): return _simstring.StringVector_capacity(self) + __swig_destroy__ = _simstring.delete_StringVector + __del__ = lambda self : None; +StringVector_swigregister = _simstring.StringVector_swigregister +StringVector_swigregister(StringVector) + +exact = _simstring.exact +dice = _simstring.dice +cosine = _simstring.cosine +jaccard = _simstring.jaccard +overlap = _simstring.overlap +class writer(_object): + __swig_setmethods__ = {} + __setattr__ = lambda self, name, value: _swig_setattr(self, writer, name, value) + __swig_getmethods__ = {} + __getattr__ = lambda self, name: _swig_getattr(self, writer, name) + __repr__ = _swig_repr + def __init__(self, *args): + this = _simstring.new_writer(*args) + try: self.this.append(this) + except: self.this = this + __swig_destroy__ = _simstring.delete_writer + __del__ = lambda self : None; + def insert(self, *args): return _simstring.writer_insert(self, *args) + def close(self): return _simstring.writer_close(self) +writer_swigregister = _simstring.writer_swigregister +writer_swigregister(writer) + +class reader(_object): + __swig_setmethods__ = {} + __setattr__ = lambda self, name, value: _swig_setattr(self, reader, name, value) + __swig_getmethods__ = {} + __getattr__ = lambda self, name: _swig_getattr(self, reader, name) + __repr__ = _swig_repr + def __init__(self, *args): + this = _simstring.new_reader(*args) + try: self.this.append(this) + except: self.this = this + __swig_destroy__ = _simstring.delete_reader + __del__ = lambda self : None; + def retrieve(self, *args): return _simstring.reader_retrieve(self, *args) + def check(self, *args): return _simstring.reader_check(self, *args) + def close(self): return _simstring.reader_close(self) + __swig_setmethods__["measure"] = _simstring.reader_measure_set + __swig_getmethods__["measure"] = _simstring.reader_measure_get + if _newclass:measure = _swig_property(_simstring.reader_measure_get, _simstring.reader_measure_set) + __swig_setmethods__["threshold"] = _simstring.reader_threshold_set + __swig_getmethods__["threshold"] = _simstring.reader_threshold_get + if _newclass:threshold = _swig_property(_simstring.reader_threshold_get, _simstring.reader_threshold_set) +reader_swigregister = _simstring.reader_swigregister +reader_swigregister(reader) + +# This file is compatible with both classic and new-style classes. + + diff --git a/simstring.sln b/simstring.sln deleted file mode 100644 index 1ddf817..0000000 --- a/simstring.sln +++ /dev/null @@ -1,20 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual Studio 2010 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "frontend", "frontend\frontend.vcxproj", "{DE6A2D5D-8AFA-4471-A9A2-C8E671CCC301}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Win32 = Debug|Win32 - Release|Win32 = Release|Win32 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {DE6A2D5D-8AFA-4471-A9A2-C8E671CCC301}.Debug|Win32.ActiveCfg = Debug|Win32 - {DE6A2D5D-8AFA-4471-A9A2-C8E671CCC301}.Debug|Win32.Build.0 = Debug|Win32 - {DE6A2D5D-8AFA-4471-A9A2-C8E671CCC301}.Release|Win32.ActiveCfg = Release|Win32 - {DE6A2D5D-8AFA-4471-A9A2-C8E671CCC301}.Release|Win32.Build.0 = Release|Win32 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/include/simstring/cdbpp.h b/simstring/cdbpp.h similarity index 100% rename from include/simstring/cdbpp.h rename to simstring/cdbpp.h diff --git a/include/simstring/measure.h b/simstring/measure.h similarity index 100% rename from include/simstring/measure.h rename to simstring/measure.h diff --git a/include/simstring/memory_mapped_file.h b/simstring/memory_mapped_file.h similarity index 99% rename from include/simstring/memory_mapped_file.h rename to simstring/memory_mapped_file.h index 118017c..f3b0385 100644 --- a/include/simstring/memory_mapped_file.h +++ b/simstring/memory_mapped_file.h @@ -35,7 +35,6 @@ #include #include -#include class memory_mapped_file_base { diff --git a/include/simstring/memory_mapped_file_posix.h b/simstring/memory_mapped_file_posix.h similarity index 100% rename from include/simstring/memory_mapped_file_posix.h rename to simstring/memory_mapped_file_posix.h diff --git a/include/simstring/memory_mapped_file_win32.h b/simstring/memory_mapped_file_win32.h similarity index 100% rename from include/simstring/memory_mapped_file_win32.h rename to simstring/memory_mapped_file_win32.h diff --git a/include/simstring/ngram.h b/simstring/ngram.h similarity index 100% rename from include/simstring/ngram.h rename to simstring/ngram.h diff --git a/include/simstring/simstring.h b/simstring/simstring.h similarity index 100% rename from include/simstring/simstring.h rename to simstring/simstring.h diff --git a/swig/INSTALL b/swig/INSTALL deleted file mode 100644 index d1922c2..0000000 --- a/swig/INSTALL +++ /dev/null @@ -1,37 +0,0 @@ - - SimString SWIG interface - http://www.chokkan.org/software/simstring/swig/ - - - -* DIRECTORY STRUCTURE -[The current "swig" directory] -./export.i SWIG interface definition -./export.h C++ header file defining the API -./export.cpp C++ implementation of the API - -[Language directories] -The "swig" directory contains language subdirectories, e.g., python, ruby, -perl, java. These language directories store language-dependent staffs -(e.g., build/install script). - - -* BUILD INSTRUCTION -[Using the distribution package (*.tar.gz)] -$ cd language-directory -$ ./prepare.sh -$ # Run the language-dependent build script. - -[Using the source repository] -$ cd language-directory -$ ./prepare.sh --swig -$ # Run the language-dependent build script. - - -The distribution package (*.tar.gz) includes a SWIG-generated wrapper for -every language, which is not managed by (committed in) the source -repository. It may be ideal for a user to generate a SWIG wrapper by -themselves, but the official distribution includes wrappers for the -following reasons: -- To build SWIG bindings on the machine where SWIG is not installed -- To avoid errors caused by the version difference of SWIG diff --git a/swig/Makefile.am b/swig/Makefile.am deleted file mode 100644 index afa74a0..0000000 --- a/swig/Makefile.am +++ /dev/null @@ -1,32 +0,0 @@ -# $Id:$ - -EXTRA_DIST = \ - python/prepare.sh \ - python/setup.py.in \ - python/export_wrap.cpp \ - python/simstring.py \ - python/sample.py \ - python/sample_unicode.py \ - ruby/prepare.sh \ - ruby/extconf.rb.in \ - ruby/export_wrap.cpp \ - ruby/sample.rb \ - ruby/sample_unicode.rb \ - perl/prepare.sh \ - perl/Makefile.PL.in \ - perl/export_wrap.cpp \ - perl/simstring.pm \ - perl/run_sample.sh \ - perl/sample.pl \ - perl/t/00_compile.t \ - perl/t/01_usage.t \ - perl/t/02_usage.t \ - java/prepare.sh \ - java/Makefile \ - java/export_wrap.cpp \ - java/simstring/*.java \ - java/run_sample.sh \ - java/Sample.java \ - export.i \ - export.h \ - export.cpp diff --git a/swig/doc/doxyfile b/swig/doc/doxyfile deleted file mode 100644 index 615aba0..0000000 --- a/swig/doc/doxyfile +++ /dev/null @@ -1,1514 +0,0 @@ -# Doxyfile 1.6.1 - -# This file describes the settings to be used by the documentation system -# doxygen (www.doxygen.org) for a project -# -# All text after a hash (#) is considered a comment and will be ignored -# The format is: -# TAG = value [value, ...] -# For lists items can also be appended using: -# TAG += value [value, ...] -# Values that contain spaces should be placed between quotes (" ") - -#--------------------------------------------------------------------------- -# Project related configuration options -#--------------------------------------------------------------------------- - -# This tag specifies the encoding used for all characters in the config file -# that follow. The default is UTF-8 which is also the encoding used for all -# text before the first occurrence of this tag. Doxygen uses libiconv (or the -# iconv built into libc) for the transcoding. See -# http://www.gnu.org/software/libiconv for the list of possible encodings. - -DOXYFILE_ENCODING = UTF-8 - -# The PROJECT_NAME tag is a single word (or a sequence of words surrounded -# by quotes) that should identify the project. - -PROJECT_NAME = SimString - -# The PROJECT_NUMBER tag can be used to enter a project or revision number. -# This could be handy for archiving the generated documentation or -# if some version control system is used. - -PROJECT_NUMBER = - -# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) -# base path where the generated documentation will be put. -# If a relative path is entered, it will be relative to the location -# where doxygen was started. If left blank the current directory will be used. - -OUTPUT_DIRECTORY = - -# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create -# 4096 sub-directories (in 2 levels) under the output directory of each output -# format and will distribute the generated files over these directories. -# Enabling this option can be useful when feeding doxygen a huge amount of -# source files, where putting all generated files in the same directory would -# otherwise cause performance problems for the file system. - -CREATE_SUBDIRS = NO - -# The OUTPUT_LANGUAGE tag is used to specify the language in which all -# documentation generated by doxygen is written. Doxygen will use this -# information to generate all constant output in the proper language. -# The default language is English, other supported languages are: -# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional, -# Croatian, Czech, Danish, Dutch, Esperanto, Farsi, Finnish, French, German, -# Greek, Hungarian, Italian, Japanese, Japanese-en (Japanese with English -# messages), Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, -# Polish, Portuguese, Romanian, Russian, Serbian, Serbian-Cyrilic, Slovak, -# Slovene, Spanish, Swedish, Ukrainian, and Vietnamese. - -OUTPUT_LANGUAGE = English - -# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will -# include brief member descriptions after the members that are listed in -# the file and class documentation (similar to JavaDoc). -# Set to NO to disable this. - -BRIEF_MEMBER_DESC = YES - -# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend -# the brief description of a member or function before the detailed description. -# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the -# brief descriptions will be completely suppressed. - -REPEAT_BRIEF = YES - -# This tag implements a quasi-intelligent brief description abbreviator -# that is used to form the text in various listings. Each string -# in this list, if found as the leading text of the brief description, will be -# stripped from the text and the result after processing the whole list, is -# used as the annotated text. Otherwise, the brief description is used as-is. -# If left blank, the following values are used ("$name" is automatically -# replaced with the name of the entity): "The $name class" "The $name widget" -# "The $name file" "is" "provides" "specifies" "contains" -# "represents" "a" "an" "the" - -ABBREVIATE_BRIEF = - -# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then -# Doxygen will generate a detailed section even if there is only a brief -# description. - -ALWAYS_DETAILED_SEC = NO - -# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all -# inherited members of a class in the documentation of that class as if those -# members were ordinary class members. Constructors, destructors and assignment -# operators of the base classes will not be shown. - -INLINE_INHERITED_MEMB = NO - -# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full -# path before files name in the file list and in the header files. If set -# to NO the shortest path that makes the file name unique will be used. - -FULL_PATH_NAMES = NO - -# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag -# can be used to strip a user-defined part of the path. Stripping is -# only done if one of the specified strings matches the left-hand part of -# the path. The tag can be used to show relative paths in the file list. -# If left blank the directory from which doxygen is run is used as the -# path to strip. - -STRIP_FROM_PATH = - -# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of -# the path mentioned in the documentation of a class, which tells -# the reader which header file to include in order to use a class. -# If left blank only the name of the header file containing the class -# definition is used. Otherwise one should specify the include paths that -# are normally passed to the compiler using the -I flag. - -STRIP_FROM_INC_PATH = - -# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter -# (but less readable) file names. This can be useful is your file systems -# doesn't support long names like on DOS, Mac, or CD-ROM. - -SHORT_NAMES = NO - -# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen -# will interpret the first line (until the first dot) of a JavaDoc-style -# comment as the brief description. If set to NO, the JavaDoc -# comments will behave just like regular Qt-style comments -# (thus requiring an explicit @brief command for a brief description.) - -JAVADOC_AUTOBRIEF = YES - -# If the QT_AUTOBRIEF tag is set to YES then Doxygen will -# interpret the first line (until the first dot) of a Qt-style -# comment as the brief description. If set to NO, the comments -# will behave just like regular Qt-style comments (thus requiring -# an explicit \brief command for a brief description.) - -QT_AUTOBRIEF = NO - -# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen -# treat a multi-line C++ special comment block (i.e. a block of //! or /// -# comments) as a brief description. This used to be the default behaviour. -# The new default is to treat a multi-line C++ comment block as a detailed -# description. Set this tag to YES if you prefer the old behaviour instead. - -MULTILINE_CPP_IS_BRIEF = NO - -# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented -# member inherits the documentation from any documented member that it -# re-implements. - -INHERIT_DOCS = YES - -# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce -# a new page for each member. If set to NO, the documentation of a member will -# be part of the file/class/namespace that contains it. - -SEPARATE_MEMBER_PAGES = NO - -# The TAB_SIZE tag can be used to set the number of spaces in a tab. -# Doxygen uses this value to replace tabs by spaces in code fragments. - -TAB_SIZE = 4 - -# This tag can be used to specify a number of aliases that acts -# as commands in the documentation. An alias has the form "name=value". -# For example adding "sideeffect=\par Side Effects:\n" will allow you to -# put the command \sideeffect (or @sideeffect) in the documentation, which -# will result in a user-defined paragraph with heading "Side Effects:". -# You can put \n's in the value part of an alias to insert newlines. - -ALIASES = - -# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C -# sources only. Doxygen will then generate output that is more tailored for C. -# For instance, some of the names that are used will be different. The list -# of all members will be omitted, etc. - -OPTIMIZE_OUTPUT_FOR_C = YES - -# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java -# sources only. Doxygen will then generate output that is more tailored for -# Java. For instance, namespaces will be presented as packages, qualified -# scopes will look different, etc. - -OPTIMIZE_OUTPUT_JAVA = NO - -# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran -# sources only. Doxygen will then generate output that is more tailored for -# Fortran. - -OPTIMIZE_FOR_FORTRAN = NO - -# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL -# sources. Doxygen will then generate output that is tailored for -# VHDL. - -OPTIMIZE_OUTPUT_VHDL = NO - -# Doxygen selects the parser to use depending on the extension of the files it parses. -# With this tag you can assign which parser to use for a given extension. -# Doxygen has a built-in mapping, but you can override or extend it using this tag. -# The format is ext=language, where ext is a file extension, and language is one of -# the parsers supported by doxygen: IDL, Java, Javascript, C#, C, C++, D, PHP, -# Objective-C, Python, Fortran, VHDL, C, C++. For instance to make doxygen treat -# .inc files as Fortran files (default is PHP), and .f files as C (default is Fortran), -# use: inc=Fortran f=C. Note that for custom extensions you also need to set FILE_PATTERNS otherwise the files are not read by doxygen. - -EXTENSION_MAPPING = - -# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want -# to include (a tag file for) the STL sources as input, then you should -# set this tag to YES in order to let doxygen match functions declarations and -# definitions whose arguments contain STL classes (e.g. func(std::string); v.s. -# func(std::string) {}). This also make the inheritance and collaboration -# diagrams that involve STL classes more complete and accurate. - -BUILTIN_STL_SUPPORT = YES - -# If you use Microsoft's C++/CLI language, you should set this option to YES to -# enable parsing support. - -CPP_CLI_SUPPORT = NO - -# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only. -# Doxygen will parse them like normal C++ but will assume all classes use public -# instead of private inheritance when no explicit protection keyword is present. - -SIP_SUPPORT = NO - -# For Microsoft's IDL there are propget and propput attributes to indicate getter -# and setter methods for a property. Setting this option to YES (the default) -# will make doxygen to replace the get and set methods by a property in the -# documentation. This will only work if the methods are indeed getting or -# setting a simple type. If this is not the case, or you want to show the -# methods anyway, you should set this option to NO. - -IDL_PROPERTY_SUPPORT = YES - -# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC -# tag is set to YES, then doxygen will reuse the documentation of the first -# member in the group (if any) for the other members of the group. By default -# all members of a group must be documented explicitly. - -DISTRIBUTE_GROUP_DOC = NO - -# Set the SUBGROUPING tag to YES (the default) to allow class member groups of -# the same type (for instance a group of public functions) to be put as a -# subgroup of that type (e.g. under the Public Functions section). Set it to -# NO to prevent subgrouping. Alternatively, this can be done per class using -# the \nosubgrouping command. - -SUBGROUPING = YES - -# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum -# is documented as struct, union, or enum with the name of the typedef. So -# typedef struct TypeS {} TypeT, will appear in the documentation as a struct -# with name TypeT. When disabled the typedef will appear as a member of a file, -# namespace, or class. And the struct will be named TypeS. This can typically -# be useful for C code in case the coding convention dictates that all compound -# types are typedef'ed and only the typedef is referenced, never the tag name. - -TYPEDEF_HIDES_STRUCT = NO - -# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to -# determine which symbols to keep in memory and which to flush to disk. -# When the cache is full, less often used symbols will be written to disk. -# For small to medium size projects (<1000 input files) the default value is -# probably good enough. For larger projects a too small cache size can cause -# doxygen to be busy swapping symbols to and from disk most of the time -# causing a significant performance penality. -# If the system has enough physical memory increasing the cache will improve the -# performance by keeping more symbols in memory. Note that the value works on -# a logarithmic scale so increasing the size by one will rougly double the -# memory usage. The cache size is given by this formula: -# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0, -# corresponding to a cache size of 2^16 = 65536 symbols - -SYMBOL_CACHE_SIZE = 0 - -#--------------------------------------------------------------------------- -# Build related configuration options -#--------------------------------------------------------------------------- - -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. -# Private class members and static file members will be hidden unless -# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES - -EXTRACT_ALL = NO - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class -# will be included in the documentation. - -EXTRACT_PRIVATE = NO - -# If the EXTRACT_STATIC tag is set to YES all static members of a file -# will be included in the documentation. - -EXTRACT_STATIC = NO - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) -# defined locally in source files will be included in the documentation. -# If set to NO only classes defined in header files are included. - -EXTRACT_LOCAL_CLASSES = NO - -# This flag is only useful for Objective-C code. When set to YES local -# methods, which are defined in the implementation section but not in -# the interface are included in the documentation. -# If set to NO (the default) only methods in the interface are included. - -EXTRACT_LOCAL_METHODS = NO - -# If this flag is set to YES, the members of anonymous namespaces will be -# extracted and appear in the documentation as a namespace called -# 'anonymous_namespace{file}', where file will be replaced with the base -# name of the file that contains the anonymous namespace. By default -# anonymous namespace are hidden. - -EXTRACT_ANON_NSPACES = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all -# undocumented members of documented classes, files or namespaces. -# If set to NO (the default) these members will be included in the -# various overviews, but no documentation section is generated. -# This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_MEMBERS = YES - -# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. -# If set to NO (the default) these classes will be included in the various -# overviews. This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_CLASSES = YES - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all -# friend (class|struct|union) declarations. -# If set to NO (the default) these declarations will be included in the -# documentation. - -HIDE_FRIEND_COMPOUNDS = YES - -# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any -# documentation blocks found inside the body of a function. -# If set to NO (the default) these blocks will be appended to the -# function's detailed documentation block. - -HIDE_IN_BODY_DOCS = YES - -# The INTERNAL_DOCS tag determines if documentation -# that is typed after a \internal command is included. If the tag is set -# to NO (the default) then the documentation will be excluded. -# Set it to YES to include the internal documentation. - -INTERNAL_DOCS = NO - -# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate -# file names in lower-case letters. If set to YES upper-case letters are also -# allowed. This is useful if you have classes or files whose names only differ -# in case and if your file system supports case sensitive file names. Windows -# and Mac users are advised to set this option to NO. - -CASE_SENSE_NAMES = YES - -# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen -# will show members with their full class and namespace scopes in the -# documentation. If set to YES the scope will be hidden. - -HIDE_SCOPE_NAMES = NO - -# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen -# will put a list of the files that are included by a file in the documentation -# of that file. - -SHOW_INCLUDE_FILES = NO - -# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] -# is inserted in the documentation for inline members. - -INLINE_INFO = YES - -# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen -# will sort the (detailed) documentation of file and class members -# alphabetically by member name. If set to NO the members will appear in -# declaration order. - -SORT_MEMBER_DOCS = YES - -# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the -# brief documentation of file, namespace and class members alphabetically -# by member name. If set to NO (the default) the members will appear in -# declaration order. - -SORT_BRIEF_DOCS = NO - -# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the (brief and detailed) documentation of class members so that constructors and destructors are listed first. If set to NO (the default) the constructors will appear in the respective orders defined by SORT_MEMBER_DOCS and SORT_BRIEF_DOCS. This tag will be ignored for brief docs if SORT_BRIEF_DOCS is set to NO and ignored for detailed docs if SORT_MEMBER_DOCS is set to NO. - -SORT_MEMBERS_CTORS_1ST = NO - -# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the -# hierarchy of group names into alphabetical order. If set to NO (the default) -# the group names will appear in their defined order. - -SORT_GROUP_NAMES = NO - -# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be -# sorted by fully-qualified names, including namespaces. If set to -# NO (the default), the class list will be sorted only by class name, -# not including the namespace part. -# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. -# Note: This option applies only to the class list, not to the -# alphabetical list. - -SORT_BY_SCOPE_NAME = NO - -# The GENERATE_TODOLIST tag can be used to enable (YES) or -# disable (NO) the todo list. This list is created by putting \todo -# commands in the documentation. - -GENERATE_TODOLIST = YES - -# The GENERATE_TESTLIST tag can be used to enable (YES) or -# disable (NO) the test list. This list is created by putting \test -# commands in the documentation. - -GENERATE_TESTLIST = YES - -# The GENERATE_BUGLIST tag can be used to enable (YES) or -# disable (NO) the bug list. This list is created by putting \bug -# commands in the documentation. - -GENERATE_BUGLIST = YES - -# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or -# disable (NO) the deprecated list. This list is created by putting -# \deprecated commands in the documentation. - -GENERATE_DEPRECATEDLIST= YES - -# The ENABLED_SECTIONS tag can be used to enable conditional -# documentation sections, marked by \if sectionname ... \endif. - -ENABLED_SECTIONS = - -# The MAX_INITIALIZER_LINES tag determines the maximum number of lines -# the initial value of a variable or define consists of for it to appear in -# the documentation. If the initializer consists of more lines than specified -# here it will be hidden. Use a value of 0 to hide initializers completely. -# The appearance of the initializer of individual variables and defines in the -# documentation can be controlled using \showinitializer or \hideinitializer -# command in the documentation regardless of this setting. - -MAX_INITIALIZER_LINES = 30 - -# Set the SHOW_USED_FILES tag to NO to disable the list of files generated -# at the bottom of the documentation of classes and structs. If set to YES the -# list will mention the files that were used to generate the documentation. - -SHOW_USED_FILES = NO - -# If the sources in your project are distributed over multiple directories -# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy -# in the documentation. The default is NO. - -SHOW_DIRECTORIES = NO - -# Set the SHOW_FILES tag to NO to disable the generation of the Files page. -# This will remove the Files entry from the Quick Index and from the -# Folder Tree View (if specified). The default is YES. - -SHOW_FILES = YES - -# Set the SHOW_NAMESPACES tag to NO to disable the generation of the -# Namespaces page. -# This will remove the Namespaces entry from the Quick Index -# and from the Folder Tree View (if specified). The default is YES. - -SHOW_NAMESPACES = YES - -# The FILE_VERSION_FILTER tag can be used to specify a program or script that -# doxygen should invoke to get the current version for each file (typically from -# the version control system). Doxygen will invoke the program by executing (via -# popen()) the command , where is the value of -# the FILE_VERSION_FILTER tag, and is the name of an input file -# provided by doxygen. Whatever the program writes to standard output -# is used as the file version. See the manual for examples. - -FILE_VERSION_FILTER = - -# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed by -# doxygen. The layout file controls the global structure of the generated output files -# in an output format independent way. The create the layout file that represents -# doxygen's defaults, run doxygen with the -l option. You can optionally specify a -# file name after the option, if omitted DoxygenLayout.xml will be used as the name -# of the layout file. - -LAYOUT_FILE = - -#--------------------------------------------------------------------------- -# configuration options related to warning and progress messages -#--------------------------------------------------------------------------- - -# The QUIET tag can be used to turn on/off the messages that are generated -# by doxygen. Possible values are YES and NO. If left blank NO is used. - -QUIET = NO - -# The WARNINGS tag can be used to turn on/off the warning messages that are -# generated by doxygen. Possible values are YES and NO. If left blank -# NO is used. - -WARNINGS = YES - -# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings -# for undocumented members. If EXTRACT_ALL is set to YES then this flag will -# automatically be disabled. - -WARN_IF_UNDOCUMENTED = YES - -# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for -# potential errors in the documentation, such as not documenting some -# parameters in a documented function, or documenting parameters that -# don't exist or using markup commands wrongly. - -WARN_IF_DOC_ERROR = YES - -# This WARN_NO_PARAMDOC option can be abled to get warnings for -# functions that are documented, but have no documentation for their parameters -# or return value. If set to NO (the default) doxygen will only warn about -# wrong or incomplete parameter documentation, but not about the absence of -# documentation. - -WARN_NO_PARAMDOC = NO - -# The WARN_FORMAT tag determines the format of the warning messages that -# doxygen can produce. The string should contain the $file, $line, and $text -# tags, which will be replaced by the file and line number from which the -# warning originated and the warning text. Optionally the format may contain -# $version, which will be replaced by the version of the file (if it could -# be obtained via FILE_VERSION_FILTER) - -WARN_FORMAT = "$file:$line: $text" - -# The WARN_LOGFILE tag can be used to specify a file to which warning -# and error messages should be written. If left blank the output is written -# to stderr. - -WARN_LOGFILE = - -#--------------------------------------------------------------------------- -# configuration options related to the input files -#--------------------------------------------------------------------------- - -# The INPUT tag can be used to specify the files and/or directories that contain -# documented source files. You may enter file names like "myfile.cpp" or -# directories like "/usr/src/myproject". Separate the files or directories -# with spaces. - -INPUT = ../export.h - -# This tag can be used to specify the character encoding of the source files -# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is -# also the default input encoding. Doxygen uses libiconv (or the iconv built -# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for -# the list of possible encodings. - -INPUT_ENCODING = UTF-8 - -# If the value of the INPUT tag contains directories, you can use the -# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank the following patterns are tested: -# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx -# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90 - -FILE_PATTERNS = - -# The RECURSIVE tag can be used to turn specify whether or not subdirectories -# should be searched for input files as well. Possible values are YES and NO. -# If left blank NO is used. - -RECURSIVE = YES - -# The EXCLUDE tag can be used to specify files and/or directories that should -# excluded from the INPUT source files. This way you can easily exclude a -# subdirectory from a directory tree whose root is specified with the INPUT tag. - -EXCLUDE = - -# The EXCLUDE_SYMLINKS tag can be used select whether or not files or -# directories that are symbolic links (a Unix filesystem feature) are excluded -# from the input. - -EXCLUDE_SYMLINKS = NO - -# If the value of the INPUT tag contains directories, you can use the -# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude -# certain files from those directories. Note that the wildcards are matched -# against the file with absolute path, so to exclude all test directories -# for example use the pattern */test/* - -EXCLUDE_PATTERNS = - -# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names -# (namespaces, classes, functions, etc.) that should be excluded from the -# output. The symbol name can be a fully qualified name, a word, or if the -# wildcard * is used, a substring. Examples: ANamespace, AClass, -# AClass::ANamespace, ANamespace::*Test - -EXCLUDE_SYMBOLS = - -# The EXAMPLE_PATH tag can be used to specify one or more files or -# directories that contain example code fragments that are included (see -# the \include command). - -EXAMPLE_PATH = .. - -# If the value of the EXAMPLE_PATH tag contains directories, you can use the -# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank all files are included. - -EXAMPLE_PATTERNS = - -# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be -# searched for input files to be used with the \include or \dontinclude -# commands irrespective of the value of the RECURSIVE tag. -# Possible values are YES and NO. If left blank NO is used. - -EXAMPLE_RECURSIVE = NO - -# The IMAGE_PATH tag can be used to specify one or more files or -# directories that contain image that are included in the documentation (see -# the \image command). - -IMAGE_PATH = - -# The INPUT_FILTER tag can be used to specify a program that doxygen should -# invoke to filter for each input file. Doxygen will invoke the filter program -# by executing (via popen()) the command , where -# is the value of the INPUT_FILTER tag, and is the name of an -# input file. Doxygen will then use the output that the filter program writes -# to standard output. -# If FILTER_PATTERNS is specified, this tag will be -# ignored. - -INPUT_FILTER = - -# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern -# basis. -# Doxygen will compare the file name with each pattern and apply the -# filter if there is a match. -# The filters are a list of the form: -# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further -# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER -# is applied to all files. - -FILTER_PATTERNS = - -# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using -# INPUT_FILTER) will be used to filter the input files when producing source -# files to browse (i.e. when SOURCE_BROWSER is set to YES). - -FILTER_SOURCE_FILES = NO - -#--------------------------------------------------------------------------- -# configuration options related to source browsing -#--------------------------------------------------------------------------- - -# If the SOURCE_BROWSER tag is set to YES then a list of source files will -# be generated. Documented entities will be cross-referenced with these sources. -# Note: To get rid of all source code in the generated output, make sure also -# VERBATIM_HEADERS is set to NO. - -SOURCE_BROWSER = NO - -# Setting the INLINE_SOURCES tag to YES will include the body -# of functions and classes directly in the documentation. - -INLINE_SOURCES = NO - -# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct -# doxygen to hide any special comment blocks from generated source code -# fragments. Normal C and C++ comments will always remain visible. - -STRIP_CODE_COMMENTS = YES - -# If the REFERENCED_BY_RELATION tag is set to YES -# then for each documented function all documented -# functions referencing it will be listed. - -REFERENCED_BY_RELATION = YES - -# If the REFERENCES_RELATION tag is set to YES -# then for each documented function all documented entities -# called/used by that function will be listed. - -REFERENCES_RELATION = YES - -# If the REFERENCES_LINK_SOURCE tag is set to YES (the default) -# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from -# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will -# link to the source code. -# Otherwise they will link to the documentation. - -REFERENCES_LINK_SOURCE = YES - -# If the USE_HTAGS tag is set to YES then the references to source code -# will point to the HTML generated by the htags(1) tool instead of doxygen -# built-in source browser. The htags tool is part of GNU's global source -# tagging system (see http://www.gnu.org/software/global/global.html). You -# will need version 4.8.6 or higher. - -USE_HTAGS = NO - -# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen -# will generate a verbatim copy of the header file for each class for -# which an include is specified. Set to NO to disable this. - -VERBATIM_HEADERS = NO - -#--------------------------------------------------------------------------- -# configuration options related to the alphabetical class index -#--------------------------------------------------------------------------- - -# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index -# of all compounds will be generated. Enable this if the project -# contains a lot of classes, structs, unions or interfaces. - -ALPHABETICAL_INDEX = NO - -# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then -# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns -# in which this list will be split (can be a number in the range [1..20]) - -COLS_IN_ALPHA_INDEX = 5 - -# In case all classes in a project start with a common prefix, all -# classes will be put under the same header in the alphabetical index. -# The IGNORE_PREFIX tag can be used to specify one or more prefixes that -# should be ignored while generating the index headers. - -IGNORE_PREFIX = - -#--------------------------------------------------------------------------- -# configuration options related to the HTML output -#--------------------------------------------------------------------------- - -# If the GENERATE_HTML tag is set to YES (the default) Doxygen will -# generate HTML output. - -GENERATE_HTML = YES - -# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `html' will be used as the default path. - -HTML_OUTPUT = html - -# The HTML_FILE_EXTENSION tag can be used to specify the file extension for -# each generated HTML page (for example: .htm,.php,.asp). If it is left blank -# doxygen will generate files with .html extension. - -HTML_FILE_EXTENSION = .html - -# The HTML_HEADER tag can be used to specify a personal HTML header for -# each generated HTML page. If it is left blank doxygen will generate a -# standard header. - -HTML_HEADER = header.html - -# The HTML_FOOTER tag can be used to specify a personal HTML footer for -# each generated HTML page. If it is left blank doxygen will generate a -# standard footer. - -HTML_FOOTER = footer.html - -# The HTML_STYLESHEET tag can be used to specify a user-defined cascading -# style sheet that is used by each HTML page. It can be used to -# fine-tune the look of the HTML output. If the tag is left blank doxygen -# will generate a default style sheet. Note that doxygen will try to copy -# the style sheet file to the HTML output directory, so don't put your own -# stylesheet in the HTML output directory as well, or it will be erased! - -HTML_STYLESHEET = - -# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, -# files or namespaces will be aligned in HTML using tables. If set to -# NO a bullet list will be used. - -HTML_ALIGN_MEMBERS = YES - -# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML -# documentation will contain sections that can be hidden and shown after the -# page has loaded. For this to work a browser that supports -# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox -# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari). - -HTML_DYNAMIC_SECTIONS = NO - -# If the GENERATE_DOCSET tag is set to YES, additional index files -# will be generated that can be used as input for Apple's Xcode 3 -# integrated development environment, introduced with OSX 10.5 (Leopard). -# To create a documentation set, doxygen will generate a Makefile in the -# HTML output directory. Running make will produce the docset in that -# directory and running "make install" will install the docset in -# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find -# it at startup. -# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html for more information. - -GENERATE_DOCSET = NO - -# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the -# feed. A documentation feed provides an umbrella under which multiple -# documentation sets from a single provider (such as a company or product suite) -# can be grouped. - -DOCSET_FEEDNAME = "Doxygen generated docs" - -# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that -# should uniquely identify the documentation set bundle. This should be a -# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen -# will append .docset to the name. - -DOCSET_BUNDLE_ID = org.doxygen.Project - -# If the GENERATE_HTMLHELP tag is set to YES, additional index files -# will be generated that can be used as input for tools like the -# Microsoft HTML help workshop to generate a compiled HTML help file (.chm) -# of the generated HTML documentation. - -GENERATE_HTMLHELP = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can -# be used to specify the file name of the resulting .chm file. You -# can add a path in front of the file if the result should not be -# written to the html output directory. - -CHM_FILE = - -# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can -# be used to specify the location (absolute path including file name) of -# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run -# the HTML help compiler on the generated index.hhp. - -HHC_LOCATION = - -# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag -# controls if a separate .chi index file is generated (YES) or that -# it should be included in the master .chm file (NO). - -GENERATE_CHI = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING -# is used to encode HtmlHelp index (hhk), content (hhc) and project file -# content. - -CHM_INDEX_ENCODING = - -# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag -# controls whether a binary table of contents is generated (YES) or a -# normal table of contents (NO) in the .chm file. - -BINARY_TOC = NO - -# The TOC_EXPAND flag can be set to YES to add extra items for group members -# to the contents of the HTML help documentation and to the tree view. - -TOC_EXPAND = NO - -# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and QHP_VIRTUAL_FOLDER -# are set, an additional index file will be generated that can be used as input for -# Qt's qhelpgenerator to generate a Qt Compressed Help (.qch) of the generated -# HTML documentation. - -GENERATE_QHP = NO - -# If the QHG_LOCATION tag is specified, the QCH_FILE tag can -# be used to specify the file name of the resulting .qch file. -# The path specified is relative to the HTML output folder. - -QCH_FILE = - -# The QHP_NAMESPACE tag specifies the namespace to use when generating -# Qt Help Project output. For more information please see -# http://doc.trolltech.com/qthelpproject.html#namespace - -QHP_NAMESPACE = - -# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating -# Qt Help Project output. For more information please see -# http://doc.trolltech.com/qthelpproject.html#virtual-folders - -QHP_VIRTUAL_FOLDER = doc - -# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom filter to add. -# For more information please see -# http://doc.trolltech.com/qthelpproject.html#custom-filters - -QHP_CUST_FILTER_NAME = - -# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of the custom filter to add.For more information please see -# Qt Help Project / Custom Filters. - -QHP_CUST_FILTER_ATTRS = - -# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this project's -# filter section matches. -# Qt Help Project / Filter Attributes. - -QHP_SECT_FILTER_ATTRS = - -# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can -# be used to specify the location of Qt's qhelpgenerator. -# If non-empty doxygen will try to run qhelpgenerator on the generated -# .qhp file. - -QHG_LOCATION = - -# The DISABLE_INDEX tag can be used to turn on/off the condensed index at -# top of each HTML page. The value NO (the default) enables the index and -# the value YES disables it. - -DISABLE_INDEX = NO - -# This tag can be used to set the number of enum values (range [1..20]) -# that doxygen will group on one line in the generated HTML documentation. - -ENUM_VALUES_PER_LINE = 4 - -# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index -# structure should be generated to display hierarchical information. -# If the tag value is set to YES, a side panel will be generated -# containing a tree-like index structure (just like the one that -# is generated for HTML Help). For this to work a browser that supports -# JavaScript, DHTML, CSS and frames is required (i.e. any modern browser). -# Windows users are probably better off using the HTML help feature. - -GENERATE_TREEVIEW = NO - -# By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories, -# and Class Hierarchy pages using a tree view instead of an ordered list. - -USE_INLINE_TREES = NO - -# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be -# used to set the initial width (in pixels) of the frame in which the tree -# is shown. - -TREEVIEW_WIDTH = 250 - -# Use this tag to change the font size of Latex formulas included -# as images in the HTML documentation. The default is 10. Note that -# when you change the font size after a successful doxygen run you need -# to manually remove any form_*.png images from the HTML output directory -# to force them to be regenerated. - -FORMULA_FONTSIZE = 10 - -# When the SEARCHENGINE tag is enable doxygen will generate a search box for the HTML output. The underlying search engine uses javascript -# and DHTML and should work on any modern browser. Note that when using HTML help (GENERATE_HTMLHELP) or Qt help (GENERATE_QHP) -# there is already a search function so this one should typically -# be disabled. - -SEARCHENGINE = NO - -#--------------------------------------------------------------------------- -# configuration options related to the LaTeX output -#--------------------------------------------------------------------------- - -# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will -# generate Latex output. - -GENERATE_LATEX = NO - -# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `latex' will be used as the default path. - -LATEX_OUTPUT = latex - -# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be -# invoked. If left blank `latex' will be used as the default command name. - -LATEX_CMD_NAME = latex - -# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to -# generate index for LaTeX. If left blank `makeindex' will be used as the -# default command name. - -MAKEINDEX_CMD_NAME = makeindex - -# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact -# LaTeX documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_LATEX = NO - -# The PAPER_TYPE tag can be used to set the paper type that is used -# by the printer. Possible values are: a4, a4wide, letter, legal and -# executive. If left blank a4wide will be used. - -PAPER_TYPE = a4wide - -# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX -# packages that should be included in the LaTeX output. - -EXTRA_PACKAGES = - -# The LATEX_HEADER tag can be used to specify a personal LaTeX header for -# the generated latex document. The header should contain everything until -# the first chapter. If it is left blank doxygen will generate a -# standard header. Notice: only use this tag if you know what you are doing! - -LATEX_HEADER = - -# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated -# is prepared for conversion to pdf (using ps2pdf). The pdf file will -# contain links (just like the HTML output) instead of page references -# This makes the output suitable for online browsing using a pdf viewer. - -PDF_HYPERLINKS = NO - -# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of -# plain latex in the generated Makefile. Set this option to YES to get a -# higher quality PDF documentation. - -USE_PDFLATEX = NO - -# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. -# command to the generated LaTeX files. This will instruct LaTeX to keep -# running if errors occur, instead of asking the user for help. -# This option is also used when generating formulas in HTML. - -LATEX_BATCHMODE = NO - -# If LATEX_HIDE_INDICES is set to YES then doxygen will not -# include the index chapters (such as File Index, Compound Index, etc.) -# in the output. - -LATEX_HIDE_INDICES = NO - -# If LATEX_SOURCE_CODE is set to YES then doxygen will include source code with syntax highlighting in the LaTeX output. Note that which sources are shown also depends on other settings such as SOURCE_BROWSER. - -LATEX_SOURCE_CODE = NO - -#--------------------------------------------------------------------------- -# configuration options related to the RTF output -#--------------------------------------------------------------------------- - -# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output -# The RTF output is optimized for Word 97 and may not look very pretty with -# other RTF readers or editors. - -GENERATE_RTF = NO - -# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `rtf' will be used as the default path. - -RTF_OUTPUT = rtf - -# If the COMPACT_RTF tag is set to YES Doxygen generates more compact -# RTF documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_RTF = NO - -# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated -# will contain hyperlink fields. The RTF file will -# contain links (just like the HTML output) instead of page references. -# This makes the output suitable for online browsing using WORD or other -# programs which support those fields. -# Note: wordpad (write) and others do not support links. - -RTF_HYPERLINKS = NO - -# Load stylesheet definitions from file. Syntax is similar to doxygen's -# config file, i.e. a series of assignments. You only have to provide -# replacements, missing definitions are set to their default value. - -RTF_STYLESHEET_FILE = - -# Set optional variables used in the generation of an rtf document. -# Syntax is similar to doxygen's config file. - -RTF_EXTENSIONS_FILE = - -#--------------------------------------------------------------------------- -# configuration options related to the man page output -#--------------------------------------------------------------------------- - -# If the GENERATE_MAN tag is set to YES (the default) Doxygen will -# generate man pages - -GENERATE_MAN = NO - -# The MAN_OUTPUT tag is used to specify where the man pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `man' will be used as the default path. - -MAN_OUTPUT = man - -# The MAN_EXTENSION tag determines the extension that is added to -# the generated man pages (default is the subroutine's section .3) - -MAN_EXTENSION = .3 - -# If the MAN_LINKS tag is set to YES and Doxygen generates man output, -# then it will generate one additional man file for each entity -# documented in the real man page(s). These additional files -# only source the real man page, but without them the man command -# would be unable to find the correct page. The default is NO. - -MAN_LINKS = NO - -#--------------------------------------------------------------------------- -# configuration options related to the XML output -#--------------------------------------------------------------------------- - -# If the GENERATE_XML tag is set to YES Doxygen will -# generate an XML file that captures the structure of -# the code including all documentation. - -GENERATE_XML = NO - -# The XML_OUTPUT tag is used to specify where the XML pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `xml' will be used as the default path. - -XML_OUTPUT = xml - -# The XML_SCHEMA tag can be used to specify an XML schema, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_SCHEMA = - -# The XML_DTD tag can be used to specify an XML DTD, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_DTD = - -# If the XML_PROGRAMLISTING tag is set to YES Doxygen will -# dump the program listings (including syntax highlighting -# and cross-referencing information) to the XML output. Note that -# enabling this will significantly increase the size of the XML output. - -XML_PROGRAMLISTING = YES - -#--------------------------------------------------------------------------- -# configuration options for the AutoGen Definitions output -#--------------------------------------------------------------------------- - -# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will -# generate an AutoGen Definitions (see autogen.sf.net) file -# that captures the structure of the code including all -# documentation. Note that this feature is still experimental -# and incomplete at the moment. - -GENERATE_AUTOGEN_DEF = NO - -#--------------------------------------------------------------------------- -# configuration options related to the Perl module output -#--------------------------------------------------------------------------- - -# If the GENERATE_PERLMOD tag is set to YES Doxygen will -# generate a Perl module file that captures the structure of -# the code including all documentation. Note that this -# feature is still experimental and incomplete at the -# moment. - -GENERATE_PERLMOD = NO - -# If the PERLMOD_LATEX tag is set to YES Doxygen will generate -# the necessary Makefile rules, Perl scripts and LaTeX code to be able -# to generate PDF and DVI output from the Perl module output. - -PERLMOD_LATEX = NO - -# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be -# nicely formatted so it can be parsed by a human reader. -# This is useful -# if you want to understand what is going on. -# On the other hand, if this -# tag is set to NO the size of the Perl module output will be much smaller -# and Perl will parse it just the same. - -PERLMOD_PRETTY = YES - -# The names of the make variables in the generated doxyrules.make file -# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. -# This is useful so different doxyrules.make files included by the same -# Makefile don't overwrite each other's variables. - -PERLMOD_MAKEVAR_PREFIX = - -#--------------------------------------------------------------------------- -# Configuration options related to the preprocessor -#--------------------------------------------------------------------------- - -# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will -# evaluate all C-preprocessor directives found in the sources and include -# files. - -ENABLE_PREPROCESSING = YES - -# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro -# names in the source code. If set to NO (the default) only conditional -# compilation will be performed. Macro expansion can be done in a controlled -# way by setting EXPAND_ONLY_PREDEF to YES. - -MACRO_EXPANSION = NO - -# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES -# then the macro expansion is limited to the macros specified with the -# PREDEFINED and EXPAND_AS_DEFINED tags. - -EXPAND_ONLY_PREDEF = NO - -# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files -# in the INCLUDE_PATH (see below) will be search if a #include is found. - -SEARCH_INCLUDES = YES - -# The INCLUDE_PATH tag can be used to specify one or more directories that -# contain include files that are not input files but should be processed by -# the preprocessor. - -INCLUDE_PATH = - -# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard -# patterns (like *.h and *.hpp) to filter out the header-files in the -# directories. If left blank, the patterns specified with FILE_PATTERNS will -# be used. - -INCLUDE_FILE_PATTERNS = - -# The PREDEFINED tag can be used to specify one or more macro names that -# are defined before the preprocessor is started (similar to the -D option of -# gcc). The argument of the tag is a list of macros of the form: name -# or name=definition (no spaces). If the definition and the = are -# omitted =1 is assumed. To prevent a macro definition from being -# undefined via #undef or recursively expanded use the := operator -# instead of the = operator. - -PREDEFINED = DOXYGEN_SHOULD_SKIP_THIS - -# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then -# this tag can be used to specify a list of macro names that should be expanded. -# The macro definition that is found in the sources will be used. -# Use the PREDEFINED tag if you want to use a different macro definition. - -EXPAND_AS_DEFINED = - -# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then -# doxygen's preprocessor will remove all function-like macros that are alone -# on a line, have an all uppercase name, and do not end with a semicolon. Such -# function macros are typically used for boiler-plate code, and will confuse -# the parser if not removed. - -SKIP_FUNCTION_MACROS = YES - -#--------------------------------------------------------------------------- -# Configuration::additions related to external references -#--------------------------------------------------------------------------- - -# The TAGFILES option can be used to specify one or more tagfiles. -# Optionally an initial location of the external documentation -# can be added for each tagfile. The format of a tag file without -# this location is as follows: -# -# TAGFILES = file1 file2 ... -# Adding location for the tag files is done as follows: -# -# TAGFILES = file1=loc1 "file2 = loc2" ... -# where "loc1" and "loc2" can be relative or absolute paths or -# URLs. If a location is present for each tag, the installdox tool -# does not have to be run to correct the links. -# Note that each tag file must have a unique name -# (where the name does NOT include the path) -# If a tag file is not located in the directory in which doxygen -# is run, you must also specify the path to the tagfile here. - -TAGFILES = - -# When a file name is specified after GENERATE_TAGFILE, doxygen will create -# a tag file that is based on the input files it reads. - -GENERATE_TAGFILE = - -# If the ALLEXTERNALS tag is set to YES all external classes will be listed -# in the class index. If set to NO only the inherited external classes -# will be listed. - -ALLEXTERNALS = NO - -# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed -# in the modules index. If set to NO, only the current project's groups will -# be listed. - -EXTERNAL_GROUPS = YES - -# The PERL_PATH should be the absolute path and name of the perl script -# interpreter (i.e. the result of `which perl'). - -PERL_PATH = /usr/bin/perl - -#--------------------------------------------------------------------------- -# Configuration options related to the dot tool -#--------------------------------------------------------------------------- - -# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will -# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base -# or super classes. Setting the tag to NO turns the diagrams off. Note that -# this option is superseded by the HAVE_DOT option below. This is only a -# fallback. It is recommended to install and use dot, since it yields more -# powerful graphs. - -CLASS_DIAGRAMS = NO - -# You can define message sequence charts within doxygen comments using the \msc -# command. Doxygen will then run the mscgen tool (see -# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the -# documentation. The MSCGEN_PATH tag allows you to specify the directory where -# the mscgen tool resides. If left empty the tool is assumed to be found in the -# default search path. - -MSCGEN_PATH = - -# If set to YES, the inheritance and collaboration graphs will hide -# inheritance and usage relations if the target is undocumented -# or is not a class. - -HIDE_UNDOC_RELATIONS = YES - -# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is -# available from the path. This tool is part of Graphviz, a graph visualization -# toolkit from AT&T and Lucent Bell Labs. The other options in this section -# have no effect if this option is set to NO (the default) - -HAVE_DOT = NO - -# By default doxygen will write a font called FreeSans.ttf to the output -# directory and reference it in all dot files that doxygen generates. This -# font does not include all possible unicode characters however, so when you need -# these (or just want a differently looking font) you can specify the font name -# using DOT_FONTNAME. You need need to make sure dot is able to find the font, -# which can be done by putting it in a standard location or by setting the -# DOTFONTPATH environment variable or by setting DOT_FONTPATH to the directory -# containing the font. - -DOT_FONTNAME = FreeSans - -# The DOT_FONTSIZE tag can be used to set the size of the font of dot graphs. -# The default size is 10pt. - -DOT_FONTSIZE = 10 - -# By default doxygen will tell dot to use the output directory to look for the -# FreeSans.ttf font (which doxygen will put there itself). If you specify a -# different font using DOT_FONTNAME you can set the path where dot -# can find it using this tag. - -DOT_FONTPATH = - -# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect inheritance relations. Setting this tag to YES will force the -# the CLASS_DIAGRAMS tag to NO. - -CLASS_GRAPH = NO - -# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect implementation dependencies (inheritance, containment, and -# class references variables) of the class with other documented classes. - -COLLABORATION_GRAPH = NO - -# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for groups, showing the direct groups dependencies - -GROUP_GRAPHS = NO - -# If the UML_LOOK tag is set to YES doxygen will generate inheritance and -# collaboration diagrams in a style similar to the OMG's Unified Modeling -# Language. - -UML_LOOK = NO - -# If set to YES, the inheritance and collaboration graphs will show the -# relations between templates and their instances. - -TEMPLATE_RELATIONS = NO - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT -# tags are set to YES then doxygen will generate a graph for each documented -# file showing the direct and indirect include dependencies of the file with -# other documented files. - -INCLUDE_GRAPH = NO - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and -# HAVE_DOT tags are set to YES then doxygen will generate a graph for each -# documented header file showing the documented files that directly or -# indirectly include this file. - -INCLUDED_BY_GRAPH = NO - -# If the CALL_GRAPH and HAVE_DOT options are set to YES then -# doxygen will generate a call dependency graph for every global function -# or class method. Note that enabling this option will significantly increase -# the time of a run. So in most cases it will be better to enable call graphs -# for selected functions only using the \callgraph command. - -CALL_GRAPH = NO - -# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then -# doxygen will generate a caller dependency graph for every global function -# or class method. Note that enabling this option will significantly increase -# the time of a run. So in most cases it will be better to enable caller -# graphs for selected functions only using the \callergraph command. - -CALLER_GRAPH = NO - -# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen -# will graphical hierarchy of all classes instead of a textual one. - -GRAPHICAL_HIERARCHY = NO - -# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES -# then doxygen will show the dependencies a directory has on other directories -# in a graphical way. The dependency relations are determined by the #include -# relations between the files in the directories. - -DIRECTORY_GRAPH = YES - -# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images -# generated by dot. Possible values are png, jpg, or gif -# If left blank png will be used. - -DOT_IMAGE_FORMAT = png - -# The tag DOT_PATH can be used to specify the path where the dot tool can be -# found. If left blank, it is assumed the dot tool can be found in the path. - -DOT_PATH = - -# The DOTFILE_DIRS tag can be used to specify one or more directories that -# contain dot files that are included in the documentation (see the -# \dotfile command). - -DOTFILE_DIRS = - -# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of -# nodes that will be shown in the graph. If the number of nodes in a graph -# becomes larger than this value, doxygen will truncate the graph, which is -# visualized by representing a node as a red box. Note that doxygen if the -# number of direct children of the root node in a graph is already larger than -# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note -# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. - -DOT_GRAPH_MAX_NODES = 50 - -# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the -# graphs generated by dot. A depth value of 3 means that only nodes reachable -# from the root by following a path via at most 3 edges will be shown. Nodes -# that lay further from the root node will be omitted. Note that setting this -# option to 1 or 2 may greatly reduce the computation time needed for large -# code bases. Also note that the size of a graph can be further restricted by -# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction. - -MAX_DOT_GRAPH_DEPTH = 0 - -# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent -# background. This is disabled by default, because dot on Windows does not -# seem to support this out of the box. Warning: Depending on the platform used, -# enabling this option may lead to badly anti-aliased labels on the edges of -# a graph (i.e. they become hard to read). - -DOT_TRANSPARENT = NO - -# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output -# files in one run (i.e. multiple -o and -T options on the command line). This -# makes dot run faster, but since only newer versions of dot (>1.8.10) -# support this, this feature is disabled by default. - -DOT_MULTI_TARGETS = NO - -# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will -# generate a legend page explaining the meaning of the various boxes and -# arrows in the dot generated graphs. - -GENERATE_LEGEND = YES - -# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will -# remove the intermediate dot files that are used to generate -# the various graphs. - -DOT_CLEANUP = YES diff --git a/swig/doc/footer.html b/swig/doc/footer.html deleted file mode 100644 index 834ec63..0000000 --- a/swig/doc/footer.html +++ /dev/null @@ -1,7 +0,0 @@ -
-
-Copyright (c) 2002-2010 by Naoaki Okazaki -
$datetime -
- - diff --git a/swig/doc/header.html b/swig/doc/header.html deleted file mode 100644 index fca500e..0000000 --- a/swig/doc/header.html +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - -SimString: A fast and efficient implementation of approximate string matching - - - - diff --git a/swig/export.i b/swig/export.i deleted file mode 100644 index 791ec4b..0000000 --- a/swig/export.i +++ /dev/null @@ -1,30 +0,0 @@ -%module simstring - -%{ -#include "export.h" -%} - -%include "std_string.i" -%include "std_vector.i" -%include "exception.i" - -namespace std { - %template(StringVector) vector; -} - -%exception { - try { - $action - } catch(const std::invalid_argument& e) { - SWIG_exception(SWIG_IOError, e.what()); - } catch(const std::runtime_error& e) { - SWIG_exception(SWIG_RuntimeError, e.what()); - } catch (const std::exception& e) { - SWIG_exception(SWIG_RuntimeError, e.what()); - } catch(...) { - SWIG_exception(SWIG_RuntimeError,"Unknown exception"); - } -} - -%include "export.h" - diff --git a/swig/java/Makefile b/swig/java/Makefile deleted file mode 100644 index 7b9b495..0000000 --- a/swig/java/Makefile +++ /dev/null @@ -1,17 +0,0 @@ -# -# SWIG example make file for Linux -# -all: - g++ -fPIC -c export.cpp -I../../include - g++ -fPIC -c export_wrap.cpp - g++ -shared export.o export_wrap.o -o libSimString.so - -sample: - javac simstring/*.java - javac Sample.java - -clean: - rm -rf *.o *.so *.cpp *.class export.* simstring - -purge: - rm -rf *.o *.so *.cpp export.* simstring diff --git a/swig/java/Sample.java b/swig/java/Sample.java deleted file mode 100644 index e8b5dc4..0000000 --- a/swig/java/Sample.java +++ /dev/null @@ -1,53 +0,0 @@ -import simstring.*; - -public class Sample { - static { - try { - System.loadLibrary("SimString"); - } catch (UnsatisfiedLinkError e) { - System.err.println("Couldn't find the SimString library."); - } - } - - private static void sampleWriter() { - // Create a SimString database with two person names. - writer db = new writer("sample.db", 3, false, false); - db.insert("Barack Hussein Obama II"); - db.insert("James Gordon Brown"); - db.close(); - } - - private static void output(StringVector strs) { - // Output the retrieved strings separated by ", ". - for (int i = 0;i < strs.size();++i) { - if (i != 0) { - System.out.print(", "); - } - System.out.print(strs.get(i)); - } - System.out.print('\n'); - } - - private static void sampleReader() { - // Open the database for reading. - reader db = new reader("sample.db"); - - // Use cosine similarity and threshold 0.6. - db.setMeasure(simstringConstants.cosine); - db.setThreshold(0.6); - output(db.retrieve("Barack Obama")); - output(db.retrieve("Gordon Brown")); - output(db.retrieve("Obama")); - - // Use overlap coefficient and threshold 1.0. - db.setMeasure(simstringConstants.overlap); - db.setThreshold(1.); - output(db.retrieve("Obama")); - } - - public static void main(String[] args) { - sampleWriter(); - sampleReader(); - } -} - diff --git a/swig/java/prepare.sh b/swig/java/prepare.sh deleted file mode 100755 index f07933a..0000000 --- a/swig/java/prepare.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/sh - -ln -s ../export.cpp -ln -s ../export.h -ln -s ../export.i - -if [ "$1" = "--swig" ]; -then - mkdir simstring - swig -c++ -java -package simstring -outdir simstring -o export_wrap.cpp export.i -fi diff --git a/swig/java/run_sample.sh b/swig/java/run_sample.sh deleted file mode 100755 index de3fcb1..0000000 --- a/swig/java/run_sample.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -LD_LIBRARY_PATH=.:$LD_LIBRARY_PATH java Sample - diff --git a/swig/perl/Makefile.PL.in b/swig/perl/Makefile.PL.in deleted file mode 100644 index 5046b74..0000000 --- a/swig/perl/Makefile.PL.in +++ /dev/null @@ -1,14 +0,0 @@ -use 5.008; -use strict; -use warnings; -use ExtUtils::MakeMaker; - -WriteMakefile( - 'CC' => 'g++', - 'LD' => 'g++', - 'NAME' => '@PACKAGE@', - 'VERSION' => '@VERSION@', - 'OBJECT' => 'export.o export_wrap.o', - 'OPTIMIZE' => '-O2', - 'INC' => '-I../../include', -); diff --git a/swig/perl/prepare.sh b/swig/perl/prepare.sh deleted file mode 100755 index 51e1d98..0000000 --- a/swig/perl/prepare.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/sh -# $Id:$ - -ln -s ../export.cpp -ln -s ../export.h -ln -s ../export.i - -if [ "$1" = "--swig" ]; -then - swig -c++ -perl -o export_wrap.cpp export.i -fi diff --git a/swig/perl/run_sample.sh b/swig/perl/run_sample.sh deleted file mode 100755 index 289066e..0000000 --- a/swig/perl/run_sample.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -perl -I./blib/arch sample.pl diff --git a/swig/perl/sample.pl b/swig/perl/sample.pl deleted file mode 100644 index 0d2e7c7..0000000 --- a/swig/perl/sample.pl +++ /dev/null @@ -1,28 +0,0 @@ -#!/usr/bin/env perl - -use warnings; -use strict; -use simstring; - -# Create a SimString database with two person names. -my $db = simstring::writer->new('sample.db'); -$db->insert('Barack Hussein Obama II'); -$db->insert('James Gordon Brown'); -$db->close; - -# Open the database for reading. -$db = simstring::reader->new('sample.db'); - -# Use cosine similarity and threshold 0.6. -$db->swig_measure_set($simstring::cosine); -$db->swig_threshold_set(0.6); -print @{ $db->retrieve('Barack Obama') }, "\n"; # OK. -print @{ $db->retrieve('Gordon Brown') }, "\n"; # OK. -print @{ $db->retrieve('Obama') }, "\n"; # Too dissimilar! - -# Use overlap coefficient and threshold 1.0. -$db->swig_measure_set($simstring::overlap); -$db->swig_threshold_set(1); -print @{ $db->retrieve('Obama') }, "\n"; # OK. - -__END__ diff --git a/swig/perl/t/00_compile.t b/swig/perl/t/00_compile.t deleted file mode 100644 index 3600a54..0000000 --- a/swig/perl/t/00_compile.t +++ /dev/null @@ -1,9 +0,0 @@ -use strict; -use warnings; -use Test::More tests => 2; -use simstring; - -BEGIN{ - use_ok 'simstring'; -} -require_ok( 'simstring' ); diff --git a/swig/perl/t/01_usage.t b/swig/perl/t/01_usage.t deleted file mode 100644 index 4ab68e6..0000000 --- a/swig/perl/t/01_usage.t +++ /dev/null @@ -1,44 +0,0 @@ -use strict; -use warnings; -use Test::More tests => 8; -use simstring; - -# *insert = *simstringc::writer_insert; -# *close = *simstringc::writer_close; - -# *retrieve = *simstringc::reader_retrieve; -# *close = *simstringc::reader_close; -# *swig_measure_get = *simstringc::reader_measure_get; -# *swig_measure_set = *simstringc::reader_measure_set; -# *swig_threshold_get = *simstringc::reader_threshold_get; -# *swig_threshold_set = *simstringc::reader_threshold_set; - -# *exact = *simstringc::exact; 0 -# *dice = *simstringc::dice; 1 -# *cosine = *simstringc::cosine; 2 -# *jaccard = *simstringc::jaccard; 3 -# *overlap = *simstringc::overlap; 4 - -my $db = simstring::writer->new('sample.db'); -ok( $db, 'writer->new' ); -$db->insert('Barack Hussein Obama II'); -$db->insert('James Gordon Brown'); -$db->close; - -$db = simstring::reader->new('sample.db'); -ok( $db, 'reader->new' ); -$db->swig_measure_set($simstring::cosine); -ok( $db->swig_measure_get == 2, 'measure_get: cosine' ); -$db->swig_threshold_set(0.6); -ok( $db->swig_threshold_get == 0.6, 'threshold_get: 0.6' ); - -ok( ( scalar @{ $db->retrieve('Barack Obama') } == 1 - && scalar @{ $db->retrieve('Gordon Brown') } == 1 - && scalar @{ $db->retrieve('Obama') } == 0), 'retrieve (cosine 0.6)' ); - -$db->swig_measure_set($simstring::overlap); -ok( $db->swig_measure_get == 4, 'measure_get: overlap' ); -$db->swig_threshold_set(1); -ok( $db->swig_threshold_get == 1, 'threshold_get: 1' ); - -ok( scalar @{ $db->retrieve('Obama') } == 1, 'retrieve (overlap 1)' ); diff --git a/swig/perl/t/02_usage.t b/swig/perl/t/02_usage.t deleted file mode 100644 index f654e65..0000000 --- a/swig/perl/t/02_usage.t +++ /dev/null @@ -1,36 +0,0 @@ -use strict; -use warnings; -use Test::More tests => 5; -use simstring; -use utf8; - -# *insert = *simstringc::writer_insert; -# *close = *simstringc::writer_close; - -# *retrieve = *simstringc::reader_retrieve; -# *close = *simstringc::reader_close; -# *swig_measure_get = *simstringc::reader_measure_get; -# *swig_measure_set = *simstringc::reader_measure_set; -# *swig_threshold_get = *simstringc::reader_threshold_get; -# *swig_threshold_set = *simstringc::reader_threshold_set; - -# *exact = *simstringc::exact; 0 -# *dice = *simstringc::dice; 1 -# *cosine = *simstringc::cosine; 2 -# *jaccard = *simstringc::jaccard; 3 -# *overlap = *simstringc::overlap; 4 - -my $db = simstring::writer->new('sample_unicode.db', 3, undef, 1); -ok( $db, 'writer->new' ); -$db->insert('スパゲティ'); -$db->close; - -$db = simstring::reader->new('sample_unicode.db'); -ok( $db, 'reader->new' ); -$db->swig_measure_set($simstring::cosine); -ok( $db->swig_measure_get == 2, 'measure_get: cosine' ); -$db->swig_threshold_set(0.6); -ok( $db->swig_threshold_get == 0.6, 'threshold_get: 0.6' ); - -ok( scalar @{ $db->retrieve('スパゲティー') } == 1, 'retrieve (cosine 0.6)' ); - diff --git a/swig/python/prepare.sh b/swig/python/prepare.sh deleted file mode 100755 index 2bf1095..0000000 --- a/swig/python/prepare.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/sh -# $Id:$ - -ln -s ../export.cpp -ln -s ../export.h -ln -s ../export.i - -if [ "$1" = "--swig" ]; -then - swig -c++ -python -o export_wrap.cpp export.i -fi diff --git a/swig/python/simstring.py b/swig/python/simstring.py deleted file mode 100644 index 9a19f45..0000000 --- a/swig/python/simstring.py +++ /dev/null @@ -1,344 +0,0 @@ -# This file was automatically generated by SWIG (http://www.swig.org). -# Version 3.0.10 -# -# Do not make changes to this file unless you know what you are doing--modify -# the SWIG interface file instead. - - - - - -from sys import version_info as _swig_python_version_info -if _swig_python_version_info >= (2, 7, 0): - def swig_import_helper(): - import importlib - pkg = __name__.rpartition('.')[0] - mname = '.'.join((pkg, '_simstring')).lstrip('.') - try: - return importlib.import_module(mname) - except ImportError: - return importlib.import_module('_simstring') - _simstring = swig_import_helper() - del swig_import_helper -elif _swig_python_version_info >= (2, 6, 0): - def swig_import_helper(): - from os.path import dirname - import imp - fp = None - try: - fp, pathname, description = imp.find_module('_simstring', [dirname(__file__)]) - except ImportError: - import _simstring - return _simstring - if fp is not None: - try: - _mod = imp.load_module('_simstring', fp, pathname, description) - finally: - fp.close() - return _mod - _simstring = swig_import_helper() - del swig_import_helper -else: - import _simstring -del _swig_python_version_info -try: - _swig_property = property -except NameError: - pass # Python < 2.2 doesn't have 'property'. - -try: - import builtins as __builtin__ -except ImportError: - import __builtin__ - -def _swig_setattr_nondynamic(self, class_type, name, value, static=1): - if (name == "thisown"): - return self.this.own(value) - if (name == "this"): - if type(value).__name__ == 'SwigPyObject': - self.__dict__[name] = value - return - method = class_type.__swig_setmethods__.get(name, None) - if method: - return method(self, value) - if (not static): - if _newclass: - object.__setattr__(self, name, value) - else: - self.__dict__[name] = value - else: - raise AttributeError("You cannot add attributes to %s" % self) - - -def _swig_setattr(self, class_type, name, value): - return _swig_setattr_nondynamic(self, class_type, name, value, 0) - - -def _swig_getattr(self, class_type, name): - if (name == "thisown"): - return self.this.own() - method = class_type.__swig_getmethods__.get(name, None) - if method: - return method(self) - raise AttributeError("'%s' object has no attribute '%s'" % (class_type.__name__, name)) - - -def _swig_repr(self): - try: - strthis = "proxy of " + self.this.__repr__() - except __builtin__.Exception: - strthis = "" - return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) - -try: - _object = object - _newclass = 1 -except __builtin__.Exception: - class _object: - pass - _newclass = 0 - -class SwigPyIterator(_object): - __swig_setmethods__ = {} - __setattr__ = lambda self, name, value: _swig_setattr(self, SwigPyIterator, name, value) - __swig_getmethods__ = {} - __getattr__ = lambda self, name: _swig_getattr(self, SwigPyIterator, name) - - def __init__(self, *args, **kwargs): - raise AttributeError("No constructor defined - class is abstract") - __repr__ = _swig_repr - __swig_destroy__ = _simstring.delete_SwigPyIterator - __del__ = lambda self: None - - def value(self): - return _simstring.SwigPyIterator_value(self) - - def incr(self, n=1): - return _simstring.SwigPyIterator_incr(self, n) - - def decr(self, n=1): - return _simstring.SwigPyIterator_decr(self, n) - - def distance(self, x): - return _simstring.SwigPyIterator_distance(self, x) - - def equal(self, x): - return _simstring.SwigPyIterator_equal(self, x) - - def copy(self): - return _simstring.SwigPyIterator_copy(self) - - def next(self): - return _simstring.SwigPyIterator_next(self) - - def __next__(self): - return _simstring.SwigPyIterator___next__(self) - - def previous(self): - return _simstring.SwigPyIterator_previous(self) - - def advance(self, n): - return _simstring.SwigPyIterator_advance(self, n) - - def __eq__(self, x): - return _simstring.SwigPyIterator___eq__(self, x) - - def __ne__(self, x): - return _simstring.SwigPyIterator___ne__(self, x) - - def __iadd__(self, n): - return _simstring.SwigPyIterator___iadd__(self, n) - - def __isub__(self, n): - return _simstring.SwigPyIterator___isub__(self, n) - - def __add__(self, n): - return _simstring.SwigPyIterator___add__(self, n) - - def __sub__(self, *args): - return _simstring.SwigPyIterator___sub__(self, *args) - def __iter__(self): - return self -SwigPyIterator_swigregister = _simstring.SwigPyIterator_swigregister -SwigPyIterator_swigregister(SwigPyIterator) - -class StringVector(_object): - __swig_setmethods__ = {} - __setattr__ = lambda self, name, value: _swig_setattr(self, StringVector, name, value) - __swig_getmethods__ = {} - __getattr__ = lambda self, name: _swig_getattr(self, StringVector, name) - __repr__ = _swig_repr - - def iterator(self): - return _simstring.StringVector_iterator(self) - def __iter__(self): - return self.iterator() - - def __nonzero__(self): - return _simstring.StringVector___nonzero__(self) - - def __bool__(self): - return _simstring.StringVector___bool__(self) - - def __len__(self): - return _simstring.StringVector___len__(self) - - def __getslice__(self, i, j): - return _simstring.StringVector___getslice__(self, i, j) - - def __setslice__(self, *args): - return _simstring.StringVector___setslice__(self, *args) - - def __delslice__(self, i, j): - return _simstring.StringVector___delslice__(self, i, j) - - def __delitem__(self, *args): - return _simstring.StringVector___delitem__(self, *args) - - def __getitem__(self, *args): - return _simstring.StringVector___getitem__(self, *args) - - def __setitem__(self, *args): - return _simstring.StringVector___setitem__(self, *args) - - def pop(self): - return _simstring.StringVector_pop(self) - - def append(self, x): - return _simstring.StringVector_append(self, x) - - def empty(self): - return _simstring.StringVector_empty(self) - - def size(self): - return _simstring.StringVector_size(self) - - def swap(self, v): - return _simstring.StringVector_swap(self, v) - - def begin(self): - return _simstring.StringVector_begin(self) - - def end(self): - return _simstring.StringVector_end(self) - - def rbegin(self): - return _simstring.StringVector_rbegin(self) - - def rend(self): - return _simstring.StringVector_rend(self) - - def clear(self): - return _simstring.StringVector_clear(self) - - def get_allocator(self): - return _simstring.StringVector_get_allocator(self) - - def pop_back(self): - return _simstring.StringVector_pop_back(self) - - def erase(self, *args): - return _simstring.StringVector_erase(self, *args) - - def __init__(self, *args): - this = _simstring.new_StringVector(*args) - try: - self.this.append(this) - except __builtin__.Exception: - self.this = this - - def push_back(self, x): - return _simstring.StringVector_push_back(self, x) - - def front(self): - return _simstring.StringVector_front(self) - - def back(self): - return _simstring.StringVector_back(self) - - def assign(self, n, x): - return _simstring.StringVector_assign(self, n, x) - - def resize(self, *args): - return _simstring.StringVector_resize(self, *args) - - def insert(self, *args): - return _simstring.StringVector_insert(self, *args) - - def reserve(self, n): - return _simstring.StringVector_reserve(self, n) - - def capacity(self): - return _simstring.StringVector_capacity(self) - __swig_destroy__ = _simstring.delete_StringVector - __del__ = lambda self: None -StringVector_swigregister = _simstring.StringVector_swigregister -StringVector_swigregister(StringVector) - -exact = _simstring.exact -dice = _simstring.dice -cosine = _simstring.cosine -jaccard = _simstring.jaccard -overlap = _simstring.overlap -class writer(_object): - __swig_setmethods__ = {} - __setattr__ = lambda self, name, value: _swig_setattr(self, writer, name, value) - __swig_getmethods__ = {} - __getattr__ = lambda self, name: _swig_getattr(self, writer, name) - __repr__ = _swig_repr - - def __init__(self, filename, n=3, be=False, unicode=False): - this = _simstring.new_writer(filename, n, be, unicode) - try: - self.this.append(this) - except __builtin__.Exception: - self.this = this - __swig_destroy__ = _simstring.delete_writer - __del__ = lambda self: None - - def insert(self, string): - return _simstring.writer_insert(self, string) - - def close(self): - return _simstring.writer_close(self) -writer_swigregister = _simstring.writer_swigregister -writer_swigregister(writer) - -class reader(_object): - __swig_setmethods__ = {} - __setattr__ = lambda self, name, value: _swig_setattr(self, reader, name, value) - __swig_getmethods__ = {} - __getattr__ = lambda self, name: _swig_getattr(self, reader, name) - __repr__ = _swig_repr - - def __init__(self, filename): - this = _simstring.new_reader(filename) - try: - self.this.append(this) - except __builtin__.Exception: - self.this = this - __swig_destroy__ = _simstring.delete_reader - __del__ = lambda self: None - - def retrieve(self, query): - return _simstring.reader_retrieve(self, query) - - def check(self, query): - return _simstring.reader_check(self, query) - - def close(self): - return _simstring.reader_close(self) - __swig_setmethods__["measure"] = _simstring.reader_measure_set - __swig_getmethods__["measure"] = _simstring.reader_measure_get - if _newclass: - measure = _swig_property(_simstring.reader_measure_get, _simstring.reader_measure_set) - __swig_setmethods__["threshold"] = _simstring.reader_threshold_set - __swig_getmethods__["threshold"] = _simstring.reader_threshold_get - if _newclass: - threshold = _swig_property(_simstring.reader_threshold_get, _simstring.reader_threshold_set) -reader_swigregister = _simstring.reader_swigregister -reader_swigregister(reader) - -# This file is compatible with both classic and new-style classes. - - diff --git a/swig/ruby/extconf.rb.in b/swig/ruby/extconf.rb.in deleted file mode 100644 index 74e1bd0..0000000 --- a/swig/ruby/extconf.rb.in +++ /dev/null @@ -1,6 +0,0 @@ -require 'mkmf' -$CFLAGS='-I../../include' -$LDFLAGS="-lstdc++" - -create_makefile('@PACKAGE@') - diff --git a/swig/ruby/prepare.sh b/swig/ruby/prepare.sh deleted file mode 100755 index 3e3f0b3..0000000 --- a/swig/ruby/prepare.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/sh -# $Id:$ - -ln -s ../export.cpp -ln -s ../export.h -ln -s ../export.i - -if [ "$1" = "--swig" ]; -then - swig -c++ -ruby -o export_wrap.cpp export.i -fi - - diff --git a/swig/ruby/sample.rb b/swig/ruby/sample.rb deleted file mode 100644 index 1a8f04d..0000000 --- a/swig/ruby/sample.rb +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env ruby - -require 'simstring' - -# Create a SimString database with two person names. -db = Simstring::Writer.new('sample.db') -db.insert('Barack Hussein Obama II') -db.insert('James Gordon Brown') -db.close() - - -# Open the database for reading. -db = Simstring::Reader.new('sample.db') - -# Use cosine similarity and threshold 0.6. -db.measure = Simstring::Cosine -db.threshold = 0.6 -p(db.retrieve('Barack Obama')) # OK. -p(db.retrieve('Gordon Brown')) # OK. -p(db.retrieve('Obama')) # Too dissimilar! - -# Use overlap coefficient and threshold 1.0. -db.measure = Simstring::Overlap -db.threshold = 1 -p(db.retrieve('Obama')) # OK. diff --git a/swig/ruby/sample_unicode.rb b/swig/ruby/sample_unicode.rb deleted file mode 100644 index 4ae8253..0000000 --- a/swig/ruby/sample_unicode.rb +++ /dev/null @@ -1,21 +0,0 @@ -#!/usr/bin/env ruby -Ku - -require 'simstring' - -# Open a SimString database for writing with Unicode mode. -db = Simstring::Writer.new('sample_unicode.db', 3, false, true) - -# Write a string, and close the database. -db.insert('スパゲティ') -db.close() - - -# Open the database for reading. -db = Simstring::Reader.new('sample_unicode.db') - -# Set a similarity measure and threshold. -db.measure = Simstring::Cosine -db.threshold = 0.6 - -# Use an 8-bit string in UTF-8 encoding. -p(db.retrieve('スパゲティー')) diff --git a/win32/stdint.h b/win32/stdint.h deleted file mode 100644 index 7fafda1..0000000 --- a/win32/stdint.h +++ /dev/null @@ -1,679 +0,0 @@ -/* A portable stdint.h - * - * Copyright (c) 2005-2007 Paul Hsieh - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * Redistributions in binary form must not misrepresent the orignal - * source in the documentation and/or other materials provided - * with the distribution. - * - * The names of the authors nor its contributors may be used to - * endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, - * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED - * OF THE POSSIBILITY OF SUCH DAMAGE. - * - **************************************************************************** - * - * Version 0.1.8 - * - * The ANSI C standard committee, for the C99 standard, specified the - * inclusion of a new standard include file called stdint.h. This is - * a very useful and long desired include file which contains several - * very precise definitions for integer scalar types that is - * critically important for making portable several classes of - * applications including cryptography, hashing, variable length - * integer libraries and so on. But for most developers its likely - * useful just for programming sanity. - * - * The problem is that most compiler vendors have decided not to - * implement the C99 standard, and the next C++ language standard - * (which has a lot more mindshare these days) will be a long time in - * coming and its unknown whether or not it will include stdint.h or - * how much adoption it will have. Either way, it will be a long time - * before all compilers come with a stdint.h and it also does nothing - * for the extremely large number of compilers available today which - * do not include this file, or anything comparable to it. - * - * So that's what this file is all about. Its an attempt to build a - * single universal include file that works on as many platforms as - * possible to deliver what stdint.h is supposed to. A few things - * that should be noted about this file: - * - * 1) It is not guaranteed to be portable and/or present an identical - * interface on all platforms. The extreme variability of the - * ANSI C standard makes this an impossibility right from the - * very get go. Its really only meant to be useful for the vast - * majority of platforms that possess the capability of - * implementing usefully and precisely defined, standard sized - * integer scalars. Systems which are not intrinsically 2s - * complement may produce invalid constants. - * - * 2) There is an unavoidable use of non-reserved symbols. - * - * 3) Other standard include files are invoked. - * - * 4) This file may come in conflict with future platforms that do - * include stdint.h. The hope is that one or the other can be - * used with no real difference. - * - * 5) In the current verison, if your platform can't represent - * int32_t, int16_t and int8_t, it just dumps out with a compiler - * error. - * - * 6) 64 bit integers may or may not be defined. Test for their - * presence with the test: #ifdef INT64_MAX or #ifdef UINT64_MAX. - * Note that this is different from the C99 specification which - * requires the existence of 64 bit support in the compiler. If - * this is not defined for your platform, yet it is capable of - * dealing with 64 bits then it is because this file has not yet - * been extended to cover all of your system's capabilities. - * - * 7) (u)intptr_t may or may not be defined. Test for its presence - * with the test: #ifdef PTRDIFF_MAX. If this is not defined - * for your platform, then it is because this file has not yet - * been extended to cover all of your system's capabilities, not - * because its optional. - * - * 8) The following might not been defined even if your platform is - * capable of defining it: - * - * WCHAR_MIN - * WCHAR_MAX - * (u)int64_t - * PTRDIFF_MIN - * PTRDIFF_MAX - * (u)intptr_t - * - * 9) The following have not been defined: - * - * WINT_MIN - * WINT_MAX - * - * 10) The criteria for defining (u)int_least(*)_t isn't clear, - * except for systems which don't have a type that precisely - * defined 8, 16, or 32 bit types (which this include file does - * not support anyways). Default definitions have been given. - * - * 11) The criteria for defining (u)int_fast(*)_t isn't something I - * would trust to any particular compiler vendor or the ANSI C - * committee. It is well known that "compatible systems" are - * commonly created that have very different performance - * characteristics from the systems they are compatible with, - * especially those whose vendors make both the compiler and the - * system. Default definitions have been given, but its strongly - * recommended that users never use these definitions for any - * reason (they do *NOT* deliver any serious guarantee of - * improved performance -- not in this file, nor any vendor's - * stdint.h). - * - * 12) The following macros: - * - * PRINTF_INTMAX_MODIFIER - * PRINTF_INT64_MODIFIER - * PRINTF_INT32_MODIFIER - * PRINTF_INT16_MODIFIER - * PRINTF_LEAST64_MODIFIER - * PRINTF_LEAST32_MODIFIER - * PRINTF_LEAST16_MODIFIER - * PRINTF_INTPTR_MODIFIER - * - * are strings which have been defined as the modifiers required - * for the "d", "u" and "x" printf formats to correctly output - * (u)intmax_t, (u)int64_t, (u)int32_t, (u)int16_t, (u)least64_t, - * (u)least32_t, (u)least16_t and (u)intptr_t types respectively. - * PRINTF_INTPTR_MODIFIER is not defined for some systems which - * provide their own stdint.h. PRINTF_INT64_MODIFIER is not - * defined if INT64_MAX is not defined. These are an extension - * beyond what C99 specifies must be in stdint.h. - * - * In addition, the following macros are defined: - * - * PRINTF_INTMAX_HEX_WIDTH - * PRINTF_INT64_HEX_WIDTH - * PRINTF_INT32_HEX_WIDTH - * PRINTF_INT16_HEX_WIDTH - * PRINTF_INT8_HEX_WIDTH - * PRINTF_INTMAX_DEC_WIDTH - * PRINTF_INT64_DEC_WIDTH - * PRINTF_INT32_DEC_WIDTH - * PRINTF_INT16_DEC_WIDTH - * PRINTF_INT8_DEC_WIDTH - * - * Which specifies the maximum number of characters required to - * print the number of that type in either hexadecimal or decimal. - * These are an extension beyond what C99 specifies must be in - * stdint.h. - * - * Compilers tested (all with 0 warnings at their highest respective - * settings): Borland Turbo C 2.0, WATCOM C/C++ 11.0 (16 bits and 32 - * bits), Microsoft Visual C++ 6.0 (32 bit), Microsoft Visual Studio - * .net (VC7), Intel C++ 4.0, GNU gcc v3.3.3 - * - * This file should be considered a work in progress. Suggestions for - * improvements, especially those which increase coverage are strongly - * encouraged. - * - * Acknowledgements - * - * The following people have made significant contributions to the - * development and testing of this file: - * - * Chris Howie - * John Steele Scott - * Dave Thorup - * - */ - -#include -#include -#include - -/* - * For gcc with _STDINT_H, fill in the PRINTF_INT*_MODIFIER macros, and - * do nothing else. On the Mac OS X version of gcc this is _STDINT_H_. - */ - -#if ((defined(__STDC__) && __STDC__ && __STDC_VERSION__ >= 199901L) || (defined (__WATCOMC__) && (defined (_STDINT_H_INCLUDED) || __WATCOMC__ >= 1250)) || (defined(__GNUC__) && (defined(_STDINT_H) || defined(_STDINT_H_)) )) && !defined (_PSTDINT_H_INCLUDED) -#include -#define _PSTDINT_H_INCLUDED -# ifndef PRINTF_INT64_MODIFIER -# define PRINTF_INT64_MODIFIER "ll" -# endif -# ifndef PRINTF_INT32_MODIFIER -# define PRINTF_INT32_MODIFIER "l" -# endif -# ifndef PRINTF_INT16_MODIFIER -# define PRINTF_INT16_MODIFIER "h" -# endif -# ifndef PRINTF_INTMAX_MODIFIER -# define PRINTF_INTMAX_MODIFIER PRINTF_INT64_MODIFIER -# endif -# ifndef PRINTF_INT64_HEX_WIDTH -# define PRINTF_INT64_HEX_WIDTH "16" -# endif -# ifndef PRINTF_INT32_HEX_WIDTH -# define PRINTF_INT32_HEX_WIDTH "8" -# endif -# ifndef PRINTF_INT16_HEX_WIDTH -# define PRINTF_INT16_HEX_WIDTH "4" -# endif -# ifndef PRINTF_INT8_HEX_WIDTH -# define PRINTF_INT8_HEX_WIDTH "2" -# endif -# ifndef PRINTF_INT64_DEC_WIDTH -# define PRINTF_INT64_DEC_WIDTH "20" -# endif -# ifndef PRINTF_INT32_DEC_WIDTH -# define PRINTF_INT32_DEC_WIDTH "10" -# endif -# ifndef PRINTF_INT16_DEC_WIDTH -# define PRINTF_INT16_DEC_WIDTH "5" -# endif -# ifndef PRINTF_INT8_DEC_WIDTH -# define PRINTF_INT8_DEC_WIDTH "3" -# endif -# ifndef PRINTF_INTMAX_HEX_WIDTH -# define PRINTF_INTMAX_HEX_WIDTH PRINTF_INT64_HEX_WIDTH -# endif -# ifndef PRINTF_INTMAX_DEC_WIDTH -# define PRINTF_INTMAX_DEC_WIDTH PRINTF_INT64_DEC_WIDTH -# endif -#endif - -#ifndef _PSTDINT_H_INCLUDED -#define _PSTDINT_H_INCLUDED - -#ifndef SIZE_MAX -# define SIZE_MAX (~(size_t)0) -#endif - -/* - * Deduce the type assignments from limits.h under the assumption that - * integer sizes in bits are powers of 2, and follow the ANSI - * definitions. - */ - -#ifndef UINT8_MAX -# define UINT8_MAX 0xff -#endif -#ifndef uint8_t -# if (UCHAR_MAX == UINT8_MAX) || defined (S_SPLINT_S) - typedef unsigned char uint8_t; -# define UINT8_C(v) ((uint8_t) v) -# else -# error "Platform not supported" -# endif -#endif - -#ifndef INT8_MAX -# define INT8_MAX 0x7f -#endif -#ifndef INT8_MIN -# define INT8_MIN INT8_C(0x80) -#endif -#ifndef int8_t -# if (SCHAR_MAX == INT8_MAX) || defined (S_SPLINT_S) - typedef signed char int8_t; -# define INT8_C(v) ((int8_t) v) -# else -# error "Platform not supported" -# endif -#endif - -#ifndef UINT16_MAX -# define UINT16_MAX 0xffff -#endif -#ifndef uint16_t -#if (UINT_MAX == UINT16_MAX) || defined (S_SPLINT_S) - typedef unsigned int uint16_t; -# ifndef PRINTF_INT16_MODIFIER -# define PRINTF_INT16_MODIFIER "" -# endif -# define UINT16_C(v) ((uint16_t) (v)) -#elif (USHRT_MAX == UINT16_MAX) - typedef unsigned short uint16_t; -# define UINT16_C(v) ((uint16_t) (v)) -# ifndef PRINTF_INT16_MODIFIER -# define PRINTF_INT16_MODIFIER "h" -# endif -#else -#error "Platform not supported" -#endif -#endif - -#ifndef INT16_MAX -# define INT16_MAX 0x7fff -#endif -#ifndef INT16_MIN -# define INT16_MIN INT16_C(0x8000) -#endif -#ifndef int16_t -#if (INT_MAX == INT16_MAX) || defined (S_SPLINT_S) - typedef signed int int16_t; -# define INT16_C(v) ((int16_t) (v)) -# ifndef PRINTF_INT16_MODIFIER -# define PRINTF_INT16_MODIFIER "" -# endif -#elif (SHRT_MAX == INT16_MAX) - typedef signed short int16_t; -# define INT16_C(v) ((int16_t) (v)) -# ifndef PRINTF_INT16_MODIFIER -# define PRINTF_INT16_MODIFIER "h" -# endif -#else -#error "Platform not supported" -#endif -#endif - -#ifndef UINT32_MAX -# define UINT32_MAX (0xffffffffUL) -#endif -#ifndef uint32_t -#if (ULONG_MAX == UINT32_MAX) || defined (S_SPLINT_S) - typedef unsigned long uint32_t; -# define UINT32_C(v) v ## UL -# ifndef PRINTF_INT32_MODIFIER -# define PRINTF_INT32_MODIFIER "l" -# endif -#elif (UINT_MAX == UINT32_MAX) - typedef unsigned int uint32_t; -# ifndef PRINTF_INT32_MODIFIER -# define PRINTF_INT32_MODIFIER "" -# endif -# define UINT32_C(v) v ## U -#elif (USHRT_MAX == UINT32_MAX) - typedef unsigned short uint32_t; -# define UINT32_C(v) ((unsigned short) (v)) -# ifndef PRINTF_INT32_MODIFIER -# define PRINTF_INT32_MODIFIER "" -# endif -#else -#error "Platform not supported" -#endif -#endif - -#ifndef INT32_MAX -# define INT32_MAX (0x7fffffffL) -#endif -#ifndef INT32_MIN -# define INT32_MIN INT32_C(0x80000000) -#endif -#ifndef int32_t -#if (LONG_MAX == INT32_MAX) || defined (S_SPLINT_S) - typedef signed long int32_t; -# define INT32_C(v) v ## L -# ifndef PRINTF_INT32_MODIFIER -# define PRINTF_INT32_MODIFIER "l" -# endif -#elif (INT_MAX == INT32_MAX) - typedef signed int int32_t; -# define INT32_C(v) v -# ifndef PRINTF_INT32_MODIFIER -# define PRINTF_INT32_MODIFIER "" -# endif -#elif (SHRT_MAX == INT32_MAX) - typedef signed short int32_t; -# define INT32_C(v) ((short) (v)) -# ifndef PRINTF_INT32_MODIFIER -# define PRINTF_INT32_MODIFIER "" -# endif -#else -#error "Platform not supported" -#endif -#endif - -/* - * The macro stdint_int64_defined is temporarily used to record - * whether or not 64 integer support is available. It must be - * defined for any 64 integer extensions for new platforms that are - * added. - */ - -#undef stdint_int64_defined -#if (defined(__STDC__) && defined(__STDC_VERSION__)) || defined (S_SPLINT_S) -# if (__STDC__ && __STDC_VERSION >= 199901L) || defined (S_SPLINT_S) -# define stdint_int64_defined - typedef long long int64_t; - typedef unsigned long long uint64_t; -# define UINT64_C(v) v ## ULL -# define INT64_C(v) v ## LL -# ifndef PRINTF_INT64_MODIFIER -# define PRINTF_INT64_MODIFIER "ll" -# endif -# endif -#endif - -#if !defined (stdint_int64_defined) -# if defined(__GNUC__) -# define stdint_int64_defined - __extension__ typedef long long int64_t; - __extension__ typedef unsigned long long uint64_t; -# define UINT64_C(v) v ## ULL -# define INT64_C(v) v ## LL -# ifndef PRINTF_INT64_MODIFIER -# define PRINTF_INT64_MODIFIER "ll" -# endif -# elif defined(__MWERKS__) || defined (__SUNPRO_C) || defined (__SUNPRO_CC) || defined (__APPLE_CC__) || defined (_LONG_LONG) || defined (_CRAYC) || defined (S_SPLINT_S) -# define stdint_int64_defined - typedef long long int64_t; - typedef unsigned long long uint64_t; -# define UINT64_C(v) v ## ULL -# define INT64_C(v) v ## LL -# ifndef PRINTF_INT64_MODIFIER -# define PRINTF_INT64_MODIFIER "ll" -# endif -# elif (defined(__WATCOMC__) && defined(__WATCOM_INT64__)) || (defined(_MSC_VER) && _INTEGRAL_MAX_BITS >= 64) || (defined (__BORLANDC__) && __BORLANDC__ > 0x460) || defined (__alpha) || defined (__DECC) -# define stdint_int64_defined - typedef __int64 int64_t; - typedef unsigned __int64 uint64_t; -# define UINT64_C(v) v ## UI64 -# define INT64_C(v) v ## I64 -# ifndef PRINTF_INT64_MODIFIER -# define PRINTF_INT64_MODIFIER "I64" -# endif -# endif -#endif - -#if !defined (LONG_LONG_MAX) && defined (INT64_C) -# define LONG_LONG_MAX INT64_C (9223372036854775807) -#endif -#ifndef ULONG_LONG_MAX -# define ULONG_LONG_MAX UINT64_C (18446744073709551615) -#endif - -#if !defined (INT64_MAX) && defined (INT64_C) -# define INT64_MAX INT64_C (9223372036854775807) -#endif -#if !defined (INT64_MIN) && defined (INT64_C) -# define INT64_MIN INT64_C (-9223372036854775808) -#endif -#if !defined (UINT64_MAX) && defined (INT64_C) -# define UINT64_MAX UINT64_C (18446744073709551615) -#endif - -/* - * Width of hexadecimal for number field. - */ - -#ifndef PRINTF_INT64_HEX_WIDTH -# define PRINTF_INT64_HEX_WIDTH "16" -#endif -#ifndef PRINTF_INT32_HEX_WIDTH -# define PRINTF_INT32_HEX_WIDTH "8" -#endif -#ifndef PRINTF_INT16_HEX_WIDTH -# define PRINTF_INT16_HEX_WIDTH "4" -#endif -#ifndef PRINTF_INT8_HEX_WIDTH -# define PRINTF_INT8_HEX_WIDTH "2" -#endif - -#ifndef PRINTF_INT64_DEC_WIDTH -# define PRINTF_INT64_DEC_WIDTH "20" -#endif -#ifndef PRINTF_INT32_DEC_WIDTH -# define PRINTF_INT32_DEC_WIDTH "10" -#endif -#ifndef PRINTF_INT16_DEC_WIDTH -# define PRINTF_INT16_DEC_WIDTH "5" -#endif -#ifndef PRINTF_INT8_DEC_WIDTH -# define PRINTF_INT8_DEC_WIDTH "3" -#endif - -/* - * Ok, lets not worry about 128 bit integers for now. Moore's law says - * we don't need to worry about that until about 2040 at which point - * we'll have bigger things to worry about. - */ - -#ifdef stdint_int64_defined - typedef int64_t intmax_t; - typedef uint64_t uintmax_t; -# define INTMAX_MAX INT64_MAX -# define INTMAX_MIN INT64_MIN -# define UINTMAX_MAX UINT64_MAX -# define UINTMAX_C(v) UINT64_C(v) -# define INTMAX_C(v) INT64_C(v) -# ifndef PRINTF_INTMAX_MODIFIER -# define PRINTF_INTMAX_MODIFIER PRINTF_INT64_MODIFIER -# endif -# ifndef PRINTF_INTMAX_HEX_WIDTH -# define PRINTF_INTMAX_HEX_WIDTH PRINTF_INT64_HEX_WIDTH -# endif -# ifndef PRINTF_INTMAX_DEC_WIDTH -# define PRINTF_INTMAX_DEC_WIDTH PRINTF_INT64_DEC_WIDTH -# endif -#else - typedef int32_t intmax_t; - typedef uint32_t uintmax_t; -# define INTMAX_MAX INT32_MAX -# define UINTMAX_MAX UINT32_MAX -# define UINTMAX_C(v) UINT32_C(v) -# define INTMAX_C(v) INT32_C(v) -# ifndef PRINTF_INTMAX_MODIFIER -# define PRINTF_INTMAX_MODIFIER PRINTF_INT32_MODIFIER -# endif -# ifndef PRINTF_INTMAX_HEX_WIDTH -# define PRINTF_INTMAX_HEX_WIDTH PRINTF_INT32_HEX_WIDTH -# endif -# ifndef PRINTF_INTMAX_DEC_WIDTH -# define PRINTF_INTMAX_DEC_WIDTH PRINTF_INT32_DEC_WIDTH -# endif -#endif - -/* - * Because this file currently only supports platforms which have - * precise powers of 2 as bit sizes for the default integers, the - * least definitions are all trivial. Its possible that a future - * version of this file could have different definitions. - */ - -#ifndef stdint_least_defined - typedef int8_t int_least8_t; - typedef uint8_t uint_least8_t; - typedef int16_t int_least16_t; - typedef uint16_t uint_least16_t; - typedef int32_t int_least32_t; - typedef uint32_t uint_least32_t; -# define PRINTF_LEAST32_MODIFIER PRINTF_INT32_MODIFIER -# define PRINTF_LEAST16_MODIFIER PRINTF_INT16_MODIFIER -# define UINT_LEAST8_MAX UINT8_MAX -# define INT_LEAST8_MAX INT8_MAX -# define UINT_LEAST16_MAX UINT16_MAX -# define INT_LEAST16_MAX INT16_MAX -# define UINT_LEAST32_MAX UINT32_MAX -# define INT_LEAST32_MAX INT32_MAX -# define INT_LEAST8_MIN INT8_MIN -# define INT_LEAST16_MIN INT16_MIN -# define INT_LEAST32_MIN INT32_MIN -# ifdef stdint_int64_defined - typedef int64_t int_least64_t; - typedef uint64_t uint_least64_t; -# define PRINTF_LEAST64_MODIFIER PRINTF_INT64_MODIFIER -# define UINT_LEAST64_MAX UINT64_MAX -# define INT_LEAST64_MAX INT64_MAX -# define INT_LEAST64_MIN INT64_MIN -# endif -#endif -#undef stdint_least_defined - -/* - * The ANSI C committee pretending to know or specify anything about - * performance is the epitome of misguided arrogance. The mandate of - * this file is to *ONLY* ever support that absolute minimum - * definition of the fast integer types, for compatibility purposes. - * No extensions, and no attempt to suggest what may or may not be a - * faster integer type will ever be made in this file. Developers are - * warned to stay away from these types when using this or any other - * stdint.h. - */ - -typedef int_least8_t int_fast8_t; -typedef uint_least8_t uint_fast8_t; -typedef int_least16_t int_fast16_t; -typedef uint_least16_t uint_fast16_t; -typedef int_least32_t int_fast32_t; -typedef uint_least32_t uint_fast32_t; -#define UINT_FAST8_MAX UINT_LEAST8_MAX -#define INT_FAST8_MAX INT_LEAST8_MAX -#define UINT_FAST16_MAX UINT_LEAST16_MAX -#define INT_FAST16_MAX INT_LEAST16_MAX -#define UINT_FAST32_MAX UINT_LEAST32_MAX -#define INT_FAST32_MAX INT_LEAST32_MAX -#define INT_FAST8_MIN IN_LEASTT8_MIN -#define INT_FAST16_MIN INT_LEAST16_MIN -#define INT_FAST32_MIN INT_LEAST32_MIN -#ifdef stdint_int64_defined - typedef int_least64_t int_fast64_t; - typedef uint_least64_t uint_fast64_t; -# define UINT_FAST64_MAX UINT_LEAST64_MAX -# define INT_FAST64_MAX INT_LEAST64_MAX -# define INT_FAST64_MIN INT_LEAST64_MIN -#endif - -#undef stdint_int64_defined - -/* - * Whatever piecemeal, per compiler thing we can do about the wchar_t - * type limits. - */ - -#if defined(__WATCOMC__) || defined(_MSC_VER) || defined (__GNUC__) -# include -# ifndef WCHAR_MIN -# define WCHAR_MIN 0 -# endif -# ifndef WCHAR_MAX -# define WCHAR_MAX ((wchar_t)-1) -# endif -#endif - -/* - * Whatever piecemeal, per compiler/platform thing we can do about the - * (u)intptr_t types and limits. - */ - -#if defined (_MSC_VER) && defined (_UINTPTR_T_DEFINED) -# define STDINT_H_UINTPTR_T_DEFINED -#endif - -#ifndef STDINT_H_UINTPTR_T_DEFINED -# if defined (__alpha__) || defined (__ia64__) || defined (__x86_64__) || defined (_WIN64) -# define stdint_intptr_bits 64 -# elif defined (__WATCOMC__) || defined (__TURBOC__) -# if defined(__TINY__) || defined(__SMALL__) || defined(__MEDIUM__) -# define stdint_intptr_bits 16 -# else -# define stdint_intptr_bits 32 -# endif -# elif defined (__i386__) || defined (_WIN32) || defined (WIN32) -# define stdint_intptr_bits 32 -# elif defined (__INTEL_COMPILER) -/* TODO -- what will Intel do about x86-64? */ -# endif - -# ifdef stdint_intptr_bits -# define stdint_intptr_glue3_i(a,b,c) a##b##c -# define stdint_intptr_glue3(a,b,c) stdint_intptr_glue3_i(a,b,c) -# ifndef PRINTF_INTPTR_MODIFIER -# define PRINTF_INTPTR_MODIFIER stdint_intptr_glue3(PRINTF_INT,stdint_intptr_bits,_MODIFIER) -# endif -# ifndef PTRDIFF_MAX -# define PTRDIFF_MAX stdint_intptr_glue3(INT,stdint_intptr_bits,_MAX) -# endif -# ifndef PTRDIFF_MIN -# define PTRDIFF_MIN stdint_intptr_glue3(INT,stdint_intptr_bits,_MIN) -# endif -# ifndef UINTPTR_MAX -# define UINTPTR_MAX stdint_intptr_glue3(UINT,stdint_intptr_bits,_MAX) -# endif -# ifndef INTPTR_MAX -# define INTPTR_MAX stdint_intptr_glue3(INT,stdint_intptr_bits,_MAX) -# endif -# ifndef INTPTR_MIN -# define INTPTR_MIN stdint_intptr_glue3(INT,stdint_intptr_bits,_MIN) -# endif -# ifndef INTPTR_C -# define INTPTR_C(x) stdint_intptr_glue3(INT,stdint_intptr_bits,_C)(x) -# endif -# ifndef UINTPTR_C -# define UINTPTR_C(x) stdint_intptr_glue3(UINT,stdint_intptr_bits,_C)(x) -# endif - typedef stdint_intptr_glue3(uint,stdint_intptr_bits,_t) uintptr_t; - typedef stdint_intptr_glue3( int,stdint_intptr_bits,_t) intptr_t; -# else -/* TODO -- This following is likely wrong for some platforms, and does - nothing for the definition of uintptr_t. */ - typedef ptrdiff_t intptr_t; -# endif -# define STDINT_H_UINTPTR_T_DEFINED -#endif - -/* - * Assumes sig_atomic_t is signed and we have a 2s complement machine. - */ - -#ifndef SIG_ATOMIC_MAX -# define SIG_ATOMIC_MAX ((((sig_atomic_t) 1) << (sizeof (sig_atomic_t)*CHAR_BIT-1)) - 1) -#endif - -#endif