Coconut Framework  beta
CNTextString.h
Go to the documentation of this file.
1 
8 #ifndef CNTEXTSTRING_H
9 #define CNTEXTSTRING_H
10 
11 #include "CNForwarders.h"
12 
15 {
17  size_t length ;
19  unsigned char * string ;
20 } ;
21 
26 static inline struct CNTextString
28 {
29  const struct CNTextString empty = {0, NULL} ;
30  return empty ;
31 }
32 
38 static inline const unsigned char *
40 {
41  return src->string ;
42 }
43 
49 static inline size_t
51 {
52  return src->length ;
53 }
54 
55 #endif /* CNTEXTSTRING_H */
Forward declaration of data types.
static size_t CNLengthOfTextString(const struct CNTextString *src)
Get length of source text-string.
Definition: CNTextString.h:50
size_t length
Definition: CNTextString.h:17
unsigned char * string
Definition: CNTextString.h:19
static struct CNTextString CNMakeEmptyTextString(void)
Return empty text-string.
Definition: CNTextString.h:27
Definition: CNTextString.h:14
static const unsigned char * CNContentOfTextString(const struct CNTextString *src)
Get content of source text-string.
Definition: CNTextString.h:39