KiCad PCB EDA Suite
Loading...
Searching...
No Matches
sexpr_parser.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2016 Mark Roszko <
[email protected]
>
3
* Copyright The KiCad Developers, see AUTHORS.txt for contributors.
4
*
5
* This program is free software: you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License as published by
7
* the Free Software Foundation, either version 2 of the License, or
8
* (at your option) any later version.
9
*
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
14
*
15
* You should have received a copy of the GNU General Public License
16
* along with this program. If not, see <http://www.gnu.org/licenses/>.
17
*/
18
19
#ifndef SEXPR_PARSER_H_
20
#define SEXPR_PARSER_H_
21
22
#include "
sexpr/sexpr.h
"
23
24
#include <memory>
25
#include <string>
26
#include <vector>
27
28
29
namespace
SEXPR
30
{
31
class
PARSER
32
{
33
public
:
34
PARSER
();
35
~PARSER
();
36
std::unique_ptr<SEXPR>
Parse
(
const
std::string& aString );
37
std::unique_ptr<SEXPR>
ParseFromFile
(
const
std::string& aFilename );
38
static
std::string
GetFileContents
(
const
std::string& aFilename );
39
40
private
:
41
std::unique_ptr<SEXPR>
parseString
(
42
const
std::string& aString, std::string::const_iterator& it );
43
static
const
std::string
whitespaceCharacters
;
44
int
m_lineNumber
;
45
};
46
}
47
48
#endif
SEXPR::PARSER::PARSER
PARSER()
Definition
sexpr_parser.cpp:37
SEXPR::PARSER::m_lineNumber
int m_lineNumber
Definition
sexpr_parser.h:44
SEXPR::PARSER::~PARSER
~PARSER()
Definition
sexpr_parser.cpp:41
SEXPR::PARSER::whitespaceCharacters
static const std::string whitespaceCharacters
Definition
sexpr_parser.h:43
SEXPR::PARSER::parseString
std::unique_ptr< SEXPR > parseString(const std::string &aString, std::string::const_iterator &it)
Definition
sexpr_parser.cpp:81
SEXPR::PARSER::GetFileContents
static std::string GetFileContents(const std::string &aFilename)
Definition
sexpr_parser.cpp:59
SEXPR::PARSER::ParseFromFile
std::unique_ptr< SEXPR > ParseFromFile(const std::string &aFilename)
Definition
sexpr_parser.cpp:51
SEXPR::PARSER::Parse
std::unique_ptr< SEXPR > Parse(const std::string &aString)
Definition
sexpr_parser.cpp:45
SEXPR
Definition
isexprable.h:24
sexpr.h
src
libs
sexpr
include
sexpr
sexpr_parser.h
Generated on Sun Sep 21 2025 01:05:27 for KiCad PCB EDA Suite by
1.13.2