Parsing.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 1996-2023 The Squid Software Foundation and contributors
3 *
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
7 */
8
9/* DEBUG: section 03 Configuration File Parsing */
10
11#ifndef SQUID_PARSING_H
12#define SQUID_PARSING_H
13
14#include "ip/Address.h"
15
16double xatof(const char *token);
17int xatoi(const char *token);
18unsigned int xatoui(const char *token, char eov = '\0');
19long xatol(const char *token);
20int64_t xatoll(const char *token, int base, char eov = '\0');
21uint64_t xatoull(const char *token, int base, char eov = '\0');
22unsigned short xatos(const char *token);
23
27int64_t GetInteger64(void);
28
34int GetInteger(void);
35
47double GetPercentage(bool limit = true);
48
49unsigned short GetShort(void);
50
51// on success, returns true and sets *p (if any) to the end of the integer
52bool StringToInt(const char *str, int &result, const char **p, int base);
53bool StringToInt64(const char *str, int64_t &result, const char **p, int base);
54
61bool GetHostWithPort(char *token, Ip::Address *ipa);
62
63#endif /* SQUID_PARSING_H */
64
int64_t xatoll(const char *token, int base, char eov='\0')
Definition: Parsing.cc:86
unsigned int xatoui(const char *token, char eov='\0')
Definition: Parsing.cc:58
bool GetHostWithPort(char *token, Ip::Address *ipa)
Definition: Parsing.cc:257
double GetPercentage(bool limit=true)
Definition: Parsing.cc:178
double xatof(const char *token)
Definition: Parsing.cc:25
uint64_t xatoull(const char *token, int base, char eov='\0')
Definition: Parsing.cc:105
unsigned short xatos(const char *token)
Definition: Parsing.cc:114
bool StringToInt(const char *str, int &result, const char **p, int base)
Definition: Parsing.cc:217
bool StringToInt64(const char *str, int64_t &result, const char **p, int base)
Definition: Parsing.cc:237
int64_t GetInteger64(void)
Definition: Parsing.cc:132
unsigned short GetShort(void)
Definition: Parsing.cc:205
int GetInteger(void)
Definition: Parsing.cc:148
long xatol(const char *token)
Definition: Parsing.cc:72
int xatoi(const char *token)
Definition: Parsing.cc:44

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors