diff --git a/.travis.yml b/.travis.yml index 4e7a151f..a61fd0ad 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,13 +1,79 @@ -language: c++ -compiler: - - clang - - gcc +dist: xenial +language: cpp +matrix: + include: + # Linux (gcc4.9) + - os: linux + compiler: gcc-4.9 + addons: + apt: + sources: + - ubuntu-toolchain-r-test + packages: + - g++-4.9 + - libtbb-dev + env: + - CC=gcc-4.9 + - CXX=g++-4.9 + # Linux (gcc8) + - os: linux + compiler: gcc-8 + addons: + apt: + sources: + - ubuntu-toolchain-r-test + packages: + - g++-8 + - libtbb-dev + env: + - CC=gcc-8 + - CXX=g++-8 + # MacOS + - os: osx + osx_image: xcode11.2 + compiler: clang + env: + - CC=clang + - CXX=clang++ + - NPROC="$(sysctl -n hw.activecpu)" + before_install: + - brew unlink python@2 + - brew install tbb + # ARM 64-bit + - os: linux + arch: arm64 + compiler: gcc + env: + - POPCNT_CAPABILITY=0 + - NO_TBB=1 + # IBM Z (big endian) + - arch: s390x + compiler: gcc + env: + - POPCNT_CAPABILITY=0 + - NO_TBB=1 + before_install: + # The tests only work with `--threads 1`. + - sed -i 's/--threads $nthreads/--threads 1/' scripts/test/simple_tests.pl + # PPC64LE + - os: linux + arch: ppc64le + compiler: gcc + env: + - POPCNT_CAPABILITY=0 + - NO_TBB=1 + # Skip make simple-test as it fails. + script: make -j $NPROC allall cache: apt -addons: - apt: - packages: - - libtbb-dev -script: make allall && make simple-test +env: + global: + - NPROC="$(nproc)" +before_script: + - uname -m + - echo CC=${CC} CXX=${CXX} NPROC=${NPROC} + - $CC --version + - $CXX --version +script: make -j $NPROC allall && make simple-test notifications: - slack: - secure: K/SdL+S1lb+Vf3KucmiMh4Fyd9sWmosw+mSRjtAjAzXUYZ3zMp91bM6GzHVD1nonMQWDu3vY6TOApvnikSfd4ZSRhO4ijDda5zF3SN19Uly4vXRTC0C4UKloyVqOjx2uwXU4Mz+7cuO9RCb4CczL2HUG9tiLN5BjfbnHvQlZzsE6dJuo+5BoKq88SbNhlBlGIuLWAsVmpnaozNjowNBLb2+BtrK5KSN5eTyCVerZeoJ2ChexDXGf7SnGVQhgu05hfOB52ti1mzRaTRGY91jnKAibBaO/gyW2Q5/AeBy+OrL5poenM0rAJHjztUCw1lC1G4Mej73YyHn6V1NF0DHSYM9l8aBe0nAweAuB4tuRJ9gJtqR6GjXdqURI5ABBsFIkb9pNbJz59g9sTpKrrWmIqqj7a8Eld7nk1K+IjBVOvDT9x3PWjl/H1sAl+0bRT42lu+zjJV9BIn/Fwn+xC0syRazgDimkfPLbn/aAEBKeofwdk/DHb3amBtbHsEFZsAdI5Mrq/tIuCYO0i7jYxlmNTNsXA5a0gF1OExGJvPPDV2/lp/bPx/ncvcZvwjpst6BEyJURmM5MsMCeHbiuPvlVmA4R29BTMBaW/ZN5smF4E+CkV2IxPlpgh2c+YSX44ikYnG3v4H5QKxLI4W4E+TTn9/1EmdO0KMzNG8gEiNnKcTg= + slack: + secure: K/SdL+S1lb+Vf3KucmiMh4Fyd9sWmosw+mSRjtAjAzXUYZ3zMp91bM6GzHVD1nonMQWDu3vY6TOApvnikSfd4ZSRhO4ijDda5zF3SN19Uly4vXRTC0C4UKloyVqOjx2uwXU4Mz+7cuO9RCb4CczL2HUG9tiLN5BjfbnHvQlZzsE6dJuo+5BoKq88SbNhlBlGIuLWAsVmpnaozNjowNBLb2+BtrK5KSN5eTyCVerZeoJ2ChexDXGf7SnGVQhgu05hfOB52ti1mzRaTRGY91jnKAibBaO/gyW2Q5/AeBy+OrL5poenM0rAJHjztUCw1lC1G4Mej73YyHn6V1NF0DHSYM9l8aBe0nAweAuB4tuRJ9gJtqR6GjXdqURI5ABBsFIkb9pNbJz59g9sTpKrrWmIqqj7a8Eld7nk1K+IjBVOvDT9x3PWjl/H1sAl+0bRT42lu+zjJV9BIn/Fwn+xC0syRazgDimkfPLbn/aAEBKeofwdk/DHb3amBtbHsEFZsAdI5Mrq/tIuCYO0i7jYxlmNTNsXA5a0gF1OExGJvPPDV2/lp/bPx/ncvcZvwjpst6BEyJURmM5MsMCeHbiuPvlVmA4R29BTMBaW/ZN5smF4E+CkV2IxPlpgh2c+YSX44ikYnG3v4H5QKxLI4W4E+TTn9/1EmdO0KMzNG8gEiNnKcTg= diff --git a/Makefile b/Makefile index bbce0a26..7c97a9b2 100644 --- a/Makefile +++ b/Makefile @@ -5,13 +5,13 @@ prefix = /usr/local bindir = $(prefix)/bin -SEQAN_DIR = ./SeqAn-1.1 +SEQAN_DIR = ./third_party/seqan-library-1.4.2/include # treat SeqAn as a sysdir to suppress warnings SEQAN_INC = -isystem $(SEQAN_DIR) -INC = $(if $(RELEASE_BUILD),-I$(CURDIR)/.include) $(SEQAN_INC) -I third_party -CPP = g++ -CXX = $(CPP) -CC = gcc +INC = $(if $(RELEASE_BUILD),-I$(CURDIR)/.include) $(SEQAN_INC) +CPP ?= g++ +CXX ?= $(CPP) +CC ?= gcc LIBS = $(LDFLAGS) $(if $(RELEASE_BUILD),-L$(CURDIR)/.lib) -lz HEADERS = $(wildcard *.h) BOWTIE_MM = 1 @@ -162,6 +162,12 @@ VERSION = $(shell cat VERSION) BITS=32 ifeq (x86_64,$(shell uname -m)) BITS=64 +else ifeq (aarch64,$(shell uname -m)) + BITS=64 +else ifeq (s390x,$(shell uname -m)) + BITS=64 +else ifeq (ppc64le,$(shell uname -m)) + BITS=64 endif # msys will always be 32 bit so look at the cpu arch instead. ifneq (,$(findstring AMD64,$(PROCESSOR_ARCHITEW6432))) @@ -180,8 +186,8 @@ ifeq (32,$(BITS)) $(error bowtie2 compilation requires a 64-bit platform ) endif -DEBUG_FLAGS = -O0 -g3 -m64 -RELEASE_FLAGS = -O3 -m64 +DEBUG_FLAGS = -O0 -g3 +RELEASE_FLAGS = -O3 NOASSERT_FLAGS = -DNDEBUG FILE_FLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE diff --git a/SeqAn-1.1/GPL.txt b/SeqAn-1.1/GPL.txt deleted file mode 100644 index 94a9ed02..00000000 --- a/SeqAn-1.1/GPL.txt +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. diff --git a/SeqAn-1.1/LGPL.txt b/SeqAn-1.1/LGPL.txt deleted file mode 100644 index fc8a5de7..00000000 --- a/SeqAn-1.1/LGPL.txt +++ /dev/null @@ -1,165 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - - This version of the GNU Lesser General Public License incorporates -the terms and conditions of version 3 of the GNU General Public -License, supplemented by the additional permissions listed below. - - 0. Additional Definitions. - - As used herein, "this License" refers to version 3 of the GNU Lesser -General Public License, and the "GNU GPL" refers to version 3 of the GNU -General Public License. - - "The Library" refers to a covered work governed by this License, -other than an Application or a Combined Work as defined below. - - An "Application" is any work that makes use of an interface provided -by the Library, but which is not otherwise based on the Library. -Defining a subclass of a class defined by the Library is deemed a mode -of using an interface provided by the Library. - - A "Combined Work" is a work produced by combining or linking an -Application with the Library. The particular version of the Library -with which the Combined Work was made is also called the "Linked -Version". - - The "Minimal Corresponding Source" for a Combined Work means the -Corresponding Source for the Combined Work, excluding any source code -for portions of the Combined Work that, considered in isolation, are -based on the Application, and not on the Linked Version. - - The "Corresponding Application Code" for a Combined Work means the -object code and/or source code for the Application, including any data -and utility programs needed for reproducing the Combined Work from the -Application, but excluding the System Libraries of the Combined Work. - - 1. Exception to Section 3 of the GNU GPL. - - You may convey a covered work under sections 3 and 4 of this License -without being bound by section 3 of the GNU GPL. - - 2. Conveying Modified Versions. - - If you modify a copy of the Library, and, in your modifications, a -facility refers to a function or data to be supplied by an Application -that uses the facility (other than as an argument passed when the -facility is invoked), then you may convey a copy of the modified -version: - - a) under this License, provided that you make a good faith effort to - ensure that, in the event an Application does not supply the - function or data, the facility still operates, and performs - whatever part of its purpose remains meaningful, or - - b) under the GNU GPL, with none of the additional permissions of - this License applicable to that copy. - - 3. Object Code Incorporating Material from Library Header Files. - - The object code form of an Application may incorporate material from -a header file that is part of the Library. You may convey such object -code under terms of your choice, provided that, if the incorporated -material is not limited to numerical parameters, data structure -layouts and accessors, or small macros, inline functions and templates -(ten or fewer lines in length), you do both of the following: - - a) Give prominent notice with each copy of the object code that the - Library is used in it and that the Library and its use are - covered by this License. - - b) Accompany the object code with a copy of the GNU GPL and this license - document. - - 4. Combined Works. - - You may convey a Combined Work under terms of your choice that, -taken together, effectively do not restrict modification of the -portions of the Library contained in the Combined Work and reverse -engineering for debugging such modifications, if you also do each of -the following: - - a) Give prominent notice with each copy of the Combined Work that - the Library is used in it and that the Library and its use are - covered by this License. - - b) Accompany the Combined Work with a copy of the GNU GPL and this license - document. - - c) For a Combined Work that displays copyright notices during - execution, include the copyright notice for the Library among - these notices, as well as a reference directing the user to the - copies of the GNU GPL and this license document. - - d) Do one of the following: - - 0) Convey the Minimal Corresponding Source under the terms of this - License, and the Corresponding Application Code in a form - suitable for, and under terms that permit, the user to - recombine or relink the Application with a modified version of - the Linked Version to produce a modified Combined Work, in the - manner specified by section 6 of the GNU GPL for conveying - Corresponding Source. - - 1) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (a) uses at run time - a copy of the Library already present on the user's computer - system, and (b) will operate properly with a modified version - of the Library that is interface-compatible with the Linked - Version. - - e) Provide Installation Information, but only if you would otherwise - be required to provide such information under section 6 of the - GNU GPL, and only to the extent that such information is - necessary to install and execute a modified version of the - Combined Work produced by recombining or relinking the - Application with a modified version of the Linked Version. (If - you use option 4d0, the Installation Information must accompany - the Minimal Corresponding Source and Corresponding Application - Code. If you use option 4d1, you must provide the Installation - Information in the manner specified by section 6 of the GNU GPL - for conveying Corresponding Source.) - - 5. Combined Libraries. - - You may place library facilities that are a work based on the -Library side by side in a single library together with other library -facilities that are not Applications and are not covered by this -License, and convey such a combined library under terms of your -choice, if you do both of the following: - - a) Accompany the combined library with a copy of the same work based - on the Library, uncombined with any other library facilities, - conveyed under the terms of this License. - - b) Give prominent notice with the combined library that part of it - is a work based on the Library, and explaining where to find the - accompanying uncombined form of the same work. - - 6. Revised Versions of the GNU Lesser General Public License. - - The Free Software Foundation may publish revised and/or new versions -of the GNU Lesser General Public License from time to time. Such new -versions will be similar in spirit to the present version, but may -differ in detail to address new problems or concerns. - - Each version is given a distinguishing version number. If the -Library as you received it specifies that a certain numbered version -of the GNU Lesser General Public License "or any later version" -applies to it, you have the option of following the terms and -conditions either of that published version or of any later version -published by the Free Software Foundation. If the Library as you -received it does not specify a version number of the GNU Lesser -General Public License, you may choose any version of the GNU Lesser -General Public License ever published by the Free Software Foundation. - - If the Library as you received it specifies that a proxy can decide -whether future versions of the GNU Lesser General Public License shall -apply, that proxy's public statement of acceptance of any version is -permanent authorization for you to choose that version for the -Library. diff --git a/SeqAn-1.1/README.txt b/SeqAn-1.1/README.txt deleted file mode 100644 index 53f2d081..00000000 --- a/SeqAn-1.1/README.txt +++ /dev/null @@ -1,29 +0,0 @@ -This is SeqAn, the C++ template library for sequence analysis - -See http://www.seqan.de for more information - -Read "docs/Page_Installation.html" for detailed installation instructions. - - -Folders: -======== - -"seqan": SeqAn library (add the folder that contains "seqan" to - your include path) -"demos": SeqAn demos, see also "docs/INDEXPAGE_Demo.html" -"apps": SeqAn applications -"docs": HTML-Documentation - - -Files: -====== - -"Makefile": make file for Linux/Darwin/Solaris -"*_7.sln", "*_7.vcproj": Visual Studio .net 2003 solution and project files -"*_8.sln", "*_8.vcproj": Visual Studio .net 2005 solution and project files -"*_9.sln", "*_9.vcproj": Visual Studio .net 2008 solution and project files - - -Have fun! - -Your SeqAn Team diff --git a/SeqAn-1.1/platform_linux_gcc.h b/SeqAn-1.1/platform_linux_gcc.h deleted file mode 100644 index a385cea3..00000000 --- a/SeqAn-1.1/platform_linux_gcc.h +++ /dev/null @@ -1,26 +0,0 @@ -#define PLATFORM "gcc" - -#ifndef PLATFORM_GCC - #define PLATFORM_GCC -#endif - -// should be set before including anything -#ifndef _FILE_OFFSET_BITS - #define _FILE_OFFSET_BITS 64 -#endif - -#ifndef _LARGEFILE_SOURCE - #define _LARGEFILE_SOURCE -#endif - -//#include -#include - -#define finline __inline__ - -// default 64bit type -typedef int64_t __int64; - - -//define SEQAN_SWITCH_USE_FORWARDS to use generated forwards -#define SEQAN_SWITCH_USE_FORWARDS diff --git a/SeqAn-1.1/platform_windows_mingw.h b/SeqAn-1.1/platform_windows_mingw.h deleted file mode 100644 index 70bda5b9..00000000 --- a/SeqAn-1.1/platform_windows_mingw.h +++ /dev/null @@ -1,10 +0,0 @@ -#define PLATFORM "windows" - -#ifndef PLATFORM_WINDOWS - #define PLATFORM_WINDOWS -#endif - -#define finline __inline__ - -//define SEQAN_SWITCH_USE_FORWARDS to use generated forwards -//#define SEQAN_SWITCH_USE_FORWARDS diff --git a/SeqAn-1.1/platform_windows_vs.h b/SeqAn-1.1/platform_windows_vs.h deleted file mode 100644 index 7f097d16..00000000 --- a/SeqAn-1.1/platform_windows_vs.h +++ /dev/null @@ -1,13 +0,0 @@ -#define PLATFORM "windows" - -#ifndef PLATFORM_WINDOWS - #define PLATFORM_WINDOWS -#endif - -#pragma warning( disable : 4675 ) -#pragma warning( disable : 4503 ) - -#define finline __forceinline - -//define SEQAN_SWITCH_USE_FORWARDS to use generated forwards -//#define SEQAN_SWITCH_USE_FORWARDS diff --git a/SeqAn-1.1/seqan/basic.h b/SeqAn-1.1/seqan/basic.h deleted file mode 100644 index 27beba1c..00000000 --- a/SeqAn-1.1/seqan/basic.h +++ /dev/null @@ -1,115 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic.h,v 1.2 2009/05/06 20:32:59 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_H -#define SEQAN_HEADER_BASIC_H - -//____________________________________________________________________________ -// prerequisites - -#include - -//#include -#ifdef PLATFORM_WINDOWS -#include // limits include file exists only for g++ >= 3.0 -#endif - -#include // size_t -#include // FILE, basic_debug -#include -#include -#include -#include // memset -#include // basic_profile - -#define SEQAN_NAMESPACE_MAIN seqan - -//____________________________________________________________________________ - -#include -#ifdef SEQAN_SWITCH_USE_FORWARDS -#include -#endif - -#include -#include -#include -#include -#include -#include - -//____________________________________________________________________________ -// allocators - -#include -#include - -#include - -#include -#include -#include -//#include - -//____________________________________________________________________________ - -#include -#include -#include - -#include - -//____________________________________________________________________________ -// iterators - -#include -#include - -#include - -#include -#include -#include -#include -//#include - -#include - -#include - -//____________________________________________________________________________ -// alphabets - -#include -#include - -#include - -#include -#include - -//____________________________________________________________________________ - -//#include -#include - -#include - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_aggregates.h b/SeqAn-1.1/seqan/basic/basic_aggregates.h deleted file mode 100644 index 68e4e708..00000000 --- a/SeqAn-1.1/seqan/basic/basic_aggregates.h +++ /dev/null @@ -1,689 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_aggregates.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_AGGREGATES_H -#define SEQAN_HEADER_BASIC_AGGREGATES_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -//____________________________________________________________________________ - - struct _Compressed; - typedef Tag<_Compressed> Compressed; - - // for Pairs with small i1-values - // store i1 and i2 in one word of type i2 - // use the upper bits for i1 and the lower bits for i2 - template - struct CutCompressed { - enum { bitSizeI1 = Log2::VALUE }; - }; - -/** -.Class.Pair: -..cat:Aggregates -..summary:Stores two arbitrary objects. -..signature:Pair -..param.T1:The type of the first object. -..param.T2:The type of the second object. -..param.Compression:If $Compressed$, the pair is stored in a more space efficient way (useful for external storage). -...note:When compression is enabled, referring to members is not allowed. -...default:$void$, no compression (faster access). -.Memfunc.Pair#Pair: -..class:Class.Pair -..summary:Constructor -..signature:Pair () -..signature:Pair (pair) -..signature:Pair (i1, i2) -..param.pair:Other Pair object. (copy constructor) -..param.i1:T1 object. -..param.i2:T2 object. -.Memvar.Pair#i1: -..class:Class.Pair -..summary:T1 object -.Memvar.Pair#i2: -..class:Class.Pair -..summary:T2 object -*/ - - // standard storage - template - struct Pair { - typedef _T1 T1; - typedef _T2 T2; - _T1 i1; - _T2 i2; - inline Pair() {} - inline Pair(Pair const &_p): i1(_p.i1), i2(_p.i2) {} - inline Pair(_T1 const &_i1, _T2 const &_i2): i1(_i1), i2(_i2) {} - - template - inline Pair(Pair<__T1, __T2, __TCompression> const &_p): - i1(getValueI1(_p)), i2(getValueI2(_p)) {} - }; - - - - // unaligned and unpadded storage (space efficient) -#ifdef PLATFORM_WINDOWS - #pragma pack(push,1) -#endif - template - struct Pair<_T1, _T2, Compressed> { - typedef _T1 T1; - typedef _T2 T2; - _T1 i1; - _T2 i2; - inline Pair() {} - inline Pair(Pair const &_p): i1(_p.i1), i2(_p.i2) {} - inline Pair(_T1 const &_i1, _T2 const &_i2): i1(_i1), i2(_i2) {} - - template - inline Pair(Pair<__T1, __T2, __TCompression> const &_p): - i1(getValueI1(_p)), i2(getValueI2(_p)) {} - } -#ifndef PLATFORM_WINDOWS - __attribute__((packed)) -#endif - ; -#ifdef PLATFORM_WINDOWS - #pragma pack(pop) -#endif - - - -#ifdef PLATFORM_WINDOWS - #pragma pack(push,1) -#endif - template - struct Pair<_T1, _T2, CutCompressed > { - typedef _T1 T1; - typedef _T2 T2; - - typedef _T2 T12; - - T12 i12; - - enum { bitSizeI1 = CutCompressed::bitSizeI1 }; - enum { bitShiftI1 = BitsPerValue::VALUE - bitSizeI1 }; - - inline Pair() {} - inline Pair(Pair const &_p): i12(_p.i12) {} - inline Pair(_T1 const &_i1, _T2 const &_i2): - i12(((T12)_i1 << bitShiftI1) + (T12)_i2) {} - - template - inline Pair(Pair<__T1, __T2, __TCompression> const &_p): - i12(((T12)getValueI1(_p) << bitShiftI1) + (T12)getValueI2(_p)) {} - } -#ifndef PLATFORM_WINDOWS - __attribute__((packed)) -#endif - ; -#ifdef PLATFORM_WINDOWS - #pragma pack(pop) -#endif - - - - template - std::ostream& operator<<(std::ostream &out, Pair<_T1,_T2,TCompression> const &p) { - out << "< " << getValueI1(p) << " , " << getValueI2(p) << " >"; - return out; - } - - template - struct Value< Pair, 1 > { - typedef T1 Type; - }; - - template - struct Value< Pair, 2 > { - typedef T2 Type; - }; - - template - struct Spec< Pair > { - typedef TCompression Type; - }; - - -//____________________________________________________________________________ - - template - struct Key< Pair > - { - typedef TKey Type; - }; - - template - struct Cargo< Pair > - { - typedef TCargo Type; - }; -//____________________________________________________________________________ - -/** -.Class.Triple: -..cat:Aggregates -..summary:Stores three arbitrary objects. -..signature:Triple -..param.T1:The type of the first object. -..param.T2:The type of the second object. -..param.T3:The type of the third object. -..param.Compression:If $Compressed$, the triple is stored in a more space efficient way (useful for external storage). -...note:When compression is enabled, referring to members is not allowed. -...default:$void$, no compression (faster access). -.Memfunc.Triple#Triple: -..class:Class.Triple -..summary:Constructor -..signature:Triple () -..signature:Triple (triple) -..signature:Triple (i1, i2, i3) -..param.triple:Other Triple object. (copy constructor) -..param.i1:T1 object. -..param.i2:T2 object. -..param.i3:T3 object. -.Memvar.Triple#i1: -..class:Class.Triple -..summary:T1 object -.Memvar.Triple#i2: -..class:Class.Triple -..summary:T2 object -.Memvar.Triple#i3: -..class:Class.Triple -..summary:T3 object -*/ - - // standard storage - template - struct Triple { - typedef _T1 T1; - typedef _T2 T2; - typedef _T3 T3; - _T1 i1; - _T2 i2; - _T3 i3; - inline Triple() {} - inline Triple(Triple const &_p): - i1(_p.i1), i2(_p.i2), i3(_p.i3) {} - inline Triple(_T1 const &_i1, _T2 const &_i2, _T3 const &_i3): - i1(_i1), i2(_i2), i3(_i3) {} - - template - inline Triple(Triple<__T1, __T2, __T3, __TCompression> const &_p): - i1(getValueI1(_p)), i2(getValueI2(_p)), i3(getValueI3(_p)) {} - }; - - // unaligned and unpadded storage (space efficient) -#ifdef PLATFORM_WINDOWS - #pragma pack(push,1) -#endif - template - struct Triple<_T1, _T2, _T3, Compressed> { - typedef _T1 T1; - typedef _T2 T2; - typedef _T3 T3; - _T1 i1; - _T2 i2; - _T3 i3; - inline Triple() {} - inline Triple(Triple const &_p): - i1(_p.i1), i2(_p.i2), i3(_p.i3) {} - inline Triple(_T1 const &_i1, _T2 const &_i2, _T3 const &_i3): - i1(_i1), i2(_i2), i3(_i3) {} - - template - inline Triple(Triple<__T1, __T2, __T3, __TCompression> const &_p): - i1(getValueI1(_p)), i2(getValueI2(_p)), i3(getValueI3(_p)) {} - } -#ifndef PLATFORM_WINDOWS - __attribute__((packed)) -#endif - ; -#ifdef PLATFORM_WINDOWS - #pragma pack(pop) -#endif - - template - std::ostream& operator<<(std::ostream &out, Triple<_T1,_T2,_T3,TCompression> const &t) { - out << "< " << getValueI1(t) << " , " << getValueI2(t) << " , " << getValueI3(t) << " >"; - return out; - } - - template - struct Value< Triple, 1 > { - typedef T1 Type; - }; - - template - struct Value< Triple, 2 > { - typedef T2 Type; - }; - - template - struct Value< Triple, 3 > { - typedef T3 Type; - }; - - template - struct Spec< Triple > { - typedef TCompression Type; - }; - - -//____________________________________________________________________________ - -/** -.Class.Tuple: -..cat:Aggregates -..summary:A plain fixed-length string. -..signature:Tuple -..param.T:The value type, that is the type of characters stored in the tuple. -..param.size:The size/length of the tuple. -...remarks:In contrast to @Class.String@ the length of Tuple is fixed. -..param.compress:Enable/Disable compression. -..param.compress:If $void$, no compression is used. -..param.compress:If $Compressed$, the characters are stored as a bit sequence in an ordinal type (char, ..., __int64) -...remarks:Only useful for small alphabets and small tuple sizes (|Sigma|^size <= 2^64) as for DNA or protein m-grams) -...default:void. -..see:Spec.Sampler -*/ - - // standard storage - template - struct Tuple { - typedef _T T; - enum { size = _size }; - _T i[_size]; - - template - inline _T& operator[](TPos k) { - SEQAN_ASSERT(k >= 0 && k < size); - return i[k]; - } - template - inline const _T& operator[](TPos k) const { - SEQAN_ASSERT(k >= 0 && k < size); - return i[k]; - } - inline _T* operator&() { return i; } - inline const _T* operator&() const { return i; } - - // has to be inline because elements (like this tuple) of packed structs can't be arguments - template - inline SSS const assignValueAt(TPos k, SSS const source) { - return i[k] = source; - } - }; - - - template < unsigned char _size > - struct _BitVector { - typedef typename _BitVector<_size + 1>::Type Type; - }; - - template <> struct _BitVector<8> { typedef unsigned char Type; }; - template <> struct _BitVector<16> { typedef unsigned short Type; }; - template <> struct _BitVector<32> { typedef unsigned int Type; }; - template <> struct _BitVector<64> { typedef __int64 Type; }; - template <> struct _BitVector<255> { typedef __int64 Type; }; - - // bit-compressed storage (space efficient) -#ifdef PLATFORM_WINDOWS - #pragma pack(push,1) -#endif - template - struct Tuple<_T, _size, Compressed> { - typedef _T T; - enum { size = _size }; - enum { bitSize = BitsPerValue<_T>::VALUE }; - enum { bitMask = (1 << bitSize) - 1 }; - enum { mask = (1 << (size * bitSize)) - 1 }; - typedef typename _BitVector< bitSize * size >::Type CT; - - CT i; -/* - inline Tuple() { - SEQAN_ASSERT(bitSize * size <= sizeof(CT) * 8); - } -*/ - template - inline const _T operator[](TPos k) const { - SEQAN_ASSERT(k >= 0 && k < size); - return (i >> (size - 1 - k) * bitSize) & bitMask; - } - template - inline Tuple operator=(Tuple<_T, __size, Compressed> const &_right) { - i = _right.i; - return *this; - } - template - inline CT operator<<=(TShiftSize shift) { - return i = (i << (shift * bitSize)) & mask; - } - template - inline CT operator<<(TShiftSize shift) const { - return (i << (shift * bitSize)) & mask; - } - template - inline CT operator>>=(TShiftSize shift) { - return i = (i >> (shift * bitSize)); - } - template - inline CT operator>>(TShiftSize shift) const { - return i >> (shift * bitSize); - } - template - inline void operator|=(T const &t) { - i |= t; - } - template - inline void operator|=(SimpleType const &t) { - i |= t.value; - } - inline CT* operator&() { return &i; } - inline const CT* operator&() const { return &i; } - - // has to be inline because elements (like this tuple) of packed structs can't be arguments - template - inline SSS const assignValueAt(TPos k, SSS const source) { - typedef Tuple<_T, _size, Compressed> Tup; - typename Tup::CT mask = Tup::bitMask << ((_size - 1 - k) * bitSize); - i = (i & ~mask) | ((CT)source << ((_size - 1 - k) * bitSize)); - return source; - } - } -#ifndef PLATFORM_WINDOWS - __attribute__((packed)) -#endif - ; -#ifdef PLATFORM_WINDOWS - #pragma pack(pop) -#endif - - -////////////////////////////////////////////////////////////////////////////// -// length - - template - inline unsigned length(Tuple<_T, _size, TCompression> const &) { return _size; } - - ///.Metafunction.LENGTH.param.T.type:Class.Tuple - template - struct LENGTH< Tuple<_T, _size, TCompression> > - { - enum { VALUE = _size }; - }; - -////////////////////////////////////////////////////////////////////////////// -// assignValueAt - - template - inline TSource & - assignValueAt(TObject &me, TPos k, TSource &source) { - assign(value(me, k), source); - return source; - } - - template - inline TSource const & - assignValueAt(TObject &me, TPos k, TSource const &source) { - assign(value(me, k), source); - return source; - } - - template - inline SSS const assignValueAt(Tuple &me, TPos k, SSS const source) { - return me.i[k] = source; - } - - template - inline SSS const assignValueAt(Tuple &me, TPos k, SSS const source) { - typedef Tuple Tup; - typename Tup::CT mask = Tup::bitMask << ((_size - 1 - k) * me.bitSize); - me.i = (me.i & ~mask) | source << ((_size - 1 - k) * me.bitSize); - return source; - } - - template - inline SimpleType const & assignValueAt(Tuple &me, TPos k, SimpleType const &source) { - typedef Tuple Tup; - typename Tup::CT mask = Tup::bitMask << ((_size - 1 - k) * me.bitSize); - me.i = (me.i & ~mask) | source.value << ((_size - 1 - k) * me.bitSize); - return source; - } - -////////////////////////////////////////////////////////////////////////////// -// clear - - template - inline void clear(Tuple &me) { - memset(&(me.i)); - } - template - inline void clear(Tuple &me) { - me.i = 0; - } - -////////////////////////////////////////////////////////////////////////////// -// optimized compares - - template - inline bool operator<(Tuple const &_left, Tuple const &_right) { - return _left.i < _right.i; - } - template - inline bool operator>(Tuple const &_left, Tuple const &_right) { - return _left.i > _right.i; - } - template - inline bool operator==(Tuple const &_left, Tuple const &_right) { - return _left.i == _right.i; - } - template - inline bool operator!=(Tuple const &_left, Tuple const &_right) { - return _left.i != _right.i; - } - -////////////////////////////////////////////////////////////////////////////// -// optimized shifts - - struct _TupleShiftLeftWorker { - template - static inline void body(Arg &arg, unsigned I) { - arg[I-1] = arg[I]; - } - }; - - struct _TupleShiftRightWorker { - template - static inline void body(Arg &arg, unsigned I) { - arg[I] = arg[I-1]; - } - }; - - template - inline void shiftLeft(Tuple<_T, _size, TCompression> &me) { - LOOP<_TupleShiftLeftWorker, _size - 1>::run(me); - } - - template - inline void shiftRight(Tuple<_T, _size, TCompression> &me) { - LOOP_REVERSE<_TupleShiftRightWorker, _size - 1>::run(me); - } - - template - inline void shiftLeft(Tuple<_T, _size, Compressed> &me) { - me<<=1; - } - - template - inline void shiftRight(Tuple<_T, _size, Compressed> &me) { - me>>=1; - } - -////////////////////////////////////////////////////////////////////////////// -// standard output - - template - std::ostream& operator<<(std::ostream& out, Tuple<_T,_size,TCompression> const &a) { - out << "["; - if (a.size > 0) - out << a[0]; - for(unsigned j = 1; j < a.size; ++j) - out << " " << a[j]; - out << "]"; - return out; - } - - template - struct Value< Tuple<_T, _size, TCompression> > { - typedef _T Type; - }; - - template - struct Spec< Tuple<_T, _size, TCompression> > { - typedef TCompression Type; - }; - -////////////////////////////////////////////////////////////////////////////// -// getValueIx - - template - inline T1 getValueI1(Pair const &pair) { - return pair.i1; - } - - template - inline T2 getValueI2(Pair const &pair) { - return pair.i2; - } - - template - inline T1 getValueI1(Pair > const &pair) { - typedef Pair > TPair; - return pair.i12 >> TPair::bitShiftI1; - } - - template - inline T2 getValueI2(Pair > const &pair) { - typedef Pair > TPair; - return pair.i12 & (((typename TPair::T12)1 << TPair::bitShiftI1) - 1); - } -//____________________________________________________________________________ - - template - inline T1 getValueI1(Triple const &triple) { - return triple.i1; - } - - template - inline T2 getValueI2(Triple const &triple) { - return triple.i2; - } - - template - inline T3 getValueI3(Triple const &triple) { - return triple.i3; - } - -////////////////////////////////////////////////////////////////////////////// -// assignValueIx - - template - inline void assignValueI1(Pair &pair, T const &_i) { - pair.i1 = _i; - } - - template - inline void assignValueI2(Pair &pair, T const &_i) { - pair.i2 = _i; - } - - template - inline void assignValueI1(Pair > &pair, T const &_i) - { - typedef Pair > TPair; - pair.i12 = ((typename TPair::T12)_i << TPair::bitShiftI1) | - (pair.i12 & (((typename TPair::T12)1 << TPair::bitShiftI1) - 1)); - } - - template - inline void assignValueI2(Pair > &pair, T const &_i) { - typedef Pair > TPair; - pair.i12 = (pair.i12 & ~(((typename TPair::T12)1 << TPair::bitShiftI1) - 1)) | _i; - } -//____________________________________________________________________________ - - template - inline T const assignValueI1(Triple &triple, T const &_i) { - return triple.i1 = _i; - } - - template - inline T const assignValueI2(Triple &triple, T const &_i) { - return triple.i2 = _i; - } - - template - inline T const assignValueI3(Triple &triple, T const &_i) { - return triple.i3 = _i; - } - -////////////////////////////////////////////////////////////////////////////// -// operator ==/!= for pairs and triples - - template - inline bool operator==(Pair const &_left, Pair const &_right) { - return _left.i1 == _right.i1 && _left.i2 == _right.i2; - } - template - inline bool operator!=(Pair const &_left, Pair const &_right) { - return _left.i1 != _right.i1 || _left.i2 != _right.i2; - } - - template - inline bool operator==(Pair > const &_left, Pair > const &_right) { - return _left.i12 == _right.i12; - } - template - inline bool operator!=(Pair > const &_left, Pair > const &_right) { - return _left.i12 != _right.i12; - } -//____________________________________________________________________________ - - template < - typename L1, typename L2, typename L3, typename LCompression, - typename R1, typename R2, typename R3, typename RCompression> - inline bool operator==(Triple const &_left, Triple const &_right) { - return _left.i1 == _right.i1 && _left.i2 == _right.i2 && _left.i3 == _right.i3; - } - template < - typename L1, typename L2, typename L3, typename LCompression, - typename R1, typename R2, typename R3, typename RCompression> - inline bool operator!=(Triple const &_left, Triple const &_right) { - return _left.i1 != _right.i1 || _left.i2 != _right.i2 || _left.i3 != _right.i3; - } - -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_allocator_interface.h b/SeqAn-1.1/seqan/basic/basic_allocator_interface.h deleted file mode 100644 index cc48e0de..00000000 --- a/SeqAn-1.1/seqan/basic/basic_allocator_interface.h +++ /dev/null @@ -1,236 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_allocator_interface.h,v 1.1 2008/08/25 16:20:02 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALLOCATOR_INTERFACE_H -#define SEQAN_HEADER_BASIC_ALLOCATOR_INTERFACE_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -//Allocator -////////////////////////////////////////////////////////////////////////////// - - -/** -.Class.Allocator: -..cat:Basic -..summary:Manager for allocated memory. -..signature:Allocator -..param.TSpec:The specializing type. -...metafunction:Metafunction.Spec -..implements:Concept.Allocator -..include:basic.h -..remarks:There are two reasons for using non-trivial allocators: -...text:1. Allocators support the function @Function.Allocator#clear@ for a fast deallocation of all -allocated memory blocks. -...text:2. Some allocators are faster in allocating an deallocating memory. -Pool allocators like e.g. @Spec.Single Pool Allocator@ or @Spec.Multi Pool Allocator@ -speed up @Function.allocate@, @Function.deallocate@, and @Function.Allocator#clear@ for -pooled memory blocks. -*/ - -template -struct Allocator; - -///.Function.allocate.param.object.type:Class.Allocator -///.Function.deallocate.param.object.type:Class.Allocator - - -////////////////////////////////////////////////////////////////////////////// -// Metafunctions -////////////////////////////////////////////////////////////////////////////// - -//.Metafunction.Spec.param.T.type:Class.Allocator - -template -struct Spec > -{ - typedef TSpec Type; -}; - - -////////////////////////////////////////////////////////////////////////////// -/** -.Tag.Allocator Usage: -..summary:The purpose of an allocated memory block. -..tag.TagAllocateTemp:Temporary memory. -..tag.TagAllocateStorage:Memory for storing container content. -..see:Function.allocate -..see:Function.deallocate -*/ -struct TagAllocateUnspecified_; //< usage not specified -typedef Tag const TagAllocateUnspecified; - -struct TagAllocateTemp_; //< allocate temporary memory -typedef Tag const TagAllocateTemp; - -struct TagAllocateStorage_; //< allocate memory for storing member data -typedef Tag const TagAllocateStorage; - - -////////////////////////////////////////////////////////////////////////////// -//allocates memory on heap. No c'tors are called. -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.allocate: -..cat:Memory -..summary:Allocates memory from heap. -..signature:allocate(object, data, count [, usage_tag]) -..param.object:Allocator object. -...remarks:$object$ is conceptually the "owner" of the allocated memory. - Objects of all types can be used as allocators. If no special behavior is implemented, - default functions allocation/deallocation are applied that uses standard - $new$ and $delete$ operators. -..param.count:Number of items that could be stored in the allocated memory. -...text:The type of the allocated items is given by the type of $data$. -..param.usage_tag:A tag the specifies the purpose for the allocated memory. -...value:@Tag.Allocator Usage@ -..returns.param.data:Pointer to allocated memory. -...remarks:The value of this pointer is overwritten by the function. -..remarks: -...text:The function allocates at least $count*sizeof(data)$ bytes. - The allocated memory is large enough - to hold $count$ objects of type $T$, where $T *$ is type of $data$. -...note:These objects are not constructed by $allocate$. -...text:Use e.g. one of the functions @Function.valueConstruct@, @Function.arrayConstruct@, @Function.arrayConstructCopy@ or @Function.arrayFill@ -to construct the objects. -A $new$ operator which is part of the C++ standard (defined in $$) - can also be used to construct objects at a given memory address. -..note:All allocated memory blocks should be deallocated by the corresponding function @Function.deallocate@. -..see:Function.deallocate -..see:Function.valueConstruct -..see:Function.arrayFill -..see:Function.arrayConstruct -..see:Function.arrayConstructCopy -*/ -template -inline void -allocate(T const & me, - TValue * & data, - TSize count) -{ - allocate(me, data, count, TagAllocateUnspecified()); -} -template -inline void -allocate(T & me, - TValue * & data, - TSize count) -{ - allocate(me, data, count, TagAllocateUnspecified()); -} - -template -inline void -allocate(T const &, - TValue * & data, - TSize count, - Tag const) -{ - data = (TValue *) operator new(count * sizeof(TValue)); - if (data) - SEQAN_PROADD(SEQAN_PROMEMORY, count * sizeof(TValue)); -} -template -inline void -allocate(T &, - TValue * & data, - TSize count, - Tag const) -{ - data = (TValue *) operator new(count * sizeof(TValue)); - if (data) - SEQAN_PROADD(SEQAN_PROMEMORY, count * sizeof(TValue)); -} - - -////////////////////////////////////////////////////////////////////////////// -//deallocates memory that was allocates using allocate(.) - -/** -.Function.deallocate: -..cat:Memory -..summary:Deallocates memory. -..signature:deallocate(object, data, count [, usage_tag]) -..param.object:Allocator object. -...remarks:$object$ is conceptually the "owner" of the allocated memory. - Objects of all types can be used as allocators. If no special behavior is implemented, - default functions allocation/deallocation are applied that uses standard - $new$ and $delete$ operators. -..param.data:Pointer to allocated memory that was allocated by $allocate$. -..param.count:Number of items that could be stored in the allocated memory. -..param.usage_tag:A tag the specifies the purpose for the allocated memory. -...value:@Tag.Allocator Usage@ -..remarks: -...text:The values for $object$, $count$ and $usage_tag$ should be the same that was -used when $allocate$ was called. The value of $data$ should be the same that was -returned by $allocate$. -...note:$deallocate$ does not destruct objects. -...text:Use e.g. one of the functions @Function.valueDestruct@ or @Function.arrayDestruct@ to destruct the objects. -$delete$ and $delete []$ operators which are part of the C++ standard (defined in $$) - can also be used to destruct objects at a given memory address. -..see:Function.valueDestruct -..see:Function.arrayDestruct -*/ -template -inline void -deallocate(T const & me, - TValue * data, - TSize const count) -{ - deallocate(me, data, count, TagAllocateUnspecified()); -} -template -inline void -deallocate(T & me, - TValue * data, - TSize const count) -{ - deallocate(me, data, count, TagAllocateUnspecified()); -} - -template -inline void -deallocate(T const & /*me*/, - TValue * data, - TSize count, - Tag const) -{ - if (data && count) // .. to use count if SEQAN_PROFILE is not defined - SEQAN_PROSUB(SEQAN_PROMEMORY, count * sizeof(TValue)); - operator delete ((void *) data); -} -template -inline void -deallocate(T & /*me*/, - TValue * data, - TSize count, - Tag const) -{ - if (data && count) // .. to use count if SEQAN_PROFILE is not defined - SEQAN_PROSUB(SEQAN_PROMEMORY, count * sizeof(TValue)); - operator delete ((void *) data); -} -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_allocator_multipool.h b/SeqAn-1.1/seqan/basic/basic_allocator_multipool.h deleted file mode 100644 index c637e208..00000000 --- a/SeqAn-1.1/seqan/basic/basic_allocator_multipool.h +++ /dev/null @@ -1,230 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_allocator_multipool.h,v 1.2 2009/02/19 01:51:23 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALLOCATOR_MULTIPOOL_H -#define SEQAN_HEADER_BASIC_ALLOCATOR_MULTIPOOL_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// MultiPool Allocator -////////////////////////////////////////////////////////////////////////////// - -/** -.Spec.Multi Pool Allocator: -..cat:Allocators -..general:Class.Allocator -..summary:Allocator that pools memory blocks. -..signature:Allocator< MultiPool > -..param.ParentAllocator:An allocator that is by the pool allocator used to allocate memory. -...default:@Spec.Simple Allocator@ -...note:The multi pool allocator only supports @Function.clear@ if this function is also implemented for $ParentAllocator$. -..remarks:A pool allocator allocates several memory blocks at once. -..param.BLOCKING_LIMIT:The maximum size for memory blocks to be pooled. -...default:256 -Freed blocks are not immediately deallocated but recycled in subsequential allocations. -This way, the number of calls to the heap manager is reduced, and that speeds up memory management. -...text:Note that memory blocks larger than $BLOCKING_LIMIT$ are not pooled -but immediately allocated and deallocated using $ParentAllocator$. -*/ - - -template >, unsigned int BLOCKING_LIMIT = 0x100> -struct MultiPool; - -////////////////////////////////////////////////////////////////////////////// - -typedef Allocator >, 0x100> > PoolAllocator; - -template -struct Allocator > -{ - enum - { - BLOCKING_LIMIT = BLOCKING_LIMIT_, - GRANULARITY_BITS = 2, - BLOCKING_COUNT = BLOCKING_LIMIT >> GRANULARITY_BITS, - STORAGE_SIZE = 0xf80 - }; - - char * data_recycled_blocks [BLOCKING_COUNT]; - char * data_current_begin [BLOCKING_COUNT]; - char * data_current_free [BLOCKING_COUNT]; - Holder data_parent_allocator; - - Allocator() - { -SEQAN_CHECKPOINT - memset(data_recycled_blocks, 0, sizeof(data_recycled_blocks)); - memset(data_current_begin, 0, sizeof(data_current_begin)); - memset(data_current_free, 0, sizeof(data_current_free)); - } - - Allocator(TParentAllocator & parent_alloc) - { -SEQAN_CHECKPOINT - memset(data_recycled_blocks, 0, sizeof(data_recycled_blocks)); - memset(data_current_begin, 0, sizeof(data_current_begin)); - memset(data_current_free, 0, sizeof(data_current_free)); - - setValue(data_parent_allocator, parent_alloc); - } - - //Dummy copy - Allocator(Allocator const &) - { - memset(data_recycled_blocks, 0, sizeof(data_recycled_blocks)); - memset(data_current_begin, 0, sizeof(data_current_begin)); - memset(data_current_free, 0, sizeof(data_current_free)); - } - inline Allocator & - operator = (Allocator const &) - { - clear(*this); - return *this; - } - - ~Allocator() - { -SEQAN_CHECKPOINT - clear(*this); - } -}; -////////////////////////////////////////////////////////////////////////////// - -template -inline TParentAllocator & -parentAllocator(Allocator > & me) -{ -SEQAN_CHECKPOINT - return value(me.data_parent_allocator); -} - -////////////////////////////////////////////////////////////////////////////// - -template -void -clear(Allocator > & me) -{ -SEQAN_CHECKPOINT - memset(me.data_recycled_blocks, 0, sizeof(me.data_recycled_blocks)); - memset(me.data_current_begin, 0, sizeof(me.data_current_begin)); - memset(me.data_current_free, 0, sizeof(me.data_current_free)); - - clear(parentAllocator(me)); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline unsigned int -_allocatorBlockNumber(Allocator > &, - size_t size_) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - - SEQAN_ASSERT(size_) - - if (size_ < BLOCKING_LIMIT) - {//blocks - return size_ >> TAllocator::GRANULARITY_BITS; - } - else - {//no blocking - return TAllocator::BLOCKING_COUNT; - } -} - - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -allocate(Allocator > & me, - TValue * & data, - TSize count, - Tag const tag_) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - - size_t bytes_needed = count * sizeof(TValue); - char * ptr; - - unsigned int block_number = _allocatorBlockNumber(me, bytes_needed); - if (block_number == TAllocator::BLOCKING_COUNT) - {//no blocking - return allocate(parentAllocator(me), data, count, tag_); - } - - bytes_needed = (block_number + 1) << TAllocator::GRANULARITY_BITS; - - if (me.data_recycled_blocks[block_number]) - {//use recycled - ptr = me.data_recycled_blocks[block_number]; - me.data_recycled_blocks[block_number] = * reinterpret_cast(ptr); - } - else - {//use new - ptr = me.data_current_free[block_number]; - if (!ptr || (ptr + bytes_needed > me.data_current_begin[block_number] + TAllocator::STORAGE_SIZE)) - {//not enough free space in current storage: allocate new - allocate(parentAllocator(me), ptr, (size_t) TAllocator::STORAGE_SIZE, tag_); - me.data_current_begin[block_number] = ptr; - } - me.data_current_free[block_number] = ptr + bytes_needed; - } - - data = reinterpret_cast(ptr); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -deallocate(Allocator > & me, - TValue * data, - TSize count, - Tag const tag_) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - - size_t bytes_needed = count * sizeof(TValue); - - unsigned int block_number = _allocatorBlockNumber(me, bytes_needed); - if (block_number == TAllocator::BLOCKING_COUNT) - {//no blocking - return deallocate(parentAllocator(me), data, count, tag_); - } - - bytes_needed = (block_number + 1) << TAllocator::GRANULARITY_BITS; - - //link in recycling list - *reinterpret_cast(data) = me.data_recycled_blocks[block_number]; - me.data_recycled_blocks[block_number] = reinterpret_cast(data); -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_allocator_simple.h b/SeqAn-1.1/seqan/basic/basic_allocator_simple.h deleted file mode 100644 index 6b570cc7..00000000 --- a/SeqAn-1.1/seqan/basic/basic_allocator_simple.h +++ /dev/null @@ -1,210 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_allocator_simple.h,v 1.1 2008/08/25 16:20:02 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALLOCATOR_SIMPLE_H -#define SEQAN_HEADER_BASIC_ALLOCATOR_SIMPLE_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// - - -////////////////////////////////////////////////////////////////////////////// -// SimpleAlloc Allocator -////////////////////////////////////////////////////////////////////////////// - -/** -.Spec.Simple Allocator: -..cat:Allocators -..general:Class.Allocator -..summary:General purpose allocator. -..signature:Allocator< SimpleAlloc > -..param.ParentAllocator:An allocator that is by the simple allocator used to allocate memory. -...default:@Tag.Default@ -...remarks:@Tag.Default@ used as allocator means that the default implementations -of @Function.allocate@ and @Function.deallocate@ are used. -*/ - -template -struct SimpleAlloc; - -////////////////////////////////////////////////////////////////////////////// - - -typedef Allocator > SimpleAllocator; - -template -struct Allocator > -{ - struct Header - { - Header * left; - Header * right; - size_t size; - }; - - Header * data_storages; - Holder data_parent_allocator; - - Allocator(): - data_storages(0) - { -SEQAN_CHECKPOINT - } - - Allocator(TParentAllocator & parent_alloc): - data_storages(0) - { -SEQAN_CHECKPOINT - setValue(data_parent_allocator, parent_alloc); - } - - //Dummy copy - Allocator(Allocator const &): - data_storages(0) - { - } - inline Allocator & - operator = (Allocator const &) - { - clear(*this); - return *this; - } - - ~Allocator() - { -SEQAN_CHECKPOINT - clear(*this); - } -}; - -////////////////////////////////////////////////////////////////////////////// - -template -inline TParentAllocator & -parentAllocator(Allocator > & me) -{ -SEQAN_CHECKPOINT - return value(me.data_parent_allocator); -} - -////////////////////////////////////////////////////////////////////////////// -/** -.Function.Allocator#clear: -..cat:Memory -..summary:Deallocates all memory blocks. -..signature:clear(allocator) -..param.allocator:Allocator object. -...type:Class.Allocator -...concept:Concept.Allocator -..remarks:This function deallocates all memory blocks -that was allocated using @Function.allocate@ for $allocator$. -The memory is not pooled but directly passed back to the heap manager. -..see:Function.allocate -..see:Function.deallocate -*/ -template -void -clear(Allocator > & me) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - - while (me.data_storages) - { - typename TAllocator::Header * next_storage = me.data_storages->right; - deallocate(parentAllocator(me), reinterpret_cast(me.data_storages), me.data_storages->size); - me.data_storages = next_storage; - } -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -allocate(Allocator > & me, - TValue * & data, - TSize count, - Tag const) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - typedef typename TAllocator::Header THeader; - - //compute needed bytes - size_t bytes_needed = count * sizeof(TValue) + sizeof(THeader); - - //allocate storage from parent - char * ptr; - allocate(parentAllocator(me), ptr, bytes_needed, TagAllocateStorage()); - - THeader * new_block = reinterpret_cast(ptr); - new_block->left = 0; - new_block->right = me.data_storages; - new_block->size = bytes_needed; - - if (me.data_storages) - { - me.data_storages->left = new_block; - } - me.data_storages = new_block; - - //return data - data = reinterpret_cast(ptr + sizeof(THeader)); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -deallocate(Allocator > & me, - TValue * data, - TSize, - Tag const) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - typedef typename TAllocator::Header THeader; - - //update links - THeader & header = *(reinterpret_cast(data) - 1); - if (header.left) - { - header.left->right = header.right; - } - else - { - me.data_storages = header.right; - } - if (header.right) - { - header.right->left = header.left; - } - - //deallocate storage using parent - char * ptr = reinterpret_cast(& header); - deallocate(parentAllocator(me), ptr, header.size); -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_allocator_singlepool.h b/SeqAn-1.1/seqan/basic/basic_allocator_singlepool.h deleted file mode 100644 index 88fde00d..00000000 --- a/SeqAn-1.1/seqan/basic/basic_allocator_singlepool.h +++ /dev/null @@ -1,299 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_allocator_singlepool.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALLOCATOR_SINGLE_POOL_H -#define SEQAN_HEADER_BASIC_ALLOCATOR_SINGLE_POOL_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// SinglePool Allocator -////////////////////////////////////////////////////////////////////////////// - -/** -.Spec.Single Pool Allocator: -..cat:Allocators -..general:Class.Allocator -..summary:Allocator that pools memory blocks of specific size. -..signature:Allocator< SinglePool > -..param.SIZE:Size of memory blocks that are pooled. -...value:An unsigned integer with $SIZE >= sizeof(void *)$. -..param.ParentAllocator:An allocator that is by the pool allocator used to allocate memory. -...default:@Spec.Simple Allocator@ -...note:The single pool allocator only supports @Function.clear@ if this function is also implemented for $ParentAllocator$. -..remarks:A pool allocator allocates several memory blocks at once. -Freed blocks are not immediately deallocated but recycled in subsequential allocations. -This way, the number of calls to the heap manager is reduced, and that speeds up memory management. -...text:The single pool allocator only pools memory blocks of size $SIZE$. -Blocks of other sizes are allocated and deallocated using an allocator of type $ParentAllocator$. -...text:Using the single pool allocator for blocksizes larger than some KB is not advised. -*/ - -template -struct SinglePool; - -////////////////////////////////////////////////////////////////////////////// - -template -struct Allocator > -{ - enum - { - SIZE_PER_ITEM = SIZE, - ITEMS_PER_BLOCK = (SIZE_PER_ITEM < 0x0100) ? 0x01000 / SIZE_PER_ITEM : 16, - STORAGE_SIZE = SIZE * ITEMS_PER_BLOCK, - - STORAGE_SIZE_MIN = SIZE - }; - - char * data_recycled_blocks; - char * data_current_begin; - char * data_current_end; - char * data_current_free; - Holder data_parent_allocator; - - Allocator() - { -SEQAN_CHECKPOINT - data_recycled_blocks = data_current_end = data_current_free = 0; - //dont need to initialize data_current_begin - } - - Allocator(size_t reserve_item_count) - { -SEQAN_CHECKPOINT - data_recycled_blocks = 0; - - size_t storage_size = (reserve_item_count * SIZE > STORAGE_SIZE_MIN) ? reserve_item_count * SIZE : STORAGE_SIZE_MIN; - allocate( parentAllocator( *this ), data_current_begin, storage_size ); - data_current_end = data_current_begin + storage_size; - data_current_free = data_current_begin; - } - - Allocator(TParentAllocator & parent_alloc) - { -SEQAN_CHECKPOINT - setValue(data_parent_allocator, parent_alloc); - - data_recycled_blocks = data_current_end = data_current_free = 0; - //dont need to initialize data_current_begin - } - - Allocator(size_t reserve_item_count, TParentAllocator & parent_alloc) - { -SEQAN_CHECKPOINT - data_recycled_blocks = 0; - - setValue(data_parent_allocator, parent_alloc); - - size_t storage_size = (reserve_item_count * SIZE > STORAGE_SIZE_MIN) ? reserve_item_count * SIZE : STORAGE_SIZE_MIN; - allocate( parentAllocator( *this ), data_current_begin, storage_size ); - data_current_end = data_current_begin + storage_size; - data_current_free = data_current_begin; - } - - //Dummy copy - Allocator(Allocator const &) - { - data_recycled_blocks = data_current_end = data_current_free = 0; - //dont need to initialize data_current_begin - } - inline Allocator & - operator = (Allocator const &) - { - clear(*this); - return *this; - } - - ~Allocator() - { -SEQAN_CHECKPOINT - clear(*this); - } -}; -////////////////////////////////////////////////////////////////////////////// - -template -inline TParentAllocator & -parentAllocator(Allocator > & me) -{ -SEQAN_CHECKPOINT - return value(me.data_parent_allocator); -} - -////////////////////////////////////////////////////////////////////////////// - -template -void -clear(Allocator > & me) -{ -SEQAN_CHECKPOINT - - me.data_recycled_blocks = me.data_current_end = me.data_current_free = 0; - - clear(parentAllocator(me)); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -allocate(Allocator > & me, - TValue * & data, - TSize count, - Tag const tag_) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - size_t bytes_needed = count * sizeof(TValue); - - if (bytes_needed != TAllocator::SIZE_PER_ITEM) - {//no blocking - allocate(parentAllocator(me), data, count, tag_); - return; - } - - char * ptr; - if (me.data_recycled_blocks) - {//use recycled - ptr = me.data_recycled_blocks; - me.data_recycled_blocks = * reinterpret_cast(ptr); - } - else - {//use new - ptr = me.data_current_free; - if (ptr + bytes_needed > me.data_current_end) - {//not enough free space in current storage: allocate new - allocate(parentAllocator(me), ptr, (size_t) TAllocator::STORAGE_SIZE, tag_); - me.data_current_begin = ptr; - me.data_current_end = ptr + TAllocator::STORAGE_SIZE; - } - me.data_current_free = ptr + bytes_needed; - } - - data = reinterpret_cast(ptr); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -deallocate(Allocator > & me, - TValue * data, - TSize count, - Tag const tag_) -{ -SEQAN_CHECKPOINT - typedef Allocator > TAllocator; - - size_t bytes_needed = count * sizeof(TValue); - - if (bytes_needed != TAllocator::SIZE_PER_ITEM) - {//no blocking - deallocate(parentAllocator(me), data, count, tag_); - return; - } - - //link in recycling list - *reinterpret_cast(data) = me.data_recycled_blocks; - me.data_recycled_blocks = reinterpret_cast(data); -} - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -// alternative Interface that takes a Type instead of a SIZE -////////////////////////////////////////////////////////////////////////////// - - -template -struct SinglePool2; - -template -struct Allocator > -{ - Allocator > data_alloc; - - - Allocator(size_t reserve_item_count) - : data_alloc(reserve_item_count) - { - } - - Allocator(TParentAllocator & parent_alloc) - : data_alloc(parent_alloc) - { - } - - Allocator(size_t reserve_item_count, TParentAllocator & parent_alloc) - : data_alloc(reserve_item_count, parent_alloc) - - { - } -}; - -////////////////////////////////////////////////////////////////////////////// - -template -inline TParentAllocator & -parentAllocator(Allocator > & me) -{ -SEQAN_CHECKPOINT - return parentAllocator(me.data_alloc); -} - -////////////////////////////////////////////////////////////////////////////// - -template -void -clear(Allocator > & me) -{ -SEQAN_CHECKPOINT - clear(me.data_alloc); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -allocate(Allocator > & me, - TValue2 * & data, - TSize count, - Tag const tag_) -{ -SEQAN_CHECKPOINT - allocate(me.data_alloc, data, count, tag_); -} - -template -inline void -deallocate(Allocator > & me, - TValue2 * data, - TSize count, - Tag const tag_) -{ -SEQAN_CHECKPOINT - deallocate(me.data_alloc, data, count, tag_); -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_allocator_to_std.h b/SeqAn-1.1/seqan/basic/basic_allocator_to_std.h deleted file mode 100644 index e54589de..00000000 --- a/SeqAn-1.1/seqan/basic/basic_allocator_to_std.h +++ /dev/null @@ -1,178 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_allocator_to_std.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALLOCATOR_TO_STD_H -#define SEQAN_HEADER_BASIC_ALLOCATOR_TO_STD_H - - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// -//helper caller for calling functions that have same name as member functions - -template -inline void call_allocate(TMe & me, TValue * & data, TSize const count) -{ - allocate(me, data, count); -} -template -inline void call_deallocate(TMe & me, TValue * data, TSize const count) -{ - deallocate(me, data, count); -} - -////////////////////////////////////////////////////////////////////////////// -//Filter that adapts seqan allocator zu std allocator -/** -.Class.ToStdAllocator: -..summary:Emulates standard conform allocator. -..signature:ToStdAllocator -..param.THost:Type of the host allocator object. -...text:This object is used to call @Function.allocate@ and @Function.deallocate@. -..param.TValue:Type of allocated items. -..remarks:The member functions $allocate$ and $deallocate$ of $ToStdAllocator$ call -the (globale) functions @Function.allocate@ and @Function.deallocate@, respectively. The globale functions -get an allocator object as their first arguments. This allocator object is not the $ToStdAllocator$ object itself, -but the host object that was given to the constructor. -..remarks: -..see:Function.allocate -..see:Function.deallocate -*/ -template -struct ToStdAllocator -{ - typedef TValue value_type; - typedef value_type * pointer; - typedef value_type & reference; - typedef value_type const * const_pointer; - typedef value_type const & const_reference; - -// typedef typename THost::Size size_type; -// typedef typename THost::Difference difference_type; - typedef size_t size_type; - typedef ptrdiff_t difference_type; - -/** -.Memfunc.ToStdAllocator: -..summary:Constructor -..signature:ToStdAllocator(host) -..class:Class.ToStdAllocator -..param.host:The host object that is used as allocator for @Function.allocate@ and @Function.deallocate@. -*/ - ToStdAllocator(THost & host): m_host(& host) - { - } - ToStdAllocator(ToStdAllocator const & alloc): m_host(alloc.m_host) - { - } - ToStdAllocator & operator= (ToStdAllocator const & alloc) - { - m_host = alloc.m_host; - } - ~ToStdAllocator() - { - } - -/** -.Function.host: -..summary:The object a given object depends on. -..cat:Dependent Objects -..signature:host(object) -..param.object:An object. -...type:Class.ToStdAllocator -..returns:The host object. -*/ - friend THost & host(ToStdAllocator & me) - { - return *me.m_host; - } - - pointer allocate(size_type count) - { - value_type * ptr; - call_allocate(*m_host, ptr, count); - return pointer(ptr); - } - pointer allocate(size_type count, const void *) - { - value_type * ptr; - call_allocate(*m_host, ptr, count); - return pointer(ptr); - } - - void deallocate(pointer data, size_type count) - { - call_deallocate(*m_host, data, count); - } - - void construct(pointer ptr, const_reference data) - { - new(ptr) TValue(data); - } - - void destroy(pointer ptr) - { - ptr->~TValue(); - } - - pointer address(reference value) const - { - return (&value); - } - const_pointer address(const_reference value) const - { - return (&value); - } - - size_type max_size() const - { - return ~0UL / sizeof(value_type); - } - - template - struct rebind - { - typedef ToStdAllocator other; - }; - - private: - THost * m_host; -}; -////////////////////////////////////////////////////////////////////////////// - - - -//returns std-allocator type (for allocators) -template -struct StdAllocator -{ - typedef ToStdAllocator Type; -}; - - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - - -////////////////////////////////////////////////////////////////////////////// - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_alphabet_interface.h b/SeqAn-1.1/seqan/basic/basic_alphabet_interface.h deleted file mode 100644 index dd9a92f0..00000000 --- a/SeqAn-1.1/seqan/basic/basic_alphabet_interface.h +++ /dev/null @@ -1,917 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_alphabet_interface.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALPHABET_INTERFACE_H -#define SEQAN_HEADER_BASIC_ALPHABET_INTERFACE_H - -#include - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -//IsSimple -////////////////////////////////////////////////////////////////////////////// - -/** -.Metafunction.IsSimple: -..summary:Tests type to be simple. -..signature:IsSimple::Type -..param.T:Type that is tested. -..returns.param.Type:@Tag.Logical Values.True@, if $T$ is a simple type, @Tag.Logical Values.False@ otherwise. -...default:@Tag.Logical Values.False@ -..remarks:A simple type is a type that does not need constructors to be created, -a destructor to be destroyed, and copy assignment operators or copy constructors -to be copied. All POD ("plain old data") types are simple, but some -non-POD types could be simple too, e.g. some specializations of @Class.SimpleType@. -..see:Class.SimpleType -*/ - -template -struct _IsSimple { - typedef False Type; -}; - -template -struct IsSimple: - public _IsSimple {}; -template -struct IsSimple: - public IsSimple {}; - -////////////////////////////////////////////////////////////////////////////// -//very basic Alphabets - -typedef char Ascii; -typedef unsigned char Byte; -typedef wchar_t Unicode; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.valueConstruct: -..cat:Content Manipulation -..summary:Constructs an object at specified position. -..signature:valueConstruct(iterator [, param [, move_tag] ]) -..param.iterator:Pointer or iterator to position where the object should be constructed. -..param.param:Parameter that is forwarded to constructor. (optional) -..param.move_tag:Instance of the @Tag.Move Switch.move switch tag@. (optional) -...remarks:If the @Tag.Move Switch.move switch tag@ is specified, it is forwarded to the constructor, -so the constructed object must support move construction. -..remarks:The type of the destructed object is the @Metafunction.Value.value type@ of $iterator$. -*/ - -struct _ValueConstructor -{ - template - static inline void - construct(TIterator it) - { - typedef typename Value::Type TValue; - new( & value(it) ) TValue; - } - - template - static inline void - construct(TIterator it, - TParam const & param_) - { - typedef typename Value::Type TValue; - new( & value(it) ) TValue(param_); - } - - template - static inline void - construct(TIterator it, - TParam const & param_, - Move tag) - { - typedef typename Value::Type TValue; - new( & value(it) ) TValue(param_, tag); - } -}; - -struct _ValueConstructorProxy -{ - template - static inline void construct(TIterator) {} - - template - static inline void construct(TIterator, TParam const &) {} - - template - static inline void construct(TIterator, TParam const &, Move) {} -}; - -//____________________________________________________________________________ - -struct _ValueDestructor -{ - template - static inline void - destruct(TIterator it) - { - typedef typename Value::Type TValue; - value(it).~TValue(); - } -}; -struct _ValueDestructorProxy -{ - template - static inline void destruct(TIterator) {} -}; - -//____________________________________________________________________________ - -template -inline void -valueConstruct(TIterator it) -{ -SEQAN_CHECKPOINT - typedef typename IF< - TYPECMP< - typename Value::Type &, - typename Reference::Type - >::VALUE, - // THEN - _ValueConstructor, // true, types are equal - // ELSE - _ValueConstructorProxy // false, types differ -> value() returns a proxy - >::Type TConstructor; - - TConstructor::construct(it); -} - -template -inline void -valueConstruct(TIterator it, - TParam const & param_) -{ -SEQAN_CHECKPOINT - typedef typename IF< - TYPECMP< - typename Value::Type &, - typename Reference::Type - >::VALUE, - // THEN - _ValueConstructor, // true, types are equal - // ELSE - _ValueConstructorProxy // false, types differ -> value() returns a proxy - >::Type TConstructor; - - TConstructor::construct(it, param_); -} - -template -inline void -valueConstruct(TIterator it, - TParam const & param_, - Move tag) -{ -SEQAN_CHECKPOINT - typedef typename IF< - TYPECMP< - typename Value::Type &, - typename Reference::Type - >::VALUE, - // THEN - _ValueConstructor, // true, types are equal - // ELSE - _ValueConstructorProxy // false, types differ -> value() returns a proxy - >::Type TConstructor; - - TConstructor::construct(it, param_, tag); -} - -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.valueDestruct: -..cat:Content Manipulation -..summary:Destoys an object at specified position. -..signature:valueDestruct(iterator) -..param.iterator:Pointer or iterator to position where the object should be constructed. -..remarks:The type of the constructed object is the @Metafunction.Value.value type@ of $iterator$. -..see:Function.valueConstruct -*/ -template -inline void -valueDestruct(TIterator it) -{ -SEQAN_CHECKPOINT - typedef typename IF< - TYPECMP< - typename Value::Type &, - typename Reference::Type - >::VALUE, - // THEN - _ValueDestructor, // true, types are equal - // ELSE - _ValueDestructorProxy // false, types differ -> value() returns a proxy - >::Type TDestructor; - - TDestructor::destruct(it); -} - - -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.valueConstructMove: -..cat:Content Manipulation -..summary:Move constructs an object at specified position. -..signature:valueConstructMove(iterator, param) -..param.iterator:Pointer or iterator to position where the object should be constructed. -..param.param:Parameter that is moved to the new constructed object. -..remarks:The type of the destructed object is the @Metafunction.Value.value type@ of $iterator$. -..remarks:The default implementation just calls @Function.valueConstruct@. -*/ -template -inline void -valueConstructMove(TIterator it, TValue const & value) -{ - valueConstruct(it, value); -} - - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -//arrayConstruct -////////////////////////////////////////////////////////////////////////////// -/** -.Function.arrayConstruct: -..cat:Array Handling -..summary:Construct objects in a given memory buffer. -..signature:arrayConstruct(begin, end [, value]) -..param.begin:Iterator to the begin of the range that is to be constructed. -..param.end:Iterator behind the end of the range. -..param.value:Argument that is forwarded to the constructor. (optional) -...text:An appropriate constructor is required. -If $value$ is not specified, the default constructor is used. -..remarks:The type of the constructed Objects is the @Metafunction.Value.value type@ -of $begin$ and $end$. -..see:Function.arrayDestruct -..see:Function.arrayConstructCopy -..see:Function.arrayFill -..see:Class.SimpleType -..see:Function.valueConstruct -*/ -template -inline void -_arrayConstruct_Default(TIterator1 begin_, - TIterator2 end_) -{ -SEQAN_CHECKPOINT - while (begin_ != end_) - { - valueConstruct(begin_); - ++begin_; - } -} -template -inline void -arrayConstruct(TIterator1 begin_, - TIterator2 end_) -{ -SEQAN_CHECKPOINT - _arrayConstruct_Default(begin_, end_); -} - -//____________________________________________________________________________ - -template -inline void -_arrayConstruct_Default(TIterator1 begin_, - TIterator2 end_, - TParam const & param_) -{ -SEQAN_CHECKPOINT - while (begin_ != end_) - { - valueConstruct(begin_, param_); - ++begin_; - } -} -template -inline void -arrayConstruct(TIterator1 begin_, - TIterator2 end_, - TParam const & param_) -{ -SEQAN_CHECKPOINT - _arrayConstruct_Default(begin_, end_, param_); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayConstructCopy -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayConstructCopy: -..cat:Array Handling -..summary:Copy constructs an array of objects into in a given memory buffer. -..signature:arrayConstructCopy(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source range. -..param.source_end:Iterator behind the last element of the source range. -...text:$source_end$ should have the same type as $source_begin$. -..param.target:Pointer to the memory block the new objects will be constructed in. -...text:The type of $target$ specifies the type of the constructed objects: -If $T*$ is the type of $target$, then the function constructs objects of type $T$. -...text:The memory buffer should be large enough to store $source_end$ - $source_begin$ objects. -An appropriate (copy-) constructor that constructs an target objects given a source object is required. -..see:Function.arrayDestruct -..see:Function.arrayCopyForward -..see:Function.arrayCopy -..see:Function.valueConstruct -*/ -template -inline void -_arrayConstructCopy_Default(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - while (source_begin != source_end) - { - valueConstruct(target_begin, *source_begin); - ++source_begin; - ++target_begin; - } -} - -template -inline void -arrayConstructCopy(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - _arrayConstructCopy_Default(source_begin, source_end, target_begin); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayConstructMove -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayConstructMove: -..cat:Array Handling -..summary:Move constructs an array of objects into in a given memory buffer. -..signature:arrayConstructMove(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source range. -..param.source_end:Iterator behind the last element of the source range. -...text:$source_end$ should have the same type as $source_begin$. -..param.target:Pointer to the memory block the new objects will be constructed in. -...text:The type of $target$ specifies the type of the constructed objects: -If $T*$ is the type of $target$, then the function constructs objects of type $T$. -...text:The memory buffer should be large enough to store $source_end$ - $source_begin$ objects. -An appropriate move constructor that constructs an target objects given a source object is required. -..see:Function.arrayDestruct -..see:Function.arrayConstructCopy -..see:Function.arrayMoveForward -..see:Function.arrayMove -..see:Function.valueConstruct -*/ -template -inline void -_arrayConstructMove_Default(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - while (source_begin < source_end) - { - valueConstructMove(target_begin, *source_begin); - ++source_begin; - ++target_begin; - } -} - -template -inline void -arrayConstructMove(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - _arrayMoveConstruct_Default(source_begin, source_end, target_begin); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayDestruct -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayDestruct: -..cat:Array Handling -..summary:Destroys an array of objects. -..signature:arrayDestruct(begin, end) -..param.begin:Iterator to the begin of the range that is to be destructed. -..param.end:Iterator behind the end of the range. -..remarks:This function does not deallocates the memory. -..see:Class.SimpleType -..see:Function.valueDestruct -*/ -template -inline void -_arrayDestruct_Default(TIterator1 begin_, - TIterator2 end_) -{ -SEQAN_CHECKPOINT - while (begin_ != end_) - { - valueDestruct(begin_); - ++begin_; - } -} -template -inline void -arrayDestruct(TIterator1 begin_, - TIterator2 end_) -{ -SEQAN_CHECKPOINT - _arrayDestruct_Default(begin_, end_); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayFill -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayFill: -..cat:Array Handling -..summary:Assigns one object to each element of a range. -..signature:arrayFill(begin, end, value) -..param.begin:Iterator to the begin of the range that is to be filled. -..param.end:Iterator behind the end of the range. -..param.value:Argument that is assigned to all $count$ objects in $array$. -..remarks:All objects $target_begin[0]$ to $target_begin[count-1]$ are set to $value$. -..see:Function.arrayCopy -..see:Function.arrayCopyForward -*/ -template -inline void -arrayFill(TIterator1 begin_, - TIterator2 end_, - TValue const & value) -{ -SEQAN_CHECKPOINT - ::std::fill_n(begin_, end_ - begin_, value); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayCopyForward -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayCopyForward: -..cat:Array Handling -..summary:Copies a range of objects into another range of objects starting from the first element. -..signature:arrayCopyForward(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source array. -..param.source_end:Iterator behind the last element of the source array. -...text:$source_end$ must have the same type as $source_begin$. -..param.target:Iterator to the first element of the target array. -...text:The target capacity should be at least as long as the source range. -..remarks.note:Be careful if source and target range overlap, because in this case - some source elements could be accidently overwritten before they are moved. -..remarks:If there is no need for the source elements to persist, consider to use -@Function.arrayMoveForward@ instead to improve performance. -..see:Class.SimpleType -*/ -template -inline void -_arrayCopyForward_Default(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - ::std::copy(source_begin, source_end, target_begin); -} -template -inline void -arrayCopyForward(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - _arrayCopyForward_Default(source_begin, source_end, target_begin); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayCopyBackward -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayCopyBackward: -..cat:Array Handling -..summary:Copies a range of objects into another range of objects starting from the last element. -..signature:arrayCopyBackward(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source array. -..param.source_end:Iterator behind the last element of the source array. -...text:$source_end$ must have the same type as $source_begin$. -..param.target:Iterator to the first element of the target array. -...text:The target capacity should be at least as long as the source range. -..remarks.note:Be careful if source and target range overlap, because in this case - some source elements could be accidently overwritten before they are moved. -..remarks.text:If source and target do not overlap, consider to use the function -@Function.arrayCopyForward@ instead that is faster in some cases. -..remarks:If there is no need for the source elements to persist, consider to use -@Function.arrayMoveBackward@ instead to improve performance. -..remarks.note:The semantic of this function's argument $target$ differ from the arguments of $::std::copy_backward$. -..see:Function.arrayCopyForward -..see:Class.SimpleType -*/ -template -inline void -_arrayCopyBackward_Default(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - ::std::copy_backward(source_begin, source_end, target_begin + (source_end - source_begin)); -} -template -inline void -arrayCopyBackward(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - _arrayCopyBackward_Default(source_begin, source_end, target_begin); -} - - -////////////////////////////////////////////////////////////////////////////// -//arrayCopy -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayCopy: -..cat:Array Handling -..summary:Copies a range of objects into another range of objects. -..signature:arrayCopy(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source range. -..param.source_end:Iterator behind the last element of the source range. -...text:$source_end$ must have the same type as $source_begin$. -..param.target:Iterator to the first element of the target range. -...text:The target capacity should be at least as long as the source range. -..remarks.text:If source and target range do not overlap, consider to use - @Function.arrayCopyForward@ instead to improve performance. -..remarks:If there is no need for the source elements to persist, consider to use - @Function.arrayMoveForward@ instead to improve performance. -..DISABLED.remarks.note:Be careful if source and target range overlap and the size of the - source elements differ from the size of target elements, because in this case - some source elements could be accidently overwritten before they are moved. -..see:Function.arrayCopyForward -..see:Function.arrayCopyBackward -..see:Class.SimpleType -*/ -template -inline void arrayCopy(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ - if ((void *) source_begin >= (void *) target_begin) - { -SEQAN_CHECKPOINT - arrayCopyForward(source_begin, source_end, target_begin); - } - else - { -SEQAN_CHECKPOINT - arrayCopyBackward(source_begin, source_end, target_begin); - } -} - -////////////////////////////////////////////////////////////////////////////// -//arrayMoveForward -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayMoveForward: -..cat:Array Handling -..summary:Moves a range of objects into another range of objects starting from the first element. -..signature:arrayMoveForward(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source array. -..param.source_end:Iterator behind the last element of the source array. -...text:$source_end$ must have the same type as $source_begin$. -..param.target:Iterator to the first element of the target array. -...text:The target capacity should be at least as long as the source range. -..remarks:The function possibly clears (but does not destroy) the source elements. - If source elements must persist, consider to use @Function.arrayCopyForward@ instead. -..remarks.note:Be careful if source and target range overlap, because in this case - some source elements could be accidently overwritten before they are moved. -..see:Function.arrayCopyForward -..see:Class.SimpleType -*/ -template -inline void -_arrayMoveForward_Default(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - while (source_begin != source_end) - { - move(*target_begin, *source_begin); - ++source_begin; - ++target_begin; - } -} -template -inline void -arrayMoveForward(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - _arrayMoveForward_Default(source_begin, source_end, target_begin); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayMoveBackward -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayMoveBackward: -..cat:Array Handling -..summary:Moves a range of objects into another range of objects starting from the last element. -..signature:arrayMoveBackward(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source array. -..param.source_end:Iterator behind the last element of the source array. -...text:$source_end$ must have the same type as $source_begin$. -..param.target:Iterator to the first element of the target array. -...text:The target capacity should be at least as long as the source range. -..remarks:The function possibly clears (but does not destroy) the source elements. - If source elements must persist, consider to use @Function.arrayCopyBackward@ instead. -..remarks.note:Be careful if source and target range overlap, because in this case - some source elements could be accidently overwritten before they are moved. -..remarks.text:If source and target do not overlap, consider to use the function -@Function.arrayMoveForward@ instead that is faster in some cases. -..remarks.note:The semantic of this function's argument $target$ differ from the arguments of $::std::copy_backward$. -..see:Function.arrayMoveForward -..see:Function.arrayCopyBackward -..see:Class.SimpleType -*/ -template -inline void -_arrayMoveBackward_Default(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - target_begin += (source_end - source_begin); - while (source_end != source_begin) - { - --source_end; - --target_begin; - move(*target_begin, *source_end); - } -} -template -inline void -arrayMoveBackward(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ -SEQAN_CHECKPOINT - _arrayMoveBackward_Default(source_begin, source_end, target_begin); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayMove -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayMove: -..cat:Array Handling -..summary:Moves a range of objects into another range of objects. -..signature:arrayMove(source_begin, source_end, target) -..param.source_begin:Iterator to the first element of the source range. -..param.source_end:Iterator behind the last element of the source range. -...text:$source_end$ must have the same type as $source_begin$. -..param.target:Iterator to the first element of the target range. -...text:The target capacity should be at least as long as the source range. -..remarks:The function possibly clears (but does not destroy) the source elements. - If source elements must persist, consider to use @Function.arrayCopy@ instead. -..remarks.text:If source and target range do not overlap, consider to use - @Function.arrayMoveForward@ instead to improve performance. -..DISABLED.remarks.note:Be careful if source and target range overlap and the size of the - source elements differ from the size of target elements, because in this case - some source elements could be accidently overwritten before they are moved. -..remarks.note:Don't confuse this function with the standard $move$ function that -resembles @Function.arrayCopy@. -..see:Function.arrayMoveForward -..see:Function.arrayMoveBackward -..see:Function.arrayCopy -..see:Class.SimpleType -*/ -template -inline void -arrayMove(TSource1 source_begin, - TSource2 source_end, - TTarget target_begin) -{ - if ((void *) source_begin >= (void *) target_begin) - { -SEQAN_CHECKPOINT - arrayMoveForward(source_begin, source_end, target_begin); - } - else - { -SEQAN_CHECKPOINT - arrayMoveBackward(source_begin, source_end, target_begin); - } -} - -////////////////////////////////////////////////////////////////////////////// -//arrayClearSpace -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.arrayClearSpace: -..cat:Array Handling -..summary:Destroys the begin of an array and keeps the rest. -..signature:arrayClearSpace(arr_begin, arr_length, keep_from, move_to) -..param.arr_begin:Pointer to the first element of the array. -..param.arr_length:Length of the array. -..param.keep_from:Offset of the first object that will be kept. -..param.move_to:Offset the first kept object will get at the end of the function. -..remarks.text:The objects $arr[keep_from]$ to $arr[arr_length-1]$ -are moved to the area beginning at positions $move_to$. -All objects in $arr[0]$ to $arr[keep_from-1]$ are destroyed. -After this function, the first $move_to$ positions of the array -are free and dont contain objects. -..remarks.text:The array must have at least enough space to store $arr_length + move_to - keep_from$ objects. -..see:Function.arrayCopy -..see:Function.arrayDestruct -..see:Function.arrayCopyForward -..see:Class.SimpleType -*/ -template -void _arrayClearSpace_Default(TIterator array_begin, - size_t array_length, - size_t keep_from, - size_t move_to) -{ - if (keep_from == array_length) - { - arrayDestruct(array_begin, array_begin + array_length); - return; - } - - SEQAN_ASSERT(keep_from < array_length) - - if (keep_from == move_to) - { - arrayDestruct(array_begin, array_begin + move_to); - } - else if (keep_from < move_to) - { - if (array_length > move_to) - { -SEQAN_CHECKPOINT - size_t middle = array_length - (move_to - keep_from); - arrayConstructMove(array_begin + middle, array_begin + array_length, array_begin + array_length); - arrayMove(array_begin + keep_from, array_begin + middle, array_begin + move_to); - arrayDestruct(array_begin, array_begin + move_to); - } - else - { -SEQAN_CHECKPOINT - arrayConstructMove(array_begin + keep_from, array_begin + array_length, array_begin + move_to); - arrayDestruct(array_begin, array_begin + array_length); - } - } - else - { -SEQAN_CHECKPOINT - arrayMove(array_begin + keep_from, array_begin + array_length, array_begin + move_to); - arrayDestruct(array_begin, array_begin + move_to); - arrayDestruct(array_begin + array_length - (keep_from - move_to), array_begin + array_length); - } -} - -template -void arrayClearSpace(TIterator array_begin, - size_t array_length, - size_t keep_from, - size_t move_to) -{ - _arrayClearSpace_Default(array_begin, array_length, keep_from, move_to); -} - - -////////////////////////////////////////////////////////////////////////////// -//BitsPerValue -////////////////////////////////////////////////////////////////////////////// -/** -.Metafunction.BitsPerValue: -..summary:Number of bits needed to store a value. -..signature:BitsPerValue::VALUE -..param.T:A class. -..returns.param.VALUE:Number of bits needed to store $T$. -...default:$sizeof * 8$ -..see:Metafunction.ValueSize -*/ -template -struct BitsPerValue -{ - enum { VALUE = sizeof(TValue) * 8 }; -}; -template -struct BitsPerValue: - public BitsPerValue {}; - -////////////////////////////////////////////////////////////////////////////// -//ValueSize -////////////////////////////////////////////////////////////////////////////// -/** -.Metafunction.ValueSize: -..summary:Number of different values a value type object can have. -..signature:ValueSize::VALUE -..param.T:A class. -..returns.param.VALUE:Value size of $T$. -..remarks -...text:This function is only defined for integral types like $unsigned int$, $double$ or @Spec.Dna@. -..see:Metafunction.Value -*/ -template -struct ValueSize -{ - enum { VALUE = 1 << BitsPerValue::VALUE }; -}; -template -struct ValueSize: - public ValueSize {}; - - - -template < typename T > -struct _SupremumValueUnsigned { static const T VALUE; }; -template < typename T > -struct _SupremumValueSigned { static const T VALUE; }; - -template < typename T > -struct _InfimumValueUnsigned { static const T VALUE; }; -template < typename T > -struct _InfimumValueSigned { static const T VALUE; }; - - - -template < typename T > -const T _SupremumValueUnsigned::VALUE = ~(T)0; -template < typename T > -const T _SupremumValueSigned::VALUE = ( (((T)1 << (BitsPerValue::VALUE - 2)) - 1) << 1) + 1; - -template < typename T > -const T _InfimumValueUnsigned::VALUE = 0; -template < typename T > -const T _InfimumValueSigned::VALUE = ~(T)_SupremumValueSigned::VALUE; - - - -template < - typename T, - typename TParent = typename IF< - TYPECMP< typename _MakeSigned::Type, T >::VALUE, - _SupremumValueSigned, - _SupremumValueUnsigned >::Type > -struct SupremumValue: - public TParent -{ -}; - -template < - typename T, - typename TParent = typename IF< - TYPECMP< typename _MakeSigned::Type, T >::VALUE, - _InfimumValueSigned, - _InfimumValueUnsigned >::Type > -struct InfimumValue: - public TParent -{ -}; - -////////////////////////////////////////////////////////////////////////////// -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_alphabet_interface2.h b/SeqAn-1.1/seqan/basic/basic_alphabet_interface2.h deleted file mode 100644 index d523e2b6..00000000 --- a/SeqAn-1.1/seqan/basic/basic_alphabet_interface2.h +++ /dev/null @@ -1,178 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_alphabet_interface2.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALPHABET_INTERFACE2_H -#define SEQAN_HEADER_BASIC_ALPHABET_INTERFACE2_H - -#include - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// -// gapValue, gapValueImpl -////////////////////////////////////////////////////////////////////////////// -/** -.Function.gapValueImpl: -..hidefromindex -..cat:Alphabets -..summary:Implements @Function.gapValue@. -..signature:gapValueImpl(value_pointer_tag) -..param.value_pointer_tag:A pointer that is used as a tag to specify the value type. -...remarks:The pointer needs not to point to a valid object, so it is possible to use a null pointer here. -..returns:A gap character. -..remarks.text:This function implements @Function.getValue@. -It is recommended to use @Function.gapValue@ rather than $gapValueImpl$. -*/ - -template -inline T const & -gapValueImpl(T *) -{ -SEQAN_CHECKPOINT - static T const _gap = T(); - return _gap; -} - - -/** -.Function.gapValue: -..cat:Alphabets -..cat:Alignments -..summary:Returns reference to a value that is used as gap character. -..signature:gapValue() -..param.TValue:Value type. -..returns:A gap character. -..remarks.text:The function is implemented in @Function.gapValueImpl@. -Do not specialize $gapValue$, specialize @Function.gapValueImpl@ instead! -..see:Function.gapValueImpl -*/ - -template -inline T const & -gapValue() -{ -SEQAN_CHECKPOINT - T * _tag = 0; - return gapValueImpl(_tag); -} - - -////////////////////////////////////////////////////////////////////////////// -// supremumValue, supremumValueImpl -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.supremumValueImpl: -..hidefromindex -..cat:Alphabets -..summary:Implements @Function.supremumValue@. -..signature:supremumValueImpl(value_pointer_tag) -..param.value_pointer_tag:A pointer that is used as a tag to specify the value type. -...remarks:The pointer needs not to point to a valid object, so it is possible to use a null pointer here. -..returns:A value $inf$ that holds: $inf >= i$ for all values $i$. -..remarks.text:This function implements @Function.supremumValue@. -It is recommended to use @Function.supremumValue@ rather than $supremumValueImpl$. -*/ - -/* -template -inline T const & -supremumValueImpl(T *) -{ - static T const _value = -1; - return _value; -} -*/ - -/** -.Function.supremumValue: -..cat:Alphabets -..summary:Supremum for a given type. -..signature:supremumValue() -..param.T:An ordered type. -..returns:A value $inf$ that holds: $inf >= i$ for all values $i$ of type $T$. -..remarks.text:The function is implemented in @Function.supremumValueImpl@. -Do not specialize $supremumValue$, specialize @Function.supremumValueImpl@ instead! -..see:Function.supremumValueImpl -*/ - -template -inline T const & -supremumValue() -{ -SEQAN_CHECKPOINT - T * _tag = 0; - return supremumValueImpl(_tag); -} - -////////////////////////////////////////////////////////////////////////////// -// infimumValue, infimumValueImpl -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.infimumValueImpl: -..hidefromindex -..cat:Alphabets -..summary:Implements @Function.infimumValue@. -..signature:infimumValueImpl(value_pointer_tag) -..param.value_pointer_tag:A pointer that is used as a tag to specify the value type. -...remarks:The pointer needs not to point to a valid object, so it is possible to use a null pointer here. -..returns:A value $inf$ that holds: $inf <= i$ for all values $i$. -..remarks.text:This function implements @Function.infimumValue@. -It is recommended to use @Function.infimumValue@ rather than $infimumValueImpl$. -*/ - -/* -template -inline T const & -infimumValueImpl(T *) -{ - static T const _value = -1; - return _value; -} -*/ - -/** -.Function.infimumValue: -..cat:Alphabets -..summary:Infimum for a given type. -..signature:infimumValue() -..param.T:An ordered type. -..returns:A value $inf$ that holds: $inf <= i$ for all values $i$ of type $T$. -..remarks.text:The function is implemented in @Function.infimumValueImpl@. -Do not specialize $infimumValue$, specialize @Function.infimumValueImpl@ instead! -..see:Function.infimumValueImpl -..see:Function.supremumValue -*/ - -template -inline T const & -infimumValue() -{ -SEQAN_CHECKPOINT - T * _tag = 0; - return infimumValueImpl(_tag); -} - -////////////////////////////////////////////////////////////////////////////// -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_alphabet_simple.h b/SeqAn-1.1/seqan/basic/basic_alphabet_simple.h deleted file mode 100644 index 9703666d..00000000 --- a/SeqAn-1.1/seqan/basic/basic_alphabet_simple.h +++ /dev/null @@ -1,1296 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_alphabet_simple.h,v 1.1 2008/08/25 16:20:02 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALPHABET_SIMPLE_H -#define SEQAN_HEADER_BASIC_ALPHABET_SIMPLE_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// -//Class that is used for various simple value types -////////////////////////////////////////////////////////////////////////////// - -/** -.Class.SimpleType: -..cat:Basic -..summary:Implementation for "simple" types. -..signature:SimpleType -..param.TValue:Type that stores the values of an instance. -...remarks:TValue must be a simple type. -...metafunction:Metafunction.Value -..param.TSpec:Specialization tag. -...metafunction:Metafunction.Spec -..remarks: -...text:A "simple type" is a C++ type that can be constructed without constructor, -destructed without destructor and copied without copy constructor or assignment operator. -All basic types (like $char$, $int$ or $float$) are simple. Pointers, references and arrays of -simple types are simple. -POD types ("plain old data types"), that are - simplified spoken - C++-types that already existed in C, -are simple too. -...text:Arrays of simple types can be copied very fast by memory manipulation routines, -but the default implementation of functions like @Function.arrayCopyForward@ and @Function.arrayCopy@ -are not optimized for simple types this way. -But for classes derived from $SimpleType$, optimized variants of array manipulation functions are applied. -...text:Note that simple types need not to be derived or specialized from $SimpleType$, but -it could be convenient to do so. -..implements:Concept.Simple Type -*/ -template -struct SimpleType -{ -//____________________________________________________________________________ - - TValue value; - -//____________________________________________________________________________ - - SimpleType() - { -SEQAN_CHECKPOINT - } - -//____________________________________________________________________________ - - SimpleType(SimpleType const & other) - { -SEQAN_CHECKPOINT - assign(*this, other); - } - - template - SimpleType(T const & other) - { -SEQAN_CHECKPOINT - assign(*this, other); - } - - -//____________________________________________________________________________ - - SimpleType & operator=(SimpleType const & other) - { -SEQAN_CHECKPOINT - assign(*this, other); - return *this; - } - template - SimpleType & operator=(T const & other) - { -SEQAN_CHECKPOINT - assign(*this, other); - return *this; - } -//____________________________________________________________________________ - - ~SimpleType() - { -SEQAN_CHECKPOINT - } -//____________________________________________________________________________ - - //this cannot be a template since a template would be in conflict to - //the template c'tor - - - operator long() const - { -SEQAN_CHECKPOINT - long c; - assign(c, *this); - return c; - } - operator unsigned long() const - { -SEQAN_CHECKPOINT - unsigned long c; - assign(c, *this); - return c; - } - operator int() const - { -SEQAN_CHECKPOINT - int c; - assign(c, *this); - return c; - } - operator unsigned int() const - { -SEQAN_CHECKPOINT - unsigned int c; - assign(c, *this); - return c; - } - operator short() const - { -SEQAN_CHECKPOINT - short c; - assign(c, *this); - return c; - } - operator unsigned short() const - { -SEQAN_CHECKPOINT - unsigned short c; - assign(c, *this); - return c; - } - operator char() const - { -SEQAN_CHECKPOINT - char c; - assign(c, *this); - return c; - } - operator signed char() const - { -SEQAN_CHECKPOINT - signed char c; - assign(c, *this); - return c; - } - operator unsigned char() const - { -SEQAN_CHECKPOINT - unsigned char c; - assign(c, *this); - return c; - } - -//____________________________________________________________________________ -}; - -////////////////////////////////////////////////////////////////////////////// -// METAFUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.IsSimple.param.T.type:Class.SimpleType - -template -struct IsSimple > -{ - typedef True Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Value.param.T.type:Class.SimpleType -template -struct Value > -{ - typedef TValue Type; -}; - -template -struct Value const > -{ - typedef TValue const Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Spec.param.T.type:Class.SimpleType -template -struct Spec > -{ - typedef TSpec Type; -}; - -template -struct Spec const > -{ - typedef TSpec Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -template -struct Iterator, Standard> -{ - typedef SimpleType * Type; -// typedef Iter, SimpleIterator> * Type; -}; - -template -struct Iterator const, Standard> -{ - typedef SimpleType const * Type; -// typedef Iter const, SimpleIterator> * Type; -}; - - -////////////////////////////////////////////////////////////////////////////// -// FUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -template -inline typename _RemoveConst::Type -convertImpl(Convert const, - SimpleType const & source_) -{ -SEQAN_CHECKPOINT - typename _RemoveConst::Type target_; - assign(target_, source_); - return target_; -} - - - -////////////////////////////////////////////////////////////////////////////// - -template -inline TStream & -operator << (TStream & stream, - SimpleType const & data) -{ -SEQAN_CHECKPOINT - stream << convert(data); - return stream; -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline TStream & -operator >> (TStream & stream, - SimpleType & data) -{ -SEQAN_CHECKPOINT - char c; - stream >> c; - assign(data, c); - return stream; -} - -////////////////////////////////////////////////////////////////////////////// -// assign -////////////////////////////////////////////////////////////////////////////// - -///.Function.assign.param.target.type:Class.SimpleType -///.Function.assign.param.source.type:Class.SimpleType - - -template -inline void -assign(SimpleType & target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - target.value = source.value; -} -template -inline void -assign(SimpleType & target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - target.value = source.value; -} - -//____________________________________________________________________________ - -template -inline void -assign(SimpleType & target, - TSource & source) -{ -SEQAN_CHECKPOINT - target.value = source; -} -template -inline void -assign(SimpleType & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - target.value = source; -} - -//____________________________________________________________________________ -// Assign Proxy to SimpleType -//??? Diese Funktionen wurden noetig wegen eines seltsamen VC++-Verhaltens - -template -inline void -assign(SimpleType & target, - Proxy & source) -{ -SEQAN_CHECKPOINT - target.value = getValue(source); -} - -template -inline void -assign(SimpleType & target, - Proxy const & source) -{ -SEQAN_CHECKPOINT - target.value = getValue(source); -} - -//____________________________________________________________________________ -//INTEGRAL TYPES -//note: it is not possible to write a single function here since "assign" -//must be specialized for the first argument at the first place - -//int -template -inline void -assign(int & c_target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} -template -inline void -assign(int & c_target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} - -//unsigned int -template -inline void -assign(unsigned int & c_target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} -template -inline void -assign(unsigned int & c_target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} - -//short -template -inline void -assign(short & c_target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} -template -inline void -assign(short & c_target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} - -//unsigned short -template -inline void -assign(unsigned short & c_target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} -template -inline void -assign(unsigned short & c_target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} - -//char -template -inline void -assign(char & c_target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} -template -inline void -assign(char & c_target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} - -//signed char -template -inline void -assign(signed char & c_target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} -template -inline void -assign(signed char & c_target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} - -//unsigned char -template -inline void -assign(unsigned char & c_target, - SimpleType & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} -template -inline void -assign(unsigned char & c_target, - SimpleType const & source) -{ -SEQAN_CHECKPOINT - c_target = source.value; -} - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -// CompareType -////////////////////////////////////////////////////////////////////////////// - -/**.Metafunction.CompareType: -..summary:Type to convert other types for comparisons. -..signature:CompareType::Type -..param.TLeft:Type of the left operand of a comparison. -..param.TRight:Type of the right operand of a comparison. -..return.Type:The Type in which the arguments are converted in order to compare them. -..remarks:Comparisons are for example operators like $==$ or $<$. -..remarks.text:Note that there is no rule that guarantees that $CompareType::Type$ -is the same as $CompareType::Type$. It is also possible, that only one of these -two types is defined. -..remarks.text:This metafunction is used for the implementation of -comparisons that involve @Class.SimpleType@. -*/ -//???TODO: muss geprueft werden, ob diese Metafunktion noch ausgeweitet oder aber versteckt wird. - -template -struct CompareType; - -template -struct CompareType -{ - typedef T Type; -}; - -//____________________________________________________________________________ - -template -struct CompareType, TRight> -{ - typedef TRight Type; -}; - -////////////////////////////////////////////////////////////////////////////// -// operator == - -template -inline bool -operator == (SimpleType const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} - -template -inline bool -operator == (TLeft const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} - -template -inline bool -operator == (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} - -template -inline bool -operator == (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - return convert(left_) == convert(right_); -} - - -template -inline bool -operator == (Proxy const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} -template -inline bool -operator == (SimpleType const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} - - -//____________________________________________________________________________ -// operator != - -template -inline bool -operator != (SimpleType const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} - -template -inline bool -operator != (TLeft const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} - -template -inline bool -operator != (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} - -template -inline bool -operator != (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - return convert(left_) != convert(right_); -} - - -template -inline bool -operator != (Proxy const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} -template -inline bool -operator != (SimpleType const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} - - -//____________________________________________________________________________ -// operator < - -template -inline bool -operator < (SimpleType const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} - -template -inline bool -operator < (TLeft const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} - -template -inline bool -operator < (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} - -template -inline bool -operator < (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - return convert(left_) < convert(right_); -} - - -template -inline bool -operator < (Proxy const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} -template -inline bool -operator < (SimpleType const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} - - -//____________________________________________________________________________ -// operator <= - -template -inline bool -operator <= (SimpleType const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} - -template -inline bool -operator <= (TLeft const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} - -template -inline bool -operator <= (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} - -template -inline bool -operator <= (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - return convert(left_) <= convert(right_); -} - - -template -inline bool -operator <= (Proxy const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} -template -inline bool -operator <= (SimpleType const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} - - - -//____________________________________________________________________________ -// operator > - -template -inline bool -operator > (SimpleType const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} - -template -inline bool -operator > (TLeft const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} - -template -inline bool -operator > (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} - -template -inline bool -operator > (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - return convert(left_) > convert(right_); -} - - -template -inline bool -operator > (Proxy const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} -template -inline bool -operator > (SimpleType const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} - - -//____________________________________________________________________________ -// operator >= - -template -inline bool -operator >= (SimpleType const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} - -template -inline bool -operator >= (TLeft const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} - -template -inline bool -operator >= (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} - -template -inline bool -operator >= (SimpleType const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - return convert(left_) >= convert(right_); -} - - -template -inline bool -operator >= (Proxy const & left_, - SimpleType const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef SimpleType TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} -template -inline bool -operator >= (SimpleType const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef SimpleType TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} - - -////////////////////////////////////////////////////////////////////////////// - -template -inline -bool lexLess(SimpleType<_T, TSpec> const &_Left, SimpleType<_T, TSpec> const &_Right) -{ // return lexicographical _Left < _Right - typedef typename _MakeUnsigned<_T>::Type TUnsigned; - return (TUnsigned)(_Left.value) < (TUnsigned)(_Right.value); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline SimpleType & -operator ++ (SimpleType & me) -{ - ++me.value; - return me; -} -template -inline SimpleType -operator ++ (SimpleType & me, - int) -{ - SimpleType dummy = me; - ++me.value; - return dummy; -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline SimpleType & -operator -- (SimpleType & me) -{ - --me.value; - return me; -} -template -inline SimpleType -operator -- (SimpleType & me, - int) -{ - SimpleType dummy = me; - --me.value; - return dummy; -} - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// - -/** -.Spec.Dna: -..cat:Alphabets -..summary:Alphabet for DNA. -..general:Class.SimpleType -..signature:Dna -..remarks: -...text:The @Metafunction.ValueSize@ of $Dna$ is 4. -The nucleotides are enumerated this way: $'A' = 0, 'C' = 1, 'G' = 2, 'T' = 3$. -...text:Objects of type $Dna$ can be converted to various other types and vice versa. -An object that has a value not in ${'A', 'C', 'G', 'T'}$ is converted to $'A'$. -...text:$Dna$ is typedef for $SimpleType$, while $_Dna$ is a helper -specialization tag class. -..see:Metafunction.ValueSize -..see:Spec.Dna5 -*/ -struct _Dna {}; -typedef SimpleType Dna; - -template <> struct ValueSize< Dna > { enum { VALUE = 4 }; }; -template <> struct BitsPerValue< Dna > { enum { VALUE = 2 }; }; - -//____________________________________________________________________________ - -/** -.Spec.Dna5: -..cat:Alphabets -..summary:Alphabet for DNA including 'N' character. -..general:Class.SimpleType -..signature:Dna5 -..remarks: -...text:The @Metafunction.ValueSize@ of $Dna5$ is 5. -The nucleotides are enumerated this way: $'A' = 0, 'C' = 1, 'G' = 2, 'T' = 3$. -The 'N' character ("unkown nucleotide") is encoded by 4. -...text:Objects of type $Dna5$ can be converted to various other types and vice versa. -An object that has a value not in ${'A', 'C', 'G', 'T'}$ is converted to $'N'$. -...text:$Dna5$ is typedef for $SimpleType$, while $_Dna5$ is a helper -specialization tag class. -..see:Metafunction.ValueSize -*/ -struct _Dna5 {}; -typedef SimpleType Dna5; - -template <> struct ValueSize< Dna5 > { enum { VALUE = 5 }; }; -template <> struct BitsPerValue< Dna5 > { enum { VALUE = 3 }; }; - -//____________________________________________________________________________ - -/** -.Spec.Iupac: -..cat:Alphabets -..summary:Iupac code for DNA. -..general:Class.SimpleType -..signature:Iupac -..remarks: -...text:The @Metafunction.ValueSize@ of $Iupac$ is 16. -The nucleotides are enumerated from 0 to 15 in this order: -'U'=0, 'T', 'A', 'W', 'C', 'Y', 'M', 'H', 'G', 'K', 'R', 'D', 'S', 'B', 'V', 'N'=15. -...text:Objects of type $Iupac$ can be converted to various other types and vice versa. -Unkown values are converted to $'N'$. -...text:$Iupac$ is typedef for $SimpleType$, while $_Iupac$ is a helper -specialization tag class. -..see:Metafunction.ValueSize -*/ -struct _Iupac {}; -typedef SimpleType Iupac; - -template <> struct ValueSize< Iupac > { enum { VALUE = 16 }; }; -template <> struct BitsPerValue< Iupac > { enum { VALUE = 4 }; }; - - -//____________________________________________________________________________ - -/** -.Spec.AminoAcid: -..cat:Alphabets -..summary:Iupac code for amino acids. -..general:Class.SimpleType -..signature:AminoAcid -..remarks: -...text:The @Metafunction.ValueSize@ of $AminoAcid$ is 24. -...text:The amino acids are enumerated from 0 to 15 in this order: -...text:'A'=0, 'R', 'N', 'D', 'C', 'Q', 'E', 'G', 'H', 'I', 'L', 'K', 'M', 'F', 'P', 'S', 'T', 'W', 'Y', 'V'=19. -...text:The remaining 4 symbols are: -...text: 'B'=20 (Aspartic Acid, Asparagine), 'Z'=21 (Glutamic Acid, Glutamine), 'X'=22 (unknown), '*'=23 (terminator) -...text:Objects of type $AminoAcid$ can be converted to $char$ and vice versa. -Unkown values are converted to $'X'$. -...text:$AminoAcid$ is typedef for $SimpleType$, while $_AminoAcid$ is a helper -specialization tag class. -..see:Metafunction.ValueSize -*/ -struct _AminoAcid {}; -typedef SimpleType AminoAcid; - -template <> struct ValueSize< AminoAcid > { enum { VALUE = 24 }; }; -template <> struct BitsPerValue< AminoAcid > { enum { VALUE = 5 }; }; - -////////////////////////////////////////////////////////////////////////////// -//ASCII - -inline void assign(Ascii & c_target, - Dna const & source) -{ -SEQAN_CHECKPOINT - c_target = _Translate_Table_Dna5_2_Ascii<>::VALUE[source.value]; -} -//____________________________________________________________________________ - -inline void assign(Ascii & c_target, - Dna5 const & source) -{ -SEQAN_CHECKPOINT - c_target = _Translate_Table_Dna5_2_Ascii<>::VALUE[source.value]; -} -//____________________________________________________________________________ - -inline void assign(Ascii & c_target, Iupac const & source) -{ -SEQAN_CHECKPOINT - c_target = _Translate_Table_Iupac_2_Ascii<>::VALUE[source.value]; -} -//____________________________________________________________________________ - -inline void assign(Ascii & c_target, AminoAcid const & source) -{ -SEQAN_CHECKPOINT - c_target = _Translate_Table_AA_2_Ascii<>::VALUE[source.value]; -} - -////////////////////////////////////////////////////////////////////////////// -//DNA (4 letters) - -template <> -struct CompareType { typedef Dna Type; }; -inline void assign(Dna & target, Byte c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Byte_2_Dna<>::VALUE[c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna Type; }; -inline void assign(Dna & target, Ascii c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_Dna<>::VALUE[(unsigned char)c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna Type; }; -inline void assign(Dna & target, Unicode c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_Dna<>::VALUE[(unsigned char) c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna Type; }; -inline void assign(Dna & target, Dna5 const & c_source) -{ -SEQAN_CHECKPOINT - target.value = c_source.value & 0x03; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna Type; }; -inline void assign(Dna & target, Iupac const & source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Iupac_2_Dna<>::VALUE[source.value]; -} - -////////////////////////////////////////////////////////////////////////////// -//DNA (5 letters) - -template <> -struct CompareType { typedef Dna5 Type; }; -inline void assign(Dna5 & target, Byte c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Byte_2_Dna5<>::VALUE[c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna5 Type; }; -inline void assign(Dna5 & target, Ascii c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_Dna5<>::VALUE[(unsigned char) c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna5 Type; }; -inline void assign(Dna5 & target, Unicode c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_Dna5<>::VALUE[(unsigned char) c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna5 Type; }; -inline void assign(Dna5 & target, Iupac const & source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Iupac_2_Dna5<>::VALUE[source.value]; -} - -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Dna Type; }; -inline void assign(Dna5 & target, Dna const & c_source) -{ -SEQAN_CHECKPOINT - target.value = c_source.value; -} - -////////////////////////////////////////////////////////////////////////////// -//IUPAC (4 bits) - -template <> -struct CompareType { typedef Iupac Type; }; -inline void assign(Iupac & target, Byte c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Byte_2_Iupac<>::VALUE[c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Iupac Type; }; -inline void assign(Iupac & target, Ascii c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_Iupac<>::VALUE[(unsigned char) c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef Iupac Type; }; -inline void assign(Iupac & target, Unicode c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_Iupac<>::VALUE[(unsigned char) c_source]; -} -//____________________________________________________________________________ - -inline void assign(Iupac & target, Dna const & source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Dna5_2_Iupac<>::VALUE[source.value]; -} -//____________________________________________________________________________ - -inline void assign(Iupac & target, Dna5 const & source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Dna5_2_Iupac<>::VALUE[source.value]; -} - -////////////////////////////////////////////////////////////////////////////// -//Amino Acid (5 bits) - -template <> -struct CompareType { typedef AminoAcid Type; }; -inline void assign(AminoAcid & target, Byte c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Byte_2_AA<>::VALUE[c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef AminoAcid Type; }; -inline void assign(AminoAcid & target, Ascii c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_AA<>::VALUE[(unsigned char) c_source]; -} -//____________________________________________________________________________ - -template <> -struct CompareType { typedef AminoAcid Type; }; -inline void assign(AminoAcid & target, Unicode c_source) -{ -SEQAN_CHECKPOINT - target.value = _Translate_Table_Ascii_2_AA<>::VALUE[(unsigned char) c_source]; -} - -////////////////////////////////////////////////////////////////////////////// - - -////////////////////////////////////////////////////////////////////////////// -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_alphabet_simple_tabs.h b/SeqAn-1.1/seqan/basic/basic_alphabet_simple_tabs.h deleted file mode 100644 index 6a82ad9a..00000000 --- a/SeqAn-1.1/seqan/basic/basic_alphabet_simple_tabs.h +++ /dev/null @@ -1,439 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_alphabet_simple_tabs.h,v 1.1 2008/08/25 16:20:02 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALPHABET_SIMPLE_TABS_H -#define SEQAN_HEADER_BASIC_ALPHABET_SIMPLE_TABS_H - - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// - -//use same tables for Dna - -template -struct _Translate_Table_Dna5_2_Ascii -{ - static char const VALUE[5]; -}; -template -char const _Translate_Table_Dna5_2_Ascii::VALUE[5] = {'A', 'C', 'G', 'T', 'N'}; - -//____________________________________________________________________________ - -template -struct _Translate_Table_Dna5_2_Iupac -{ - static char const VALUE[5]; -}; -template -char const _Translate_Table_Dna5_2_Iupac::VALUE[5] = {0x02, 0x04, 0x08, 0x01, 0x0f}; - -//____________________________________________________________________________ - -template -struct _Translate_Table_Iupac_2_Ascii -{ - static char const VALUE[16]; -}; -template -char const _Translate_Table_Iupac_2_Ascii::VALUE[16] = -{ - 'U', //0000=0 - 'T', //0001=1 //T=1: change between U and T is just inc/dec - 'A', //0010=2 - 'W', //0011=3 TA - 'C', //0100=4 - 'Y', //0101=5 TC (pyrimidine) - 'M', //0110=6 AC - 'H', //0111=7 not-G - 'G', //1000=8 - 'K', //1001=9 TG - 'R', //1010=A AG (purine) - 'D', //1011=B not-C - 'S', //1100=C CG - 'B', //1101=D non-A - 'V', //1110=E non-T - 'N' //1111=F any -}; - -//____________________________________________________________________________ - -template -struct _Translate_Table_Iupac_2_Dna -{ - static char const VALUE[16]; -}; -template -char const _Translate_Table_Iupac_2_Dna::VALUE[16] = -{ - 3, //'U' - 3, //'T' - 0, //'A' - 0, //'W' = TA - 1, //'C' - 1, //'Y' = TC - 0, //'M' = AC - 0, //'H' = not-G - 2, //'G' - 2, //'K' = TG - 0, //'R' = AG - 0, //'D' = not-C - 1, //'S' = CG - 1, //'B' = non-A - 0, //'V' = non-T - 0 //'N' = any -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_Iupac_2_Dna5 -{ - static char const VALUE[16]; -}; -template -char const _Translate_Table_Iupac_2_Dna5::VALUE[16] = -{ - 3, //'U' - 3, //'T' - 0, //'A' - 4, //'W' = TA - 1, //'C' - 4, //'Y' = TC - 4, //'M' = AC - 4, //'H' = not-G - 2, //'G' - 4, //'K' = TG - 4, //'R' = AG - 4, //'D' = not-C - 4, //'S' = CG - 4, //'B' = non-A - 4, //'V' = non-T - 4 //'N' = any -}; - -//____________________________________________________________________________ - -template -struct _Translate_Table_Ascii_2_Dna -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Ascii_2_Dna::VALUE[256] = -{ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //0 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //1 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //2 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //3 - - 0, 0, 0, 1, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, //4 -// , A, B, C, D, E, D, G, H, I, J, K, L, M, N, O, - - 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //5 -// P, Q, R, S, T, U, V, W, X, Y, Z, , , , , - - 0, 0, 0, 1, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, //6 -// , a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, - - 0, 0, 0, 0, 3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //7 -// p, q, r, s, t, u, v, w, x, y, z, , , , , - - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //8 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //9 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //10 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //11 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //12 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //13 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //14 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 //15 -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_Ascii_2_Dna5 -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Ascii_2_Dna5::VALUE[256] = -{ - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //0 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //1 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //2 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //3 - - 4, 0, 4, 1, 4, 4, 4, 2, 4, 4, 4, 4, 4, 4, 4, 4, //4 -// , A, B, C, D, E, D, G, H, I, J, K, L, M, N, O, - - 4, 4, 4, 4, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //5 -// P, Q, R, S, T, U, V, W, X, Y, Z, , , , , - - 4, 0, 4, 1, 4, 4, 4, 2, 4, 4, 4, 4, 4, 4, 4, 4, //6 -// , a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, - - 4, 4, 4, 4, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //7 -// p, q, r, s, t, u, v, w, x, y, z, , , , , - - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //8 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //9 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //10 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //11 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //12 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //13 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //14 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4 //15 -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_Ascii_2_Iupac -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Ascii_2_Iupac::VALUE[256] = -{ - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //0 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //1 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //2 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //3 - - 15, 2, 13, 4, 11, 15, 15, 8, 7, 15, 15, 9, 15, 6, 15, 15, //4 - // , A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, - - 15, 15, 10, 12, 1, 0, 14, 3, 15, 5, 15, 15, 15, 15, 15, 15, //5 - // P, Q, R, S, T, U, V, W, X, Y, Z, , , , , - - 15, 2, 13, 4, 11, 15, 15, 8, 7, 15, 15, 9, 15, 6, 15, 15, //6 - // , a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, - - 15, 15, 10, 12, 1, 0, 14, 3, 15, 5, 15, 15, 15, 15, 15, 15, //7 - // p, q, r, s, t, u, v, w, x, y, z, , , , , - - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //8 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //9 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //10 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //11 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //12 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //13 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //14 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15 //15 -}; - -//____________________________________________________________________________ - -template -struct _Translate_Table_Byte_2_Dna -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Byte_2_Dna::VALUE[256] = -{ - 0, 1, 2, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //0 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //1 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //2 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //3 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //4 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //5 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //6 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //7 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //8 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //9 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //10 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //11 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //12 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //13 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //14 - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 //15 -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_Byte_2_Dna5 -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Byte_2_Dna5::VALUE[256] = { - 0, 1, 2, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //0 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //1 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //2 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //3 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //4 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //5 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //6 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //7 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //8 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //9 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //10 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //11 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //12 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //13 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, //14 - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4 //15 -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_Byte_2_Iupac -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Byte_2_Iupac::VALUE[256] = -{ - 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, //0 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //1 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //2 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //3 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //4 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //5 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //6 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //7 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //8 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //9 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //10 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //11 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //12 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //13 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, //14 - 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15 //15 -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_AA_2_Ascii -{ - static char const VALUE[24]; -}; -template -char const _Translate_Table_AA_2_Ascii::VALUE[24] = -{ - 'A', // 0 Ala Alanine - 'R', // 1 Arg Arginine - 'N', // 2 Asn Asparagine - 'D', // 3 Asp Aspartic Acid - 'C', // 4 Cys Cystine - 'Q', // 5 Gln Glutamine - 'E', // 6 Glu Glutamic Acid - 'G', // 7 Gly Glycine - 'H', // 8 His Histidine - 'I', // 9 Ile Isoleucine - 'L', //10 Leu Leucine - 'K', //11 Lys Lysine - 'M', //12 Met Methionine - 'F', //13 Phe Phenylalanine - 'P', //14 Pro Proline - 'S', //15 Ser Serine - 'T', //16 Thr Threonine - 'W', //17 Trp Tryptophan - 'Y', //18 Tyr Tyrosine - 'V', //19 Val Valine - 'B', //20 Aspartic Acid, Asparagine - 'Z', //21 Glutamic Acid, Glutamine - 'X', //22 Unknown - '*' //23 Terminator -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_Ascii_2_AA -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Ascii_2_AA::VALUE[256] = -{ - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //0 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //1 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 23, 22, 22, 22, 22, 22, //2 -// * - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //3 - 22, 0, 20, 4, 3, 6, 13, 7, 8, 9, 22, 11, 10, 12, 2, 22, //4 -// , A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, - - 14, 5, 1, 15, 16, 22, 19, 17, 22, 18, 21, 22, 22, 22, 22, 22, //5 -// P, Q, R, S, T, U, V, W, X, Y, Z, , , , , , - - 22, 0, 20, 4, 3, 6, 13, 7, 8, 9, 22, 11, 10, 12, 2, 22, //6 -// , a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, - - 14, 5, 1, 15, 16, 22, 19, 17, 22, 18, 21, 22, 22, 22, 22, 22, //7 -// p, q, r, s, t, u, v, w, x, y, z, , , , , , - - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //8 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //9 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //10 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //11 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //12 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //13 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //14 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22 //15 -}; - -//____________________________________________________________________________ - - -template -struct _Translate_Table_Byte_2_AA -{ - static char const VALUE[256]; -}; -template -char const _Translate_Table_Byte_2_AA::VALUE[256] = -{ - 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, //0 - 16, 17, 18, 19, 20, 21, 22, 23, 22, 22, 22, 22, 22, 22, 22, 22, //1 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //2 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //3 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //4 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //5 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //6 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //7 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //8 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //9 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //10 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //11 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //12 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //13 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, //14 - 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22 //15 -}; - -////////////////////////////////////////////////////////////////////////////// - -}//namespace SEQAN_NAMESPACE_MAIN -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_alphabet_trait_basic.h b/SeqAn-1.1/seqan/basic/basic_alphabet_trait_basic.h deleted file mode 100644 index 024bf55d..00000000 --- a/SeqAn-1.1/seqan/basic/basic_alphabet_trait_basic.h +++ /dev/null @@ -1,733 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_alphabet_trait_basic.h,v 1.2 2009/02/19 01:51:23 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ALPHABET_TRAIT_BASIC_H -#define SEQAN_HEADER_BASIC_ALPHABET_TRAIT_BASIC_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// -//arrayConstruct -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayConstruct_Pointer(TIterator, - TIterator, - True) -{ -SEQAN_CHECKPOINT - //nothing to do -} -template -inline void -_arrayConstruct_Pointer(TIterator begin_, - TIterator end_, - False) -{ -SEQAN_CHECKPOINT - _arrayConstruct_Default(begin_, end_); -} -template -inline void -arrayConstruct(TValue * begin_, - TValue * end_) -{ -SEQAN_CHECKPOINT - _arrayConstruct_Pointer(begin_, end_, typename IsSimple::Type() ); -} - -//____________________________________________________________________________ - -template -inline void -_arrayConstruct_Pointer(TIterator begin_, - TIterator end_, - TParam const & param_, - True) -{ -SEQAN_CHECKPOINT - arrayFill(begin_, end_, param_); -} -template -inline void -_arrayConstruct_Pointer(TIterator begin_, - TIterator end_, - TParam const & param_, - False) -{ -SEQAN_CHECKPOINT - _arrayConstruct_Default(begin_, end_, param_); -} -template -inline void -arrayConstruct(TValue * begin_, - TValue * end_, - TParam const & param_) -{ -SEQAN_CHECKPOINT - _arrayConstruct_Pointer(begin_, end_, param_, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayConstructCopy -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayConstructCopy_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - True) -{ -SEQAN_CHECKPOINT - arrayCopyForward(source_begin, source_end, target_begin); -} -template -inline void -_arrayConstructCopy_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - False) -{ -SEQAN_CHECKPOINT - _arrayConstructCopy_Default(source_begin, source_end, target_begin); -} -template -inline void -arrayConstructCopy(TValue * source_begin, - TValue * source_end, - TValue * target_begin) -{ -SEQAN_CHECKPOINT - _arrayConstructCopy_Pointer(source_begin, source_end, target_begin, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayConstructMove -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayConstructMove_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - True) -{ -SEQAN_CHECKPOINT - arrayMoveForward(source_begin, source_end, target_begin); -} -template -inline void -_arrayConstructMove_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - False) -{ -SEQAN_CHECKPOINT - _arrayConstructMove_Default(source_begin, source_end, target_begin); -} -template -inline void -arrayConstructMove(TValue * source_begin, - TValue * source_end, - TValue * target_begin) -{ -SEQAN_CHECKPOINT - _arrayConstructMove_Pointer(source_begin, source_end, target_begin, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayDestruct -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayDestruct_Pointer(TValue * /*begin_*/, - TValue * /*end_*/, - True) -{ -SEQAN_CHECKPOINT - //do nothing -} -template -inline void -_arrayDestruct_Pointer(TValue * begin_, - TValue * end_, - False) -{ -SEQAN_CHECKPOINT - _arrayDestruct_Default(begin_, end_); -} -template -inline void -arrayDestruct(TValue * begin_, - TValue * end_) -{ -SEQAN_CHECKPOINT - _arrayDestruct_Pointer(begin_, end_, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayFill -////////////////////////////////////////////////////////////////////////////// - -//no specializiation for pointer to simple - -////////////////////////////////////////////////////////////////////////////// -//arrayCopyForward -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayCopyForward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - True) -{ -SEQAN_CHECKPOINT - memmove(target_begin, source_begin, (source_end - source_begin) * sizeof(TValue)); -} -template -inline void -_arrayCopyForward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - False) -{ -SEQAN_CHECKPOINT - _arrayCopyForward_Default(source_begin, source_end, target_begin); -} -template -inline void -arrayCopyForward(TValue * source_begin, - TValue * source_end, - TValue * target_begin) -{ -SEQAN_CHECKPOINT - _arrayCopyForward_Pointer(source_begin, source_end, target_begin, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayCopyBackward -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayCopyBackward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - True) -{ -SEQAN_CHECKPOINT - memmove(target_begin, source_begin, (source_end - source_begin) * sizeof(TValue)); -} -template -inline void -_arrayCopyBackward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - False) -{ -SEQAN_CHECKPOINT - _arrayCopyBackward_Default(source_begin, source_end, target_begin); -} -template -inline void -arrayCopyBackward(TValue * source_begin, - TValue * source_end, - TValue * target_begin) -{ -SEQAN_CHECKPOINT - _arrayCopyBackward_Pointer(source_begin, source_end, target_begin, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayMoveForward -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayMoveForward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - True) -{ -SEQAN_CHECKPOINT - memmove(target_begin, source_begin, (source_end - source_begin) * sizeof(TValue)); -} -template -inline void -_arrayMoveForward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - False) -{ -SEQAN_CHECKPOINT - _arrayMoveForward_Default(source_begin, source_end, target_begin); -} -template -inline void -arrayMoveForward(TValue * source_begin, - TValue * source_end, - TValue * target_begin) -{ -SEQAN_CHECKPOINT - _arrayMoveForward_Pointer(source_begin, source_end, target_begin, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayMoveBackward -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayMoveBackward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - True) -{ -SEQAN_CHECKPOINT - memmove(target_begin, source_begin, (source_end - source_begin) * sizeof(TValue)); -} -template -inline void -_arrayMoveBackward_Pointer(TValue * source_begin, - TValue * source_end, - TValue * target_begin, - False) -{ -SEQAN_CHECKPOINT - _arrayMoveBackward_Default(source_begin, source_end, target_begin); -} -template -inline void -arrayMoveBackward(TValue * source_begin, - TValue * source_end, - TValue * target_begin) -{ -SEQAN_CHECKPOINT - _arrayMoveBackward_Pointer(source_begin, source_end, target_begin, typename IsSimple::Type() ); -} - -////////////////////////////////////////////////////////////////////////////// -//arrayClearSpace -////////////////////////////////////////////////////////////////////////////// - -template -inline void -_arrayClearSpace_Pointer(TValue * array_begin, - size_t array_length, - size_t keep_from, - size_t move_to, - True) -{ - if (keep_from == move_to) return; -SEQAN_CHECKPOINT - arrayMove(array_begin + keep_from, array_begin + array_length, array_begin + move_to); -} -template -inline void -_arrayClearSpace_Pointer(TValue * array_begin, - size_t array_length, - size_t keep_from, - size_t move_to, - False) -{ - _arrayClearSpace_Default(array_begin, array_length, keep_from, move_to); -} -template -void arrayClearSpace(TValue * array_begin, - size_t array_length, - size_t keep_from, - size_t move_to) -{ - _arrayClearSpace_Pointer(array_begin, array_length, keep_from, move_to, typename IsSimple::Type() ); -} - - - -////////////////////////////////////////////////////////////////////////////// -// IsSimple specializations -////////////////////////////////////////////////////////////////////////////// - -// standard types -template <> struct _IsSimple< bool > { typedef True Type; }; -template <> struct _IsSimple< char > { typedef True Type; }; - -template <> struct _IsSimple< unsigned char > { typedef True Type; }; -template <> struct _IsSimple< unsigned short > { typedef True Type; }; -template <> struct _IsSimple< unsigned int > { typedef True Type; }; -template <> struct _IsSimple< unsigned long > { typedef True Type; }; - -template <> struct _IsSimple< signed char > { typedef True Type; }; -template <> struct _IsSimple< signed short > { typedef True Type; }; -template <> struct _IsSimple< signed int > { typedef True Type; }; -template <> struct _IsSimple< signed long > { typedef True Type; }; - -template <> struct _IsSimple< float > { typedef True Type; }; -template <> struct _IsSimple< double > { typedef True Type; }; -template <> struct _IsSimple< long double > { typedef True Type; }; - -// user defined types (re-specializations are allowed here) -template <> struct IsSimple< wchar_t > { typedef True Type; }; -template <> struct IsSimple< __int64 > { typedef True Type; }; - -////////////////////////////////////////////////////////////////////////////// -// gapValue -////////////////////////////////////////////////////////////////////////////// - -inline char const & -gapValueImpl(char *) -{ -SEQAN_CHECKPOINT - static char const _gap = '-'; - return _gap; -} -inline char const & -gapValueImpl(char const *) -{ -SEQAN_CHECKPOINT - static char const _gap = '-'; - return _gap; -} - -////////////////////////////////////////////////////////////////////////////// -// generic extreme values -////////////////////////////////////////////////////////////////////////////// - -template -inline T const & -supremumValueImpl(T *) -{ -SEQAN_CHECKPOINT - return SupremumValue::VALUE; -} -template -inline T const & -infimumValueImpl(T *) -{ -SEQAN_CHECKPOINT - return InfimumValue::VALUE; -} - -////////////////////////////////////////////////////////////////////////////// -// bool -////////////////////////////////////////////////////////////////////////////// - -template <> struct BitsPerValue< bool > { enum { VALUE = 1 }; }; - -/* -////////////////////////////////////////////////////////////////////////////// -// char -////////////////////////////////////////////////////////////////////////////// - -inline char const & -supremumValueImpl(char *) -{ -SEQAN_CHECKPOINT - static char const _value = (char) 127; - return _value; -} -inline char const & -infimumValueImpl(char *) -{ -SEQAN_CHECKPOINT - static char const _value = (char) -128; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// signed char -////////////////////////////////////////////////////////////////////////////// - -inline signed char const & -supremumValueImpl(signed char *) -{ -SEQAN_CHECKPOINT - static signed char const _value = 127; - return _value; -} -inline signed char const & -infimumValueImpl(signed char *) -{ -SEQAN_CHECKPOINT - static signed char const _value = -128; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// unsigned char -////////////////////////////////////////////////////////////////////////////// - -inline unsigned char const & -supremumValueImpl(unsigned char *) -{ -SEQAN_CHECKPOINT - static unsigned char const _value = 255; - return _value; -} -inline unsigned char const & -infimumValueImpl(unsigned char *) -{ -SEQAN_CHECKPOINT - static unsigned char const _value = 0; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// wchar_t -////////////////////////////////////////////////////////////////////////////// - -inline wchar_t const & -supremumValueImpl(wchar_t *) -{ -SEQAN_CHECKPOINT - static wchar_t const _value = 1UL << (BitsPerValue::VALUE) - 1; - return _value; -} -inline wchar_t const & -infimumValueImpl(wchar_t *) -{ -SEQAN_CHECKPOINT - static wchar_t const _value = 0; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// signed short -////////////////////////////////////////////////////////////////////////////// - -inline signed short const & -supremumValueImpl(signed short *) -{ -SEQAN_CHECKPOINT - static signed short const _value = (((1 << (BitsPerValue::VALUE - 2)) - 1) << 1) + 1; - return _value; -} -inline signed short const & -infimumValueImpl(signed short *dummy) -{ -SEQAN_CHECKPOINT - static signed short const _value = -supremumValueImpl(dummy) - 1; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// unsigned short -////////////////////////////////////////////////////////////////////////////// - -inline unsigned short const & -supremumValueImpl(unsigned short *) -{ -SEQAN_CHECKPOINT - static unsigned short const _value = (((1 << (BitsPerValue::VALUE - 1)) - 1) << 1) + 1; - return _value; -} -inline unsigned short const & -infimumValueImpl(unsigned short *) -{ -SEQAN_CHECKPOINT - static unsigned short const _value = 0; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// signed int -////////////////////////////////////////////////////////////////////////////// - -inline signed int const & -supremumValueImpl(signed int *) -{ -SEQAN_CHECKPOINT - static signed int const _value = (((1 << (BitsPerValue::VALUE - 2)) - 1) << 1) + 1; - return _value; -} -inline signed int const & -infimumValueImpl(signed int *dummy) -{ -SEQAN_CHECKPOINT - static signed int const _value = -supremumValueImpl(dummy) - 1; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// unsigned int -////////////////////////////////////////////////////////////////////////////// - -inline unsigned int const & -supremumValueImpl(unsigned int *) -{ -SEQAN_CHECKPOINT - static unsigned int const _value = ~0ul; - return _value; -} -inline unsigned int const & -infimumValueImpl(unsigned int *) -{ -SEQAN_CHECKPOINT - static unsigned int const _value = 0; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// signed long -////////////////////////////////////////////////////////////////////////////// - -inline signed long const & -supremumValueImpl(signed long *) -{ -SEQAN_CHECKPOINT - static signed long const _value = (((1 << (BitsPerValue::VALUE - 2)) - 1) << 1) + 1; - return _value; -} -inline signed long const & -infimumValueImpl(signed long *dummy) -{ -SEQAN_CHECKPOINT - static signed long const _value = -supremumValueImpl(dummy) - 1; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// unsigned long -////////////////////////////////////////////////////////////////////////////// - -inline unsigned long const & -supremumValueImpl(unsigned long *) -{ -SEQAN_CHECKPOINT - static unsigned long const _value = ~0ul; - return _value; -} -inline unsigned long const & -infimumValueImpl(unsigned long *) -{ -SEQAN_CHECKPOINT - static unsigned long const _value = 0; - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// signed 64bit int (cannot use long long <- no ISO C++) -////////////////////////////////////////////////////////////////////////////// - -inline __int64 const & -supremumValueImpl(__int64 *) -{ -SEQAN_CHECKPOINT - static __int64 const _value = ((((__int64)1 << (BitsPerValue<__int64>::VALUE - 2)) - 1) << 1) + 1; - return _value; -} -inline __int64 const & -infimumValueImpl(__int64 *dummy) -{ -SEQAN_CHECKPOINT - static __int64 const _value = -supremumValueImpl(dummy) - 1; - return _value; -} -*/ - -////////////////////////////////////////////////////////////////////////////// -// float -////////////////////////////////////////////////////////////////////////////// - -inline float const & -supremumValueImpl(float *) -{ -SEQAN_CHECKPOINT -#ifdef PLATFORM_WINDOWS - static float const _value = ::std::numeric_limits::infinity( ); -#else - static float const _value = 3.40282347e+38F; -#endif - return _value; -} -inline float const & -infimumValueImpl(float *) -{ -SEQAN_CHECKPOINT -#ifdef PLATFORM_WINDOWS - static float const _value = -::std::numeric_limits::infinity( ); -#else - static float const _value = -3.40282347e+38F; -#endif - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// double -////////////////////////////////////////////////////////////////////////////// - -inline double const & -supremumValueImpl(double *) -{ -SEQAN_CHECKPOINT -#ifdef PLATFORM_WINDOWS - static double const _value = ::std::numeric_limits::infinity( ); -#else - static double const _value = 1.7976931348623157e+308; -#endif - return _value; -} -inline double const & -infimumValueImpl(double *) -{ -SEQAN_CHECKPOINT -#ifdef PLATFORM_WINDOWS - static double const _value = -::std::numeric_limits::infinity( ); -#else - static double const _value = -1.7976931348623157e+308; -#endif - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -// long double -////////////////////////////////////////////////////////////////////////////// - -inline long double const & -supremumValueImpl(long double *) -{ -SEQAN_CHECKPOINT -#ifdef PLATFORM_WINDOWS - static long double const _value = ::std::numeric_limits::infinity( ); -#else - static long double const _value = 1.7976931348623157e+308; -#endif - return _value; -} -inline long double const & -infimumValueImpl(long double *) -{ -SEQAN_CHECKPOINT -#ifdef PLATFORM_WINDOWS - static long double const _value = -::std::numeric_limits::infinity( ); -#else - static long double const _value = -1.7976931348623157e+308; -#endif - return _value; -} - -////////////////////////////////////////////////////////////////////////////// -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_compare.h b/SeqAn-1.1/seqan/basic/basic_compare.h deleted file mode 100644 index 6499da9f..00000000 --- a/SeqAn-1.1/seqan/basic/basic_compare.h +++ /dev/null @@ -1,60 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_compare.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_COMPARE_H -#define SEQAN_HEADER_BASIC_COMPARE_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// - -template -struct CompareType; - -template -struct CompareType -{ - typedef typename CompareType::Type const Type; -}; -template -struct CompareType -{ - typedef typename CompareType::Type const Type; -}; -template -struct CompareType -{ - typedef typename CompareType::Type const Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -template inline -bool lexLess(const _T& _Left, const _T& _Right) -{ // return lexicographical _Left < _Right - typedef typename _MakeUnsigned<_T>::Type TUnsigned; - return (TUnsigned)_Left < (TUnsigned)_Right; -} - -////////////////////////////////////////////////////////////////////////////// -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_converter.h b/SeqAn-1.1/seqan/basic/basic_converter.h deleted file mode 100644 index 966f4675..00000000 --- a/SeqAn-1.1/seqan/basic/basic_converter.h +++ /dev/null @@ -1,117 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_converter.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_CONVERTER_H -#define SEQAN_HEADER_BASIC_CONVERTER_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// -//Convert -////////////////////////////////////////////////////////////////////////////// - -//gibt den Typ an, in den TSource konvertiert werden kann (TTarget oder TTarget &) - -/** -.Metafunction.Convert: -..summary:Return type of a conversion. -..signature:Convert::Type -..param.Target:Type the object should be converted to. -..param.Source:Type of the object that should be converted to $Target$. -..returns.param.Type:Type that is returned by @Function.convert@. -...remarks:This is either $Target$ or $Target &$: -If instances of $Source: /fs/szdevel/src/cvsroot/bowtie/SeqAn-1.1/seqan/basic/basic_converter.h,v $ can be re-interpreted as instances of $Target$, -than this metafunction returns a reference, otherwise it returns $Target$, -that is @Function.convert@ returns a temporary. -..remarks:A constant instance of $Convert$ is (ab)used as tag argument of @Function.convertImpl@. -*/ -template -struct Convert -{ - typedef TTarget Type; - -}; - -////////////////////////////////////////////////////////////////////////////// -//convertImpl -////////////////////////////////////////////////////////////////////////////// -/** -.Function.convertImpl: -..hidefromindex -..cat:Alphabets -..summary:Implements @Function.convert@. -..signature:Convert convertImpl(convert, source) -..param.convert:Object that specifies the conversion. -...type:Metafunction.Convert -...remarks:A constant instance of @Metafunction.Convert@ is used to specify the conversion target. -..param.source:An object that should be converted. -..returns:$source$ converted to the type specified by convert. -...metafunction:Metafunction.Convert -..remarks:This function implements @Function.convert@. -It is recommended to use @Function.convert@ rather than $convertImpl$. -*/ -//??? Spezialisiere convertImpl, verwende convert -//??? Konversion eines einzelnen Zeichens in ein einzelnes Zeichen. Konversion von Sequenzen in Sequenzen finden wo anders statt. -//??? Kann entweder kopieren oder re-interpretieren, je nach Convert::Type -template -inline typename Convert::Type -convertImpl(Convert const, - TSource & source) -{ - return source; -} -template -inline typename Convert::Type -convertImpl(Convert const, - TSource const & source) -{ - return source; -} - -////////////////////////////////////////////////////////////////////////////// -//convert -////////////////////////////////////////////////////////////////////////////// -/** -.Function.convert: -..cat:Alphabets -..summary:Converts a value into another value. -..signature:Convert convert(source) -..param.Target:The type $source$ is converted to. -..param.source:An object that is converted to $Target$. -..returns:$source$ converted to $Target$. -...remarks:If $source$ can be re-interpreted as instance of $Target$, then a reference is returned. -Otherwise the function returns a temporary object. -...metafunction:Metafunction.Convert -..remarks:This function is implemented in @Function.convertImpl@. -Do not specialize $convert$, specialize @Function.convertImpl@ instead. -..see:Function.convertImpl -*/ -template -inline typename Convert::Type -convert(TSource const & source) -{ - return convertImpl(Convert(), source); -} - -////////////////////////////////////////////////////////////////////////////// -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_counted_ptr.h b/SeqAn-1.1/seqan/basic/basic_counted_ptr.h deleted file mode 100644 index 4973a9f1..00000000 --- a/SeqAn-1.1/seqan/basic/basic_counted_ptr.h +++ /dev/null @@ -1,116 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_counted_ptr.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -// THIS FILE IS CURRENTLY NOT USED IN SEQAN - -#ifndef SEQAN_HEADER_BASIC_COUNTED_PTR_H -#define SEQAN_HEADER_BASIC_COUNTED_PTR_H - -namespace SEQAN_NAMESPACE_MAIN -{ - - ////////////////////////////////////////////////////////////////////////////// - // counted pointer - - template < typename Type > - struct CountedPtr - { - typedef CountedPtr _Self; - typedef CountedPtr* _SelfPtr; - typedef CountedPtr& _SelfRef; - - typedef Type& reference; - typedef const Type& const_reference; - typedef Type* pointer; - - explicit CountedPtr(pointer p = 0): // allocate a new counter - itsCounter(0) - { - if (p) itsCounter = new counter(p); - } - - CountedPtr(const _Self& r) throw() { - acquire(r.itsCounter); - } - - ~CountedPtr() { - release(); - } - - CountedPtr& operator=(const _Self& r) - { - if (this != &r) { - release(); - acquire(r.itsCounter); - } - return *this; - } - - reference operator*() const throw() { - return *itsCounter->ptr; - } - - pointer operator->() const throw() { - return itsCounter->ptr; - } - - pointer get() const throw() { - return itsCounter ? itsCounter->ptr : 0; - } - - bool unique() const throw() { - return (itsCounter ? itsCounter->count == 1 : true); - } - - inline operator pointer () const { - return get(); - } - - private: - - struct counter { - pointer ptr; - unsigned count; - counter(pointer p = 0, unsigned c = 1): - ptr(p), - count(c) { } - }* itsCounter; - - void acquire(counter* c) throw() - { // increment the count - itsCounter = c; - if (c) ++c->count; - } - - void release() - { // decrement the count, delete if it is 0 - if (itsCounter) { - if (--itsCounter->count == 0) { - delete itsCounter->ptr; - delete itsCounter; - } - itsCounter = 0; - } - } - }; - -} - -#endif diff --git a/SeqAn-1.1/seqan/basic/basic_debug.h b/SeqAn-1.1/seqan/basic/basic_debug.h deleted file mode 100644 index 424b011e..00000000 --- a/SeqAn-1.1/seqan/basic/basic_debug.h +++ /dev/null @@ -1,385 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_debug.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_DEBUG_H -#define SEQAN_HEADER_BASIC_DEBUG_H - -#ifndef SEQAN_DEBUG_OR_TEST_ -#ifdef SEQAN_DEBUG -#define SEQAN_DEBUG_OR_TEST_ -#else //#ifdef SEQAN_DEBUG -#ifdef SEQAN_TEST -#define SEQAN_DEBUG_OR_TEST_ -#endif //#ifdef SEQAN_TEST -#endif //#ifdef SEQAN_DEBUG -#endif //#ifndef SEQAN_DEBUG_OR_TEST_ - - -#ifdef SEQAN_DEBUG_OR_TEST_ -#include -#endif //#ifdef SEQAN_DEBUG_OR_TEST_ - -#ifdef SEQAN_DEBUG - -//throw a fatal debug report if _cond is false -#define SEQAN_ASSERT(_cond) { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Error< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, #_cond " is FALSE"); } -#define SEQAN_ASSERT1(_cond) SEQAN_ASSERT(_cond) -#define SEQAN_ASSERT2(_cond, _comment) { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Error< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, _comment); } - -//throw a debug report if _cond is false -#define SEQAN_CHECK(_cond) { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Message< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, #_cond " is FALSE"); } -#define SEQAN_CHECK1(_cond) SEQAN_CHECK(_cond) -#define SEQAN_CHECK2(_cond, _comment) { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Message< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, _comment); } - -#define SEQAN_DO(_cond) { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Message< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, #_cond " is FALSE"); } -#define SEQAN_DO1(_cond) SEQAN_DO(_cond) -#define SEQAN_DO2(_cond, _comment) { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Error< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, _comment); } - -//report a message -#define SEQAN_ABORT(_comment) { ::SEQAN_NAMESPACE_MAIN::debug::Error< ::SEQAN_NAMESPACE_MAIN::debug::Report >(__FILE__, __LINE__, _comment); } -#define SEQAN_REPORT(_comment) { ::SEQAN_NAMESPACE_MAIN::debug::Message< ::SEQAN_NAMESPACE_MAIN::debug::Report >(__FILE__, __LINE__, _comment); } - -#else //#ifdef SEQAN_DEBUG - -//disable debug reports in release built -#define SEQAN_ASSERT(_cond) {} -#define SEQAN_ASSERT1(_cond) {} -#define SEQAN_ASSERT2(_cond, _comment) {} - -#define SEQAN_CHECK(_cond) {} -#define SEQAN_CHECK1(_cond) {} -#define SEQAN_CHECK2(_cond, _comment) {} - -#define SEQAN_DO(_cond) { _cond; } -#define SEQAN_DO1(_cond) SEQAN_DO(_cond) -#define SEQAN_DO2(_cond, _comment) { _cond; } - -#define SEQAN_ABORT(_comment) {} -#define SEQAN_REPORT(_comment) {} - -#endif //#ifdef SEQAN_DEBUG - -#ifdef SEQAN_TEST - -//test a condition and report test result -#define SEQAN_TASSERT(_cond) \ - { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Error< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, "(" #_cond ") is FALSE"); } -#define SEQAN_TASSERT1(_cond) SEQAN_TASSERT(_cond) -#define SEQAN_TASSERT2(_cond, _comment) \ - { if (!(_cond)) ::SEQAN_NAMESPACE_MAIN::debug::Error< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, _comment); } - -#define SEQAN_TCHECK(_cond) \ - { if (_cond) ::SEQAN_NAMESPACE_MAIN::debug::Result< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, "(" #_cond ") is TRUE"); \ - else ::SEQAN_NAMESPACE_MAIN::debug::Result< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, "(" #_cond ") is FALSE"); } -#define SEQAN_TCHECK1(_cond) SEQAN_TCHECK(_cond) -#define SEQAN_TCHECK2(_cond, _comment) \ - { if (_cond) ::SEQAN_NAMESPACE_MAIN::debug::Result< ::SEQAN_NAMESPACE_MAIN::debug::Check >(__FILE__, __LINE__, _comment); } - -//report a test result -#define SEQAN_TABORT(_comment) { ::SEQAN_NAMESPACE_MAIN::debug::Error< ::SEQAN_NAMESPACE_MAIN::debug::Report >(__FILE__, __LINE__, _comment); } -#define SEQAN_TREPORT(_comment) { ::SEQAN_NAMESPACE_MAIN::debug::Result< ::SEQAN_NAMESPACE_MAIN::debug::Report >(__FILE__, __LINE__, _comment); } - -#else //#ifdef SEQAN_TEST - -#define SEQAN_TASSERT(_cond) {} -#define SEQAN_TASSERT1(_cond) {} -#define SEQAN_TASSERT2(_cond, _comment) {} - -#define SEQAN_TCHECK(_cond) {} -#define SEQAN_TABORT(_comment) {} -#define SEQAN_TREPORT(_comment) {} - -#endif //#ifdef SEQAN_TEST -//____________________________________________________________________________ - -#ifdef SEQAN_DEBUG_OR_TEST_ - -//Test Helper Functions - -// compare two files, do not translate linebreaks -inline bool -_compareBinaryFiles(char * file1, char * file2) -{ - bool ret = false; - - FILE * fl1 = fopen(file1, "rb"); - if (!fl1) return ret; - - FILE * fl2 = fopen(file2, "rb"); - if (!fl2) - { - fclose(fl1); - return ret; - } - - while (!feof(fl1) && !feof(fl2)) - { - if (fgetc(fl1) != fgetc(fl2)) goto End; - } - - ret = feof(fl1) && feof(fl2); - -End: - fclose(fl2); - fclose(fl1); - - return ret; - -} -//____________________________________________________________________________ - -//one line break is either \r, \n, or \r\n. -inline void -_compareTextFiles_readChar(FILE * fl, char & c, bool & is_lb, bool & is_eof) -{ - is_lb = false; - is_eof = false; - - c = fgetc(fl); - if (c == '\r') - { - is_lb = true; - char c_help = fgetc(fl); - if (feof(fl)) is_eof = true; - else - { - if (c_help == '\n') - { - c = fgetc(fl); - if (feof(fl)) is_eof = true; - } - else c = c_help; - } - } - if (c == '\n') - { - is_lb = true; - c = fgetc(fl); - if (feof(fl)) is_eof = true; - } -} - -// compare two files, translate linebreaks -inline bool -_compareTextFiles(char * file1, char * file2) -{ - FILE * fl1 = fopen(file1, "rb"); - if (!fl1) return false; - - FILE * fl2 = fopen(file2, "rb"); - if (!fl2) - { - fclose(fl1); - return false; - } - - bool ret = false; - - bool is_lb1, is_lb2, is_eof1, is_eof2; - char c1, c2; - - while (!feof(fl1) && !feof(fl2)) - { - _compareTextFiles_readChar(fl1, c1, is_lb1, is_eof1); - _compareTextFiles_readChar(fl2, c2, is_lb2, is_eof2); - - if (is_lb1 ^ is_lb2) - { - goto End; - } - if (is_eof1 ^ is_eof2) - { - goto End; - } - if (c1 != c2) - { - goto End; - } - } - - ret = feof(fl1) && feof(fl2); - -End: - fclose(fl2); - fclose(fl1); - - return ret; - -} - - -//____________________________________________________________________________ - -namespace SEQAN_NAMESPACE_MAIN -{ - -namespace debug -{ - -//action of SEQAN_ASSERT, SEQAN_TCHECK and SEQAN_CHECK -//use as template argument for Error<> and Message<> and Result<> -class Check {}; - -//action of SEQAN_ABORT, SEQAN_TREPORT and SEQAN_REPORT -//use as template argument for Error<> and Message<> and Result<> -class Report {}; - - -//report fatal error -//template argument TAction is the action (Check or Report) -//use explicit instatiation for overwriting the default behavior -template -void Error(const char * file, int line, const char * comment="-") -{ - std::fprintf(stderr, "%s(%i) : SEQAN: %s\nSEQAN: execution aborted\n", file, line, comment); - exit(1); -} - -//report debug message -//template argument TAction is the action (Check or Report) -//use explicit instatiation for overwriting the default behavior -template -void Message(const char * file, int line, const char * comment="-") -{ - std::fprintf(stderr, "%s(%i) : SEQAN: %s\n", file, line, comment); -} - -//report test result -//template argument TAction is the action (Check or Report) -//use explicit instatiation for overwriting the default behavior -template -void Result(const char * file, int line, const char * comment="-") -{ - std::fprintf(stdout, "%s(%i) : %s\n", file, line, comment); -} - -} //namespace debug - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifdef SEQAN_DEBUG_OR_TEST_ - - -//____________________________________________________________________________ -//Checkpoint Testing - -//note: this framework relies on the filenames in the project to be unique - -#ifdef SEQAN_TEST - -#include -#include -#include - -namespace SEQAN_NAMESPACE_MAIN -{ -namespace debug -{ -struct Checkpoint -{ - char const* file; - unsigned int line; -}; - -struct CheckpointLess : public ::std::binary_function -{ - inline bool operator() (Checkpoint const &a, Checkpoint const &b) const - { - int c = strcmp(a.file, b.file); - return c < 0 || (c == 0 && a.line < b.line); - } -}; - -template -struct CheckpointStore -{ - static ::std::set data; -}; -template -::std::set CheckpointStore::data; - - -inline bool -checkpoint(unsigned int line, char const* file) -{ - char const* file_name = strrchr(file, '/'); - char const* file_name_2 = strrchr(file, '\\'); - if (file_name_2 > file_name) file_name = file_name_2; - if (!file_name) file_name = file; - else ++file_name; - - Checkpoint cp = {file_name, line}; - CheckpointStore<>::data.insert(cp); - return true; -} -#define SEQAN_CHECKPOINT \ - ::SEQAN_NAMESPACE_MAIN::debug::checkpoint(__LINE__, __FILE__); - - -inline void -testCheckpoint(char const* file, unsigned int line) -{ - Checkpoint cp = {file, line}; - if (CheckpointStore<>::data.find(cp) == CheckpointStore<>::data.end()) - Message< Report >(file, line, "Checkpoint lost"); -} - -inline void -verifyCheckpoints(char const* file) -{ - char const* file_name = strrchr(file, '/'); - char const* file_name_2 = strrchr(file, '\\'); - if (file_name_2 > file_name) file_name = file_name_2; - if (!file_name) file_name = file; - else ++file_name; - - FILE * fl = ::std::fopen(file, "r"); - if (!fl) - { - Error< Report >(file, 0, "verifyCheckpoints could not find this file."); - } - unsigned int line_number = 1; - char buf[1<<16]; - - while (::std::fgets(buf, sizeof(buf), fl)) - { - if (::std::strstr(buf, "SEQAN_CHECKPOINT")) - { - testCheckpoint(file_name, line_number); - } - ++line_number; - } - - ::std::fclose(fl); -} - -} //namespace debug - -} //namespace SEQAN_NAMESPACE_MAIN - -#else //#ifdef SEQAN_TEST - -#define SEQAN_CHECKPOINT - -#endif //#ifdef SEQAN_TEST - -//____________________________________________________________________________ - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_definition.h b/SeqAn-1.1/seqan/basic/basic_definition.h deleted file mode 100644 index b12fd4ce..00000000 --- a/SeqAn-1.1/seqan/basic/basic_definition.h +++ /dev/null @@ -1,405 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_definition.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_DEFINITION_H -#define SEQAN_HEADER_BASIC_DEFINITION_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// - -template -struct Tag -{ -}; - -////////////////////////////////////////////////////////////////////////////// -/** -.Tag.Default: -..summary:Tag that specifies default behavior. -..tag.Default:Use default behavior. -*/ -struct Default_; -typedef Tag const Default; - -////////////////////////////////////////////////////////////////////////////// -/** -.Tag.Move Switch: -..summary:Switch to force move. -..tag.Move:Move instead of assign. -..remarks.text:The difference between move constructor and copy constructor -is that the source object is not copied but moved into the target object. -The source object can lose its content and will be empty after -this operation in this case. -A move constructor can sigificantly faster than a copy constructor. -..example.code:String source("hello"); -String target(source, Move()); // source is moved to target -std::cout << source; //nothing printed since source lost content -std::cout << target; //"hello" -..see:Function.move -*/ - -struct Move_; -typedef Tag const Move; - -////////////////////////////////////////////////////////////////////////////// - -//Pass to c'tor of iterator to move it to the end -struct GoEnd_; -typedef Tag const GoEnd; - - -////////////////////////////////////////////////////////////////////////////// - -//construct without initializing -struct MinimalCtor_; -typedef Tag const MinimalCtor; - -//construct with initializing -struct NonMinimalCtor_; -typedef Tag const NonMinimalCtor; - -////////////////////////////////////////////////////////////////////////////// -/** -.Tag.Logical Values: -..summary:Tag that represents true and false. -..tag.True:The logical value "true". -..tag.False:The logical value "false". -*/ -struct True { enum { VALUE = true }; }; -struct False { enum { VALUE = false }; }; - - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Nothing: -..summary:Tag that represents an absent parameter or an absent type. -..tag.Nothing:Omit parameter. -*/ -///Empty Data Class. -struct Nothing {}; - - - -////////////////////////////////////////////////////////////////////////////// -// returns TTo const, if TFrom is const, TTo otherwise - -template -struct _CopyConst -{ - typedef TTo Type; -}; -template -struct _CopyConst -{ - typedef TTo const Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Internal._RemoveConst: -..signature:_RemoveConst -..returns:$t$ if $T$ is $t const$, otherwise $T$. -*/ -template -struct _RemoveConst -{ - typedef T Type; -}; -template -struct _RemoveConst: - public _RemoveConst {}; - -template -struct _RemoveConst -{ - typedef typename _RemoveConst::Type & Type; -}; -template -struct _RemoveConst -{ - typedef typename _RemoveConst::Type * Type; -}; -template -struct _RemoveConst -{ - typedef T * Type; -}; - -////////////////////////////////////////////////////////////////////////////// -/** -.Internal._MakeUnsigned: -..signature:_MakeUnsigned -..returns:$unsigned t$ if $T$ is not $unsigned t$, otherwise $T$. -*/ -template -struct _MakeUnsigned -{ - typedef T Type; -}; - -template -struct _MakeUnsigned { - typedef typename _MakeUnsigned::Type const Type; -}; - -template <> -struct _MakeUnsigned -{ - typedef unsigned char Type; -}; - -template <> -struct _MakeUnsigned -{ - typedef unsigned char Type; -}; - -template <> -struct _MakeUnsigned -{ - typedef unsigned int Type; -}; - -template <> -struct _MakeUnsigned -{ - typedef unsigned short Type; -}; - -template <> -struct _MakeUnsigned -{ - typedef unsigned long Type; -}; - -/* -template <> -struct _MakeUnsigned -{ - typedef unsigned long long Type; -}; -*/ - -////////////////////////////////////////////////////////////////////////////// -/** -.Internal._MakeSigned: -..signature:_MakeSigned -..returns:$signed t$ if $T$ is not $signed t$, otherwise $T$. -*/ -template -struct _MakeSigned -{ - typedef T Type; -}; - -template -struct _MakeSigned { - typedef typename _MakeSigned::Type const Type; -}; - -template <> -struct _MakeSigned -{ - typedef signed char Type; -}; - -template <> -struct _MakeSigned -{ - typedef signed char Type; -}; - -template <> -struct _MakeSigned -{ - typedef signed int Type; -}; - -template <> -struct _MakeSigned -{ - typedef signed short Type; -}; - -template <> -struct _MakeSigned -{ - typedef signed long Type; -}; - -/* -template <> -struct _MakeSigned -{ - typedef signed long long Type; -}; -*/ - -////////////////////////////////////////////////////////////////////////////// -/** -.Internal._ClassIdentifier: -..signature:void * _ClassIdentifier::getID() -..returns:A void * that identifies $T$. -...text:The returned values of two calls of $getID$ are equal if and only if -the used type $T$ was the same. -*/ -template -struct _ClassIdentifier -{ - static inline void * - getID() - { -SEQAN_CHECKPOINT - static bool _id_dummy; - return &_id_dummy; - } -}; - -////////////////////////////////////////////////////////////////////////////// -/** -.Function.log2: -..cat:Miscellaneous -..summary:Computes logarithm of base 2 for integer types -..signature:unsigned int log2(i) -..param.i:An integer type. -..returns:The largest integer smaller or equal than -the logarithm of $i$. -*/ - -#if 0 -template -struct _Log2_Impl -{ - template - static inline unsigned int - log2(T val, unsigned int offset) - { - unsigned int val2 = val >> (BITS_MAX / 2); - if (val2) - { - val = val2; - offset += BITS_MAX / 2; - } - return _Log2_Impl::log2(val, offset); - } -}; - -template <> -struct _Log2_Impl<1> -{ - template - static inline unsigned int - log2(T /*val*/, unsigned int offset) - { - return offset; - } -}; - - -template -inline unsigned int -log2(T val) -{ - enum - { -// BITS_PER_VALUE = BitsPerValue::VALUE //TODO??? - BITS_PER_VALUE = sizeof(T) * 8 - }; - - return _Log2_Impl::log2(val, 0); -} -#endif - -template -inline TValue _intPow(TValue a, TExponent b) -{ -SEQAN_CHECKPOINT - TValue ret = 1; - while (b != 0) - { - if (b & 1) ret *= a; - a *= a; - b >>= 1; - } - return ret; -} - -////////////////////////////////////////////////////////////////////////////// -// to avoid conflicts with non-standard macros and namespaces -// we define our own Min/Max functions - -template inline -const _Tx& _min(const _Tx& _Left, const _Tx& _Right) -{ // return smaller of _Left and _Right - if (_Left < _Right) - return _Left; - else - return _Right; -} - -template inline -_Tx _min(const _Tx& _Left, const _Ty& _Right) -{ // return smaller of _Left and _Right - return (_Right < _Left ? _Right : _Left); -} - -template inline -const _Ty& _max(const _Ty& _Left, const _Ty& _Right) -{ // return larger of _Left and _Right - if (_Left < _Right) - return _Right; - else - return _Left; -} - -////////////////////////////////////////////////////////////////////////////// - -template -struct _IsSameType -{ - enum {VALUE = false}; - typedef False Type; -}; - -template -struct _IsSameType -{ - enum {VALUE = true}; - typedef True Type; -}; - -template -inline bool -_isSameType() -{ - return _IsSameType::VALUE; -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... - - diff --git a/SeqAn-1.1/seqan/basic/basic_forwards.h b/SeqAn-1.1/seqan/basic/basic_forwards.h deleted file mode 100644 index 13e70fbe..00000000 --- a/SeqAn-1.1/seqan/basic/basic_forwards.h +++ /dev/null @@ -1,71 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_forwards.h,v 1.1 2008/08/25 16:20:02 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_FORWARD2_H -#define SEQAN_HEADER_BASIC_FORWARD2_H - -//forward declarations (make GCC 4.x happy) - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// basic_transport.h::assign - -template -inline void -assign(TTarget & target, - TSource & source); - -template -inline void -assign(TTarget & target, - TSource const & source); - -////////////////////////////////////////////////////////////////////////////// -// string_pointer.h::assignValue - -template -inline void -assignValue(TValue * me, - TPos pos, - TValue const & _value); - -////////////////////////////////////////////////////////////////////////////// -// string_pointer.h::moveValue - -template -inline void -moveValue(TValue * me, - TPos pos, - TValue const & _value); - -////////////////////////////////////////////////////////////////////////////// -// string_pointer.h::value - -template -inline TValue & -value(TValue * me, - TPos pos); - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_generated_forwards.h b/SeqAn-1.1/seqan/basic/basic_generated_forwards.h deleted file mode 100644 index 55f8dede..00000000 --- a/SeqAn-1.1/seqan/basic/basic_generated_forwards.h +++ /dev/null @@ -1,1941 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_GENERATED_FORWARDS_H -#define SEQAN_HEADER_BASIC_GENERATED_FORWARDS_H - -////////////////////////////////////////////////////////////////////////////// -// NOTE: This file is automatically generated by build_forwards.py -// Do not edit this file manually! -////////////////////////////////////////////////////////////////////////////// - - -////////////////////////////////////////////////////////////////////////////// -// CLASSES -////////////////////////////////////////////////////////////////////////////// - -namespace SEQAN_NAMESPACE_MAIN { -namespace debug { - -//____________________________________________________________________________ -// Check - -class Check; // "projects/library/seqan/basic/basic_debug.h"(238) - -//____________________________________________________________________________ -// Checkpoint - -struct Checkpoint; // "projects/library/seqan/basic/basic_debug.h"(296) - -//____________________________________________________________________________ -// CheckpointLess - -struct CheckpointLess; // "projects/library/seqan/basic/basic_debug.h"(302) - -//____________________________________________________________________________ -// CheckpointStore - -template struct CheckpointStore; // "projects/library/seqan/basic/basic_debug.h"(312) - -//____________________________________________________________________________ -// Report - -class Report; // "projects/library/seqan/basic/basic_debug.h"(242) - -} //namespace debug -} //namespace SEQAN_NAMESPACE_MAIN -////////////////////////////////////////////////////////////////////////////// - -namespace SEQAN_NAMESPACE_MAIN { - -//____________________________________________________________________________ -// AdaptorIterator - -template struct AdaptorIterator; // "projects/library/seqan/basic/basic_iterator_adaptor.h"(31) - -//____________________________________________________________________________ -// Allocator - -template struct Allocator; // "projects/library/seqan/basic/basic_allocator_interface.h"(50) - -//____________________________________________________________________________ -// BitsPerValue - -template struct BitsPerValue; // "projects/library/seqan/basic/basic_alphabet_interface.h"(837) - -//____________________________________________________________________________ -// CASE - -template struct CASE; // "projects/library/seqan/basic/basic_metaprogramming.h"(76) - -//____________________________________________________________________________ -// Cargo - -template struct Cargo; // "projects/library/seqan/basic/basic_type.h"(290) - -//____________________________________________________________________________ -// ChunkPool - -#if 0 -template struct ChunkPool; // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(56) -#endif - -//____________________________________________________________________________ -// ChunkPool2 - -template struct ChunkPool2; // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(248) - -//____________________________________________________________________________ -// CompareType - -template struct CompareType; // "projects/library/seqan/basic/basic_alphabet_simple.h"(500) -template struct CompareType; // "projects/library/seqan/basic/basic_compare.h"(30) - -//____________________________________________________________________________ -// Container - -template struct Container; // "projects/library/seqan/basic/basic_iterator_base.h"(106) -template struct Container; // "projects/library/seqan/basic/basic_iterator.h"(147) - -//____________________________________________________________________________ -// Convert - -template struct Convert; // "projects/library/seqan/basic/basic_converter.h"(48) - -//____________________________________________________________________________ -// CountedPtr - -template struct CountedPtr; // "projects/library/seqan/basic/basic_counted_ptr.h"(34) - -//____________________________________________________________________________ -// CutCompressed - -template struct CutCompressed; // "projects/library/seqan/basic/basic_aggregates.h"(36) - -//____________________________________________________________________________ -// DeepestSpec - -template struct DeepestSpec; // "projects/library/seqan/basic/basic_type.h"(229) - -//____________________________________________________________________________ -// DefaultGetIteratorSpec - -template struct DefaultGetIteratorSpec; // "projects/library/seqan/basic/basic_iterator.h"(94) - -//____________________________________________________________________________ -// DefaultIteratorSpec - -template struct DefaultIteratorSpec; // "projects/library/seqan/basic/basic_iterator.h"(72) - -//____________________________________________________________________________ -// Default_ - -struct Default_; // "projects/library/seqan/basic/basic_definition.h"(40) - -//____________________________________________________________________________ -// Difference - -template struct Difference; // "projects/library/seqan/basic/basic_type.h"(137) - -//____________________________________________________________________________ -// DotDrawing_ - -struct DotDrawing_; // "projects/library/seqan/basic/basic_tag.h"(36) - -//____________________________________________________________________________ -// False - -struct False; // "projects/library/seqan/basic/basic_definition.h"(88) - -//____________________________________________________________________________ -// GetValue - -template struct GetValue; // "projects/library/seqan/basic/basic_type.h"(69) - -//____________________________________________________________________________ -// GoEnd_ - -struct GoEnd_; // "projects/library/seqan/basic/basic_definition.h"(66) - -//____________________________________________________________________________ -// Gotoh_ - -struct Gotoh_; // "projects/library/seqan/basic/basic_tag.h"(90) - -//____________________________________________________________________________ -// Hirschberg_ - -struct Hirschberg_; // "projects/library/seqan/basic/basic_tag.h"(118) - -//____________________________________________________________________________ -// Holder - -template struct Holder; // "projects/library/seqan/basic/basic_holder.h"(112) - -//____________________________________________________________________________ -// Host - -template struct Host; // "projects/library/seqan/basic/basic_type.h"(181) - -//____________________________________________________________________________ -// IF - -template struct IF; // "projects/library/seqan/basic/basic_metaprogramming.h"(35) - -//____________________________________________________________________________ -// Id - -template struct Id; // "projects/library/seqan/basic/basic_type.h"(335) - -//____________________________________________________________________________ -// InfimumValue - -template struct InfimumValue; // "projects/library/seqan/basic/basic_alphabet_interface.h"(911) - -//____________________________________________________________________________ -// IsSimple - -template struct IsSimple; // "projects/library/seqan/basic/basic_alphabet_interface.h"(53) - -//____________________________________________________________________________ -// Iter - -template class Iter; // "projects/library/seqan/basic/basic_iterator_base.h"(41) - -//____________________________________________________________________________ -// Iterator - -template struct Iterator; // "projects/library/seqan/basic/basic_iterator.h"(129) - -//____________________________________________________________________________ -// IteratorProxy - -template struct IteratorProxy; // "projects/library/seqan/basic/basic_proxy.h"(80) - -//____________________________________________________________________________ -// Iterator_Default_Imp - -template struct Iterator_Default_Imp; // "projects/library/seqan/basic/basic_iterator.h"(119) - -//____________________________________________________________________________ -// Key - -template struct Key; // "projects/library/seqan/basic/basic_type.h"(358) - -//____________________________________________________________________________ -// LENGTH - -template struct LENGTH; // "projects/library/seqan/basic/basic_type.h"(586) - -//____________________________________________________________________________ -// LOOP - -template class LOOP; // "projects/library/seqan/basic/basic_metaprogramming.h"(121) - -//____________________________________________________________________________ -// LOOP_REVERSE - -template class LOOP_REVERSE; // "projects/library/seqan/basic/basic_metaprogramming.h"(144) - -//____________________________________________________________________________ -// Log2 - -template <__int64 numerus > struct Log2; // "projects/library/seqan/basic/basic_metaprogramming.h"(166) - -//____________________________________________________________________________ -// Log2Floor - -template <__int64 numerus > struct Log2Floor; // "projects/library/seqan/basic/basic_metaprogramming.h"(171) - -//____________________________________________________________________________ -// MemsetConstValueWorker - -template struct MemsetConstValueWorker; // "projects/library/seqan/basic/basic_metaprogramming.h"(251) - -//____________________________________________________________________________ -// MemsetWorker - -template struct MemsetWorker; // "projects/library/seqan/basic/basic_metaprogramming.h"(205) - -//____________________________________________________________________________ -// MinimalCtor_ - -struct MinimalCtor_; // "projects/library/seqan/basic/basic_definition.h"(73) - -//____________________________________________________________________________ -// Move_ - -struct Move_; // "projects/library/seqan/basic/basic_definition.h"(60) - -//____________________________________________________________________________ -// MultiPool - -template struct MultiPool; // "projects/library/seqan/basic/basic_allocator_multipool.h"(50) - -//____________________________________________________________________________ -// MyersBitVector_ - -struct MyersBitVector_; // "projects/library/seqan/basic/basic_tag.h"(100) - -//____________________________________________________________________________ -// MyersHirschberg_ - -struct MyersHirschberg_; // "projects/library/seqan/basic/basic_tag.h"(109) - -//____________________________________________________________________________ -// NeedlemanWunsch_ - -struct NeedlemanWunsch_; // "projects/library/seqan/basic/basic_tag.h"(81) - -//____________________________________________________________________________ -// NilCase - -struct NilCase; // "projects/library/seqan/basic/basic_metaprogramming.h"(72) - -//____________________________________________________________________________ -// NonMinimalCtor_ - -struct NonMinimalCtor_; // "projects/library/seqan/basic/basic_definition.h"(77) - -//____________________________________________________________________________ -// Nothing - -struct Nothing; // "projects/library/seqan/basic/basic_definition.h"(99) - -//____________________________________________________________________________ -// Nussinov_ - -struct Nussinov_; // "projects/library/seqan/basic/basic_tag.h"(163) - -//____________________________________________________________________________ -// Object - -template struct Object; // "projects/library/seqan/basic/basic_type.h"(377) - -//____________________________________________________________________________ -// Pair - -template struct Pair; // "projects/library/seqan/basic/basic_aggregates.h"(69) - -//____________________________________________________________________________ -// Position - -template struct Position; // "projects/library/seqan/basic/basic_type.h"(161) - -//____________________________________________________________________________ -// PositionIterator - -struct PositionIterator; // "projects/library/seqan/basic/basic_iterator_position.h"(29) - -//____________________________________________________________________________ -// Power - -template <__int64 base, __int64 exponent > struct Power; // "projects/library/seqan/basic/basic_metaprogramming.h"(186) - -//____________________________________________________________________________ -// Proxy - -template struct Proxy; // "projects/library/seqan/basic/basic_transport.h"(67) -template struct Proxy; // "projects/library/seqan/basic/basic_proxy.h"(48) - -//____________________________________________________________________________ -// Reference - -template struct Reference; // "projects/library/seqan/basic/basic_type.h"(91) - -//____________________________________________________________________________ -// SWITCH - -template class SWITCH; // "projects/library/seqan/basic/basic_metaprogramming.h"(84) - -//____________________________________________________________________________ -// Simple - -struct Simple; // "projects/library/seqan/basic/basic_holder.h"(86) - -//____________________________________________________________________________ -// SimpleAlloc - -template struct SimpleAlloc; // "projects/library/seqan/basic/basic_allocator_simple.h"(46) - -//____________________________________________________________________________ -// SimpleIterator - -struct SimpleIterator; // "projects/library/seqan/basic/basic_iterator_simple.h"(30) - -//____________________________________________________________________________ -// SimpleType - -template struct SimpleType; // "projects/library/seqan/basic/basic_alphabet_simple.h"(58) - -//____________________________________________________________________________ -// SinglePool - -template struct SinglePool; // "projects/library/seqan/basic/basic_allocator_singlepool.h"(50) - -//____________________________________________________________________________ -// SinglePool2 - -template struct SinglePool2; // "projects/library/seqan/basic/basic_allocator_singlepool.h"(226) - -//____________________________________________________________________________ -// Size - -template struct Size; // "projects/library/seqan/basic/basic_type.h"(113) - -//____________________________________________________________________________ -// SmithWatermanClump_ - -struct SmithWatermanClump_; // "projects/library/seqan/basic/basic_tag.h"(145) - -//____________________________________________________________________________ -// SmithWatermanIsland_ - -struct SmithWatermanIsland_; // "projects/library/seqan/basic/basic_tag.h"(154) - -//____________________________________________________________________________ -// SmithWaterman_ - -struct SmithWaterman_; // "projects/library/seqan/basic/basic_tag.h"(136) - -//____________________________________________________________________________ -// Source - -template struct Source; // "projects/library/seqan/basic/basic_type.h"(392) - -//____________________________________________________________________________ -// Spec - -template struct Spec; // "projects/library/seqan/basic/basic_type.h"(200) - -//____________________________________________________________________________ -// StdAllocator - -template struct StdAllocator; // "projects/library/seqan/basic/basic_allocator_to_std.h"(166) - -//____________________________________________________________________________ -// StdContainerIterator - -template struct StdContainerIterator; // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(68) - -//____________________________________________________________________________ -// StdIteratorAdaptor - -struct StdIteratorAdaptor; // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(89) - -//____________________________________________________________________________ -// SupremumValue - -template struct SupremumValue; // "projects/library/seqan/basic/basic_alphabet_interface.h"(900) - -//____________________________________________________________________________ -// TYPECMP - -template struct TYPECMP; // "projects/library/seqan/basic/basic_metaprogramming.h"(54) - -//____________________________________________________________________________ -// Tag - -template struct Tag; // "projects/library/seqan/basic/basic_definition.h"(31) - -//____________________________________________________________________________ -// TagAllocateStorage_ - -struct TagAllocateStorage_; // "projects/library/seqan/basic/basic_allocator_interface.h"(84) - -//____________________________________________________________________________ -// TagAllocateTemp_ - -struct TagAllocateTemp_; // "projects/library/seqan/basic/basic_allocator_interface.h"(81) - -//____________________________________________________________________________ -// TagAllocateUnspecified_ - -struct TagAllocateUnspecified_; // "projects/library/seqan/basic/basic_allocator_interface.h"(78) - -//____________________________________________________________________________ -// TagRooted_ - -struct TagRooted_; // "projects/library/seqan/basic/basic_iterator.h"(48) - -//____________________________________________________________________________ -// TagStandard_ - -struct TagStandard_; // "projects/library/seqan/basic/basic_iterator.h"(51) - -//____________________________________________________________________________ -// ToStdAllocator - -template struct ToStdAllocator; // "projects/library/seqan/basic/basic_allocator_to_std.h"(61) - -//____________________________________________________________________________ -// Triple - -template struct Triple; // "projects/library/seqan/basic/basic_aggregates.h"(218) - -//____________________________________________________________________________ -// Tristate - -struct Tristate; // "projects/library/seqan/basic/basic_holder.h"(87) - -//____________________________________________________________________________ -// Tristate2 - -struct Tristate2; // "projects/library/seqan/basic/basic_holder.h"(790) - -//____________________________________________________________________________ -// True - -struct True; // "projects/library/seqan/basic/basic_definition.h"(87) - -//____________________________________________________________________________ -// Tuple - -template struct Tuple; // "projects/library/seqan/basic/basic_aggregates.h"(313) - -//____________________________________________________________________________ -// Value - -template struct Value; // "projects/library/seqan/basic/basic_type.h"(43) - -//____________________________________________________________________________ -// ValueSize - -template struct ValueSize; // "projects/library/seqan/basic/basic_alphabet_interface.h"(859) - -//____________________________________________________________________________ -// VertexDescriptor - -template struct VertexDescriptor; // "projects/library/seqan/basic/basic_type.h"(313) - -//____________________________________________________________________________ -// VolatilePtr - -template struct VolatilePtr; // "projects/library/seqan/basic/basic_volatile_ptr.h"(40) - -//____________________________________________________________________________ -// WEIGHT - -template struct WEIGHT; // "projects/library/seqan/basic/basic_type.h"(608) - -//____________________________________________________________________________ -// WorkerNothing - -struct WorkerNothing; // "projects/library/seqan/basic/basic_metaprogramming.h"(115) - -//____________________________________________________________________________ -// _AminoAcid - -struct _AminoAcid; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1085) - -//____________________________________________________________________________ -// _BitVector - -template struct _BitVector; // "projects/library/seqan/basic/basic_aggregates.h"(340) - -//____________________________________________________________________________ -// _ClassIdentifier - -template struct _ClassIdentifier; // "projects/library/seqan/basic/basic_definition.h"(269) - -//____________________________________________________________________________ -// _Compressed - -struct _Compressed; // "projects/library/seqan/basic/basic_aggregates.h"(29) - -//____________________________________________________________________________ -// _ConstParameter - -template struct _ConstParameter; // "projects/library/seqan/basic/basic_type.h"(474) - -//____________________________________________________________________________ -// _CopyConst - -template struct _CopyConst; // "projects/library/seqan/basic/basic_definition.h"(108) - -//____________________________________________________________________________ -// _Dna - -struct _Dna; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1010) - -//____________________________________________________________________________ -// _Dna5 - -struct _Dna5; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1034) - -//____________________________________________________________________________ -// _HammingDistance - -struct _HammingDistance; // "projects/library/seqan/basic/basic_tag.h"(50) - -//____________________________________________________________________________ -// _InfimumValueSigned - -template struct _InfimumValueSigned; // "projects/library/seqan/basic/basic_alphabet_interface.h"(876) - -//____________________________________________________________________________ -// _InfimumValueUnsigned - -template struct _InfimumValueUnsigned; // "projects/library/seqan/basic/basic_alphabet_interface.h"(874) - -//____________________________________________________________________________ -// _IsSameType - -template struct _IsSameType; // "projects/library/seqan/basic/basic_definition.h"(378) - -//____________________________________________________________________________ -// _IsSimple - -template struct _IsSimple; // "projects/library/seqan/basic/basic_alphabet_interface.h"(47) - -//____________________________________________________________________________ -// _Iupac - -struct _Iupac; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1058) - -//____________________________________________________________________________ -// _LevenshteinDistance - -struct _LevenshteinDistance; // "projects/library/seqan/basic/basic_tag.h"(51) - -//____________________________________________________________________________ -// _Log2_Impl - -template struct _Log2_Impl; // "projects/library/seqan/basic/basic_definition.h"(292) - -//____________________________________________________________________________ -// _MakeSigned - -template struct _MakeSigned; // "projects/library/seqan/basic/basic_definition.h"(212) - -//____________________________________________________________________________ -// _MakeUnsigned - -template struct _MakeUnsigned; // "projects/library/seqan/basic/basic_definition.h"(157) - -//____________________________________________________________________________ -// _Parameter - -template struct _Parameter; // "projects/library/seqan/basic/basic_type.h"(416) - -//____________________________________________________________________________ -// _Pointer - -template struct _Pointer; // "projects/library/seqan/basic/basic_type.h"(519) - -//____________________________________________________________________________ -// _RemoveConst - -template struct _RemoveConst; // "projects/library/seqan/basic/basic_definition.h"(126) - -//____________________________________________________________________________ -// _SupremumValueSigned - -template struct _SupremumValueSigned; // "projects/library/seqan/basic/basic_alphabet_interface.h"(871) - -//____________________________________________________________________________ -// _SupremumValueUnsigned - -template struct _SupremumValueUnsigned; // "projects/library/seqan/basic/basic_alphabet_interface.h"(869) - -//____________________________________________________________________________ -// _Translate_Table_AA_2_Ascii - -template struct _Translate_Table_AA_2_Ascii; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(337) - -//____________________________________________________________________________ -// _Translate_Table_Ascii_2_AA - -template struct _Translate_Table_Ascii_2_AA; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(374) - -//____________________________________________________________________________ -// _Translate_Table_Ascii_2_Dna - -template struct _Translate_Table_Ascii_2_Dna; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(138) - -//____________________________________________________________________________ -// _Translate_Table_Ascii_2_Dna5 - -template struct _Translate_Table_Ascii_2_Dna5; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(176) - -//____________________________________________________________________________ -// _Translate_Table_Ascii_2_Iupac - -template struct _Translate_Table_Ascii_2_Iupac; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(214) - -//____________________________________________________________________________ -// _Translate_Table_Byte_2_AA - -template struct _Translate_Table_Byte_2_AA; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(412) - -//____________________________________________________________________________ -// _Translate_Table_Byte_2_Dna - -template struct _Translate_Table_Byte_2_Dna; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(251) - -//____________________________________________________________________________ -// _Translate_Table_Byte_2_Dna5 - -template struct _Translate_Table_Byte_2_Dna5; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(280) - -//____________________________________________________________________________ -// _Translate_Table_Byte_2_Iupac - -template struct _Translate_Table_Byte_2_Iupac; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(308) - -//____________________________________________________________________________ -// _Translate_Table_Dna5_2_Ascii - -template struct _Translate_Table_Dna5_2_Ascii; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(33) - -//____________________________________________________________________________ -// _Translate_Table_Dna5_2_Iupac - -template struct _Translate_Table_Dna5_2_Iupac; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(43) - -//____________________________________________________________________________ -// _Translate_Table_Iupac_2_Ascii - -template struct _Translate_Table_Iupac_2_Ascii; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(53) - -//____________________________________________________________________________ -// _Translate_Table_Iupac_2_Dna - -template struct _Translate_Table_Iupac_2_Dna; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(81) - -//____________________________________________________________________________ -// _Translate_Table_Iupac_2_Dna5 - -template struct _Translate_Table_Iupac_2_Dna5; // "projects/library/seqan/basic/basic_alphabet_simple_tabs.h"(110) - -//____________________________________________________________________________ -// _TupleShiftLeftWorker - -struct _TupleShiftLeftWorker; // "projects/library/seqan/basic/basic_aggregates.h"(510) - -//____________________________________________________________________________ -// _TupleShiftRightWorker - -struct _TupleShiftRightWorker; // "projects/library/seqan/basic/basic_aggregates.h"(517) - -//____________________________________________________________________________ -// _ValueConstructor - -struct _ValueConstructor; // "projects/library/seqan/basic/basic_alphabet_interface.h"(81) - -//____________________________________________________________________________ -// _ValueConstructorProxy - -struct _ValueConstructorProxy; // "projects/library/seqan/basic/basic_alphabet_interface.h"(111) - -//____________________________________________________________________________ -// _ValueDestructor - -struct _ValueDestructor; // "projects/library/seqan/basic/basic_alphabet_interface.h"(125) - -//____________________________________________________________________________ -// _ValueDestructorProxy - -struct _ValueDestructorProxy; // "projects/library/seqan/basic/basic_alphabet_interface.h"(135) - -} //namespace SEQAN_NAMESPACE_MAIN - - -////////////////////////////////////////////////////////////////////////////// -// TYPEDEFS -////////////////////////////////////////////////////////////////////////////// - -namespace SEQAN_NAMESPACE_MAIN { - -//____________________________________________________________________________ -// AminoAcid - -typedef SimpleType AminoAcid; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1086) - -//____________________________________________________________________________ -// Ascii - -typedef char Ascii; // "projects/library/seqan/basic/basic_alphabet_interface.h"(61) - -//____________________________________________________________________________ -// Byte - -typedef unsigned char Byte; // "projects/library/seqan/basic/basic_alphabet_interface.h"(62) - -//____________________________________________________________________________ -// Compressed - -typedef Tag<_Compressed> Compressed; // "projects/library/seqan/basic/basic_aggregates.h"(30) - -//____________________________________________________________________________ -// Default - -typedef Tag const Default; // "projects/library/seqan/basic/basic_definition.h"(41) - -//____________________________________________________________________________ -// Dna - -typedef SimpleType Dna; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1011) - -//____________________________________________________________________________ -// Dna5 - -typedef SimpleType Dna5; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1035) - -//____________________________________________________________________________ -// DotDrawing - -typedef Tag const DotDrawing; // "projects/library/seqan/basic/basic_tag.h"(37) - -//____________________________________________________________________________ -// EditDistance - -typedef Tag<_LevenshteinDistance> EditDistance; // "projects/library/seqan/basic/basic_tag.h"(55) - -//____________________________________________________________________________ -// GoEnd - -typedef Tag const GoEnd; // "projects/library/seqan/basic/basic_definition.h"(67) - -//____________________________________________________________________________ -// Gotoh - -typedef Tag const Gotoh; // "projects/library/seqan/basic/basic_tag.h"(91) - -//____________________________________________________________________________ -// HammingDistance - -typedef Tag<_HammingDistance> HammingDistance; // "projects/library/seqan/basic/basic_tag.h"(53) - -//____________________________________________________________________________ -// Hirschberg - -typedef Tag const Hirschberg; // "projects/library/seqan/basic/basic_tag.h"(119) - -//____________________________________________________________________________ -// Iupac - -typedef SimpleType Iupac; // "projects/library/seqan/basic/basic_alphabet_simple.h"(1059) - -//____________________________________________________________________________ -// LevenshteinDistance - -typedef Tag<_LevenshteinDistance> LevenshteinDistance; // "projects/library/seqan/basic/basic_tag.h"(54) - -//____________________________________________________________________________ -// MinimalCtor - -typedef Tag const MinimalCtor; // "projects/library/seqan/basic/basic_definition.h"(74) - -//____________________________________________________________________________ -// Move - -typedef Tag const Move; // "projects/library/seqan/basic/basic_definition.h"(61) - -//____________________________________________________________________________ -// MyersBitVector - -typedef Tag const MyersBitVector; // "projects/library/seqan/basic/basic_tag.h"(101) - -//____________________________________________________________________________ -// MyersHirschberg - -typedef Tag const MyersHirschberg; // "projects/library/seqan/basic/basic_tag.h"(110) - -//____________________________________________________________________________ -// NeedlemanWunsch - -typedef Tag const NeedlemanWunsch; // "projects/library/seqan/basic/basic_tag.h"(82) - -//____________________________________________________________________________ -// NonMinimalCtor - -typedef Tag const NonMinimalCtor; // "projects/library/seqan/basic/basic_definition.h"(78) - -//____________________________________________________________________________ -// Nussinov - -typedef Tag const Nussinov; // "projects/library/seqan/basic/basic_tag.h"(164) - -//____________________________________________________________________________ -// PoolAllocator - -typedef Allocator >, 0x100> > PoolAllocator; // "projects/library/seqan/basic/basic_allocator_multipool.h"(54) - -//____________________________________________________________________________ -// Rooted - -typedef Tag const Rooted; // "projects/library/seqan/basic/basic_iterator.h"(49) - -//____________________________________________________________________________ -// SimpleAllocator - -typedef Allocator > SimpleAllocator; // "projects/library/seqan/basic/basic_allocator_simple.h"(51) - -//____________________________________________________________________________ -// SmithWaterman - -typedef Tag const SmithWaterman; // "projects/library/seqan/basic/basic_tag.h"(137) - -//____________________________________________________________________________ -// SmithWatermanClump - -typedef Tag const SmithWatermanClump; // "projects/library/seqan/basic/basic_tag.h"(146) - -//____________________________________________________________________________ -// SmithWatermanIsland - -typedef Tag const SmithWatermanIsland; // "projects/library/seqan/basic/basic_tag.h"(155) - -//____________________________________________________________________________ -// Standard - -typedef Tag const Standard; // "projects/library/seqan/basic/basic_iterator.h"(52) - -//____________________________________________________________________________ -// TagAllocateStorage - -typedef Tag const TagAllocateStorage; // "projects/library/seqan/basic/basic_allocator_interface.h"(85) - -//____________________________________________________________________________ -// TagAllocateTemp - -typedef Tag const TagAllocateTemp; // "projects/library/seqan/basic/basic_allocator_interface.h"(82) - -//____________________________________________________________________________ -// TagAllocateUnspecified - -typedef Tag const TagAllocateUnspecified; // "projects/library/seqan/basic/basic_allocator_interface.h"(79) - -//____________________________________________________________________________ -// Unicode - -typedef wchar_t Unicode; // "projects/library/seqan/basic/basic_alphabet_interface.h"(63) - -} //namespace SEQAN_NAMESPACE_MAIN - - -////////////////////////////////////////////////////////////////////////////// -// FUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -namespace SEQAN_NAMESPACE_MAIN { -namespace debug { - -//____________________________________________________________________________ -// Error - -template void Error(const char * file, int line, const char * comment); // "projects/library/seqan/basic/basic_debug.h"(250) - -//____________________________________________________________________________ -// Message - -template void Message(const char * file, int line, const char * comment); // "projects/library/seqan/basic/basic_debug.h"(260) - -//____________________________________________________________________________ -// Result - -template void Result(const char * file, int line, const char * comment); // "projects/library/seqan/basic/basic_debug.h"(269) - -//____________________________________________________________________________ -// checkpoint - -inline bool checkpoint(unsigned int line, char const* file); // "projects/library/seqan/basic/basic_debug.h"(321) - -//____________________________________________________________________________ -// testCheckpoint - -inline void testCheckpoint(char const* file, unsigned int line); // "projects/library/seqan/basic/basic_debug.h"(338) - -//____________________________________________________________________________ -// verifyCheckpoints - -inline void verifyCheckpoints(char const* file); // "projects/library/seqan/basic/basic_debug.h"(346) - -} //namespace debug -} //namespace SEQAN_NAMESPACE_MAIN -////////////////////////////////////////////////////////////////////////////// - -namespace SEQAN_NAMESPACE_MAIN { - -//____________________________________________________________________________ -// _allocatorBlockNumber - -template inline unsigned int _allocatorBlockNumber(Allocator > &, size_t size_); // "projects/library/seqan/basic/basic_allocator_multipool.h"(140) - -//____________________________________________________________________________ -// _arrayClearSpace_Default - -template void _arrayClearSpace_Default(TIterator array_begin, size_t array_length, size_t keep_from, size_t move_to); // "projects/library/seqan/basic/basic_alphabet_interface.h"(774) - -//____________________________________________________________________________ -// _arrayClearSpace_Pointer - -template inline void _arrayClearSpace_Pointer(TValue * array_begin, size_t array_length, size_t keep_from, size_t move_to, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(342) -template inline void _arrayClearSpace_Pointer(TValue * array_begin, size_t array_length, size_t keep_from, size_t move_to, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(354) - -//____________________________________________________________________________ -// _arrayConstructCopy_Default - -template inline void _arrayConstructCopy_Default(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(349) - -//____________________________________________________________________________ -// _arrayConstructCopy_Pointer - -template inline void _arrayConstructCopy_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(100) -template inline void _arrayConstructCopy_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(110) - -//____________________________________________________________________________ -// _arrayConstructMove_Default - -template inline void _arrayConstructMove_Default(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(397) - -//____________________________________________________________________________ -// _arrayConstructMove_Pointer - -template inline void _arrayConstructMove_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(134) -template inline void _arrayConstructMove_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(144) - -//____________________________________________________________________________ -// _arrayConstruct_Default - -template inline void _arrayConstruct_Default(TIterator1 begin_, TIterator2 end_); // "projects/library/seqan/basic/basic_alphabet_interface.h"(280) -template inline void _arrayConstruct_Default(TIterator1 begin_, TIterator2 end_, TParam const & param_); // "projects/library/seqan/basic/basic_alphabet_interface.h"(304) - -//____________________________________________________________________________ -// _arrayConstruct_Pointer - -template inline void _arrayConstruct_Pointer(TIterator, TIterator, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(36) -template inline void _arrayConstruct_Pointer(TIterator begin_, TIterator end_, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(45) -template inline void _arrayConstruct_Pointer(TIterator begin_, TIterator end_, TParam const & param_, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(66) -template inline void _arrayConstruct_Pointer(TIterator begin_, TIterator end_, TParam const & param_, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(76) - -//____________________________________________________________________________ -// _arrayCopyBackward_Default - -template inline void _arrayCopyBackward_Default(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(547) - -//____________________________________________________________________________ -// _arrayCopyBackward_Pointer - -template inline void _arrayCopyBackward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(239) -template inline void _arrayCopyBackward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(249) - -//____________________________________________________________________________ -// _arrayCopyForward_Default - -template inline void _arrayCopyForward_Default(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(504) - -//____________________________________________________________________________ -// _arrayCopyForward_Pointer - -template inline void _arrayCopyForward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(205) -template inline void _arrayCopyForward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(215) - -//____________________________________________________________________________ -// _arrayDestruct_Default - -template inline void _arrayDestruct_Default(TIterator1 begin_, TIterator2 end_); // "projects/library/seqan/basic/basic_alphabet_interface.h"(436) - -//____________________________________________________________________________ -// _arrayDestruct_Pointer - -template inline void _arrayDestruct_Pointer(TValue * , TValue * , True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(167) -template inline void _arrayDestruct_Pointer(TValue * begin_, TValue * end_, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(176) - -//____________________________________________________________________________ -// _arrayMoveBackward_Default - -template inline void _arrayMoveBackward_Default(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(679) - -//____________________________________________________________________________ -// _arrayMoveBackward_Pointer - -template inline void _arrayMoveBackward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(307) -template inline void _arrayMoveBackward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(317) - -//____________________________________________________________________________ -// _arrayMoveForward_Default - -template inline void _arrayMoveForward_Default(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(630) - -//____________________________________________________________________________ -// _arrayMoveForward_Pointer - -template inline void _arrayMoveForward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, True); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(273) -template inline void _arrayMoveForward_Pointer(TValue * source_begin, TValue * source_end, TValue * target_begin, False); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(283) - -//____________________________________________________________________________ -// _intPow - -template inline TValue _intPow(TValue a, TExponent b); // "projects/library/seqan/basic/basic_definition.h"(334) - -//____________________________________________________________________________ -// _isSameType - -template inline bool _isSameType(); // "projects/library/seqan/basic/basic_definition.h"(393) - -//____________________________________________________________________________ -// _max - -template inline const _Ty& _max(const _Ty& _Left, const _Ty& _Right); // "projects/library/seqan/basic/basic_definition.h"(367) - -//____________________________________________________________________________ -// _min - -template inline const _Tx& _min(const _Tx& _Left, const _Tx& _Right); // "projects/library/seqan/basic/basic_definition.h"(352) -template inline _Tx _min(const _Tx& _Left, const _Ty& _Right); // "projects/library/seqan/basic/basic_definition.h"(361) - -//____________________________________________________________________________ -// _toParameter - -template typename _Parameter::Type _toParameter(T * _object); // "projects/library/seqan/basic/basic_type.h"(447) -template typename _Parameter::Type _toParameter(T _object); // "projects/library/seqan/basic/basic_type.h"(454) - -//____________________________________________________________________________ -// _toPointer - -template typename _Pointer::Type _toPointer(T & _object); // "projects/library/seqan/basic/basic_type.h"(553) -template typename _Pointer::Type _toPointer(T const & _object); // "projects/library/seqan/basic/basic_type.h"(560) -template typename _Pointer::Type _toPointer(T * _object); // "projects/library/seqan/basic/basic_type.h"(568) - -//____________________________________________________________________________ -// addRef - -template inline void addRef(T & ); // "projects/library/seqan/basic/basic_holder.h"(45) -template inline void addRef(T const & ); // "projects/library/seqan/basic/basic_holder.h"(51) - -//____________________________________________________________________________ -// allocate - -template inline void allocate(Allocator > & me, TValue * & data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(162) -template inline void allocate(Allocator > & me, TValue2 * & data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(279) -template inline void allocate(Allocator > & me, TValue * & data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_multipool.h"(165) -template inline void allocate(Allocator > & me, TValue * & data, TSize count, Tag const); // "projects/library/seqan/basic/basic_allocator_simple.h"(146) -template inline void allocate(T const & me, TValue * & data, TSize count); // "projects/library/seqan/basic/basic_allocator_interface.h"(129) -template inline void allocate(T & me, TValue * & data, TSize count); // "projects/library/seqan/basic/basic_allocator_interface.h"(137) -template inline void allocate(T const &, TValue * & data, TSize count, Tag const); // "projects/library/seqan/basic/basic_allocator_interface.h"(147) -template inline void allocate(T &, TValue * & data, TSize count, Tag const); // "projects/library/seqan/basic/basic_allocator_interface.h"(158) -//template inline void allocate(Allocator > & me, TValue * & data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(173) -template inline void allocate(Allocator > & me, TValue2 * & data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(302) - -//____________________________________________________________________________ -// arrayClearSpace - -template void arrayClearSpace(TIterator array_begin, size_t array_length, size_t keep_from, size_t move_to); // "projects/library/seqan/basic/basic_alphabet_interface.h"(818) -template void arrayClearSpace(TValue * array_begin, size_t array_length, size_t keep_from, size_t move_to); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(362) - -//____________________________________________________________________________ -// arrayConstruct - -template inline void arrayConstruct(TIterator1 begin_, TIterator2 end_); // "projects/library/seqan/basic/basic_alphabet_interface.h"(292) -template inline void arrayConstruct(TIterator1 begin_, TIterator2 end_, TParam const & param_); // "projects/library/seqan/basic/basic_alphabet_interface.h"(317) -template inline void arrayConstruct(TValue * begin_, TValue * end_); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(53) -template inline void arrayConstruct(TValue * begin_, TValue * end_, TParam const & param_); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(85) - -//____________________________________________________________________________ -// arrayConstructCopy - -template inline void arrayConstructCopy(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(364) -template inline void arrayConstructCopy(TValue * source_begin, TValue * source_end, TValue * target_begin); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(119) - -//____________________________________________________________________________ -// arrayConstructMove - -template inline void arrayConstructMove(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(412) -template inline void arrayConstructMove(TValue * source_begin, TValue * source_end, TValue * target_begin); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(153) - -//____________________________________________________________________________ -// arrayCopy - -template inline void arrayCopy(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(591) - -//____________________________________________________________________________ -// arrayCopyBackward - -template inline void arrayCopyBackward(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(556) -template inline void arrayCopyBackward(TValue * source_begin, TValue * source_end, TValue * target_begin); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(258) - -//____________________________________________________________________________ -// arrayCopyForward - -template inline void arrayCopyForward(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(513) -template inline void arrayCopyForward(TValue * source_begin, TValue * source_end, TValue * target_begin); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(224) - -//____________________________________________________________________________ -// arrayDestruct - -template inline void arrayDestruct(TIterator1 begin_, TIterator2 end_); // "projects/library/seqan/basic/basic_alphabet_interface.h"(448) -template inline void arrayDestruct(TValue * begin_, TValue * end_); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(184) - -//____________________________________________________________________________ -// arrayFill - -template inline void arrayFill(TIterator1 begin_, TIterator2 end_, TValue const & value); // "projects/library/seqan/basic/basic_alphabet_interface.h"(474) - -//____________________________________________________________________________ -// arrayMove - -template inline void arrayMove(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(732) - -//____________________________________________________________________________ -// arrayMoveBackward - -template inline void arrayMoveBackward(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(694) -template inline void arrayMoveBackward(TValue * source_begin, TValue * source_end, TValue * target_begin); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(326) - -//____________________________________________________________________________ -// arrayMoveForward - -template inline void arrayMoveForward(TSource1 source_begin, TSource2 source_end, TTarget target_begin); // "projects/library/seqan/basic/basic_alphabet_interface.h"(644) -template inline void arrayMoveForward(TValue * source_begin, TValue * source_end, TValue * target_begin); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(292) - -//____________________________________________________________________________ -// assign - -template inline void assign(SimpleType & target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(294) -template inline void assign(SimpleType & target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(302) -template inline void assign(SimpleType & target, TSource & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(313) -template inline void assign(SimpleType & target, TSource const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(321) -template inline void assign(SimpleType & target, Proxy & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(334) -template inline void assign(SimpleType & target, Proxy const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(343) -template inline void assign(int & c_target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(358) -template inline void assign(int & c_target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(366) -template inline void assign(unsigned int & c_target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(376) -template inline void assign(unsigned int & c_target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(384) -template inline void assign(short & c_target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(394) -template inline void assign(short & c_target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(402) -template inline void assign(unsigned short & c_target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(412) -template inline void assign(unsigned short & c_target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(420) -template inline void assign(char & c_target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(430) -template inline void assign(char & c_target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(438) -template inline void assign(signed char & c_target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(448) -template inline void assign(signed char & c_target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(456) -template inline void assign(unsigned char & c_target, SimpleType & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(466) -template inline void assign(unsigned char & c_target, SimpleType const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(474) -inline void assign(Ascii & c_target, Dna const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1096) -inline void assign(Ascii & c_target, Dna5 const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1104) -inline void assign(Ascii & c_target, Iupac const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1111) -inline void assign(Ascii & c_target, AminoAcid const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1118) -inline void assign(Dna & target, Byte c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1129) -inline void assign(Dna & target, Ascii c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1138) -inline void assign(Dna & target, Unicode c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1147) -inline void assign(Dna & target, Dna5 const & c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1156) -inline void assign(Dna & target, Iupac const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1165) -inline void assign(Dna5 & target, Byte c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1176) -inline void assign(Dna5 & target, Ascii c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1185) -inline void assign(Dna5 & target, Unicode c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1194) -inline void assign(Dna5 & target, Iupac const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1203) -inline void assign(Dna5 & target, Dna const & c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1213) -inline void assign(Iupac & target, Byte c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1224) -inline void assign(Iupac & target, Ascii c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1233) -inline void assign(Iupac & target, Unicode c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1242) -inline void assign(Iupac & target, Dna const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1249) -inline void assign(Iupac & target, Dna5 const & source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1256) -inline void assign(AminoAcid & target, Byte c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1267) -inline void assign(AminoAcid & target, Ascii c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1276) -inline void assign(AminoAcid & target, Unicode c_source); // "projects/library/seqan/basic/basic_alphabet_simple.h"(1285) -template inline void assign(TTarget & target, TSource & source); // "projects/library/seqan/basic/basic_transport.h"(52) -template inline void assign(TTarget & target, TSource const & source); // "projects/library/seqan/basic/basic_transport.h"(60) -template inline void assign(Proxy & target, TSource & source); // "projects/library/seqan/basic/basic_transport.h"(73) -template inline void assign(Proxy & target, TSource const & source); // "projects/library/seqan/basic/basic_transport.h"(82) -template inline void assign(Iter & target, TSource const & source); // "projects/library/seqan/basic/basic_iterator_position.h"(440) -template inline void assign(Holder & target_, Holder const & source_); // "projects/library/seqan/basic/basic_holder.h"(554) -template inline void assign(Holder & target_, Holder const & source_); // "projects/library/seqan/basic/basic_holder.h"(774) -template inline void assign(Holder & target_, Holder const & source_); // "projects/library/seqan/basic/basic_holder.h"(1091) -template inline void assign(Iter > & target, TSource const & source); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(514) -template inline void assign(Iter & target, TSource const & source); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(427) - -//____________________________________________________________________________ -// assignHost - -template inline void assignHost(T & me, THost & host_); // "projects/library/seqan/basic/basic_host.h"(135) -template inline void assignHost(T & me, THost const & host_); // "projects/library/seqan/basic/basic_host.h"(143) - -//____________________________________________________________________________ -// assignValue - -template inline void assignValue(Iter & me, TValue _value); // "projects/library/seqan/basic/basic_iterator_position.h"(184) -template inline void assignValue(Iter const & me, TValue _value); // "projects/library/seqan/basic/basic_iterator_position.h"(192) -template inline void assignValue(Holder & me, TSource const & value_); // "projects/library/seqan/basic/basic_holder.h"(512) -template inline void assignValue(Holder & me, TSource const & value_); // "projects/library/seqan/basic/basic_holder.h"(752) -template inline void assignValue(Holder & me, TSource const & value_); // "projects/library/seqan/basic/basic_holder.h"(1049) -template inline void assignValue(T & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator.h"(258) -template inline void assignValue(T const & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator.h"(268) -template inline void assignValue(Iter > & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(288) -template inline void assignValue(Iter > const & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(296) -template inline void assignValue(Iter & me, TValue & val); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(165) -template inline void assignValue(Iter & me, TValue const & val); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(172) - -//____________________________________________________________________________ -// assignValueAt - -template inline TSource & assignValueAt(TObject &me, TPos k, TSource &source); // "projects/library/seqan/basic/basic_aggregates.h"(442) -template inline TSource const & assignValueAt(TObject &me, TPos k, TSource const &source); // "projects/library/seqan/basic/basic_aggregates.h"(449) -template inline SSS const assignValueAt(Tuple &me, TPos k, SSS const source); // "projects/library/seqan/basic/basic_aggregates.h"(455) -template inline SSS const assignValueAt(Tuple &me, TPos k, SSS const source); // "projects/library/seqan/basic/basic_aggregates.h"(460) -template inline SimpleType const & assignValueAt(Tuple &me, TPos k, SimpleType const &source); // "projects/library/seqan/basic/basic_aggregates.h"(468) - -//____________________________________________________________________________ -// assignValueI1 - -template inline void assignValueI1(Pair &pair, T const &_i); // "projects/library/seqan/basic/basic_aggregates.h"(613) -template inline void assignValueI1(Pair > &pair, T const &_i); // "projects/library/seqan/basic/basic_aggregates.h"(624) -template inline T const assignValueI1(Triple &triple, T const &_i); // "projects/library/seqan/basic/basic_aggregates.h"(638) - -//____________________________________________________________________________ -// assignValueI2 - -template inline void assignValueI2(Pair &pair, T const &_i); // "projects/library/seqan/basic/basic_aggregates.h"(618) -template inline void assignValueI2(Pair > &pair, T const &_i); // "projects/library/seqan/basic/basic_aggregates.h"(631) -template inline T const assignValueI2(Triple &triple, T const &_i); // "projects/library/seqan/basic/basic_aggregates.h"(643) - -//____________________________________________________________________________ -// assignValueI3 - -template inline T const assignValueI3(Triple &triple, T const &_i); // "projects/library/seqan/basic/basic_aggregates.h"(648) - -//____________________________________________________________________________ -// atBegin - -template inline bool atBegin(T const & it, TContainer const & cont); // "projects/library/seqan/basic/basic_iterator.h"(394) -template inline bool atBegin(T const & it); // "projects/library/seqan/basic/basic_iterator.h"(404) - -//____________________________________________________________________________ -// atEnd - -template inline bool atEnd(T & it, TContainer const & cont); // "projects/library/seqan/basic/basic_iterator.h"(435) -template inline bool atEnd(T const & it, TContainer const & cont); // "projects/library/seqan/basic/basic_iterator.h"(443) -template inline bool atEnd(T & it); // "projects/library/seqan/basic/basic_iterator.h"(452) -template inline bool atEnd(T const & it); // "projects/library/seqan/basic/basic_iterator.h"(459) -template inline bool atEnd(Iter > & me); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(501) - -//____________________________________________________________________________ -// atNil - -template inline bool atNil(TIterator & me); // "projects/library/seqan/basic/basic_iterator.h"(714) -template inline bool atNil(TIterator * me); // "projects/library/seqan/basic/basic_iterator.h"(723) - -//____________________________________________________________________________ -// call_allocate - -template inline void call_allocate(TMe & me, TValue * & data, TSize const count); // "projects/library/seqan/basic/basic_allocator_to_std.h"(33) - -//____________________________________________________________________________ -// call_deallocate - -template inline void call_deallocate(TMe & me, TValue * data, TSize const count); // "projects/library/seqan/basic/basic_allocator_to_std.h"(38) - -//____________________________________________________________________________ -// clear - -template void clear(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(146) -template void clear(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(266) -template inline void clear(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(314) -template inline void clear(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(685) -template inline void clear(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(901) -template void clear(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_multipool.h"(125) -template void clear(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_simple.h"(126) -//template void clear(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(157) -template void clear(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(289) -template inline void clear(Tuple &me); // "projects/library/seqan/basic/basic_aggregates.h"(479) -template inline void clear(Tuple &me); // "projects/library/seqan/basic/basic_aggregates.h"(483) - -//____________________________________________________________________________ -// clearHost - -template inline void clearHost(T & me); // "projects/library/seqan/basic/basic_host.h"(59) - -//____________________________________________________________________________ -// container - -template inline typename Container::Type container(T me); // "projects/library/seqan/basic/basic_iterator.h"(328) - -//____________________________________________________________________________ -// convert - -template inline typename Convert::Type convert(TSource const & source); // "projects/library/seqan/basic/basic_converter.h"(110) - -//____________________________________________________________________________ -// convertImpl - -template inline typename _RemoveConst::Type convertImpl(Convert const, SimpleType const & source_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(247) -template inline typename Convert >::Type convertImpl(Convert const, Proxy & source); // "projects/library/seqan/basic/basic_proxy.h"(264) -template inline typename Convert const>::Type convertImpl(Convert const, Proxy const & source); // "projects/library/seqan/basic/basic_proxy.h"(271) -template inline typename Convert::Type convertImpl(Convert const, TSource & source); // "projects/library/seqan/basic/basic_converter.h"(78) -template inline typename Convert::Type convertImpl(Convert const, TSource const & source); // "projects/library/seqan/basic/basic_converter.h"(85) - -//____________________________________________________________________________ -// create - -template inline void create(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(361) -template inline void create(Holder & me, typename _Parameter::Type value_); // "projects/library/seqan/basic/basic_holder.h"(395) -template inline void create(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(694) -template inline void create(Holder & me, TValue const & value_); // "projects/library/seqan/basic/basic_holder.h"(704) -template inline void create(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(932) -template inline void create(Holder & me, TValue const & value_); // "projects/library/seqan/basic/basic_holder.h"(966) - -//____________________________________________________________________________ -// createHost - -template inline void createHost(T & me); // "projects/library/seqan/basic/basic_host.h"(69) -template inline void createHost(T & me, THost & host_); // "projects/library/seqan/basic/basic_host.h"(80) -template inline void createHost(T & me, THost const & host_); // "projects/library/seqan/basic/basic_host.h"(88) - -//____________________________________________________________________________ -// deallocate - -template inline void deallocate(Allocator > & me, TValue * data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(202) -template inline void deallocate(Allocator > & me, TValue2 * data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(290) -template inline void deallocate(Allocator > & me, TValue * data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_multipool.h"(207) -template inline void deallocate(Allocator > & me, TValue * data, TSize, Tag const); // "projects/library/seqan/basic/basic_allocator_simple.h"(181) -template inline void deallocate(T const & me, TValue * data, TSize const count); // "projects/library/seqan/basic/basic_allocator_interface.h"(198) -template inline void deallocate(T & me, TValue * data, TSize const count); // "projects/library/seqan/basic/basic_allocator_interface.h"(206) -template inline void deallocate(T const & , TValue * data, TSize count, Tag const); // "projects/library/seqan/basic/basic_allocator_interface.h"(216) -template inline void deallocate(T & , TValue * data, TSize count, Tag const); // "projects/library/seqan/basic/basic_allocator_interface.h"(227) -//template inline void deallocate(Allocator > & me, TValue * data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(222) -template inline void deallocate(Allocator > & me, TValue2 * data, TSize count, Tag const tag_); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(313) - -//____________________________________________________________________________ -// dependent - -template inline bool dependent(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(300) -template inline bool dependent(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(675) -template inline bool dependent(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(887) - -//____________________________________________________________________________ -// dependentHost - -template inline bool dependentHost(T const & me); // "projects/library/seqan/basic/basic_host.h"(49) - -//____________________________________________________________________________ -// detach - -template inline void detach(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(430) -template inline void detach(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(714) -template inline void detach(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(987) - -//____________________________________________________________________________ -// difference - -template inline typename Difference::Type difference( TIterator const & begin, TIterator const & end); // "projects/library/seqan/basic/basic_iterator.h"(657) - -//____________________________________________________________________________ -// empty - -template inline bool empty(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(288) -template inline bool empty(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(665) -template inline bool empty(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(875) - -//____________________________________________________________________________ -// emptyHost - -template inline bool emptyHost(T const & me); // "projects/library/seqan/basic/basic_host.h"(39) - -//____________________________________________________________________________ -// gapValue - -template inline T const & gapValue(); // "projects/library/seqan/basic/basic_alphabet_interface2.h"(71) - -//____________________________________________________________________________ -// gapValueImpl - -inline char const & gapValueImpl(char *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(400) -inline char const & gapValueImpl(char const *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(407) -template inline T const & gapValueImpl(T *); // "projects/library/seqan/basic/basic_alphabet_interface2.h"(48) - -//____________________________________________________________________________ -// getValue - -template typename GetValue >::Type getValue(Proxy & me); // "projects/library/seqan/basic/basic_proxy.h"(235) -template typename GetValue const>::Type getValue(Proxy const & me); // "projects/library/seqan/basic/basic_proxy.h"(241) -template inline typename GetValue::Type getValue(T & me); // "projects/library/seqan/basic/basic_iterator.h"(210) -template inline typename GetValue::Type getValue(T const & me); // "projects/library/seqan/basic/basic_iterator.h"(217) -template inline T & getValue(T * me); // "projects/library/seqan/basic/basic_iterator.h"(225) - -//____________________________________________________________________________ -// getValueI1 - -template inline T1 getValueI1(Pair const &pair); // "projects/library/seqan/basic/basic_aggregates.h"(572) -template inline T1 getValueI1(Pair > const &pair); // "projects/library/seqan/basic/basic_aggregates.h"(582) -template inline T1 getValueI1(Triple const &triple); // "projects/library/seqan/basic/basic_aggregates.h"(595) - -//____________________________________________________________________________ -// getValueI2 - -template inline T2 getValueI2(Pair const &pair); // "projects/library/seqan/basic/basic_aggregates.h"(577) -template inline T2 getValueI2(Pair > const &pair); // "projects/library/seqan/basic/basic_aggregates.h"(588) -template inline T2 getValueI2(Triple const &triple); // "projects/library/seqan/basic/basic_aggregates.h"(600) - -//____________________________________________________________________________ -// getValueI3 - -template inline T3 getValueI3(Triple const &triple); // "projects/library/seqan/basic/basic_aggregates.h"(605) - -//____________________________________________________________________________ -// goBegin - -template inline void goBegin(TIterator & it, TContainer & container); // "projects/library/seqan/basic/basic_iterator.h"(488) -template inline void goBegin(TIterator & it); // "projects/library/seqan/basic/basic_iterator.h"(506) - -//____________________________________________________________________________ -// goEnd - -template inline void goEnd(TIterator & it, TContainer & container); // "projects/library/seqan/basic/basic_iterator.h"(536) -template inline void goEnd(TIterator & it, TContainer const & container); // "projects/library/seqan/basic/basic_iterator.h"(544) -template inline void goEnd(TIterator & it); // "projects/library/seqan/basic/basic_iterator.h"(552) - -//____________________________________________________________________________ -// goFurther - -template inline void goFurther(TIterator & it, TDiff steps); // "projects/library/seqan/basic/basic_iterator.h"(602) - -//____________________________________________________________________________ -// goNext - -template inline void goNext(Iter & me); // "projects/library/seqan/basic/basic_iterator_position.h"(295) -template inline void goNext(TIterator & it); // "projects/library/seqan/basic/basic_iterator.h"(576) -template inline void goNext(Iter > & me); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(355) -template inline void goNext(Iter & me); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(280) - -//____________________________________________________________________________ -// goNil - -template inline void goNil(TIterator & me); // "projects/library/seqan/basic/basic_iterator.h"(681) -template inline void goNil(TIterator * & me); // "projects/library/seqan/basic/basic_iterator.h"(689) - -//____________________________________________________________________________ -// goPrevious - -template inline void goPrevious(Iter & me); // "projects/library/seqan/basic/basic_iterator_position.h"(307) -template inline void goPrevious(TIterator & it); // "projects/library/seqan/basic/basic_iterator.h"(626) -template inline void goPrevious(Iter > & me); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(367) -template inline void goPrevious(Iter & me); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(292) - -//____________________________________________________________________________ -// host - -template inline typename Host::Type & host(T & me); // "projects/library/seqan/basic/basic_host.h"(117) -template inline typename Host::Type & host(T const & me); // "projects/library/seqan/basic/basic_host.h"(124) - -//____________________________________________________________________________ -// hostIterator - -template inline typename StdContainerIterator::Type & hostIterator(Iter & me); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(129) -template inline typename StdContainerIterator::Type const & hostIterator(Iter const & me); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(135) - -//____________________________________________________________________________ -// infimumValue - -template inline T const & infimumValue(); // "projects/library/seqan/basic/basic_alphabet_interface2.h"(169) - -//____________________________________________________________________________ -// infimumValueImpl - -template inline T const & infimumValueImpl(T *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(427) -inline float const & infimumValueImpl(float *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(666) -inline double const & infimumValueImpl(double *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(693) -inline long double const & infimumValueImpl(long double *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(720) - -//____________________________________________________________________________ -// length - -template inline unsigned length(Tuple const &); // "projects/library/seqan/basic/basic_aggregates.h"(428) - -//____________________________________________________________________________ -// lexLess - -template inline bool lexLess(SimpleType const &Left, SimpleType const &Right); // "projects/library/seqan/basic/basic_alphabet_simple.h"(948) -template inline bool lexLess(const TTT& Left, const TTT& Right); // "projects/library/seqan/basic/basic_compare.h"(52) - -//____________________________________________________________________________ -// log2 - -// projects/library/seqan/basic/basic_definition.h(322) -//template inline unsigned int log2(TTT v); - -//____________________________________________________________________________ -// memset - -template finline void memset(void* ptr, unsigned char c); // "projects/library/seqan/basic/basic_metaprogramming.h"(241) -template finline void memset(void* ptr); // "projects/library/seqan/basic/basic_metaprogramming.h"(287) - -//____________________________________________________________________________ -// move - -template inline void move(TTarget & target, TSource & source); // "projects/library/seqan/basic/basic_transport.h"(108) -template inline void move(TTarget const & target, TSource & source); // "projects/library/seqan/basic/basic_transport.h"(116) -template inline void move(TTarget & target, TSource const & source); // "projects/library/seqan/basic/basic_transport.h"(124) -template inline void move(TTarget const & target, TSource const & source); // "projects/library/seqan/basic/basic_transport.h"(132) - -//____________________________________________________________________________ -// moveHost - -template inline void moveHost(T & me, THost & host_); // "projects/library/seqan/basic/basic_host.h"(153) -template inline void moveHost(T & me, THost const & host_); // "projects/library/seqan/basic/basic_host.h"(161) - -//____________________________________________________________________________ -// moveValue - -template inline void moveValue(Iter & me, TValue _value); // "projects/library/seqan/basic/basic_iterator_position.h"(205) -template inline void moveValue(Iter const & me, TValue _value); // "projects/library/seqan/basic/basic_iterator_position.h"(213) -template inline void moveValue(Holder & me, TSource const & value_); // "projects/library/seqan/basic/basic_holder.h"(533) -template inline void moveValue(Holder & me, TSource const & value_); // "projects/library/seqan/basic/basic_holder.h"(763) -template inline void moveValue(Holder & me, TSource const & value_); // "projects/library/seqan/basic/basic_holder.h"(1070) -template inline void moveValue(T & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator.h"(297) -template inline void moveValue(T const & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator.h"(306) -template inline void moveValue(Iter > & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(309) -template inline void moveValue(Iter > const & me, TValue const & _value); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(317) -template inline void moveValue(Iter & me, TValue & val); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(184) -template inline void moveValue(Iter & me, TValue const & val); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(191) - -//____________________________________________________________________________ -// nukeCopies - -template inline void nukeCopies(TValue* &); // "projects/library/seqan/basic/basic_volatile_ptr.h"(152) -template inline void nukeCopies(VolatilePtr &ptr); // "projects/library/seqan/basic/basic_volatile_ptr.h"(155) - -//____________________________________________________________________________ -// operator!= - -template inline bool operator!= (SimpleType const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(594) -template inline bool operator!= (TLeft const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(605) -template inline bool operator!= (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(616) -template inline bool operator!= (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(628) -template inline bool operator!= (Proxy const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(638) -template inline bool operator!= (SimpleType const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(649) -template inline bool operator!= (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(239) -template inline bool operator!= (Proxy const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_proxy.h"(328) -template inline bool operator!= (TLeft const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(339) -template inline bool operator!= (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(350) -template inline bool operator!= (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(362) -template inline bool operator!= (Iter > const & left, Iter > const & right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(343) -template inline bool operator!=(Tuple const &_left, Tuple const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(503) -template inline bool operator!=(Pair const &_left, Pair const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(660) -template inline bool operator!=(Pair > const &_left, Pair > const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(669) -template inline bool operator!=(Triple const &_left, Triple const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(683) -template inline bool operator!= (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(216) - -//____________________________________________________________________________ -// operator* - -template inline typename Reference >::Type operator* (Iter & me); // "projects/library/seqan/basic/basic_iterator_base.h"(143) -template inline typename Reference const>::Type operator* (Iter const & me); // "projects/library/seqan/basic/basic_iterator_base.h"(150) - -//____________________________________________________________________________ -// operator+ - -template inline Iter operator+ (Iter const & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_position.h"(319) -template inline Iter operator+ (Iter const & left, int right); // "projects/library/seqan/basic/basic_iterator_position.h"(328) -template inline Iter operator+ (TIntegral left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(337) -template inline Iter operator+ (int left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(346) -template inline Iter > operator+ (Iter > const & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(380) -template inline Iter > operator+ (Iter > const & left, int right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(389) -template inline Iter > operator+ (TIntegral left, Iter > const & right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(398) -template inline Iter > operator+ (int left, Iter > const & right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(407) -template inline Iter operator+ (Iter const & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(305) -template inline Iter operator+ (Iter const & left, int right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(314) -template inline Iter operator+ (TIntegral left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(323) -template inline Iter operator+ (int left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(332) - -//____________________________________________________________________________ -// operator++ - -template inline SimpleType & operator++ (SimpleType & me); // "projects/library/seqan/basic/basic_alphabet_simple.h"(958) -template inline SimpleType operator++ (SimpleType & me, int); // "projects/library/seqan/basic/basic_alphabet_simple.h"(966) -template inline Iter const & operator++ (Iter & me); // "projects/library/seqan/basic/basic_iterator_base.h"(162) -template inline Iter const operator++ (Iter & me, int); // "projects/library/seqan/basic/basic_iterator_base.h"(171) - -//____________________________________________________________________________ -// operator+= - -template inline Iter & operator+= (Iter & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_position.h"(359) -template inline Iter & operator+= (Iter & left, int right); // "projects/library/seqan/basic/basic_iterator_position.h"(369) -template inline Iter > & operator+= (Iter > & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(420) -template inline Iter > & operator+= (Iter > & left, int right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(430) -template inline Iter & operator+= (Iter & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(345) -template inline Iter & operator+= (Iter & left, int right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(355) - -//____________________________________________________________________________ -// operator- - -template inline Iter operator- (Iter const & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_position.h"(383) -template inline Iter operator- (Iter const & left, int right); // "projects/library/seqan/basic/basic_iterator_position.h"(392) -template inline typename Difference::Type operator- (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(403) -template inline Iter > operator- (Iter > const & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(444) -template inline Iter > operator- (Iter > const & left, int right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(453) -template inline typename Difference > >::Type operator- (Iter > const & left, Iter > const & right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(464) -template inline Iter operator- (Iter const & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(369) -template inline Iter operator- (Iter const & left, int right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(378) -template inline typename Difference >::Type operator- (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(389) - -//____________________________________________________________________________ -// operator-- - -template inline SimpleType & operator-- (SimpleType & me); // "projects/library/seqan/basic/basic_alphabet_simple.h"(977) -template inline SimpleType operator-- (SimpleType & me, int); // "projects/library/seqan/basic/basic_alphabet_simple.h"(985) -template inline Iter const & operator-- (Iter & me); // "projects/library/seqan/basic/basic_iterator_base.h"(185) -template inline Iter const operator-- (Iter & me, int); // "projects/library/seqan/basic/basic_iterator_base.h"(194) - -//____________________________________________________________________________ -// operator-= - -template inline Iter & operator-= (Iter & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_position.h"(416) -template inline Iter & operator-= (Iter & left, int right); // "projects/library/seqan/basic/basic_iterator_position.h"(426) -template inline Iter > & operator-= (Iter > & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(477) -template inline Iter > & operator-= (Iter > & left, int right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(487) -template inline Iter & operator-= (Iter & left, TIntegral right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(402) -template inline Iter & operator-= (Iter & left, int right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(412) - -//____________________________________________________________________________ -// operator< - -template inline bool operator< (SimpleType const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(665) -template inline bool operator< (TLeft const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(676) -template inline bool operator< (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(687) -template inline bool operator< (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(699) -template inline bool operator< (Proxy const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(709) -template inline bool operator< (SimpleType const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(720) -template inline bool operator< (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(252) -template inline bool operator< (Proxy const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_proxy.h"(376) -template inline bool operator< (TLeft const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(387) -template inline bool operator< (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(398) -template inline bool operator< (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(410) -template inline bool operator<(Tuple const &_left, Tuple const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(491) -template inline bool operator< (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(229) - -//____________________________________________________________________________ -// operator<< - -template inline TStream & operator<< (TStream & stream, SimpleType const & data); // "projects/library/seqan/basic/basic_alphabet_simple.h"(262) -template inline TStream & operator<< (TStream & strm, Proxy & proxy); // "projects/library/seqan/basic/basic_proxy.h"(591) -template inline TStream & operator<< (TStream & strm, Proxy const & proxy); // "projects/library/seqan/basic/basic_proxy.h"(598) -template std::ostream& operator<<(std::ostream &out, Pair const &p); // "projects/library/seqan/basic/basic_aggregates.h"(148) -template std::ostream& operator<<(std::ostream &out, Triple const &t); // "projects/library/seqan/basic/basic_aggregates.h"(267) -template std::ostream& operator<<(std::ostream& out, Tuple const &a); // "projects/library/seqan/basic/basic_aggregates.h"(548) - -//____________________________________________________________________________ -// operator<= - -template inline bool operator<= (SimpleType const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(736) -template inline bool operator<= (TLeft const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(747) -template inline bool operator<= (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(758) -template inline bool operator<= (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(770) -template inline bool operator<= (Proxy const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(780) -template inline bool operator<= (SimpleType const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(791) -template inline bool operator<= (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(274) -template inline bool operator<= (Proxy const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_proxy.h"(423) -template inline bool operator<= (TLeft const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(434) -template inline bool operator<= (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(445) -template inline bool operator<= (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(457) -template inline bool operator<= (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(255) - -//____________________________________________________________________________ -// operator== - -template inline bool operator== (SimpleType const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(523) -template inline bool operator== (TLeft const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(534) -template inline bool operator== (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(545) -template inline bool operator== (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(557) -template inline bool operator== (Proxy const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(567) -template inline bool operator== (SimpleType const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(578) -template inline bool operator== (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(226) -template inline bool operator== (Proxy const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_proxy.h"(281) -template inline bool operator== (TLeft const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(292) -template inline bool operator== (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(303) -template inline bool operator== (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(315) -template inline bool operator== (Iter > const & left, Iter > const & right); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(330) -template inline bool operator==(Tuple const &_left, Tuple const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(499) -template inline bool operator==(Pair const &_left, Pair const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(656) -template inline bool operator==(Pair > const &_left, Pair > const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(665) -template inline bool operator==(Triple const &_left, Triple const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(677) -template inline bool operator== (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(203) - -//____________________________________________________________________________ -// operator> - -template inline bool operator> (SimpleType const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(808) -template inline bool operator> (TLeft const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(819) -template inline bool operator> (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(830) -template inline bool operator> (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(842) -template inline bool operator> (Proxy const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(852) -template inline bool operator> (SimpleType const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(863) -template inline bool operator> (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(261) -template inline bool operator> (Proxy const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_proxy.h"(471) -template inline bool operator> (TLeft const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(482) -template inline bool operator> (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(493) -template inline bool operator> (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(505) -template inline bool operator>(Tuple const &_left, Tuple const &_right); // "projects/library/seqan/basic/basic_aggregates.h"(495) -template inline bool operator> (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(242) - -//____________________________________________________________________________ -// operator>= - -template inline bool operator>= (SimpleType const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(879) -template inline bool operator>= (TLeft const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(890) -template inline bool operator>= (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(901) -template inline bool operator>= (SimpleType const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(913) -template inline bool operator>= (Proxy const & left_, SimpleType const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(923) -template inline bool operator>= (SimpleType const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_alphabet_simple.h"(934) -template inline bool operator>= (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_position.h"(283) -template inline bool operator>= (Proxy const & left_, TRight const & right_); // "projects/library/seqan/basic/basic_proxy.h"(519) -template inline bool operator>= (TLeft const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(530) -template inline bool operator>= (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(541) -template inline bool operator>= (Proxy const & left_, Proxy const & right_); // "projects/library/seqan/basic/basic_proxy.h"(553) -template inline bool operator>= (Iter const & left, Iter const & right); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(268) - -//____________________________________________________________________________ -// operator>> - -template inline TStream & operator>> (TStream & stream, SimpleType & data); // "projects/library/seqan/basic/basic_alphabet_simple.h"(274) -template inline TStream & operator>> (TStream & strm, Proxy & proxy); // "projects/library/seqan/basic/basic_proxy.h"(565) -template inline TStream & operator>> (TStream & strm, Proxy const& proxy); // "projects/library/seqan/basic/basic_proxy.h"(577) - -//____________________________________________________________________________ -// parentAllocator - -template inline TParentAllocator & parentAllocator(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(136) -template inline TParentAllocator & parentAllocator(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_singlepool.h"(256) -template inline TParentAllocator & parentAllocator(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_multipool.h"(115) -template inline TParentAllocator & parentAllocator(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_simple.h"(103) -//template inline TParentAllocator & parentAllocator(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(147) -template inline TParentAllocator & parentAllocator(Allocator > & me); // "projects/library/seqan/basic/basic_allocator_chunkpool.h"(279) - -//____________________________________________________________________________ -// position - -template inline typename Position const>::Type position(Iter const & me, TContainer2 const &); // "projects/library/seqan/basic/basic_iterator_base.h"(211) -template inline typename Position::Type position(T * me); // "projects/library/seqan/basic/basic_iterator.h"(354) -template inline typename Position::Type position(TIterator const & it, TContainer const & me); // "projects/library/seqan/basic/basic_iterator.h"(363) -template inline typename Position const>::Type position(Iter const & me, TContainer2 const & cont); // "projects/library/seqan/basic/basic_iterator_simple.h"(108) -template inline typename Position > const>::Type position(Iter > const & me); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(232) -template inline typename Position > const>::Type position(Iter > const & me, TContainer2 const &); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(243) - -//____________________________________________________________________________ -// releaseRef - -template inline void releaseRef(T & ); // "projects/library/seqan/basic/basic_holder.h"(73) -template inline void releaseRef(T const & ); // "projects/library/seqan/basic/basic_holder.h"(79) - -//____________________________________________________________________________ -// set - -template inline void set(TTarget & target, TSource & source); // "projects/library/seqan/basic/basic_transport.h"(160) -template inline void set(TTarget const & target, TSource & source); // "projects/library/seqan/basic/basic_transport.h"(168) -template inline void set(TTarget & target, TSource const & source); // "projects/library/seqan/basic/basic_transport.h"(176) -template inline void set(TTarget const & target, TSource const & source); // "projects/library/seqan/basic/basic_transport.h"(184) - -//____________________________________________________________________________ -// setHost - -template inline void setHost(T & me, THost & host_); // "projects/library/seqan/basic/basic_host.h"(99) -template inline void setHost(T & me, THost const & host_); // "projects/library/seqan/basic/basic_host.h"(107) - -//____________________________________________________________________________ -// setPosition - -template inline void setPosition(Iter > & me, TPosition pos_); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(256) - -//____________________________________________________________________________ -// setValue - -template inline void setValue(Holder & me, typename _Parameter::Type value_); // "projects/library/seqan/basic/basic_holder.h"(453) -template inline void setValue(Holder & me, TValue2 const & value_); // "projects/library/seqan/basic/basic_holder.h"(467) -template inline void setValue(Holder & me, TValue const & value_); // "projects/library/seqan/basic/basic_holder.h"(724) -template inline void setValue(Holder & me, TValue & value_); // "projects/library/seqan/basic/basic_holder.h"(999) - -//____________________________________________________________________________ -// shiftLeft - -template inline void shiftLeft(Tuple &me); // "projects/library/seqan/basic/basic_aggregates.h"(525) -template inline void shiftLeft(Tuple &me); // "projects/library/seqan/basic/basic_aggregates.h"(535) - -//____________________________________________________________________________ -// shiftRight - -template inline void shiftRight(Tuple &me); // "projects/library/seqan/basic/basic_aggregates.h"(530) -template inline void shiftRight(Tuple &me); // "projects/library/seqan/basic/basic_aggregates.h"(540) - -//____________________________________________________________________________ -// supremumValue - -template inline T const & supremumValue(); // "projects/library/seqan/basic/basic_alphabet_interface2.h"(120) - -//____________________________________________________________________________ -// supremumValueImpl - -template inline T const & supremumValueImpl(T *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(420) -inline float const & supremumValueImpl(float *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(655) -inline double const & supremumValueImpl(double *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(682) -inline long double const & supremumValueImpl(long double *); // "projects/library/seqan/basic/basic_alphabet_trait_basic.h"(709) - -//____________________________________________________________________________ -// value - -template inline typename Reference >::Type value(Iter & me); // "projects/library/seqan/basic/basic_iterator_position.h"(164) -template inline typename Reference >::Type value(Iter const & me); // "projects/library/seqan/basic/basic_iterator_position.h"(171) -template inline typename Reference >::Type value(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(479) -template inline typename Reference const>::Type value(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(496) -template inline typename Reference >::Type value(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(734) -template inline typename Reference const>::Type value(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(741) -template inline typename Reference >::Type value(Holder & me); // "projects/library/seqan/basic/basic_holder.h"(1016) -template inline typename Reference const>::Type value(Holder const & me); // "projects/library/seqan/basic/basic_holder.h"(1033) -template inline typename Reference::Type value(T & me); // "projects/library/seqan/basic/basic_iterator.h"(171) -template inline typename Reference::Type value(T const & me); // "projects/library/seqan/basic/basic_iterator.h"(178) -template inline T & value(T * me); // "projects/library/seqan/basic/basic_iterator.h"(187) -template inline typename Reference > >::Type value(Iter > & me); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(268) -template inline typename Reference > const>::Type value(Iter > const & me); // "projects/library/seqan/basic/basic_iterator_adaptor.h"(275) -template inline typename Reference >::Type value(Iter & me); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(146) -template inline typename Reference const>::Type value(Iter const & me); // "projects/library/seqan/basic/basic_iterator_adapt_std.h"(152) - -//____________________________________________________________________________ -// valueConstruct - -template inline void valueConstruct(TIterator it); // "projects/library/seqan/basic/basic_alphabet_interface.h"(145) -template inline void valueConstruct(TIterator it, TParam const & param_); // "projects/library/seqan/basic/basic_alphabet_interface.h"(165) -template inline void valueConstruct(TIterator it, TParam const & param_, Move tag); // "projects/library/seqan/basic/basic_alphabet_interface.h"(186) - -//____________________________________________________________________________ -// valueConstructMove - -template inline void valueConstructMove(TIterator it, TValue const & value); // "projects/library/seqan/basic/basic_alphabet_interface.h"(248) - -//____________________________________________________________________________ -// valueDestruct - -template inline void valueDestruct(TIterator it); // "projects/library/seqan/basic/basic_alphabet_interface.h"(216) - -} //namespace SEQAN_NAMESPACE_MAIN - -//____________________________________________________________________________ -// _compareBinaryFiles - -inline bool _compareBinaryFiles(char * file1, char * file2); // "projects/library/seqan/basic/basic_debug.h"(119) - -//____________________________________________________________________________ -// _compareTextFiles - -inline bool _compareTextFiles(char * file1, char * file2); // "projects/library/seqan/basic/basic_debug.h"(182) - -//____________________________________________________________________________ -// _compareTextFiles_readChar - -inline void _compareTextFiles_readChar(FILE * fl, char & c, bool & is_lb, bool & is_eof); // "projects/library/seqan/basic/basic_debug.h"(151) - -#endif - diff --git a/SeqAn-1.1/seqan/basic/basic_holder.h b/SeqAn-1.1/seqan/basic/basic_holder.h deleted file mode 100644 index df5a7916..00000000 --- a/SeqAn-1.1/seqan/basic/basic_holder.h +++ /dev/null @@ -1,1120 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_holder.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_HOLDER_H -#define SEQAN_HEADER_BASIC_HOLDER_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// -// addRef -////////////////////////////////////////////////////////////////////////////// -/** -.Function.addRef: -..summary:Called when dependency is added. -..cat:Dependent Objects -..signature:addRef(host) -..param.host:The host object. -..remarks.text:A call of this function denotes that a client object is about to become -dependent on $host$. -..remarks.text:The default behavior is: Do nothing. -..see:Class.Holder -*/ - -template -inline void -addRef(T & /*me*/) -{// general: do nothing -SEQAN_CHECKPOINT -} -template -inline void -addRef(T const & /*me*/) -{// general: do nothing -SEQAN_CHECKPOINT -} - -////////////////////////////////////////////////////////////////////////////// -// releaseRef -////////////////////////////////////////////////////////////////////////////// -/** -.Function.releaseRef: -..summary:Called when dependency is released. -..cat:Dependent Objects -..signature:releaseRef(host) -..param.host:The host object. -..remarks.text:A call of this function denotes that a former dependent client object -ceases to be dependent on $host$. -..remarks.text:The default behavior is: Do nothing. -..see:Class.Holder -..see:Function.addRef -*/ -template -inline void -releaseRef(T & /*me*/) -{// general: do nothing -SEQAN_CHECKPOINT -} -template -inline void -releaseRef(T const & /*me*/) -{// general: do nothing -SEQAN_CHECKPOINT -} - -////////////////////////////////////////////////////////////////////////////// -// Tags - -struct Simple; -struct Tristate; - - -////////////////////////////////////////////////////////////////////////////// -// Holder -////////////////////////////////////////////////////////////////////////////// - -/** -.Class.Holder: -..cat:Basic -..summary:Manages relationship to another object. -..signature:Holder -..param.TValue:Type of the managed object. -...metafunction:Metafunction.Value -..param.TSpec:The specializing type. -...metafunction:Metafunction.Spec -...default:$Tristate$ -..remarks.text:The main purpose of this class is to facilitate the handling of -member objects. If we want class $A$ to be dependent on or the owner of another object of class $B$, -then we add a data member of type $Holder$ to $A$. -$Holder$ offers some useful access functions, stores the kind of relationship between $A$ and $B$, -and executes all needed @Function.addRef@ and @Function.releaseRef@ calls. -*/ - -template -struct Holder; - - -////////////////////////////////////////////////////////////////////////////// -// METAFUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Value.param.T.type:Class.Holder - -template -struct Value< Holder > -{ - typedef typename _RemoveConst::Type Type; -}; -template -struct Value< Holder const> -{ - typedef typename _RemoveConst::Type Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Spec.param.T.type:Class.Holder - -template -struct Spec< Holder > -{ - typedef TSpec Type; -}; -template -struct Spec< Holder const> -{ - typedef TSpec Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Reference.param.T.type:Class.Holder - -template -struct Reference< Holder > -{ - typedef typename Value< Holder >::Type & Type; -}; -template -struct Reference< Holder const> -{ - typedef typename Value< Holder const>::Type & Type; -}; - - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -// Tristate Holder -////////////////////////////////////////////////////////////////////////////// -/** -.Spec.Tristate Holder -..cat:Holders -..summary:Holder that can be empty, dependent, or owner. -..signature:Holder -..param.TValue:Type of the managed object. -..general:Class.Holder -..remarks.text:A tristate holder $A$ that holds an object $B$ has one of the following states: -..remarks.text:- owner: $A$ is the owner of $B$. If $A$ is destroyed, $B$ will be destroyed automatically. -..remarks.text:- dependent: $A$ depends on $B$. $B$ should not be destroyed as long as $A$ is used. -..remarks.text:- empty: there is currently no object reference stored in the holder $A$. -..remarks.text:The state of the holder can be determined by @Function.empty@ and @Function.dependent@. -*/ - -template -struct Holder -{ -public: - enum EHolderState - { - EMPTY = 0, - OWNER = 1, - DEPENDENT = ~0 - }; - -// typedef typename _RemoveConst::Type TValue_NotConst; - typedef typename Value::Type THostValue; - - typename _Pointer::Type data_value; - EHolderState data_state; - -//____________________________________________________________________________ - -/** -.Memfunc.Holder: -..class:Class.Holder -..summary:Constructor -..signature:Holder () -..signature:Holder (holder) -..signature:Holder (value) -..param.holder:Another holder object. -..param.value:An object of type $TValue$. -..remarks.text: -The default constructor creates a holder that is in state 'empty'. -If a $value$ is passed to the constructor, the holder will be in state 'dependent'. -*/ - - Holder(): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - } - Holder(Holder const & source_): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - assign(*this, source_); - } - Holder(typename _Parameter::Type value_): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - setValue(*this, value_); - } - Holder(typename _ConstParameter::Type value_): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - assignValue(*this, value_); - } - -/** -.Memfunc.~Holder: -..class:Class.Holder -..summary:Destructor -..signature:~Holder() -..remarks.text: -If the holder is in state 'owner', the holded object will be destoyed too. -*/ - ~Holder() - { -SEQAN_CHECKPOINT - clear(*this); - } - -//____________________________________________________________________________ - - Holder const & - operator = (Holder const & source_) - { -SEQAN_CHECKPOINT - assign(*this, source_); - return *this; - } - - Holder const & - operator = (typename _ConstParameter::Type value_) - { -SEQAN_CHECKPOINT - assignValue(*this, value_); - return *this; - } - - operator typename _Parameter::Type() - { -SEQAN_CHECKPOINT - return *data_value; - } -//____________________________________________________________________________ - -}; - -////////////////////////////////////////////////////////////////////////////// -// FUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -///.Function.empty.param.object.type:Class.Holder - -template -inline bool -empty(Holder const & me) -{ -SEQAN_CHECKPOINT - return (me.data_state == Holder::EMPTY); -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.dependent.param.object.type:Class.Holder - -template -inline bool -dependent(Holder const & me) -{ -SEQAN_CHECKPOINT - return (me.data_state == Holder::DEPENDENT); -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.clear.param.object.type:Class.Holder -///.Function.clear.remarks.text:If $clear$ is applied on a @Class.Holder@ object, -///the state of this object is set to 'empty'. - -template -inline void -clear(Holder & me) -{ - switch (me.data_state) - { - case Holder::EMPTY: - break; - - case Holder::DEPENDENT: - { -SEQAN_CHECKPOINT - releaseRef(_toParameter(me.data_value)); - me.data_state = Holder::EMPTY; - } - break; - - default: /*Holder::OWNER*/ - { -SEQAN_CHECKPOINT - valueDestruct(me.data_value); - deallocate(me, me.data_value, 1); - me.data_state = Holder::EMPTY; - } - break; - } -} - -////////////////////////////////////////////////////////////////////////////// -/** -.Function.create: -..summary:Makes an object to owner of its content. -..cat:Dependent Objects -..signature:create(holder [, object]) -..param.holder:A holder object. -...type:Class.Holder -..param.object:Object from which a copy is made and stored in $holder$. (optional) -...type:Metafunction.Value.Value::Type -..remarks.text:After this operation, $holder$ will be in state 'owner'. -If $object$ is specified, $holder$ will hold a copy of $object$ at the end of this function. -If $object$ is not specified, the action depends on the former state of $holder$: -..remarks.text:- If the state of $holder$ was 'empty', a new object is default constructed and stored into $holder$. -..remarks.text:- If the state of $holder$ was 'dependent', a copy of the former object is made and stored into $holder$. -..remarks.text:- If the state of $holder$ was already 'owner', nothing happens. -..see:Class.Holder -*/ - -template -inline void -create(Holder & me) -{ - typedef Holder THolder; - - switch (me.data_state) - { - case Holder::EMPTY: - { -SEQAN_CHECKPOINT - allocate(me, me.data_value, 1); - valueConstruct(me.data_value); - me.data_state = THolder::OWNER; - } - break; - - case THolder::DEPENDENT: - { -SEQAN_CHECKPOINT - typename _Parameter::Type old_value = value(me); - allocate(me, me.data_value, 1); - valueConstruct(me.data_value, old_value); - me.data_state = THolder::OWNER; - releaseRef(old_value); - } - break; - default:; - } -} - -//____________________________________________________________________________ - -template -inline void -create(Holder & me, - typename _Parameter::Type value_) -{ -SEQAN_CHECKPOINT - - if (me.data_state == Holder::OWNER) - { - assign(_toParameter(me.data_value), value_); - return; - } - - clear(me); - allocate(me, me.data_value, 1); - valueConstruct(me.data_value, value_); - me.data_state = Holder::OWNER; -} - -////////////////////////////////////////////////////////////////////////////// -/** -.Function.detach: -..summary:Makes an object independent from other objects. -..cat:Dependent Objects -..signature:detach(object) -..param.object:An object. -...type:Class.Holder -..remarks: -After this function, $object$ does not depends from any other entity outside of $object$, -like a @Function.source@ or a @Function.host@, and @Function.dependent.dependent(object)@ returns $false$ -..see:Function.source -..see:Function.host -..see:Function.createSource -..see:Function.create -*/ - -template -inline void -detach(Holder & me) -{ -SEQAN_CHECKPOINT - create(me); -} - -////////////////////////////////////////////////////////////////////////////// -/** -.Function.setValue: -..cat:Content Manipulation -..summary:Makes holder dependent. -..signature:setValue(holder, object) -..param.holder:A holder object. -...type:Class.Holder -..param.object:Object from which $holder$ will be dependent. -...type:Metafunction.Value.Value::Type -..remarks.text:After this operation, $holder$ will be dependent in state 'dependent'. -..see:Class.Holder -*/ - -template -inline void -setValue(Holder & me, - typename _Parameter::Type value_) -{ -SEQAN_CHECKPOINT - typedef typename Value >::Type THolderType; - - clear(me); - me.data_value = _toPointer(value_); - me.data_state = Holder::DEPENDENT; - addRef(_toParameter(me.data_value)); -} - -template -inline void -setValue(Holder & me, - TValue2 const & value_) -{ -SEQAN_CHECKPOINT - set(value(me), value_); -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.value.param.object.type:Class.Holder - -template -inline typename Reference >::Type -value(Holder & me) -{ -SEQAN_CHECKPOINT - typedef Holder THolder; - - if (empty(me)) - { - allocate(me, me.data_value, 1); - valueConstruct(me.data_value); - me.data_state = THolder::OWNER; - } - - typedef typename Value >::Type THolderType; - return _toParameter(me.data_value); -} -template -inline typename Reference const>::Type -value(Holder const & me) -{ -SEQAN_CHECKPOINT - SEQAN_ASSERT(!empty(me)); - - typedef typename Value >::Type THolderType; - return _toParameter(me.data_value); -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.assignValue.param.object.type:Class.Holder - -template -inline void -assignValue(Holder & me, - TSource const & value_) -{ -SEQAN_CHECKPOINT - typedef typename Value >::Type THostValue; - if (empty(me)) - { - create(me, value_); - } - else - { - assign(_toParameter(me.data_value), value_); - } -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.moveValue.param.object.type:Class.Holder - -template -inline void -moveValue(Holder & me, - TSource const & value_) -{ -SEQAN_CHECKPOINT - if (empty(me)) - { - create(me, value_); - } - else - { - move(value(me), value_); - } -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.assign.param.target.type:Class.Holder -///.Function.assign.param.source.type:Class.Holder - -template -inline void -assign(Holder & target_, - Holder const & source_) -{ -SEQAN_CHECKPOINT - switch(source_.data_state) - { - case Holder::EMPTY: - { - clear(target_); - } - break; - - case Holder::OWNER: - { - assignValue(target_, value(source_)); - } - break; - - default: /*case Holder::DEPENDENT*/ - { - setValue(target_, value(source_)); - } - break; - } -} - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -// Simple Holder -////////////////////////////////////////////////////////////////////////////// -//??? TODO: Documentation of Simple Holder - -template -struct Holder -{ - typedef typename Value::Type THolderValue; - typedef typename _Parameter::Type THolderParameter; - - mutable THolderValue data_value; -//____________________________________________________________________________ - - Holder() - { -SEQAN_CHECKPOINT - } - Holder(Holder & source_): - data_value(source_.data_value) - { -SEQAN_CHECKPOINT - } - Holder(Holder const & source_): - data_value(source_.data_value) - { -SEQAN_CHECKPOINT - } - template - Holder(TSource & value_): - data_value(value_) - { -SEQAN_CHECKPOINT - } - template - Holder(TSource const & value_): - data_value(value_) - { -SEQAN_CHECKPOINT - } -/* - Holder(TValue const & value_): - data_value(value_) - { -SEQAN_CHECKPOINT - } -*/ - ~Holder() - { -SEQAN_CHECKPOINT - } - -//____________________________________________________________________________ - - Holder const & - operator = (Holder const & source_) - { -SEQAN_CHECKPOINT - data_value = source_.data_value; - return *this; - } - - Holder const & - operator = (THolderValue const & value_) - { -SEQAN_CHECKPOINT - data_value = value_; - return *this; - } - - operator THolderParameter() - { -SEQAN_CHECKPOINT - return *data_value; - } -//____________________________________________________________________________ -}; - - -////////////////////////////////////////////////////////////////////////////// -// FUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -empty(Holder const & me) -{ -SEQAN_CHECKPOINT - return false; -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -dependent(Holder const & me) -{ -SEQAN_CHECKPOINT - return false; -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -clear(Holder & me) -{ -SEQAN_CHECKPOINT -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -create(Holder & me) -{ -SEQAN_CHECKPOINT -} - -//____________________________________________________________________________ - -template -inline void -create(Holder & me, - TValue const & value_) -{ -SEQAN_CHECKPOINT - me.data_value = value_; -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -detach(Holder & me) -{ -SEQAN_CHECKPOINT -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -setValue(Holder & me, - TValue const & value_) -{ -SEQAN_CHECKPOINT - me.data_value = value_; -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Reference >::Type -value(Holder & me) -{ -SEQAN_CHECKPOINT - return me.data_value; -} -template -inline typename Reference const>::Type -value(Holder const & me) -{ -SEQAN_CHECKPOINT - return me.data_value; -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assignValue(Holder & me, - TSource const & value_) -{ -SEQAN_CHECKPOINT - assignValue(me.data_value, value_); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -moveValue(Holder & me, - TSource const & value_) -{ -SEQAN_CHECKPOINT - move(me.data_value, value_); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assign(Holder & target_, - Holder const & source_) -{ -SEQAN_CHECKPOINT - assignValue(target_, source_); -} - - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// - - - - -////////////////////////////////////////////////////////////////////////////// -// New Tristate Holder that works also on pointers -////////////////////////////////////////////////////////////////////////////// - -struct Tristate2; - -template -struct Holder -{ -public: - enum EHolderState - { - EMPTY = 0, - OWNER = 1, - DEPENDENT = ~0 - }; - - typedef typename Value::Type THostValue; - - TValue * data_value; - EHolderState data_state; - -//____________________________________________________________________________ - - Holder(): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - } - Holder(Holder const & source_): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - assign(*this, source_); - } - Holder(typename _Parameter::Type value_): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - setValue(*this, value_); - } - Holder(typename _ConstParameter::Type value_): - data_state(EMPTY) - { -SEQAN_CHECKPOINT - assignValue(*this, value_); - } - ~Holder() - { -SEQAN_CHECKPOINT - clear(*this); - } - -//____________________________________________________________________________ - - Holder const & - operator = (Holder const & source_) - { -SEQAN_CHECKPOINT - assign(*this, source_); - return *this; - } - - Holder const & - operator = (TValue const & value_) - { -SEQAN_CHECKPOINT - assignValue(*this, value_); - return *this; - } - - operator TValue &() - { -SEQAN_CHECKPOINT - return *data_value; - } -//____________________________________________________________________________ - -}; - -////////////////////////////////////////////////////////////////////////////// -// FUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -///.Function.empty.param.object.type:Class.Holder - -template -inline bool -empty(Holder const & me) -{ -SEQAN_CHECKPOINT - return (me.data_state == Holder::EMPTY); -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.dependent.param.object.type:Class.Holder - -template -inline bool -dependent(Holder const & me) -{ -SEQAN_CHECKPOINT - return (me.data_state == Holder::DEPENDENT); -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.clear.param.object.type:Class.Holder -///.Function.clear.remarks.text:If $clear$ is applied on a @Class.Holder@ object, -///the state of this object is set to 'empty'. - -template -inline void -clear(Holder & me) -{ - switch (me.data_state) - { - case Holder::EMPTY: - break; - - case Holder::DEPENDENT: - { -SEQAN_CHECKPOINT - releaseRef(*(me.data_value)); - me.data_state = Holder::EMPTY; - } - break; - - default: /*Holder::OWNER*/ - { -SEQAN_CHECKPOINT - valueDestruct(me.data_value); - deallocate(me, me.data_value, 1); - me.data_state = Holder::EMPTY; - } - break; - } -} - -////////////////////////////////////////////////////////////////////////////// - - -template -inline void -create(Holder & me) -{ - typedef Holder THolder; - - switch (me.data_state) - { - case Holder::EMPTY: - { -SEQAN_CHECKPOINT - allocate(me, me.data_value, 1); - valueConstruct(me.data_value); - me.data_state = THolder::OWNER; - } - break; - - case THolder::DEPENDENT: - { -SEQAN_CHECKPOINT - TValue & old_value = value(me); - allocate(me, me.data_value, 1); - valueConstruct(me.data_value, old_value); - me.data_state = THolder::OWNER; - releaseRef(old_value); - } - break; - default:; - } -} - -//____________________________________________________________________________ - -template -inline void -create(Holder & me, - TValue const & value_) -{ -SEQAN_CHECKPOINT - - if (me.data_state == Holder::OWNER) - { - assign(*(me.data_value), value_); - return; - } - - clear(me); - allocate(me, me.data_value, 1); - valueConstruct(me.data_value, value_); - me.data_state = Holder::OWNER; -} - -////////////////////////////////////////////////////////////////////////////// - - -template -inline void -detach(Holder & me) -{ -SEQAN_CHECKPOINT - create(me); -} - -////////////////////////////////////////////////////////////////////////////// - - -template -inline void -setValue(Holder & me, - TValue & value_) -{ -SEQAN_CHECKPOINT - typedef typename Value >::Type THolderType; - - clear(me); - me.data_value = & value_; - me.data_state = Holder::DEPENDENT; - addRef(value_); -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.value.param.object.type:Class.Holder - -template -inline typename Reference >::Type -value(Holder & me) -{ -SEQAN_CHECKPOINT - typedef Holder THolder; - - if (empty(me)) - { - allocate(me, me.data_value, 1); - valueConstruct(me.data_value); - me.data_state = THolder::OWNER; - } - - typedef typename Value >::Type THolderType; - return *(me.data_value); -} -template -inline typename Reference const>::Type -value(Holder const & me) -{ -SEQAN_CHECKPOINT - SEQAN_ASSERT(!empty(me)); - - return *(me.data_value); -} - - -////////////////////////////////////////////////////////////////////////////// - -///.Function.assignValue.param.object.type:Class.Holder - -template -inline void -assignValue(Holder & me, - TSource const & value_) -{ -SEQAN_CHECKPOINT - typedef typename Value >::Type THostValue; - if (empty(me)) - { - create(me, value_); - } - else - { - assign(*(me.data_value), value_); - } -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.moveValue.param.object.type:Class.Holder - -template -inline void -moveValue(Holder & me, - TSource const & value_) -{ -SEQAN_CHECKPOINT - if (empty(me)) - { - create(me, value_); - } - else - { - move(value(me), value_); - } -} - -////////////////////////////////////////////////////////////////////////////// - -///.Function.assign.param.target.type:Class.Holder -///.Function.assign.param.source.type:Class.Holder - -template -inline void -assign(Holder & target_, - Holder const & source_) -{ -SEQAN_CHECKPOINT - switch(source_.data_state) - { - case Holder::EMPTY: - { - clear(target_); - } - break; - - case Holder::OWNER: - { - assignValue(target_, value(source_)); - } - break; - - default: /*case Holder::DEPENDENT*/ - { - setValue(target_, value(source_)); - } - break; - } -} -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... - - diff --git a/SeqAn-1.1/seqan/basic/basic_host.h b/SeqAn-1.1/seqan/basic/basic_host.h deleted file mode 100644 index a1a72319..00000000 --- a/SeqAn-1.1/seqan/basic/basic_host.h +++ /dev/null @@ -1,171 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_host.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_HOST_H -#define SEQAN_HEADER_BASIC_HOST_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// - -////////////////////////////////////////////////////////////////////////////// -// Host Functions -////////////////////////////////////////////////////////////////////////////// -//these functions assume that the hosted object exports a function "_dataHost" -//that returns a reference to a holder type of Host::Type & - -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -emptyHost(T const & me) -{ -SEQAN_CHECKPOINT - return empty(_dataHost(me)); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -dependentHost(T const & me) -{ -SEQAN_CHECKPOINT - return dependent(_dataHost(me)); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -clearHost(T & me) -{ -SEQAN_CHECKPOINT - clear(_dataHost(me)); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -createHost(T & me) -{ -SEQAN_CHECKPOINT - create(_dataHost(me)); -} - -//____________________________________________________________________________ - -template -inline void -createHost(T & me, - THost & host_) -{ -SEQAN_CHECKPOINT - create(_dataHost(me), host_); -} -template -inline void -createHost(T & me, - THost const & host_) -{ -SEQAN_CHECKPOINT - create(_dataHost(me), host_); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -setHost(T & me, - THost & host_) -{ -SEQAN_CHECKPOINT - setValue(_dataHost(me), host_); -} -template -inline void -setHost(T & me, - THost const & host_) -{ -SEQAN_CHECKPOINT - setValue(_dataHost(me), host_); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Host::Type & -host(T & me) -{ -SEQAN_CHECKPOINT - return value(_dataHost(me)); -} -template -inline typename Host::Type & -host(T const & me) -{ -SEQAN_CHECKPOINT - return value(_dataHost(me)); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assignHost(T & me, - THost & host_) -{ -SEQAN_CHECKPOINT - assignValue(_dataHost(me), host_); -} -template -inline void -assignHost(T & me, - THost const & host_) -{ -SEQAN_CHECKPOINT - assignValue(_dataHost(me), host_); -} -////////////////////////////////////////////////////////////////////////////// - -template -inline void -moveHost(T & me, - THost & host_) -{ -SEQAN_CHECKPOINT - moveValue(_dataHost(me), host_); -} -template -inline void -moveHost(T & me, - THost const & host_) -{ -SEQAN_CHECKPOINT - moveValue(_dataHost(me), host_); -} - -////////////////////////////////////////////////////////////////////////////// -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... - - diff --git a/SeqAn-1.1/seqan/basic/basic_iterator.h b/SeqAn-1.1/seqan/basic/basic_iterator.h deleted file mode 100644 index 9ccc0ddb..00000000 --- a/SeqAn-1.1/seqan/basic/basic_iterator.h +++ /dev/null @@ -1,732 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_iterator.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ITERATOR_H -#define SEQAN_HEADER_BASIC_ITERATOR_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// TAGS -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Iterator Spec: -..summary:Specifies the kind of an iterator. -..tag.Rooted:Rooted iterator. -...remarks -....text:This iterator implements some more advanced functions like -@Function.container@ and @Function.position@. -....concept:Concept.Rooted Iterator -..tag.Standard:Standard conform iterator. -...remarks -....text:Note that standard iterators need not to implement all functions -that are available for rooted iterators. -....concept:Concept.Iterator -..remarks.text:The default iterator spec is given by @Metafunction.DefaultIteratorSpec@. -..see:Metafunction.DefaultIteratorSpec -..see:Concept.Iterator -*/ - -struct TagRooted_; -typedef Tag const Rooted; - -struct TagStandard_; -typedef Tag const Standard; - - -////////////////////////////////////////////////////////////////////////////// -// METAFUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -/** -.Metafunction.DefaultIteratorSpec: -..hidefromindex -..summary:Specifies default kind of iterator. -..signature:DefaultIteratorSpec::Type -..param.T:Container type for which the default iterator spec is determined. -...concept:Concept.Container -..returns.param.Type:Iterator spec of $T$. -..see:Metafunction.Iterator -*/ - -template -struct DefaultIteratorSpec -{ - typedef Standard Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Metafunction.DefaultGetIteratorSpec: -..hidefromindex -..summary:Specifies default kind of iterator returned by functions. -..signature:DefaultGetIteratorSpec::Type -..param.T:Container type for which the spec is determined. -...concept:Concept.Container -..returns.param.Type:Iterator spec of $T$. -..remarks:This metafunction returns the iterator spec of iterators that are returned by functions like -@Function.begin@, @Function.end@, or @Function.iter@. -..see:Metafunction.Iterator -..see:Metafunction.DefaultIteratorSpec -*/ - -template -struct DefaultGetIteratorSpec -{ - typedef Rooted Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Metafunction.Iterator: -..summary:Type of iterator objects that are used to traverse the container. -..signature:Iterator::Type -..param.T:Type for which the iterator type is determined. -...concept:Concept.Container -...type:Class.Iter -..param.TSpec:Specifies an @Tag.Iterator Spec.iterator spec@. -...default:The default iterator spec is given by @Metafunction.DefaultIteratorSpec@. -..returns.param.Type:Iterator type of $T$. -..remarks.text:Iterators behave like pointers in some respects. - For example, you can use $*it$ to access the value object the iterator $it$ points to. - But note that $Iterator::Type$ can differ from $T *$, depending on $T$. -..see:Metafunction.Position -*/ - -//____________________________________________________________________________ - -template -struct Iterator_Default_Imp; - -//Iterator_Default_Imp is implemented in basic_iterator_simple.h -//Iterator_Default_Imp is implemented in basic_iterator_adaptor.h - -//____________________________________________________________________________ - -template ::Type> -struct Iterator: - Iterator_Default_Imp -{ -}; - - -////////////////////////////////////////////////////////////////////////////// - -/** -.Metafunction.Container: -..summary:Type of the container given an iterator. -..signature:Container::Type -..param.T:Iterator type. -...type:Class.Iter -...concept:Concept.Iterator -..returns.param.Type:The container type to $T$. -*/ - -template -struct Container -{ - typedef T Type; -}; - - -////////////////////////////////////////////////////////////////////////////// -// GENERAL FUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -////////////////////////////////////////////////////////////////////////////// -// value -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.value: -..signature:Reference value(object) -..param.object:An object that holds a value or an iterator that points to a value. -...type:Class.Iter -...concept:Concept.Iterator -*/ - -template -inline typename Reference::Type -value(T & me) -{ -SEQAN_CHECKPOINT - return *me; -} -template -inline typename Reference::Type -value(T const & me) -{ -SEQAN_CHECKPOINT - return *me; -} - - -template -inline T & -value(T * me) -{ -SEQAN_CHECKPOINT - return *me; -} - -////////////////////////////////////////////////////////////////////////////// -// getValue -////////////////////////////////////////////////////////////////////////////// - -//unary getValue -/** -.Function.getValue: -..cat:Iteration -..signature:GetValue getValue(object) -..param.object:An object that holds a value or points to a value. -...type:Class.Iter -...concept:Concept.Iterator -..see:Metafunction.GetValue -*/ - -template -inline typename GetValue::Type -getValue(T & me) -{ -SEQAN_CHECKPOINT - return value(me); -} -template -inline typename GetValue::Type -getValue(T const & me) -{ -SEQAN_CHECKPOINT - return value(me); -} - -template -inline T & -getValue(T * me) -{ -SEQAN_CHECKPOINT - return value(me); -} - -////////////////////////////////////////////////////////////////////////////// -//toGetValue -////////////////////////////////////////////////////////////////////////////// -//Nimmt eine Reference und macht daraus einen GetValue -//???TODO toGetValue() - -////////////////////////////////////////////////////////////////////////////// -// assignValue -////////////////////////////////////////////////////////////////////////////// -/** -.Function.assignValue: -..cat:Iteration -..summary:Assigns value to item. -..signature:assignValue(object, value) -..param.object:An object that holds a value or points to a value. -...type:Class.Iter -...concept:Concept.Iterator -..param.value:A value that is assigned to the item $object$ holds or points to. -..remarks.text:This function is similar to @Function.assign@. -The difference is, that $assignValue$ just changes a value stored in $object$ or the value $object$ points to, -while @Function.assign@ changes the whole object. -..see:Function.assign -*/ - -template -inline void -assignValue(T & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - assign(value(me), _value); -} - -//const version for iterators as targets -template -inline void -assignValue(T const & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - assign(value(me), _value); -} - -////////////////////////////////////////////////////////////////////////////// -// moveValue -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.moveValue: -..cat:Iteration -..summary:Assigns value to item. -..signature:moveValue(object, value) -..param.object:An object that holds a value or points to a value. -...type:Class.Iter -...concept:Concept.Iterator -..param.value:A value that is handed over to the item $object$ holds or points to. -..remarks.text:This function is similar to @Function.move@. -The difference is, that $moveValue$ just changes a value stored in $object$ or the value $object$ points to, -while @Function.move@ changes the whole object. -..see:Function.move -..see:Function.assignValue -*/ - -template -inline void -moveValue(T & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - move(value(me), _value); -} -//const version for iterators as targets -template -inline void -moveValue(T const & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - move(value(me), _value); -} - -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.container: -..cat:Iteration -..summary:Container of an iterator. -..signature:Container container(iterator) -..param.iterator:An iterator. -...type:Class.Iter -...concept:Concept.Rooted Iterator -..returns:The container that $iterator$ traverses. -...metafunction:Metafunction.Container -*/ - -template -inline typename Container::Type -container(T me) -{ -SEQAN_CHECKPOINT - return me; -} - -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.position: -..summary:Position of an iterator. -..cat:Iteration -..signature:Position position(iterator [, container]) -..param.iterator:An iterator. -...type:Class.Iter -...concept:Concept.Iterator -..param.container:A container. -...concept:Concept.Container -...remarks:If $iterator$ implements @Concept.Rooted Iterator@, then $container$ is optional. -...remarks:If $container$ is specified, $iterator$ must be a container of $container$. -..returns:The position of the value in the container $iterator$ points to. -...metafunction:Metafunction.Position -*/ - -template -inline typename Position::Type -position(T * me) -{ -SEQAN_CHECKPOINT - return 0; -} - -template -inline typename Position::Type -position(TIterator const & it, - TContainer const & me) -{ -SEQAN_CHECKPOINT - return it - begin(me, Standard()); -} - -////////////////////////////////////////////////////////////////////////////// - - -////////////////////////////////////////////////////////////////////////////// -// atBegin -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.atBegin: -..cat:Iteration -..summary:Determines whether an iterator is at the beginning position. -..signature:bool atBegin(iterator [, container]) -..param.iterator:An iterator. -...type:Class.Iter -...concept:Concept.Iterator -..param.container:Container of $iterator$. (optional) -...remarks.text:If $iterator$ implements @Concept.Rooted Iterator@ then $container$ is optional otherwise $container$ is required. -..returns:$true$ if $iterator$ points to the fist item of the container, otherwise $false$. -..see:Function.begin -*/ - -//TODO???: Was, wenn der Container leer ist? - -template -inline bool -atBegin(T const & it, TContainer const & cont) -{ -SEQAN_CHECKPOINT - return it == begin(cont, Standard()); -} - -//____________________________________________________________________________ - -template -inline bool -atBegin(T const & it) -{ -SEQAN_CHECKPOINT - return atBegin(it, container(it)); -} - - - -////////////////////////////////////////////////////////////////////////////// -// atEnd -////////////////////////////////////////////////////////////////////////////// -/** -.Function.atEnd: -..cat:Iteration -..summary:Determines whether an iterator is at the end position. -..signature:bool atEnd(iterator [, container]) -..param.iterator:An iterator. -...type:Class.Iter -...concept:Concept.Iterator -..param.container:Container of $iterator$. -...remarks.text:If $iterator$ implements @Concept.Rooted Iterator@ then $container$ is optional. -....text:$container$ is also optional for iterators to @Adaption.char array.char arrays@. -....text:Otherwise, $container$ is required. -..returns:$true$ if $iterator$ points behind the last item of the container, otherwise $false$. -..see:Function.atBegin -..see:Function.end -*/ - -template -inline bool -atEnd(T & it, - TContainer const & cont) -{ -SEQAN_CHECKPOINT - return it == end(cont, Standard()); -} -template -inline bool -atEnd(T const & it, - TContainer const & cont) -{ -SEQAN_CHECKPOINT - return it == end(cont, Standard()); -} -//____________________________________________________________________________ - -template -inline bool -atEnd(T & it) -{ -SEQAN_CHECKPOINT - return atEnd(it, container(it)); -} -template -inline bool -atEnd(T const & it) -{ -SEQAN_CHECKPOINT - return atEnd(it, container(it)); -} - -////////////////////////////////////////////////////////////////////////////// -// goBegin -////////////////////////////////////////////////////////////////////////////// -/** -.Function.goBegin: -..cat:Iteration -..summary:Iterates to the first position of a container. -..signature:goBegin(iterator [, container]) -..param.iterator:Object that iterates through $container$. -...type:Class.Iter -...concept:Concept.Iterator -...text:$iterator$ is set to the position of the first item in $container$. -..param.container:Container of $iterator$. -...remarks.text:If $iterator$ implements @Concept.Rooted Iterator@ then $container$ is optional, -otherwise $container$ is required. -..remarks:This function is equivalent to $iterator = begin(container)$. -..see:Function.begin -..see:Function.atBegin -..see:Function.goEnd -*/ -template -inline void -goBegin(TIterator & it, - TContainer & container) -{ -SEQAN_CHECKPOINT - it = begin(container); -} -/* -template -inline void -goBegin(TIterator & it, - TContainer const & container) -{ -SEQAN_CHECKPOINT - it = begin(container); -} -*/ - -template -inline void -goBegin(TIterator & it) -{ -SEQAN_CHECKPOINT - goBegin(it, container(it)); -} - -////////////////////////////////////////////////////////////////////////////// -// goEnd -////////////////////////////////////////////////////////////////////////////// -/** -.Function.goEnd: -..cat:Iteration -..summary:Iterates to the last position of a container. -..signature:goEnd(iterator [, container]) -..param.iterator:Object that iterates through $container$. -...type:Class.Iter -...concept:Concept.Iterator -...text:$iterator$ is set to the position behin the last item in $container$. -..param.container:Container of $iterator$. -...remarks.text:If $iterator$ implements @Concept.Rooted Iterator@ then $container$ is optional, -otherwise $container$ is required. -..remarks:This function is equivalent to $iterator = end(container)$. -..see:Function.end -..see:Function.atEnd -..see:Function.goBegin -..see:Function.goEnd -*/ -template -inline void -goEnd(TIterator & it, - TContainer & container) -{ -SEQAN_CHECKPOINT - it = end(container); -} -template -inline void -goEnd(TIterator & it, - TContainer const & container) -{ -SEQAN_CHECKPOINT - it = end(container); -} - -template -inline void -goEnd(TIterator & it) -{ -SEQAN_CHECKPOINT - goEnd(it, container(it)); -} - -////////////////////////////////////////////////////////////////////////////// -// goNext -////////////////////////////////////////////////////////////////////////////// -/** -.Function.goNext: -..cat:Iteration -..summary:Iterates to next position. -..signature:goNext(iterator) -..param.iterator:An iterator. -...type:Class.Iter -...concept:Concept.Iterator -...text:$iterator$ is set to the next position of an iteration through its container. -..remarks:This function is equivalent to $++iterator$. -..see:Function.goBegin -..see:Function.goEnd -*/ -template -inline void -goNext(TIterator & it) -{ -SEQAN_CHECKPOINT - ++it; -} - -////////////////////////////////////////////////////////////////////////////// -// goFurther -////////////////////////////////////////////////////////////////////////////// -/** -.Function.goFurther: -..cat:Iteration -..summary:Iterates some steps further. -..signature:goFurther(iterator, steps) -..param.iterator:An iterator. -...type:Class.Iter -...concept:Concept.Iterator -...text:$iterator$ is set $steps$ positions further in the iteration through the container. -..param.steps:Number of steps $iterator$ should be moved further. -...remarks:If $iterator$ supports bidirectional iteration, $steps$ could also be negativ. -..remarks:This function is equivalent to $iterator += steps$ for random access iterators. -..see:Function.goNext -..see:Function.goPrevious -*/ - -template inline -void goFurther(TIterator & it, TDiff steps) -{ // return distance type from arbitrary argument - it += steps; -} - -////////////////////////////////////////////////////////////////////////////// -// goPrevious -////////////////////////////////////////////////////////////////////////////// -/** -.Function.goPrevious: -..cat:Iteration -..summary:Iterates to pevious position. -..signature:goPrevious(iterator) -..param.iterator:An iterator. -...type:Class.Iter -...concept:Concept.Iterator -...text:$iterator$ is set to the pevious position of an iteration through its container. -..remarks:This function is equivalent to $--iterator$. -..see:Function.goBegin -..see:Function.goEnd -..see:Function.goNext -*/ -template -inline void -goPrevious(TIterator & it) -{ -SEQAN_CHECKPOINT - --it; -} - -////////////////////////////////////////////////////////////////////////////// -// difference -////////////////////////////////////////////////////////////////////////////// -/** -.Function.difference: -..cat:Iteration -..summary:The difference between two iterators. -..signature:difference(begin, end) -..param.begin:Iterator to the first position of a range. -...type:Class.Iter -...Concept.Iterator -..param.end:Iterator behind the last position of a range. -...type:Class.Iter -...Concept.Iterator -..returns:Length of the range between $begin$ and $end$. -..remarks:This function is equivalent to $begin - end$. -...text:Usually, $begin$ and $end$ have the same type. -..see:Function.begin -..see:Function.end -..see:Function.length -*/ - -template inline -typename Difference::Type difference( - TIterator const & begin, - TIterator const & end) -{ // return distance type from arbitrary argument -SEQAN_CHECKPOINT - return end - begin; -} - -////////////////////////////////////////////////////////////////////////////// -// goNil -////////////////////////////////////////////////////////////////////////////// - - -/** -.Function.goNil: -..cat:Iteration -..summary:Moves iterator to nil position. -..signature:goNil(iterator) -..param.iterator:The iterator that will be moved. -...type:Class.String -..remarks:$iterator$ is set to an invalid position, e.g. $NULL$ for pointer types. -..see:Function.clear -*/ - -template -inline void -goNil(TIterator & me) -{ -SEQAN_CHECKPOINT - me = TIterator(); -} - -template -inline void -goNil(TIterator * & me) -{ -SEQAN_CHECKPOINT - me = 0; -} - -////////////////////////////////////////////////////////////////////////////// -// atNil -////////////////////////////////////////////////////////////////////////////// - - -/** -.Function.atNil: -..cat:Iteration -..summary:Tests whether iterator is at nil position. -..signature:bool atNil(iterator) -..param.iterator:An iterator. -...type:Class.String -..returns:$true$ if $iterator$ points to an ivalid position, e.g. $iterator$ is a $NULL$ pointer. -$false$ otherwise. -..see:Function.goNil -*/ - -template -inline bool -atNil(TIterator & me) -{ -SEQAN_CHECKPOINT - return me == TIterator(); -} - - -template -inline bool -atNil(TIterator * me) -{ -SEQAN_CHECKPOINT - return me == 0; -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_iterator_adapt_std.h b/SeqAn-1.1/seqan/basic/basic_iterator_adapt_std.h deleted file mode 100644 index a39f23b0..00000000 --- a/SeqAn-1.1/seqan/basic/basic_iterator_adapt_std.h +++ /dev/null @@ -1,436 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_iterator_adapt_std.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ITERATOR_ADAPT_STD_H -#define SEQAN_HEADER_BASIC_ITERATOR_ADAPT_STD_H - -////////////////////////////////////////////////////////////////////////////// - -//adapt SeqAn iterator to std -namespace std -{ - template - struct iterator_traits > - { - typedef ::seqan::Iter TIter; - - typedef random_access_iterator_tag iterator_category; - typedef typename ::seqan::Value::Type value_type; - typedef typename ::seqan::Difference::Type difference_type; - typedef typename ::seqan::Value::Type * pointer; - typedef typename ::seqan::Reference::Type reference; - }; -} - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// - -namespace SEQAN_NAMESPACE_MAIN -{ - -//helper Metafunction - -/* This simple, general implementation cannot be used due to strange VC++ 2003 behavior - -template -struct StdContainerIterator -{ - typedef typename TStdContainer::iterator Type; -}; - -template -struct StdContainerIterator -{ - typedef typename TStdContainer::const_iterator Type; -}; -*/ - -//we use this instead: specialize StdContainerIterator for each std-container -template -struct StdContainerIterator -{ - typedef void * Type; //dummy, just to make VC++ 2003 happy -}; - -template -struct StdContainerIterator< ::std::basic_string > -{ - typedef ::std::basic_string TContainer; - typedef typename TContainer::iterator Type; -}; -template -struct StdContainerIterator< ::std::basic_string const> -{ - typedef ::std::basic_string TContainer; - typedef typename TContainer::const_iterator Type; -}; - -////////////////////////////////////////////////////////////////////////////// -//adapt std iterator to SeqAn - - -struct StdIteratorAdaptor; - -template -class Iter -{ -public: - typedef typename StdContainerIterator::Type TIterator; - TIterator data_iterator; - - Iter() {} - Iter(Iter const & other_): data_iterator(other_.data_iterator) {} - Iter(TIterator const & iter_): data_iterator(iter_) {} - Iter(TContainer const & cont_): data_iterator(begin(cont_)) {} - - Iter const & operator = (Iter const & other_) - { - data_iterator = other_.data_iterator; - return *this; - } - Iter const & operator = (TIterator const & iter_) - { - data_iterator = iter_; - return *this; - } - - operator TIterator &() - { - return data_iterator; - } - - ~Iter() {} -}; - -////////////////////////////////////////////////////////////////////////////// -// hostIterator -////////////////////////////////////////////////////////////////////////////// - -template -inline typename StdContainerIterator::Type & -hostIterator(Iter & me) -{ - return me.data_iterator; -} -template -inline typename StdContainerIterator::Type const & -hostIterator(Iter const & me) -{ - return me.data_iterator; -} - -////////////////////////////////////////////////////////////////////////////// -// value -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Reference >::Type -value(Iter & me) -{ - return *(me.data_iterator); -} -template -inline typename Reference const>::Type -value(Iter const & me) -{ - return *(me.data_iterator); -} - - -///////////////////////////////////////////////////////////////////////////// -// assignValue -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assignValue(Iter & me, - TValue & val) -{ - *(me.data_iterator) = val; -} -template -inline void -assignValue(Iter & me, - TValue const & val) -{ - *(me.data_iterator) = val; -} - -///////////////////////////////////////////////////////////////////////////// -// moveValue -////////////////////////////////////////////////////////////////////////////// - -template -inline void -moveValue(Iter & me, - TValue & val) -{ - move(*(me.data_iterator), val); -} -template -inline void -moveValue(Iter & me, - TValue const & val) -{ - move(*(me.data_iterator), val); -} - -////////////////////////////////////////////////////////////////////////////// -// operator == -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator == (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) == hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator != -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator != (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) != hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator < -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator < (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) < hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator > -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator > (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) > hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator <= -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator <= (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) <= hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator >= -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator >= (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) >= hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// goNext -////////////////////////////////////////////////////////////////////////////// - -template -inline void -goNext(Iter & me) -{ -SEQAN_CHECKPOINT - goNext(hostIterator(me)); -} - -////////////////////////////////////////////////////////////////////////////// -// goPrevious -////////////////////////////////////////////////////////////////////////////// - -template -inline void -goPrevious(Iter & me) -{ -SEQAN_CHECKPOINT - goPrevious(hostIterator(me)); -} - -////////////////////////////////////////////////////////////////////////////// -// operator + -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter -operator + (Iter const & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - return Iter(hostIterator(left) + right); -} -// for types -template -inline Iter -operator + (Iter const & left, - int right) -{ -SEQAN_CHECKPOINT - return Iter(hostIterator(left) + right); -} - -template -inline Iter -operator + (TIntegral left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return Iter(hostIterator(right) + left); -} -// for types -template -inline Iter -operator + (int left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return Iter(hostIterator(right) + left); -} - -////////////////////////////////////////////////////////////////////////////// -// operator += -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter & -operator += (Iter & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - hostIterator(left) += right; - return left; -} -// for types -template -inline Iter & -operator += (Iter & left, - int right) -{ -SEQAN_CHECKPOINT - hostIterator(left) += right; - return left; -} - -////////////////////////////////////////////////////////////////////////////// -// operator - -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter -operator - (Iter const & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - return Iter(hostIterator(left) - right); -} -// for types -template -inline Iter -operator - (Iter const & left, - int right) -{ -SEQAN_CHECKPOINT - return Iter(hostIterator(left) - right); -} - -//____________________________________________________________________________ - -template -inline typename Difference >::Type -operator - (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) - hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator -= -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter & -operator -= (Iter & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - hostIterator(left) -= right; - return left; -} -// for types -template -inline Iter & -operator -= (Iter & left, - int right) -{ -SEQAN_CHECKPOINT - hostIterator(left) -= right; - return left; -} - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -// assign (Conversion) -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assign(Iter & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - target.data_iterator = begin(container(source)) + position(source); -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_iterator_adaptor.h b/SeqAn-1.1/seqan/basic/basic_iterator_adaptor.h deleted file mode 100644 index 9a68a98b..00000000 --- a/SeqAn-1.1/seqan/basic/basic_iterator_adaptor.h +++ /dev/null @@ -1,524 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_iterator_adaptor.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ITERATOR_ADAPTOR_H -#define SEQAN_HEADER_BASIC_ITERATOR_ADAPTOR_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// Tag - -//An iterator that adapts a std iterator to a default seqan iterator -template -struct AdaptorIterator; - -////////////////////////////////////////////////////////////////////////////// - -template -struct Iterator_Default_Imp -{ - typedef typename Iterator::Type TStandardIterator; - typedef Iter > Type; -}; - -////////////////////////////////////////////////////////////////////////////// -// Adaptor Iterator -////////////////////////////////////////////////////////////////////////////// - -/** -.Spec.Adaptor Iterator: -..cat:Iterators -..general:Class.Iter -..summary:Adapts iterators to @Concept.Rooted Iterator@. -..signature:Iter > -..param.TContainer:Type of the container that can be iterated by $TIterator$. -...remarks:Use @Metafunction.Container@ to get the container type for a given iterator. -..param.TIterator:Type of the iterator that is adapted to @Concept.Rooted Iterator@. -..remarks.text:Adaptor iterators can implicitly converted to $TIterator$. -*/ - -template -class Iter > -{ -private: - typename _Pointer::Type data_container; - TIterator data_iterator; -//____________________________________________________________________________ - -/** -.Memfunc.AdaptorIterator#Iter: -..class:Spec.Adaptor Iterator -..summary:Constructor -..signature:Iter() -..signature:Iter(iter) -..signature:Iter(container [, iterator]) -..param.iter:Another adaptor iterator object. -..param.container:The corresponding container object. -..param.iterator:A iterator of $container$. (optional) -...remarks.text:If this argument is omitted, the adaptor iterator is initialized to the @Function.begin.begin iterator@ of $container$. -*/ - -public: - Iter(): - data_container(0) - { -SEQAN_CHECKPOINT - data_iterator = TIterator(); - } -/*//TODO: welches "begin" zur initialisierung von "data_iterator" aufrufen? - Iter(typename _Parameter::Type container_): - data_container(_toPointer(container_)), - data_iterator(begin(container_)) - { -SEQAN_CHECKPOINT - } -*/ - Iter(typename _Parameter::Type container_, TIterator it_): - data_container(_toPointer(container_)), - data_iterator(it_) - { -SEQAN_CHECKPOINT - } - Iter(Iter const & other_): - data_container(other_.data_container), - data_iterator(other_.data_iterator) - { -SEQAN_CHECKPOINT - } -/* - template - Iter(TSource & source) - { -SEQAN_CHECKPOINT - assign(*this, source); - } - template - Iter(TSource const & source) - { -SEQAN_CHECKPOINT - assign(*this, source); - } -*/ - - ~Iter() - { -SEQAN_CHECKPOINT - } - - Iter const & - operator = (Iter const & other_) - { -SEQAN_CHECKPOINT - data_container = other_.data_container; - data_iterator = other_.data_iterator; - return *this; - } -/* - template - Iter const & - operator = (TSource & source) - { -SEQAN_CHECKPOINT - assign(*this, source); - return *this; - } - template - Iter const & - operator = (TSource const & source) - { -SEQAN_CHECKPOINT - assign(*this, source); - return *this; - } -*/ -//____________________________________________________________________________ - - friend inline typename _Parameter::Type - container(Iter & me) - { -SEQAN_CHECKPOINT - return _toParameter(me.data_container); - } - friend inline typename _Parameter::Type - container(Iter const & me) - { -SEQAN_CHECKPOINT - return _toParameter(me.data_container); - } -//____________________________________________________________________________ - - friend inline void - setContainer(Iter & me, typename _Parameter::Type container_) - { -SEQAN_CHECKPOINT - if (me.data_container && me.data_iterator != TIterator()) - { - typename Position::Type pos = position(me); - me.data_container = _toPointer(container_); - setPosition(me, pos); - } - else - { - me.data_container = _toPointer(container_); - } - } - -//____________________________________________________________________________ - - friend inline TIterator & - hostIterator(Iter & me) - { -SEQAN_CHECKPOINT - return me.data_iterator; - } - friend inline TIterator const & - hostIterator(Iter const & me) - { -SEQAN_CHECKPOINT - return me.data_iterator; - } - -//____________________________________________________________________________ - - operator TIterator () const - { -SEQAN_CHECKPOINT - return data_iterator; - } - -//____________________________________________________________________________ -}; - -////////////////////////////////////////////////////////////////////////////// -// METAFUNCTIONS -////////////////////////////////////////////////////////////////////////////// -/* -template -struct Reference > const>: - Reference -{ -}; -*/ - -////////////////////////////////////////////////////////////////////////////// -// FUNCTIONS -////////////////////////////////////////////////////////////////////////////// - -////////////////////////////////////////////////////////////////////////////// -// position -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Position > const>::Type -position(Iter > const & me) -{ -SEQAN_CHECKPOINT - return hostIterator(me) - begin(container(me), Standard()); -} - -//____________________________________________________________________________ - -template -inline typename Position > const>::Type -position(Iter > const & me, - TContainer2 const &) -{ -SEQAN_CHECKPOINT - return hostIterator(me) - begin(container(me), Standard()); -} - -////////////////////////////////////////////////////////////////////////////// -// setPosition -////////////////////////////////////////////////////////////////////////////// - -template -inline void -setPosition(Iter > & me, - TPosition pos_) -{ -SEQAN_CHECKPOINT - hostIterator(me) = begin(container(me), Standard()) + pos_; -} - -////////////////////////////////////////////////////////////////////////////// -// value -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Reference > >::Type -value(Iter > & me) -{ -SEQAN_CHECKPOINT - return value(hostIterator(me)); -} -template -inline typename Reference > const>::Type -value(Iter > const & me) -{ -SEQAN_CHECKPOINT - return value(hostIterator(me)); -} - -///////////////////////////////////////////////////////////////////////////// -// assignValue -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assignValue(Iter > & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - assignValue(hostIterator(me), _value); -} -template -inline void -assignValue(Iter > const & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - assignValue(hostIterator(me), _value); -} - -///////////////////////////////////////////////////////////////////////////// -// moveValue -////////////////////////////////////////////////////////////////////////////// - -template -inline void -moveValue(Iter > & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - moveValue(hostIterator(me), _value); -} -template -inline void -moveValue(Iter > const & me, - TValue const & _value) -{ -SEQAN_CHECKPOINT - moveValue(hostIterator(me), _value); -} - -////////////////////////////////////////////////////////////////////////////// -// operator == -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator == (Iter > const & left, - Iter > const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) == hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator != -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator != (Iter > const & left, - Iter > const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) != hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// goNext -////////////////////////////////////////////////////////////////////////////// - -template -inline void -goNext(Iter > & me) -{ -SEQAN_CHECKPOINT - goNext(hostIterator(me)); -} - -////////////////////////////////////////////////////////////////////////////// -// goPrevious -////////////////////////////////////////////////////////////////////////////// - -template -inline void -goPrevious(Iter > & me) -{ -SEQAN_CHECKPOINT - goPrevious(hostIterator(me)); -} - -////////////////////////////////////////////////////////////////////////////// -// operator + -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter > -operator + (Iter > const & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - return Iter >(container(left), hostIterator(left) + right); -} -// for types -template -inline Iter > -operator + (Iter > const & left, - int right) -{ -SEQAN_CHECKPOINT - return Iter >(container(left), hostIterator(left) + right); -} - -template -inline Iter > -operator + (TIntegral left, - Iter > const & right) -{ -SEQAN_CHECKPOINT - return Iter >(container(right), hostIterator(right) + left); -} -// for types -template -inline Iter > -operator + (int left, - Iter > const & right) -{ -SEQAN_CHECKPOINT - return Iter >(container(right), hostIterator(right) + left); -} - -////////////////////////////////////////////////////////////////////////////// -// operator += -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter > & -operator += (Iter > & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - hostIterator(left) += right; - return left; -} -// for types -template -inline Iter > & -operator += (Iter > & left, - int right) -{ -SEQAN_CHECKPOINT - hostIterator(left) += right; - return left; -} - -////////////////////////////////////////////////////////////////////////////// -// operator - -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter > -operator - (Iter > const & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - return Iter >(container(left), hostIterator(left) - right); -} -// for types -template -inline Iter > -operator - (Iter > const & left, - int right) -{ -SEQAN_CHECKPOINT - return Iter >(container(left), hostIterator(left) - right); -} - -//____________________________________________________________________________ - -template -inline typename Difference > >::Type -operator - (Iter > const & left, - Iter > const & right) -{ -SEQAN_CHECKPOINT - return hostIterator(left) - hostIterator(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator -= -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter > & -operator -= (Iter > & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - hostIterator(left) -= right; - return left; -} -// for types -template -inline Iter > & -operator -= (Iter > & left, - int right) -{ -SEQAN_CHECKPOINT - hostIterator(left) -= right; - return left; -} - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// -// atEnd -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -atEnd(Iter > & me) -{ -SEQAN_CHECKPOINT - return atEnd(me, container(me)); -} - -////////////////////////////////////////////////////////////////////////////// -// assign (Conversion) -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assign(Iter > & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - target.data_container = container(source); - target.data_iterator = begin(container(source)) + position(source); -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_iterator_base.h b/SeqAn-1.1/seqan/basic/basic_iterator_base.h deleted file mode 100644 index 4c3049ad..00000000 --- a/SeqAn-1.1/seqan/basic/basic_iterator_base.h +++ /dev/null @@ -1,221 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_iterator_base.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ITERATOR_BASE_H -#define SEQAN_HEADER_BASIC_ITERATOR_BASE_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// Iter -////////////////////////////////////////////////////////////////////////////// -/** -.Class.Iter: -..cat:Basic -..summary:Iterator that is used to traverse containers. -..signature:Iter -..param.TContainer:Type of the container that can be iterated by $Iter$. -...metafunction:Metafunction.Container -..param.TSpec:The specializing type. -...metafunction:Metafunction.Spec -..implements:Concept.Iterator -*/ -template -class Iter; - -////////////////////////////////////////////////////////////////////////////// -///.Metafunction.Spec.param.T.type:Class.Iter - -template -struct Spec > -{ - typedef TSpec Type; -}; -template -struct Spec const> -{ - typedef TSpec Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Value.param.T.type:Class.Iter - -template -struct Value >: - Value -{ -}; -template -struct Value const>: - Value -{ -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.GetValue.param.T.type:Class.Iter - -template -struct GetValue >: - GetValue -{ -}; -template -struct GetValue const>: - GetValue -{ -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Reference.param.T.type:Class.Iter - -template -struct Reference >: - Reference -{ -}; -template -struct Reference const>: - Reference -{ -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Container.param.T.type:Class.Iter - -template struct Container; - -template -struct Container > -{ - typedef TContainer Type; -}; -template -struct Container const> -{ - typedef TContainer Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -/* -///.Metafunction.Host.param.T.type:Class.Iter - -template -struct Host >: - Container > -{ -}; -template -struct Host const>: - Container const> -{ -}; -*/ - -////////////////////////////////////////////////////////////////////////////// -// operator * -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Reference >::Type -operator * (Iter & me) -{ -SEQAN_CHECKPOINT - return value(me); -} -template -inline typename Reference const>::Type -operator * (Iter const & me) -{ -SEQAN_CHECKPOINT - return value(me); -} - -////////////////////////////////////////////////////////////////////////////// -// operator ++ -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter const & -operator ++ (Iter & me) -{ -SEQAN_CHECKPOINT - goNext(me); - return me; -} - -template -inline Iter const -operator ++ (Iter & me, int) -{ -SEQAN_CHECKPOINT - Iter temp_(me); - goNext(me); - return temp_; -} - -////////////////////////////////////////////////////////////////////////////// -// operator -- -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter const & -operator -- (Iter & me) -{ -SEQAN_CHECKPOINT - goPrevious(me); - return me; -} - -template -inline Iter const -operator -- (Iter & me, int) -{ -SEQAN_CHECKPOINT - Iter temp_(me); - goPrevious(me); - return temp_; -} - -////////////////////////////////////////////////////////////////////////////// -// position -////////////////////////////////////////////////////////////////////////////// - -//most Iter classes are rooted strings - -template -inline typename Position const>::Type -position(Iter const & me, - TContainer2 const &) -{ -SEQAN_CHECKPOINT - return position(me); -} - - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_iterator_position.h b/SeqAn-1.1/seqan/basic/basic_iterator_position.h deleted file mode 100644 index adc4222c..00000000 --- a/SeqAn-1.1/seqan/basic/basic_iterator_position.h +++ /dev/null @@ -1,450 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_iterator_position.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ITERATOR_POSITION_H -#define SEQAN_HEADER_BASIC_ITERATOR_POSITION_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// Tag - -struct PositionIterator; - -////////////////////////////////////////////////////////////////////////////// -// Position Iterator -////////////////////////////////////////////////////////////////////////////// - -/** -.Spec.Position Iterator: -..cat:Iterators -..general:Class.Iter -..summary:Adapts @Metafunction.Position.position@ to @Concept.Rooted Iterator.iterator@. -..signature:Iter -..param.TContainer:Type of the container. -...metafunction:Metafunction.Container -..remarks -...text:Position Iterators provide the concept @Concept.Rooted Iterator@. -..see:Metafunction.Position -*/ - -template -class Iter -{ -public: - typedef typename Position::Type TPosition; - - typename _Pointer::Type data_container; - TPosition data_position; -//____________________________________________________________________________ - -public: -/** -.Memfunc.PositionIterator#Iter: -..class:Spec.Position Iterator -..summary:Constructor -..signature:Iter() -..signature:Iter(iter) -..signature:Iter(container [, position]) -..param.iter:Another position iterator object. -..param.container:The corresponding container object. -...metafunction:Metafunction.Container -..param.position:A position in $container$. (optional) -...metafunction:Metafunction.Position -...remarks.text:If this argument is omitted, the adaptor iterator is initialized to the @Function.beginPosition.begin position@ of $container$. -*/ - Iter() - { -SEQAN_CHECKPOINT - } - Iter(typename _Parameter::Type container_, TPosition position_ = 0): - data_container(_toPointer(container_)), - data_position(position_) - { -SEQAN_CHECKPOINT - } - Iter(Iter const & other_): - data_container(other_.data_container), - data_position(other_.data_position) - { -SEQAN_CHECKPOINT - } - template - Iter(Iter const & other_) - { -SEQAN_CHECKPOINT - assign(*this, other_); - } - ~Iter() - { -SEQAN_CHECKPOINT - } - Iter const & - operator = (Iter const & other_) - { -SEQAN_CHECKPOINT - data_container = other_.data_container; - data_position = other_.data_position; - return *this; - } -//____________________________________________________________________________ - - friend inline typename _Parameter::Type - container(Iter & me) - { -SEQAN_CHECKPOINT - return _toParameter(me.data_container); - } - friend inline typename _Parameter::Type - container(Iter const & me) - { -SEQAN_CHECKPOINT - return _toParameter(me.data_container); - } -//____________________________________________________________________________ - - friend inline void - setContainer(Iter & me, typename _Parameter::Type container_) - { -SEQAN_CHECKPOINT - typename Position::Type pos = position(me); - me.data_container = _toPointer(container_); - setPosition(me, pos); - } - -//____________________________________________________________________________ - - friend inline TPosition & - position(Iter & me) - { -SEQAN_CHECKPOINT - return me.data_position; - } - friend inline TPosition const & - position(Iter const & me) - { -SEQAN_CHECKPOINT - return me.data_position; - } -//____________________________________________________________________________ - - friend inline void - setPosition(Iter & me, TPosition position_) - { -SEQAN_CHECKPOINT - me.data_position = position_; - } -//____________________________________________________________________________ -}; - -////////////////////////////////////////////////////////////////////////////// -// value -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Reference >::Type -value(Iter & me) -{ -SEQAN_CHECKPOINT - return value(container(me), position(me)); -} -template -inline typename Reference >::Type -value(Iter const & me) -{ -SEQAN_CHECKPOINT - return value(container(me), position(me)); -} - -///////////////////////////////////////////////////////////////////////////// -// assignValue -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assignValue(Iter & me, - TValue _value) -{ -SEQAN_CHECKPOINT - assignValue(container(me), position(me), _value); -} -template -inline void -assignValue(Iter const & me, - TValue _value) -{ -SEQAN_CHECKPOINT - assignValue(container(me), position(me), _value); -} - -///////////////////////////////////////////////////////////////////////////// -// moveValue -////////////////////////////////////////////////////////////////////////////// - -template -inline void -moveValue(Iter & me, - TValue _value) -{ -SEQAN_CHECKPOINT - moveValue(container(me), position(me), _value); -} -template -inline void -moveValue(Iter const & me, - TValue _value) -{ -SEQAN_CHECKPOINT - moveValue(container(me), position(me), _value); -} - -////////////////////////////////////////////////////////////////////////////// -// operator == -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator == (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return position(left) == position(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator != -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator != (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return position(left) != position(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator < / > -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator < (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return position(left) < position(right); -} - -template -inline bool -operator > (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return position(left) > position(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator <= / >= -////////////////////////////////////////////////////////////////////////////// - -template -inline bool -operator <= (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return position(left) <= position(right); -} - -template -inline bool -operator >= (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return position(left) >= position(right); -} - -////////////////////////////////////////////////////////////////////////////// -// goNext -////////////////////////////////////////////////////////////////////////////// - -template -inline void -goNext(Iter & me) -{ -SEQAN_CHECKPOINT - setPosition(me, position(me) + 1); -} - -////////////////////////////////////////////////////////////////////////////// -// goPrevious -////////////////////////////////////////////////////////////////////////////// - -template -inline void -goPrevious(Iter & me) -{ -SEQAN_CHECKPOINT - setPosition(me, position(me) - 1); -} - -////////////////////////////////////////////////////////////////////////////// -// operator + -////////////////////////////////////////////////////////////////////////////// -template -inline Iter -operator + (Iter const & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - return Iter(container(left), position(left) + right); -} -// for types -template -inline Iter -operator + (Iter const & left, - int right) -{ -SEQAN_CHECKPOINT - return Iter(container(left), position(left) + right); -} - -template -inline Iter -operator + (TIntegral left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return Iter(container(right), position(right) + left); -} -// for types -template -inline Iter -operator + (int left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return Iter(container(right), position(right) + left); -} - -////////////////////////////////////////////////////////////////////////////// -// operator += -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter & -operator += (Iter & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - setPosition(left, position(left) + right); - return left; -} -// for types -template -inline Iter & -operator += (Iter & left, - int right) -{ -SEQAN_CHECKPOINT - setPosition(left, position(left) + right); - return left; -} - -////////////////////////////////////////////////////////////////////////////// -// operator - -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter -operator - (Iter const & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - return Iter(container(left), position(left) - right); -} -// for types -template -inline Iter -operator - (Iter const & left, - int right) -{ -SEQAN_CHECKPOINT - return Iter(container(left), position(left) - right); -} - -//____________________________________________________________________________ - -template -inline typename Difference::Type -operator - (Iter const & left, - Iter const & right) -{ -SEQAN_CHECKPOINT - return position(left) - position(right); -} - -////////////////////////////////////////////////////////////////////////////// -// operator -= -////////////////////////////////////////////////////////////////////////////// - -template -inline Iter & -operator -= (Iter & left, - TIntegral right) -{ -SEQAN_CHECKPOINT - setPosition(left, position(left) - right); - return left; -} -// for types -template -inline Iter & -operator -= (Iter & left, - int right) -{ -SEQAN_CHECKPOINT - setPosition(left, position(left) - right); - return left; -} - -////////////////////////////////////////////////////////////////////////////// -// assign (Conversion) -////////////////////////////////////////////////////////////////////////////// - -template -inline void -assign(Iter & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - target.data_container = container(source); - target.data_position = position(source); -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_iterator_simple.h b/SeqAn-1.1/seqan/basic/basic_iterator_simple.h deleted file mode 100644 index 8bfe78fd..00000000 --- a/SeqAn-1.1/seqan/basic/basic_iterator_simple.h +++ /dev/null @@ -1,117 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_iterator_simple.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_ITERATOR_SIMPLE_H -#define SEQAN_HEADER_BASIC_ITERATOR_SIMPLE_H - -namespace SEQAN_NAMESPACE_MAIN -{ -////////////////////////////////////////////////////////////////////////////// -// Iter -////////////////////////////////////////////////////////////////////////////// - -struct SimpleIterator; - -/** -.Spec.SimpleIterator: -..cat:Iterators -..summary:A simple iterator. -..signature:Iter -..param.TContainer:Type of the container that can be iterated. -...metafunction:Metafunction.Container -..general:Class.Iter -*/ -template -class Iter -{ -public: - typedef typename Value::Type TValue; - TValue * data_ptr; - - Iter() - { - } - Iter(Iter const & other_): - data_ptr(other_.data_ptr) - { - } - Iter(TValue * other_data_ptr): - data_ptr(other_data_ptr) - { - } - template - Iter(Iter const & other_): - data_ptr(other_.data_ptr) - { - } - ~Iter() - { - } - Iter const & - operator = (Iter const & other_) - { - this->data_ptr = other_.data_ptr; - return *this; - } - Iter const & - operator = (TValue * other_data_ptr) - { - data_ptr = other_data_ptr; - return *this; - } - template - Iter const & - operator = (Iter const & other_) - { - this->data_ptr = other_.data_ptr; - return *this; - } - - operator TValue * () - { - return data_ptr; - } -}; - -////////////////////////////////////////////////////////////////////////////// - -template -struct Iterator_Default_Imp -{ - typedef typename Value::Type * Type; -// typedef Iter Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -template -inline typename Position const>::Type -position(Iter const & me, - TContainer2 const & cont) -{ -SEQAN_CHECKPOINT - return me.data_ptr - begin(cont); -} - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_metaprogramming.h b/SeqAn-1.1/seqan/basic/basic_metaprogramming.h deleted file mode 100644 index fffe6601..00000000 --- a/SeqAn-1.1/seqan/basic/basic_metaprogramming.h +++ /dev/null @@ -1,293 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_metaprogramming.h,v 1.2 2009/02/19 01:51:23 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_BASIC_METAPROGRAMMING_H -#define SEQAN_BASIC_METAPROGRAMMING_H - -namespace SEQAN_NAMESPACE_MAIN -{ - - ////////////////////////////////////////////////////////////////////////////// - // generic "if" (using meta-programming) - // if Flag is true, the resulting type is Type1 - // if Flag is false, the resulting type is Type2 - ////////////////////////////////////////////////////////////////////////////// - - template - struct IF - { - typedef Type1 Type; - }; - - template - struct IF - { - typedef Type2 Type; - }; - - - ////////////////////////////////////////////////////////////////////////////// - // generic type comparison (using meta-programming) - // if Type1 equals Type2, VALUE is true - // if Type1 differs from Type2, VALUE is false - ////////////////////////////////////////////////////////////////////////////// - - template - struct TYPECMP - { - typedef False Type; - enum { VALUE = false }; - }; - - template - struct TYPECMP - { - typedef True Type; - enum { VALUE = true }; - }; - - ////////////////////////////////////////////////////////////////////////////// - // generic "switch" (using meta-programming) - ////////////////////////////////////////////////////////////////////////////// - - const int DEFAULT = ~(~0u >> 1); // initialize with the smallest int - - struct NilCase {}; - - template - struct CASE - { - enum { tag = tag_ }; - typedef Type_ Type; - typedef Next_ Next; - }; - - template - class SWITCH - { - typedef typename Case::Next NextCase; - enum - { - caseTag = Case::tag, - found = (caseTag == tag || caseTag == DEFAULT) - }; - public: - typedef typename - IF< - found, - typename Case::Type, - typename SWITCH::Type - >::Type Type; - }; - - template - class SWITCH - { - public: - typedef NilCase Type; - }; - - - ////////////////////////////////////////////////////////////////////////////// - // generic loops (using meta-programming) - // corresponds to for(i=1; i<=I; ++i) ... - ////////////////////////////////////////////////////////////////////////////// - - // example of a loop Worker class - struct WorkerNothing - { - template - static inline void body(Arg &arg, int I) {} - }; - - template - class LOOP { - public: - template - static inline void run(Arg &arg) { - LOOP::run(arg); - Worker::body(arg, I); - } - }; - - template - class LOOP { - public: - // end of loop - template - static inline void run(Arg &) {} - }; - - ////////////////////////////////////////////////////////////////////////////// - // generic reverse loops (using meta-programming) - // corresponds to for(i=I; i>0; --i) ... - ////////////////////////////////////////////////////////////////////////////// - - template - class LOOP_REVERSE { - public: - template - static inline void run(Arg &arg) { - Worker::body(arg, I); - LOOP_REVERSE::run(arg); - } - }; - - template - class LOOP_REVERSE { - public: - // end of loop - template - static inline void run(Arg &) {} - }; - - ////////////////////////////////////////////////////////////////////////////// - // logarithmus dualis (using meta-programming) - ////////////////////////////////////////////////////////////////////////////// - - template < __int64 numerus > - struct Log2 { - enum { VALUE = Log2<(numerus + 1) / 2>::VALUE + 1 }; // ceil(log_2(n)) - }; - - template < __int64 numerus > - struct Log2Floor { - enum { VALUE = Log2Floor::VALUE + 1 }; // floor(log_2(n)) - }; - - template <> struct Log2<1> { enum { VALUE = 0 }; }; - template <> struct Log2<0> { enum { VALUE = 0 }; }; - template <> struct Log2Floor<1> { enum { VALUE = 0 }; }; - template <> struct Log2Floor<0> { enum { VALUE = 0 }; }; - - - ////////////////////////////////////////////////////////////////////////////// - // exponentiation (using meta-programming) - ////////////////////////////////////////////////////////////////////////////// - - template < __int64 base, __int64 exponent > - struct Power { - enum { - VALUE = - Power::VALUE * - Power::VALUE - }; - }; - - template < __int64 base > struct Power { enum { VALUE = base }; }; - template < __int64 base > struct Power { enum { VALUE = 1 }; }; - - - ////////////////////////////////////////////////////////////////////////////// - // memset with fill size (using meta-programming) - ////////////////////////////////////////////////////////////////////////////// - - using ::memset; - - template - struct MemsetWorker { - finline static void run(unsigned char* ptr, unsigned char c) { memset(ptr, c, SIZE); } - }; - - template - struct MemsetWorker { - finline static void run(unsigned char* ptr, unsigned char c) { - *((unsigned*)ptr) = ((unsigned)c << 24) + ((unsigned)c << 16) + ((unsigned)c << 8) + (unsigned)c; - MemsetWorker::run(ptr + 4, c); - } - }; - - template <> - struct MemsetWorker<0, true> { - finline static void run(unsigned char*, unsigned char) {} - }; - - template <> - struct MemsetWorker<1, true> { - finline static void run(unsigned char* ptr, unsigned char c) { *ptr = c; } - }; - - template <> - struct MemsetWorker<2, true> { - finline static void run(unsigned char* ptr, unsigned char c) { *(unsigned short *)ptr = ((unsigned short)c << 8) + (unsigned short)c; } - }; - - template <> - struct MemsetWorker<3, true> { - finline static void run(unsigned char* ptr, unsigned char c) { - MemsetWorker<2, true>::run(ptr, c); - MemsetWorker<1, true>::run(ptr + 2, c); - } - }; - - template - finline void memset(void* ptr, unsigned char c) { - MemsetWorker::run((unsigned char*)ptr, c); - } - - - ////////////////////////////////////////////////////////////////////////////// - // memset with fill value (using meta-programming) - ////////////////////////////////////////////////////////////////////////////// - - template - struct MemsetConstValueWorker { - finline static void run(unsigned char* ptr) { memset(ptr, c, SIZE); } - }; - - template - struct MemsetConstValueWorker { - finline static void run(unsigned char* ptr) { - *((unsigned*)ptr) = ((unsigned)c << 24) + ((unsigned)c << 16) + ((unsigned)c << 8) + (unsigned)c; - MemsetConstValueWorker::run(ptr + 4); - } - }; - - template - struct MemsetConstValueWorker<0, true, c> { - finline static void run(unsigned char* ptr) {} - }; - - template - struct MemsetConstValueWorker<1, true, c> { - finline static void run(unsigned char* ptr) { *ptr = c; } - }; - - template - struct MemsetConstValueWorker<2, true, c> { - finline static void run(unsigned char* ptr) { *(unsigned short *)ptr = ((unsigned short)c << 8) + (unsigned short)c; } - }; - - template - struct MemsetConstValueWorker<3, true, c> { - finline static void run(unsigned char* ptr) { - MemsetConstValueWorker<2, true, c>::run(ptr); - MemsetConstValueWorker<1, true, c>::run(ptr + 2); - } - }; - - template - finline void memset(void* ptr) { - MemsetConstValueWorker::run((unsigned char*)ptr); - } - -} - -#endif diff --git a/SeqAn-1.1/seqan/basic/basic_operator.h b/SeqAn-1.1/seqan/basic/basic_operator.h deleted file mode 100644 index 2bd48d93..00000000 --- a/SeqAn-1.1/seqan/basic/basic_operator.h +++ /dev/null @@ -1,32 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_operator.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_OPERATOR_H -#define SEQAN_HEADER_BASIC_OPERATOR_H - -namespace SEQAN_NAMESPACE_MAIN -{ - - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... - - diff --git a/SeqAn-1.1/seqan/basic/basic_pointer.h b/SeqAn-1.1/seqan/basic/basic_pointer.h deleted file mode 100644 index 83825c05..00000000 --- a/SeqAn-1.1/seqan/basic/basic_pointer.h +++ /dev/null @@ -1,103 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_pointer.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_POINTER_H -#define SEQAN_HEADER_BASIC_POINTER_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Value.param.T.type:Adaption.char array - -template -struct Value< TValue * > -{ - typedef TValue Type; -}; -template -struct Value< TValue * const> -{ - typedef TValue Type; -}; - -//The next two metafunctions dont work in VC++ due to a compiler bug. -//(the default implementation in common_type.h is called instead) -//work-around: convert arrays to pointers. -template -struct Value< TValue [SIZE] > -{ - typedef TValue Type; -}; -template -struct Value< TValue const [SIZE] > -{ - typedef TValue const Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Iterator.param.T.type:Adaption.char array - -template -struct Iterator< TValue *, Standard> -{ - typedef TValue * Type; -}; -template -struct Iterator< TValue * const, Standard> -{ - typedef TValue * Type; -}; - -//____________________________________________________________________________ - -template -struct Iterator< TValue [SIZE], Standard>: - Iterator -{ -}; -template -struct Iterator< TValue const [SIZE], Standard>: - Iterator -{ -}; - -template -struct Iterator< TValue [SIZE], Rooted>: - Iterator -{ -}; -template -struct Iterator< TValue const [SIZE], Rooted>: - Iterator -{ -}; - - - - -////////////////////////////////////////////////////////////////////////////// -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_profile.h b/SeqAn-1.1/seqan/basic/basic_profile.h deleted file mode 100644 index edcf42bd..00000000 --- a/SeqAn-1.1/seqan/basic/basic_profile.h +++ /dev/null @@ -1,503 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_profile.h,v 1.1 2008/08/25 16:20:02 langmead Exp $ - ==========================================================================*/ - -//SEQAN_NO_GENERATED_FORWARDS: no forwards are generated for this file - -#ifndef SEQAN_HEADER_BASIC_PROFILE_H -#define SEQAN_HEADER_BASIC_PROFILE_H - -// todo: substitute defines with inlines -#ifndef SEQAN_PROFILE - - #define SEQAN_PROSET(i,v) - #define SEQAN_PROADD(i,v) - #define SEQAN_PROSUB(i,v) - #define SEQAN_PROVAL(i) 0 - #define SEQAN_PROEXTRAS(i) - #define SEQAN_PROMARK(m) - #define SEQAN_PROENDMARK(m) - #define SEQAN_PRORESET - #define SEQAN_PROGETTIME 0 - #define SEQAN_PROTIMESTART(a) - #define SEQAN_PROTIMEDIFF(a) 0 - // replace malloc and free in external tools - // with SEQAN_PROMALLOC and SEQAN_PROFREE to profile - // their memory usage - #define SEQAN_PROMALLOC(s) malloc(s) - #define SEQAN_PROFREE(p) free(p) - -#else - - #define SEQAN_PROSET(i,v) _proSet(i,v) - #define SEQAN_PROADD(i,v) _proAdd(i,v) - #define SEQAN_PROSUB(i,v) _proSub(i,v) - #define SEQAN_PROVAL(i) (_proData<>::_proValue[i]) - #define SEQAN_PROEXTRAS(i) {_proData<>::_proExtraCount = i;} - #define SEQAN_PROMARK(m) _proMark(m) - #define SEQAN_PROENDMARK(m) _proEndMark(m) - #define SEQAN_PRORESET _proReset() - #define SEQAN_PROGETTIME sysTime() - #define SEQAN_PROTIMESTART(a) _proFloat a = sysTime() - #define SEQAN_PROTIMEDIFF(a) (sysTime() - a) - #define SEQAN_PROMALLOC(s) _proMalloc(s) - #define SEQAN_PROFREE(p) _proFree(p) - -#endif - -#ifdef PLATFORM_WINDOWS - typedef __int64 _proInt; -#else - typedef int64_t _proInt; -#endif - - typedef double _proFloat; - - - typedef _proFloat _proTValue; - - enum _proConsts { - SEQAN_PROPAGESIZE = 4096, // B in byte - SEQAN_PROFLOAT = 0, - SEQAN_PROINT = 1, - SEQAN_PROTIME = 2, - SEQAN_PROTYPEMASK = 3, - SEQAN_PROSTATE = 4 - }; - - enum _proValueIndex { - SEQAN_PROSYSTIME = 0, - SEQAN_PROCPUTIME = 1, - SEQAN_PROMEMORY = 2, // current memory usage (state value) - SEQAN_PROIO = 3, // IOs done (measured in Blocks of size B) - SEQAN_PROIORANDOM = 4, // IOs calls done (read/write calls done) - SEQAN_PROIOVOLUME = 5, // current disk usage (state value) - SEQAN_PRODEPTH = 6, // algorithmic rec. depth or loop count - SEQAN_PROOPENFILES = 7, // currently opened files - SEQAN_PROIWAIT = 8, // waiting time (initiating) - SEQAN_PROCWAIT = 9, // waiting time (completing) - SEQAN_PROEXTRA1 = 10, - SEQAN_PROEXTRA2 = 11, - SEQAN_PROEXTRA3 = 12, - SEQAN_PROINDEXCOUNT = 13, - SEQAN_PROEXTRACOUNT = 3 - }; - - const char _proValueType[] = { - SEQAN_PROTIME, - SEQAN_PROTIME, - SEQAN_PROINT + SEQAN_PROSTATE, - SEQAN_PROINT, - SEQAN_PROINT, - SEQAN_PROINT + SEQAN_PROSTATE, - SEQAN_PROINT + SEQAN_PROSTATE, - SEQAN_PROINT + SEQAN_PROSTATE, - SEQAN_PROFLOAT, - SEQAN_PROFLOAT, - SEQAN_PROFLOAT + SEQAN_PROSTATE, - SEQAN_PROFLOAT + SEQAN_PROSTATE, - SEQAN_PROFLOAT + SEQAN_PROSTATE - }; - - typedef _proTValue _proTStates[SEQAN_PROINDEXCOUNT]; - typedef _proFloat _proTTimes[SEQAN_PROINDEXCOUNT]; - - - - struct _proFile; - - template - struct _proData - { - static _proTStates _proValue; - static _proTTimes _proLastUpdate; - static int _proExtraCount; - - static clock_t _proCpuTimeLast; // clock_t wraps around every 72mins - static _proInt _proCpuTimeOffset; // we have to work around this - - static _proFile* _proPFile; - static _proFile* _proPFileStream; - }; - - template _proTStates _proData::_proValue = {}; - template _proTStates _proData::_proLastUpdate = {}; - template int _proData::_proExtraCount = 0; - template clock_t _proData::_proCpuTimeLast = 0; - template _proInt _proData::_proCpuTimeOffset = 0; - template _proFile* _proData::_proPFile = NULL; - template _proFile* _proData::_proPFileStream = NULL; - - - inline _proFile* & _proPFile() { return _proData<>::_proPFile; } - inline _proFile* & _proPFileStream() { return _proData<>::_proPFileStream; } - - -// HINT: The unit of all time functions is second. - inline _proFloat cpuTime() { - clock_t now = clock(); - if (_proData<>::_proCpuTimeLast > now) { // test for time wrap - _proData<>::_proCpuTimeOffset += (~0u); // got one - _proData<>::_proCpuTimeOffset ++; -// printf("\n!!WRAP!! old:%d, now:%d ofs:%d\n",_proData<>::_proCpuTimeLast,now,_proData<>::_proCpuTimeOffset); - } - _proData<>::_proCpuTimeLast = now; - return (_proData<>::_proCpuTimeOffset + now) / (_proFloat)CLOCKS_PER_SEC; - } - - #ifdef PLATFORM_WINDOWS -// inline _proFloat sysTime() { return GetTickCount() * 1e-3; } - inline _proFloat sysTime() { return ( (_proFloat) clock() ) / CLOCKS_PER_SEC; } - #else - - #include - #if _POSIX_TIMERS > 0 - #ifndef SEQAN_USE_CLOCKGETTIME - #define SEQAN_USE_CLOCKGETTIME - #endif - #endif - - #ifndef SEQAN_USE_CLOCKGETTIME - /* some systems e.g. darwin have no clock_gettime */ - - #include - - inline _proFloat sysTime() { - struct timeval tp; - gettimeofday(&tp, NULL); - return tp.tv_sec + tp.tv_usec * 1e-6; - } - - #else - - inline _proFloat sysTime() { - /*struct timespec tp; - clock_gettime(CLOCK_MONOTONIC, &tp); - return tp.tv_sec + tp.tv_nsec * 1e-9;*/ - return 0; // BTL: to compile under cygwin - } - - #endif - - #endif - - - struct _proFile { - - FILE *out; - bool running; - - _proFloat dumpStep; // 0 .. manual dump mode, >0 .. live stream - _proFloat dumpNext; - - _proTStates all, last; - ::std::string mark; - unsigned lines; - - _proFile() { - running = false; - } - - _proFile(char const *fname, _proFloat _dumpStep = 300.0) { // five minutes default dump interval - running = false; - start(fname, _dumpStep); - } - - ~_proFile() { - if (running) stop(); - } - - inline void start(char const *fname, _proFloat _dumpStep = 300.0, bool append = false) { - if (append) - out = fopen(fname, "a"); - else { - out = fopen(fname, "w"); - dumpHeader(); - } - - if (!out) printf("WARNING: proFile could not be opened.\n"); - - setTime(_proData<>::_proValue); - syncAll(all); - syncAll(last); - running = true; - lines = 0; - dumpStep = _dumpStep; - dumpNext = sysTime(); - dump(last); - } - - inline void stop() { - dump(last); - maximize(all, last); - if (dumpStep == 0) { - mark = "Zusammenfassung"; - dump(all); - } - fclose(out); - running = false; - } - - inline void syncTime(_proTStates &dst) { - memcpy(dst, _proData<>::_proValue, 2 * sizeof(_proTValue)); - } - - inline void sync(_proTStates &dst) { - memcpy(&(dst[2]), &(_proData<>::_proValue[2]), sizeof(_proTStates) - 2 * sizeof(_proTValue)); - } - - inline void syncAll(_proTStates &dst) { - memcpy(dst, _proData<>::_proValue, sizeof(_proTStates)); - } - - inline static void setTime(_proTStates &dst) { - dst[0] = sysTime(); - dst[1] = cpuTime(); - } - - inline void maximize(_proTStates &dst, _proTStates const &src) { - for(int i = 0; i < SEQAN_PROINDEXCOUNT; ++i) - if (((_proValueType[i] & SEQAN_PROSTATE) != 0)) - if (dst[i] < src[i]) - dst[i] = src[i]; - } - - inline void dumpTab() { - if (!bol) - fprintf(out, " \t"); - bol = false; - } - - inline void dumpEndl() { fprintf(out, "\n"); } - - inline void dumpHeader() { - fprintf(out, "\"Echtzeit\"\t\"CPU-Zeit\"\t\"Speicher\"\t\"I/O-Zugriffe\"\t\"wahlfreie I/Os\"\t\"I/O-Volumen\"\t\"Rekursionstiefe\"\t\"Offene Dateien\"\t\"Idle-Zeit vor I/O\"\t\"Idle-Zeit nach I/O\"\n"); - } - - inline void dumpTime(_proFloat seconds) { - if (seconds < 0) { - fputc('-', out); - seconds = -seconds; - } - int secs = (int)seconds; - int mins = secs/60; secs -= 60*mins; - int hours = mins/60; mins -= 60*hours; - fprintf(out, "%d:%02d:%02d", hours, mins, secs); - } - - inline void dumpTimeEx(_proFloat seconds) { - int milli = (int)(seconds * 1000.0); - int secs = (int)seconds; - int mins = secs/60; secs -= 60*mins; - int hours = mins/60; mins -= 60*hours; - fprintf(out, "%d:%02d:%02d.%03d", hours, mins, secs, milli); - } - - inline void dumpValue(_proTStates &stat, int valNum) { - _proFloat f = stat[valNum]; - if ((_proValueType[valNum] & SEQAN_PROSTATE) == 0) - f = _proData<>::_proValue[valNum] - f; - - switch (_proValueType[valNum] & SEQAN_PROTYPEMASK) { - case SEQAN_PROINT: // state value -> print last seen maximum - fprintf(out, "%.0f", f); - break; - - case SEQAN_PROFLOAT: - fprintf(out, "%f", f); - break; - - case SEQAN_PROTIME: - dumpTimeEx(f); - } - } - - inline void dumpSysValues(_proTStates &stat) { - for(int i = 0; i < SEQAN_PROINDEXCOUNT - SEQAN_PROEXTRACOUNT; ++i) { - dumpTab(); - dumpValue(stat, i); - } - } - - inline void dumpExtraValues(_proTStates &stat) { - for(int i = 0; i < _proData<>::_proExtraCount; ++i) { - dumpTab(); - dumpValue(stat, SEQAN_PROINDEXCOUNT - SEQAN_PROEXTRACOUNT + i); - } - } - - inline void dumpMark() { - if (!mark.empty()) { - dumpTab(); - fprintf(out, "\"%s\"", mark.c_str()); - mark.erase(); - } - } - - inline void dump(_proTStates &stat) { - setTime(_proData<>::_proValue); - dumpNext += dumpStep; - bol = true; - bool _flush = ((dumpStep == 0.0)) || ((lines & 16) == 0); - - dumpSysValues(stat); - dumpExtraValues(stat); - dumpMark(); - dumpEndl(); - if (_flush) fflush(out); - ++lines; - } - - inline void signalDumpTest(_proFloat now) { - if (dumpStep > 0 && now > dumpNext && running) { - dump(last); - maximize(all, last); - sync(last); - } - } - - inline void signalNewMax(int valNum) { - if (running) - if (last[valNum] < _proData<>::_proValue[valNum]) - last[valNum] = _proData<>::_proValue[valNum]; - } - - inline void setMark(const char *text) { - if (running) { - mark = text; - if (dumpStep == 0.0) { - dump(last); // manual dump; - maximize(all, last); - sync(last); - } - } - } - - inline void reset() { - syncTime(last); - } - - inline void setEndMark(const char *text) { - if (running) { - setMark(text); - reset(); - } - } - - private: - - bool bol; // begin of line - }; - - - -/* - inline void _proSignalDumpTest(_proFloat now); - inline void _proSignalNewMax(int valNum); - inline void _proMark(const char *text); - inline void _proEndMark(const char *text); - inline void _proReset(); - - inline void _proSet(int valNum, _proFloat value); - inline void _proAdd(int valNum, _proFloat value); - inline void _proSub(int valNum, _proFloat value); - - // simple interface for external programs - inline void *_proMalloc(size_t size); - inline void _proFree(void *_ptr); -*/ - - inline void _proSignalDumpTest(_proFloat now) { - if (_proData<>::_proPFileStream) _proData<>::_proPFileStream->signalDumpTest(now); - } - - inline void _proSignalNewMax(int valNum) { - if (((_proValueType[valNum] & SEQAN_PROSTATE) != 0)) { - if (_proData<>::_proPFileStream) _proData<>::_proPFileStream->signalNewMax(valNum); - if (_proData<>::_proPFile) _proData<>::_proPFile->signalNewMax(valNum); - } - } - - inline void _proMark(const char *text) { - if (_proData<>::_proPFileStream) _proData<>::_proPFileStream->setMark(text); - if (_proData<>::_proPFile) _proData<>::_proPFile->setMark(text); - } - - inline void _proEndMark(const char *text) { - if (_proData<>::_proPFileStream) { _proData<>::_proPFileStream->setEndMark(text); } - if (_proData<>::_proPFile) { _proData<>::_proPFile->setEndMark(text); } - } - - inline void _proReset() { - if (_proData<>::_proPFileStream) { _proData<>::_proPFileStream->reset(); } - if (_proData<>::_proPFile) { _proData<>::_proPFile->reset(); } - } - - - - - inline void _proSet(_proValueIndex valNum, _proFloat value) { - _proFloat now = sysTime(); - _proData<>::_proLastUpdate[valNum] = now; - if (_proData<>::_proValue[valNum] < value) { - _proData<>::_proValue[valNum] = value; - _proSignalNewMax(valNum); - } else - _proData<>::_proValue[valNum] = value; - _proSignalDumpTest(now); - } - - inline void _proAdd(_proValueIndex valNum, _proFloat value) { - _proFloat now = sysTime(); - _proData<>::_proValue[valNum] += value; - _proData<>::_proLastUpdate[valNum] = now; - if (valNum == SEQAN_PROIO) _proAdd(SEQAN_PROIORANDOM, 1); - _proSignalNewMax(valNum); - _proSignalDumpTest(now); - } - - inline void _proSub(_proValueIndex valNum, _proFloat value) { - _proFloat now = sysTime(); - _proData<>::_proValue[valNum] -= value; - _proData<>::_proLastUpdate[valNum] = now; - _proSignalDumpTest(now); - } - - // simple interface for external programs - inline void *_proMalloc(size_t size) { - size_t *ptr = reinterpret_cast(malloc(size + sizeof(size_t))); - if (ptr) { - _proAdd(SEQAN_PROMEMORY, *ptr = size); -// printf("_proMalloc %x size %d\n", ptr, size); - ++ptr; - } - return ptr; - } - - inline void _proFree(void *_ptr) { - size_t *ptr = reinterpret_cast(_ptr); - if (ptr) { - --ptr; -// printf("_proFree %x size %d\n", _ptr, *ptr); - _proSub(SEQAN_PROMEMORY, *ptr); - } - free(ptr); - } - -#endif diff --git a/SeqAn-1.1/seqan/basic/basic_proxy.h b/SeqAn-1.1/seqan/basic/basic_proxy.h deleted file mode 100644 index c384e055..00000000 --- a/SeqAn-1.1/seqan/basic/basic_proxy.h +++ /dev/null @@ -1,606 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_proxy.h,v 1.1 2008/08/25 16:20:02 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_PROXY_H -#define SEQAN_HEADER_BASIC_PROXY_H - - -namespace SEQAN_NAMESPACE_MAIN -{ - - -////////////////////////////////////////////////////////////////////////////// -// Proxy -////////////////////////////////////////////////////////////////////////////// -/** -.Class.Proxy: -..cat:Basic -..summary:Emulates object of another class. -..signature:Proxy -..param.TSpec:The specializing type. -...metafunction:Metafunction.Spec -..remarks.text:Use @Metafunction.Value@ to get the emulated type. -An instance of $Proxy$ behaves like an object of its value type. -$Proxy$ can be used as reference type (see @Metafunction.Reference@). -..remarks.text:Note that functions that are both general and specialized for -the value type should be specialized for $Proxy$ too, -since otherwise the general version will be called. -*/ - -template -struct Proxy; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Spec.param.T.type:Class.Proxy - -template -struct Spec< Proxy > -{ - typedef TSpec Type; -}; -template -struct Spec< Proxy const> -{ - typedef TSpec Type; -}; - -////////////////////////////////////////////////////////////////////////////// -// Iterator Proxy -////////////////////////////////////////////////////////////////////////////// -/** -.Spec.Iterator Proxy: -..cat:Proxies -..general:Class.Proxy -..summary:Proxy that is implemented by an iterator. -..signature:Proxy > -..param.TIterator:Iterator type. -..remarks.text:The value type of an iterator proxy is the value type of the -iterator $TIterator$. -*/ - -template -struct IteratorProxy; - -//____________________________________________________________________________ - -template -struct Proxy > -{ -public: - typedef typename Value::Type TValue; - typedef typename GetValue::Type TAccessor; - - typedef typename _RemoveConst::Type TAccessor_NotConst; - -private: - TIterator data_iterator; - -public: - Proxy(TIterator const _it): - data_iterator(_it) - { -SEQAN_CHECKPOINT - } - Proxy(Proxy const & _other): - data_iterator(_other.data_iterator) - { -SEQAN_CHECKPOINT - } - - ~Proxy() - { -SEQAN_CHECKPOINT - } - - Proxy const & - operator = (Proxy const & _other) - { -SEQAN_CHECKPOINT - assignValue(data_iterator, getValue(_other.data_iterator)); - return *this; - } - - Proxy const & - operator = (TValue const & _value) - { -SEQAN_CHECKPOINT - assignValue(data_iterator, _value); - return *this; - } - - operator TAccessor_NotConst() - { -SEQAN_CHECKPOINT - return getValue(data_iterator); - } - -//____________________________________________________________________________ - - //not documented - friend inline TIterator & - iter(Proxy & me) - { - return me.data_iterator; - } - friend inline TIterator const & - iter(Proxy const & me) - { - return me.data_iterator; - } - -//____________________________________________________________________________ -}; - -////////////////////////////////////////////////////////////////////////////// -// Metafunctions -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Value.param.T.type:Class.Proxy - -template -struct Value< Proxy > >: - Value -{ -}; -template -struct Value< Proxy > const> -{ - typedef typename Value::Type const Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.GetValue.param.T.type:Class.Proxy - -template -struct GetValue< Proxy > >: - GetValue -{ -}; -template -struct GetValue< Proxy > const> -{ - typedef typename GetValue::Type Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Reference.param.T.type:Class.Proxy - -template -struct Reference< Proxy > > -{ - typedef Proxy > Type; -}; -template -struct Reference< Proxy > const > -{ - typedef Proxy > const Type; -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Size.param.T.type:Class.Proxy - -template -struct Size< Proxy > >: - Size -{ -}; -template -struct Size< Proxy > const>: - Size -{ -}; - -////////////////////////////////////////////////////////////////////////////// - -///.Metafunction.Difference.param.T.type:Class.Proxy - -template -struct Difference< Proxy > >: - Difference -{ -}; -template -struct Difference< Proxy > const>: - Difference -{ -}; - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// - -template -typename GetValue >::Type -getValue(Proxy & me) -{ - return getValue(iter(me)); -} -template -typename GetValue const>::Type -getValue(Proxy const & me) -{ - return getValue(iter(me)); -} - -////////////////////////////////////////////////////////////////////////////// -// Comparison -////////////////////////////////////////////////////////////////////////////// - -template -struct CompareType , T> -{ - typedef typename Value >::Type TValue; - typedef typename _RemoveConst::Type TValue_NoConst; - typedef typename CompareType::Type Type; -}; - -//???TODO: Symmetrie von CompareType herstellen -//____________________________________________________________________________ - -template -inline typename Convert >::Type -convertImpl(Convert const, - Proxy & source) -{ - return convert(getValue(source)); -} -template -inline typename Convert const>::Type -convertImpl(Convert const, - Proxy const & source) -{ - return convert(getValue(source)); -} -////////////////////////////////////////////////////////////////////////////// -// operator == - -template -inline bool -operator == (Proxy const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} - -template -inline bool -operator == (TLeft const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} - -template -inline bool -operator == (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) == convert(right_); -} - -template -inline bool -operator == (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef typename GetValue >::Type TAccessor; - return convert(left_) == convert(right_); -} - -//____________________________________________________________________________ -// operator != - -template -inline bool -operator != (Proxy const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} - -template -inline bool -operator != (TLeft const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} - -template -inline bool -operator != (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) != convert(right_); -} - -template -inline bool -operator != (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef typename GetValue >::Type TAccessor; - return convert(left_) != convert(right_); -} - - -//____________________________________________________________________________ -// operator < - -template -inline bool -operator < (Proxy const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} - -template -inline bool -operator < (TLeft const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} - -template -inline bool -operator < (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) < convert(right_); -} - -template -inline bool -operator < (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef typename GetValue >::Type TAccessor; - return convert(left_) < convert(right_); -} - -//____________________________________________________________________________ -// operator <= - -template -inline bool -operator <= (Proxy const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} - -template -inline bool -operator <= (TLeft const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} - -template -inline bool -operator <= (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) <= convert(right_); -} - -template -inline bool -operator <= (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef typename GetValue >::Type TAccessor; - return convert(left_) <= convert(right_); -} - - -//____________________________________________________________________________ -// operator > - -template -inline bool -operator > (Proxy const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} - -template -inline bool -operator > (TLeft const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} - -template -inline bool -operator > (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) > convert(right_); -} - -template -inline bool -operator > (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef typename GetValue >::Type TAccessor; - return convert(left_) > convert(right_); -} - - -//____________________________________________________________________________ -// operator >= - -template -inline bool -operator >= (Proxy const & left_, - TRight const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} - -template -inline bool -operator >= (TLeft const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} - -template -inline bool -operator >= (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef Proxy TLeft; - typedef Proxy TRight; - typedef typename CompareType::Type TCompareType; - return convert(left_) >= convert(right_); -} - -template -inline bool -operator >= (Proxy const & left_, - Proxy const & right_) -{ -SEQAN_CHECKPOINT - typedef typename GetValue >::Type TAccessor; - return convert(left_) >= convert(right_); -} - -////////////////////////////////////////////////////////////////////////////// - -template -inline TStream & -operator >> (TStream & strm, - Proxy & proxy) -{ - typedef Proxy TProxy; - typedef typename Value::Type TValue; - TValue temp; - strm >> temp; - assignValue(iter(proxy), temp); - return strm; -} -template -inline TStream & -operator >> (TStream & strm, - Proxy const& proxy) -{ - typedef Proxy TProxy; - typedef typename Value::Type TValue; - TValue temp; - strm >> temp; - assignValue(iter(proxy), temp); - return strm; -} - - -template -inline TStream & -operator << (TStream & strm, - Proxy & proxy) -{ - return strm << getValue(proxy); -} -template -inline TStream & -operator << (TStream & strm, - Proxy const & proxy) -{ - return strm << getValue(proxy); -} - - -////////////////////////////////////////////////////////////////////////////// -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_tag.h b/SeqAn-1.1/seqan/basic/basic_tag.h deleted file mode 100644 index 3035cbab..00000000 --- a/SeqAn-1.1/seqan/basic/basic_tag.h +++ /dev/null @@ -1,173 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_tag.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_TAG_H -#define SEQAN_HEADER_BASIC_TAG_H - -namespace SEQAN_NAMESPACE_MAIN -{ - - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.DotDrawing -..summary:Switch to trigger drawing in dot format. -..value.DotDrawing:Graphs in dot format. -*/ - -struct DotDrawing_; -typedef Tag const DotDrawing; - - -/** -.Tag.HammingDistance -..summary:Switch to trigger Hamming distance, which is a measure of character substitutions. -*/ - -/** -.Tag.LevenshteinDistance -..summary:Switch to trigger Levenshtein distance, which is a measure of edit operations (character substitutions, deletions or insertions). -*/ - -struct _HammingDistance; -struct _LevenshteinDistance; - -typedef Tag<_HammingDistance> HammingDistance; -typedef Tag<_LevenshteinDistance> LevenshteinDistance; -typedef Tag<_LevenshteinDistance> EditDistance; - - -////////////////////////////////////////////////////////////////////////////// - - -////////////////////////////////////////////////////////////////////////////// -// Alignment: Tags -////////////////////////////////////////////////////////////////////////////// -//Sollte eigentlich nach align/, aber da jetzt ja so viele -//alignment algorithmen in graph/ gelandet sind... - -/** -.Tag.Global Alignment Algorithms: -..summary:Global alignment algorithm used by globalAlignment. -..see:Function.globalAlignment -..see:Tag.Local Alignment Algorithms -*/ - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Global Alignment Algorithms.value.NeedlemanWunsch: - Dynamic programming algorithm for alignments by Needleman and Wunsch. -*/ - -struct NeedlemanWunsch_; -typedef Tag const NeedlemanWunsch; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Global Alignment Algorithms.value.Gotoh: - Gotoh's affine gap cost alignment algorithm. -*/ -struct Gotoh_; -typedef Tag const Gotoh; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Global Alignment Algorithms.value.MyersBitVector: - Myers' bit vector alignment algorithm for edit distance. - Note that this algorithm does not returns the alignment itself, but only computes the score. -*/ -struct MyersBitVector_; -typedef Tag const MyersBitVector; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Global Alignment Algorithms.value.MyersHirschberg: - Myers' bit vector algorithm for edit distance combined with Hirschberg's linear space alignment algorithm. -*/ -struct MyersHirschberg_; -typedef Tag const MyersHirschberg; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Global Alignment Algorithms.value.Hirschberg: - Hirschberg's linear space global alignment algorithm. -*/ -struct Hirschberg_; -typedef Tag const Hirschberg; - -////////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Local Alignment Algorithms: -..summary:Local alignment algorithm used by localAlignment. -..see:Function.localAlignment -*/ - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Local Alignment Algorithms.value.SmithWaterman: - Triggers a Smith Waterman local alignment algorithm. -*/ -struct SmithWaterman_; -typedef Tag const SmithWaterman; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Local Alignment Algorithms.value.SmithWatermanClump: - Local alignment algorithm with "declumping" by Waterman and Eggert. -*/ -struct SmithWatermanClump_; -typedef Tag const SmithWatermanClump; - -////////////////////////////////////////////////////////////////////////////// - -/** -.Tag.Local Alignment Algorithms.value.SmithWatermanIsland: - Local alignment algorithm finding all "islands". -*/ -struct SmithWatermanIsland_; -typedef Tag const SmithWatermanIsland; - -////////////////////////////////////////////////////////////////////////////// - -/*DISABLED -.Tag.RNA Folding Algorithms.value.Nussinov: - Nussinov style RNA folding algorithm -*/ -struct Nussinov_; -typedef Tag const Nussinov; - -////////////////////////////////////////////////////////////////////////////// - - -////////////////////////////////////////////////////////////////////////////// - -}// namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... diff --git a/SeqAn-1.1/seqan/basic/basic_transport.h b/SeqAn-1.1/seqan/basic/basic_transport.h deleted file mode 100644 index 4757d87c..00000000 --- a/SeqAn-1.1/seqan/basic/basic_transport.h +++ /dev/null @@ -1,196 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_transport.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_TRANSPORT_H -#define SEQAN_HEADER_BASIC_TRANSPORT_H - -namespace SEQAN_NAMESPACE_MAIN -{ - -////////////////////////////////////////////////////////////////////////////// -//assign -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.assign: -..summary:Assigns one object to another object. -..cat:Content Manipulation -..signature:assign(target, source) -..signature:assign(target, source [, limit] [,resize_tag]) -..param.target: Gets the content of $source$. -..param.source: Is copied to $target$. -..param.limit: The maximal length of $target$ after the operation. (optional) -...remarks:This arguments can be applied if $target$ is a container. -..param.resize_tag: Specifies the strategy that is applied if $target$ has not enough capacity to store the complete content. (optional) -...type:Tag.Overflow Strategy -...default:Specified by @Metafunction.DefaultOverflowImplicit@ of the $target$ type. -...remarks:This arguments can be applied if $target$ is a container. -..remarks:$assign(target, source)$ is semantically equivalent to $target = source$. -*/ - -template -inline void -assign(TTarget & target, - TSource & source) -{ -SEQAN_CHECKPOINT - target = source; -} -template -inline void -assign(TTarget & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - target = source; -} - -////////////////////////////////////////////////////////////////////////////// - -template struct Proxy; - -template -inline void -assign(Proxy & target, - TSource & source) -{ -SEQAN_CHECKPOINT - assignValue(iter(target), source); -} - -template -inline void -assign(Proxy & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - assignValue(iter(target), source); -} - -////////////////////////////////////////////////////////////////////////////// -// move -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.move: -..summary:Hands over content from one container to another container. -..cat:Content Manipulation -..signature:move(target, source) -..param.target:A container $source$ is moved to. -..param.source:A container that is moved to $target$. -..remarks:The function tries to hand over the contents of $source$ to $target$. -If this is possible, $source$ losts its content and will therefore be empty after this operation. -Otherwise, the function behaves like @Function.assign@ and $source$ is copied to $target$. -..see:Function.assign -*/ - -template -inline void -move(TTarget & target, - TSource & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} -template -inline void -move(TTarget const & target, - TSource & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} -template -inline void -move(TTarget & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} -template -inline void -move(TTarget const & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} - - -////////////////////////////////////////////////////////////////////////////// -// set -////////////////////////////////////////////////////////////////////////////// - -/** -.Function.set: -..summary:Assigns one object to another object avoiding to copy contents. -..cat:Content Manipulation -..signature:assign(target, source) -..signature:assign(target, source) -..param.target: Gets the content of $source$. -..param.source: Content source. -..remarks:$set(target, source)$ is semantically equivalent to $target = source$. -If possible, $set$ copies content references instead of the content itself. -*/ - -//TODO: rename set to ... - -template -inline void -set(TTarget & target, - TSource & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} -template -inline void -set(TTarget const & target, - TSource & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} -template -inline void -set(TTarget & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} -template -inline void -set(TTarget const & target, - TSource const & source) -{ -SEQAN_CHECKPOINT - assign(target, source); -} - - -////////////////////////////////////////////////////////////////////////////// - -} //namespace SEQAN_NAMESPACE_MAIN - -#endif //#ifndef SEQAN_HEADER_... - - diff --git a/SeqAn-1.1/seqan/basic/basic_type.h b/SeqAn-1.1/seqan/basic/basic_type.h deleted file mode 100644 index 320fa999..00000000 --- a/SeqAn-1.1/seqan/basic/basic_type.h +++ /dev/null @@ -1,624 +0,0 @@ - /*========================================================================== - SeqAn - The Library for Sequence Analysis - http://www.seqan.de - ============================================================================ - Copyright (C) 2007 - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 3 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - ============================================================================ - $Id: basic_type.h,v 1.1 2008/08/25 16:20:01 langmead Exp $ - ==========================================================================*/ - -#ifndef SEQAN_HEADER_BASIC_TYPE_H -#define SEQAN_HEADER_BASIC_TYPE_H - -namespace SEQAN_NAMESPACE_MAIN -{ - - -////////////////////////////////////////////////////////////////////////////// - -/** -.Metafunction.Value: -..summary:Type of the items in the container. -..signature:Value::Type -..param.T:Type for which the value type is determined. -..returns.param.Type:Value type of $T$. -..remarks.text:The value type of a container $T$ is the type of the elements in $T$. - For example, the value type of a sequence of $int$ is $int$. -..example.code:Value >::Type c; //c has type char -*/ - -template -struct Value -{ - typedef T Type; -}; -/* -template -struct Value -{ - typedef T Type; -}; -*/ -//____________________________________________________________________________ - -/** -.Metafunction.GetValue: -..summary:Type for reading values. -..signature:GetValue::Type -..param.T:Type of container that holds a value. -..returns.param.Type:GetValue type of $T$. -..remarks.text:Depending on $T$, the $GetValue$-type can either be $Value::Type &$ or $Value::Type$. -..text:$GetValue$ is the return type of @Function.getValue@ that allows a (read-only) access to objects. -Do not confuse it with @Function.value@ that returns a @Metafunction.Reference.reference@ to the value. -..see:Metafunction.Value -..see:Function.getValue -*/ -template -struct GetValue -{ - typedef typename Value::Type const & Type; -}; -template -struct GetValue: - public GetValue -{ -}; - -//____________________________________________________________________________ - -/** -.Metafunction.Reference: -..summary:Reference type. -..signature:Reference::Type -..param.T:A Type. -..returns.param.Type:Either $T &$ or a proxy object @Class.Proxy@ for $T$. -..see:Metafunction.Value -..see:Metafunction.GetValue -*/ -template -struct Reference -{ - typedef typename Value::Type & Type; -}; -template -struct Reference -{ - typedef typename Value::Type const & Type; -}; - -//____________________________________________________________________________ - - -/** -.Metafunction.Size: -..summary:Type of an object that is suitable to hold size information. -..signature:Size::Type -..param.T:Type for which the size type is determined. -..returns.param.Type:Size type of $T$. -..remarks.text:In most cases this type is $size_t$. -*/ -template -struct Size -{ - typedef size_t Type; -}; -template -struct Size: - Size -{ -}; - -//____________________________________________________________________________ - - -/** -.Metafunction.Difference: -..summary:Type of an object that stores the difference between two iterators. -..signature:Difference::Type -..param.T:Type for which the difference type is determined. -...type:Class.Iter -..returns.param.Type:Difference type of $T$. -..remarks.text:In most cases this type is $ptrdiff_t$. -..see:Metafunction.Size -*/ -template -struct Difference -{ - typedef ptrdiff_t Type; -}; -template -struct Difference: - Difference -{ -}; - -//____________________________________________________________________________ - - -/** -.Metafunction.Position: -..summary:Type of an object that represents a position in a container. -..signature:Position::Type -..param.T:Type for which the position type is determined. -...type:Class.Iter -...type:Class.String -..returns.param.Type:Position type of $T$. -..see:Metafunction.Iterator -*/ -template -struct Position -{ - typedef typename Size::Type Type; -}; -template -struct Position: - Position -{ -}; - -//____________________________________________________________________________ - -/** -.Metafunction.Host: -..summary:Type of the object a given object depends on. -..signature:Host::Type -..param.T:Type for which the host type is determined. -..returns.param.Type:Host type of $T$. -*/ -template -struct Host -{ - typedef T Type; -}; - -//____________________________________________________________________________ - -/** -.Metafunction.Spec: -..summary:The spec of a class. -..signature:Spec::Type -..param.T:Type for which the spec is determined. -..returns.param.Type:Spec of $T$. -..remarks:The spec of a SeqAn type is the class that is used in template subclassing - to specify the specialization. - For example, the spec of $String >$ is $Alloc<>$. -*/ - -// default case -template -struct Spec { - typedef void Type; -}; - - -// one argument case -template