1 #ifndef VIENNA_RNA_PACKAGE_STRING_UTILS_H
2 #define VIENNA_RNA_PACKAGE_STRING_UTILS_H
5 #define VRNA_BACKWARD_COMPAT
7 #ifdef DEPRECATION_WARNINGS
9 # define DEPRECATED(func) func __attribute__ ((deprecated))
11 # define DEPRECATED(func) func
14 # define DEPRECATED(func) func
30 #define XSTR(s) STR(s)
37 #ifndef FILENAME_MAX_LENGTH
45 #define FILENAME_MAX_LENGTH 80
53 #define FILENAME_ID_LENGTH 42
60 char *strdup(
const char *s);
142 #ifdef VRNA_BACKWARD_COMPAT
162 DEPRECATED(
char *
random_string(
int l,
const char symbols[]));
169 DEPRECATED(
int hamming(
const char *s1,
const char *s2));
176 DEPRECATED(
int hamming_bound(
const char *s1,
const char *s2,
int n));
void str_uppercase(char *sequence)
Convert an input sequence to uppercase.
int vrna_hamming_distance(const char *s1, const char *s2)
Calculate hamming distance between two sequences.
int vrna_hamming_distance_bound(const char *s1, const char *s2, int n)
Calculate hamming distance between two sequences up to a specified length.
char * vrna_random_string(int l, const char symbols[])
Create a random string using characters from a specified symbol set.
void vrna_seq_toRNA(char *sequence)
Convert an input sequence (possibly containing DNA alphabet characters) to RNA alphabet.
char * vrna_cut_point_insert(const char *string, int cp)
Add a separating '&' character into a string according to cut-point position.
void str_DNA2RNA(char *sequence)
Convert a DNA input sequence to RNA alphabet.
char * vrna_cut_point_remove(const char *string, int *cp)
Remove a separating '&' character from a string.
int hamming(const char *s1, const char *s2)
Calculate hamming distance between two sequences.
char * random_string(int l, const char symbols[])
Create a random string using characters from a specified symbol set.
void vrna_seq_toupper(char *sequence)
Convert an input sequence to uppercase.
int hamming_bound(const char *s1, const char *s2, int n)
Calculate hamming distance between two sequences up to a specified length.