FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
JSONSki/example/example3.cpp at master · AutomataLab/JSONSki · GitHub
AutomataLab
/
JSONSki
Public
Notifications
You must be signed in to change notification settings
Fork
3
Star
33
Code
Issues
0
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
JSONSki
/
example
/
example3.cpp
Copy path
More file actions
More file actions
Latest commit
History
History
History
19 lines (17 loc) · 597 Bytes
Breadcrumbs
JSONSki
/
example
/
example3.cpp
Copy path
File metadata and controls
19 lines (17 loc) · 597 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#
include
"
../src/lib/RecordLoader.h
"
#
include
"
../src/lib/QueryProcessor.h
"
int
main
() {
char
* file_path =
"
../dataset/twitter_sample_small_records.json
"
;
RecordSet* record_set =
RecordLoader::loadRecords
(file_path);
if
(record_set->
size
() ==
0
) {
cout<<
"
record loading fails.
"
<<endl;
return
-
1
;
}
QueryProcessor
processor
(
"
$.entities.urls[*].url
"
);
int
num_recs = record_set->
size
();
for
(
int
i =
0
; i < num_recs; i++) {
string output = processor.
runQuery
((*record_set)[i]);
cout<<
"
matches are:
"
<<output<<endl;
}
return
0
;
}
Back
|
FazBrowse Home
|
New Git URL