-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.h
44 lines (37 loc) · 1.24 KB
/
main.h
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
#ifndef MAIN_H
#define MAIN_H
#include <stdarg.h>
#include <unistd.h>
/**
* struct FormatSpecifierAndDisplayFunction - A structure map format specifier
* to its corresponding display function.
*
* @format_type: The character representing the format specifier.
* @displayFunctionPointer: A function pointer to the function that displays
* the argument according to the format specifier.
*/
typedef struct FormatSpecifierAndDisplayFunction
{
char format_type;
int (*displayFunctionPointer)(va_list);
} FormatSpecifierAndDisplayFunction;
/** Prototypes des fonctions*/
int _printf(const char *format, ...);
int print_character(va_list args);
/** int print_decimal(va_list);*/
int print_int(va_list args);
int print_string(va_list args);
int print_percent(va_list args);
int print_unsigned_int(va_list args);
int print_unsigned_octal(va_list args);
int print_unsigned_hexadecimal(va_list args);
int print_unsigned_Hexadecimal(va_list args);
int print_address(va_list args);
int print_unsigned_bin(va_list args);
int n_u_digit(unsigned int n);
int print_String(va_list va);
int _putchar(char c);
int is_string_equals(const char *, const char *);
int _length(const char *);
int (*find_format_function(char formatCharacter))(va_list arguments);
#endif /** MAIN_H*/