pokeheartgold/include/sys/string.h
2021-11-25 19:47:50 -05:00

26 lines
675 B
C

#ifndef POKEHEARTGOLD_STRING_H
#define POKEHEARTGOLD_STRING_H
#include "constants/charcode.h"
#include "heap.h"
#include "string_util.h"
typedef struct STRING {
u16 maxsize;
u16 size;
u32 magic;
u16 data[1];
u8 padding[2];
} STRING;
STRING *String_ctor(u32 maxsize, HeapID heapId);
void String_dtor(STRING *string);
void CopyStringToU16Array(const STRING *string, u16 *dest, u32 n);
void CopyU16ArrayToString(STRING *string, const u16 *src);
int StringCompare(STRING *a, STRING *b);
void CopyU16StringArray(u16 *dest, const u16 *src);
void StringCopy(STRING *dest, const STRING *src);
void StringSetEmpty(STRING *str);
#endif //POKEHEARTGOLD_STRING_H