#include <stddef.h>
Go to the source code of this file.
|
void * | memcpy (void *dest, const void *src, size_t len) |
|
void * | memset (void *dest, int val, size_t len) |
|
int | strcmp (const char *s1, const char *s2) |
|
size_t | strlen (const char *str) |
|
char * | strcpy (char *dest, const char *src) |
|
char * | strtok (const char *str, const char *delim) |
|
char * | strrev (char *str) |
|
void | int_to_ascii (int n, char *str) |
|
void | hex_to_ascii (unsigned int n, char *str) |
|
void | append (char *s, char n) |
|
void | backspace (char *s) |
|
◆ append()
void append |
( |
char * |
s, |
|
|
char |
n |
|
) |
| |
Appends a character to a string
- Parameters
-
s | The string |
n | The character to append |
◆ backspace()
void backspace |
( |
char * |
s | ) |
|
Deletes the last character of a string
- Parameters
-
◆ hex_to_ascii()
void hex_to_ascii |
( |
unsigned int |
n, |
|
|
char * |
str |
|
) |
| |
Converts a number to a base 16 string
- Parameters
-
n | The number to convert |
str | A buffer to hold the converted number |
◆ int_to_ascii()
void int_to_ascii |
( |
int |
n, |
|
|
char * |
str |
|
) |
| |
Converts a number to a base 10 string
- Parameters
-
n | The number to convert |
str | A buffer to hold the converted number |
◆ memcpy()
void* memcpy |
( |
void * |
dest, |
|
|
const void * |
src, |
|
|
size_t |
len |
|
) |
| |
Copies a block of memory from one address to another
- Parameters
-
dest | The destination address |
src | The source address |
len | The length of the block |
- Returns
- the destination address
◆ memset()
void* memset |
( |
void * |
dest, |
|
|
int |
val, |
|
|
size_t |
len |
|
) |
| |
Sets a block of memory to a byte
- Parameters
-
dest | The block to set |
val | The byte to set it to |
len | The length of the block |
- Returns
- the destination address
◆ strcmp()
int strcmp |
( |
const char * |
s1, |
|
|
const char * |
s2 |
|
) |
| |
Compares two strings
- Parameters
-
s1 | String 1 to compare |
s2 | String 2 to compare |
- Returns
- 0 if the strings are the same, otherwise the difference between the values of the first non-identical character
◆ strcpy()
char* strcpy |
( |
char * |
dest, |
|
|
const char * |
src |
|
) |
| |
Copies a string from one address to another
- Parameters
-
dest | The destination string |
src | The source string |
- Returns
- the destination string
◆ strlen()
size_t strlen |
( |
const char * |
str | ) |
|
Gets the length of a string
- Parameters
-
str | The string to get the length of |
- Returns
- the length of the string
◆ strrev()
char* strrev |
( |
char * |
str | ) |
|
Reverses a string in place
- Parameters
-
- Returns
- the string
◆ strtok()
char* strtok |
( |
const char * |
str, |
|
|
const char * |
delim |
|
) |
| |
Reads characters from a string until it hits a delimeter character
- Parameters
-
str | The string to read from (or NULL if you are continuing tokenization) |
delim | A stribg containing possible delimeter characters. |
- Returns
- the read characters, not including the delmimeter. This string will be overwritten by sucessive calls to strtok.