Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dlib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
钟尚武
dlib
Commits
e9e0b65d
Commit
e9e0b65d
authored
Nov 12, 2012
by
Davis King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
simplified example program
parent
e1ce4b6e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
11 deletions
+3
-11
config_reader_ex.cpp
examples/config_reader_ex.cpp
+3
-11
No files found.
examples/config_reader_ex.cpp
View file @
e9e0b65d
...
...
@@ -15,14 +15,6 @@
#include <vector>
// Here I'm just making a typedef of the config reader we will be using. If you
// look at the documentation you will see that there are two possible config_reader
// types we could use here. The other one is a thread-safe version for use in an
// application that needs to access a global config reader from multiple threads.
// But we aren't doing that here so I'm using the normal kind.
typedef
dlib
::
config_reader
cr_type
;
using
namespace
std
;
using
namespace
dlib
;
...
...
@@ -64,7 +56,7 @@ user2 {
// ----------------------------------------------------------------------------------------
void
print_config_reader_contents
(
const
c
r_type
&
cr
,
const
c
onfig_reader
&
cr
,
int
depth
=
0
);
/*
...
...
@@ -78,7 +70,7 @@ int main()
{
try
{
c
r_type
cr
(
"config.txt"
);
c
onfig_reader
cr
(
"config.txt"
);
// Use our recursive function to print everything in the config file.
print_config_reader_contents
(
cr
);
...
...
@@ -121,7 +113,7 @@ int main()
// ----------------------------------------------------------------------------------------
void
print_config_reader_contents
(
const
c
r_type
&
cr
,
const
c
onfig_reader
&
cr
,
int
depth
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment