summary refs log tree commit diff stats
path: root/generator/notion.cpp
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2017-01-24 21:50:39 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2017-01-24 21:50:39 -0500
commite1fa4a088dd95caef22045f905a9d5d22b71bef0 (patch)
tree09f30eadcbb5a7352f19a6070dc363298f16aff8 /generator/notion.cpp
parent0ba0fff06fb679f5cabedd52257fc0c38a600279 (diff)
downloadverbly-e1fa4a088dd95caef22045f905a9d5d22b71bef0.tar.gz
verbly-e1fa4a088dd95caef22045f905a9d5d22b71bef0.tar.bz2
verbly-e1fa4a088dd95caef22045f905a9d5d22b71bef0.zip
Whitespace changes
Diffstat (limited to 'generator/notion.cpp')
-rw-r--r--generator/notion.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/generator/notion.cpp b/generator/notion.cpp index 290d982..1878ba9 100644 --- a/generator/notion.cpp +++ b/generator/notion.cpp
@@ -30,15 +30,15 @@ namespace verbly {
30 { 30 {
31 // Calling code should always call hasWnid and check that the notion is a noun first. 31 // Calling code should always call hasWnid and check that the notion is a noun first.
32 assert(hasWnid_ && (partOfSpeech_ == part_of_speech::noun)); 32 assert(hasWnid_ && (partOfSpeech_ == part_of_speech::noun));
33 33
34 numOfImages_++; 34 numOfImages_++;
35 } 35 }
36 36
37 void notion::setPrepositionGroups(std::list<std::string> groups) 37 void notion::setPrepositionGroups(std::list<std::string> groups)
38 { 38 {
39 // Calling code should always check that the notion is a preposition first. 39 // Calling code should always check that the notion is a preposition first.
40 assert(partOfSpeech_ == part_of_speech::preposition); 40 assert(partOfSpeech_ == part_of_speech::preposition);
41 41
42 prepositionGroups_ = groups; 42 prepositionGroups_ = groups;
43 } 43 }
44 44
@@ -54,7 +54,7 @@ namespace verbly {
54 if (arg.hasWnid()) 54 if (arg.hasWnid())
55 { 55 {
56 fields.emplace_back("wnid", arg.getWnid()); 56 fields.emplace_back("wnid", arg.getWnid());
57 57
58 if (arg.getPartOfSpeech() == part_of_speech::noun) 58 if (arg.getPartOfSpeech() == part_of_speech::noun)
59 { 59 {
60 fields.emplace_back("images", arg.getNumOfImages()); 60 fields.emplace_back("images", arg.getNumOfImages());
@@ -63,17 +63,17 @@ namespace verbly {
63 63
64 db.insertIntoTable("notions", std::move(fields)); 64 db.insertIntoTable("notions", std::move(fields));
65 } 65 }
66 66
67 // Next, serialize the is_a relationship if this is a preposition 67 // Next, serialize the is_a relationship if this is a preposition
68 if (arg.getPartOfSpeech() == part_of_speech::preposition) 68 if (arg.getPartOfSpeech() == part_of_speech::preposition)
69 { 69 {
70 for (std::string group : arg.getPrepositionGroups()) 70 for (std::string group : arg.getPrepositionGroups())
71 { 71 {
72 std::list<field> fields; 72 std::list<field> fields;
73 73
74 fields.emplace_back("notion_id", arg.getId()); 74 fields.emplace_back("notion_id", arg.getId());
75 fields.emplace_back("groupname", group); 75 fields.emplace_back("groupname", group);
76 76
77 db.insertIntoTable("is_a", std::move(fields)); 77 db.insertIntoTable("is_a", std::move(fields));
78 } 78 }
79 } 79 }