libIntegra
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
string_helper.h
Go to the documentation of this file.
1 /* libIntegra modular audio framework
2  *
3  * Copyright (C) 2007 Birmingham City University
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
18  * USA.
19  */
20 
26 #ifndef INTEGRA_STRING_HELPER_H
27 #define INTEGRA_STRING_HELPER_H
28 
29 
30 #include <stdio.h>
31 
32 #include "common_typedefs.h"
33 #include "error.h"
34 
35 namespace integra_api
36 {
42  class INTEGRA_API CStringHelper
43  {
44  public:
45 
50  static string date_to_string( const struct tm &date );
51 
57  static CError string_to_date( const string &string, struct tm &output );
58 
63  static bool validate_node_name( const string &name );
64 
74  static string string_vector_to_string( const string_vector &strings );
75 
86  static bool string_to_string_vector( const string &input, string_vector &output );
87 
92  static string trim( const string &input );
93 
95  static const string node_name_character_set;
96 
101  static const int string_buffer_length = 1024;
102  };
103 }
104 
105 
106 
107 
108 
109 #endif
Common string routines.
Definition: string_helper.h:42
Defines class CError.
Represents an enumeration of error codes.
Definition: error.h:40
#defines and typedefs used throughout the application
static const string node_name_character_set
The set of characters which may be used in node names.
Definition: string_helper.h:95