forked from stepcode/stepcode
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathStr.h
More file actions
47 lines (37 loc) · 1.58 KB
/
Str.h
File metadata and controls
47 lines (37 loc) · 1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#ifndef STR_H
#define STR_H
/*
* NIST Utils Class Library
* clutils/Str.h
* April 1997
* K. C. Morris
* David Sauder
* Development of this software was funded by the United States Government,
* and is not subject to copyright.
*/
#include <sc_export.h>
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errordesc.h>
#ifndef STRING_DELIM
#define STRING_DELIM '\''
#endif
SC_UTILS_EXPORT char ToLower( const char c );
SC_UTILS_EXPORT char ToUpper( const char c );
SC_UTILS_EXPORT char * StrToLower( const char *, char * );
SC_UTILS_EXPORT const char * StrToLower( const char * word, std::string & s );
SC_UTILS_EXPORT const char * StrToUpper( const char * word, std::string & s );
SC_UTILS_EXPORT const char * StrToConstant( const char * word, std::string & s );
SC_UTILS_EXPORT int StrCmpIns( const char * str1, const char * str2 );
SC_UTILS_EXPORT const char * PrettyTmpName( const char * oldname );
SC_UTILS_EXPORT char * PrettyNewName( const char * oldname );
SC_UTILS_EXPORT char * EntityClassName( char * oldname );
SC_UTILS_EXPORT bool StrEndsWith( const std::string & s, const char * suffix );
SC_UTILS_EXPORT std::string GetLiteralStr( istream & in, ErrorDescriptor * err );
extern SC_UTILS_EXPORT Severity CheckRemainingInput( std::istream & in, ErrorDescriptor * err,
const char * typeName, // used in error message
const char * tokenList ); // e.g. ",)"
extern SC_UTILS_EXPORT Severity CheckRemainingInput( std::istream & in, ErrorDescriptor * err, const std::string typeName, const char * tokenList );
#endif