| Class ModifiedString Allows to modify arbitrary strings by specializing what differs from an origin.
ContainerConcept
ModifiedString
ModReverse | ModView
ModifiedString<THost[, TSpec]> Include Headers seqan/modifier.h Parameters
THost | Original sequence type. Types: ContainerConcept
TSpec | The modifier type. Metafunctions: Spec
Remarks THost can also be a modified string, so you can create custom strings by combining predefined ones. Implements ContainerConcept Specializations
ModReverse | Mirrors the characters from begin to end.
ModView | Transforms the characters of the THost string/iterator using a custom function.
Metafunctions
Host | Type of the object a given object depends on.
IsSequence | Determines whether a container stores its elements in sequential order.
Iterator | Type of iterator objects that are used to traverse the container.
Size | Type of an object that is suitable to hold size information.
Functions
assignValue | Assigns value to item. (ContainerConcept)
back | The last item in container. (ContainerConcept)
begin | The begin of a container. (ContainerConcept)
beginPosition | Begin position of object in host. (ContainerConcept)
end | The end of a container. (ContainerConcept)
endPosition | End position of object in host. (ContainerConcept)
front | The first item in container. (ContainerConcept)
getValue | Access to the value. (ContainerConcept)
length | The number of items/characters. (ContainerConcept)
moveValue | Assigns value to item. (ContainerConcept)
position | Position of an iterator. (ContainerConcept)
Shortcuts
Dna5StringComplement | Modifier for the complement of a Dna5String.
Dna5StringReverse | Modifier for the reverse of a Dna5String.
Dna5StringReverseComplement | Modifier for the reverse complement of a Dna5String.
DnaStringComplement | Modifier for the complement of a DnaString.
DnaStringReverse | Modifier for the reverse of a DnaString.
DnaStringReverseComplement | Modifier for the reverse complement of a DnaString.
Rna5StringComplement | Modifier for the complement of a Rna5String.
Rna5StringReverse | Modifier for the reverse of a Rna5String.
Rna5StringReverseComplement | Modifier for the reverse complement of a Rna5String.
RnaStringComplement | Modifier for the complement of a RnaString.
RnaStringReverse | Modifier for the reverse of a RnaString.
RnaStringReverseComplement | Modifier for the reverse complement of a RnaString.
Examples File "modified_string.cpp"
1 | #include <seqan/basic.h>
2 | #include <seqan/sequence.h>
3 | #include <seqan/file.h> // for I/O
4 | #include <seqan/modifier.h>
5 |
6 | using namespace seqan;
7 |
8 | int main()
9 | {
10 | String<Dna> seq = "TATACGCGAAAA";
11 | ModifiedString< String<Dna>, ModReverse > myModifier(seq);
12 |
13 | std::cout << seq << std::endl;
14 | std::cout << myModifier << std::endl;
15 | replace(seq, 8, 12, "TTTT");
16 | std::cout << std::endl;
17 | std::cout << seq << std::endl;
18 | std::cout << myModifier << std::endl;
19 |
20 | return 0;
21 | }
22 |
The output is as follows: TATACGCGAAAA AAAAGCGCATAT TATACGCGTTTT TTTTGCGCATAT Example Programs ModView, ModReverse, Nested Modifiers See Also RnaStringReverse, RnaStringComplement, Dna5StringReverseComplement, RnaStringReverseComplement, DnaStringReverseComplement, Dna5StringComplement, Rna5StringReverseComplement, Rna5StringComplement, Dna5StringReverse, DnaStringComplement, Rna5StringReverse, DnaStringReverse SeqAn - Sequence Analysis Library - www.seqan.de

Page built @2014/10/13 16:12:56