Skip to content

Commit 1b04d66

Browse files
jcmoscKyle-Ye
authored andcommitted
Rename OGCounterQueryType to OGGraphCounterQueryType
1 parent 5cb388e commit 1b04d66

File tree

7 files changed

+44
-44
lines changed

7 files changed

+44
-44
lines changed

Sources/OpenGraphCxx/Graph/OGGraph.cpp

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -152,33 +152,33 @@ void OGGraphSetUpdateCallback(OGGraphRef graph,
152152
graph->context.set_update_callback(OG::ClosureFunction<void>(function, context));
153153
}
154154

155-
uint64_t OGGraphGetCounter(OGGraphRef graph, OGCounterQueryType query) {
155+
uint64_t OGGraphGetCounter(OGGraphRef graph, OGGraphCounterQueryType query) {
156156
if (graph->context.isInvalid()) {
157157
OG::precondition_failure("invalidated graph");
158158
}
159159
OG::Graph::Context& context = graph->context;
160160
switch (query) {
161-
case OGCounterQueryTypeNodes:
161+
case OGGraphCounterQueryTypeNodes:
162162
return context.get_graph().get_counter_0();
163-
case OGCounterQueryTypeTransactions:
163+
case OGGraphCounterQueryTypeTransactions:
164164
return context.get_graph().get_counter_1();
165-
case OGCounterQueryTypeUpdates:
165+
case OGGraphCounterQueryTypeUpdates:
166166
return context.get_graph().get_counter_2();
167-
case OGCounterQueryTypeChanges:
167+
case OGGraphCounterQueryTypeChanges:
168168
return context.get_graph().get_counter_3();
169-
case OGCounterQueryTypeContextID:
169+
case OGGraphCounterQueryTypeContextID:
170170
return context.get_graph().get_counter_4();
171-
case OGCounterQueryTypeGraphID:
171+
case OGGraphCounterQueryTypeGraphID:
172172
return context.get_graph().get_counter_5();
173-
case OGCounterQueryTypeContextThreadUpdating:
173+
case OGGraphCounterQueryTypeContextThreadUpdating:
174174
return context.thread_is_updating();
175-
case OGCounterQueryTypeThreadUpdating:
175+
case OGGraphCounterQueryTypeThreadUpdating:
176176
return context.get_graph().thread_is_updating();
177-
case OGCounterQueryTypeContextNeedsUpdate:
177+
case OGGraphCounterQueryTypeContextNeedsUpdate:
178178
return context.get_graph().get_counter_8();
179-
case OGCounterQueryTypeNeedsUpdate:
179+
case OGGraphCounterQueryTypeNeedsUpdate:
180180
return context.get_graph().get_counter_9();
181-
case OGCounterQueryTypeMainThreadUpdates:
181+
case OGGraphCounterQueryTypeMainThreadUpdates:
182182
return context.get_graph().get_counter_10();
183183
default:
184184
return 0;

Sources/OpenGraphCxx/include/OpenGraph/OGCounterQueryType.h

Lines changed: 0 additions & 27 deletions
This file was deleted.

Sources/OpenGraphCxx/include/OpenGraph/OGGraph.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
#include <OpenGraph/OGBase.h>
99
#include <OpenGraph/Private/CFRuntime.h>
10-
#include <OpenGraph/OGCounterQueryType.h>
10+
#include <OpenGraph/OGGraphCounterQueryType.h>
1111

1212
// Note: Place all structure declaration in a single place to avoid header cycle dependency
1313

@@ -87,7 +87,7 @@ void OGGraphSetUpdateCallback(OGGraphRef graph,
8787

8888
OG_EXPORT
8989
OG_REFINED_FOR_SWIFT
90-
uint64_t OGGraphGetCounter(OGGraphRef graph, OGCounterQueryType query) OG_SWIFT_NAME(OGGraphRef.counter(self:for:));
90+
uint64_t OGGraphGetCounter(OGGraphRef graph, OGGraphCounterQueryType query) OG_SWIFT_NAME(OGGraphRef.counter(self:for:));
9191

9292
OG_EXPORT
9393
OG_REFINED_FOR_SWIFT
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
//
2+
// OGGraphCounterQueryType.h
3+
// OpenGraphCxx
4+
5+
#ifndef OGGraphCounterQueryType_h
6+
#define OGGraphCounterQueryType_h
7+
8+
#include <OpenGraph/OGBase.h>
9+
10+
typedef OG_ENUM(uint32_t, OGGraphCounterQueryType) {
11+
OGGraphCounterQueryTypeNodes,
12+
OGGraphCounterQueryTypeTransactions,
13+
OGGraphCounterQueryTypeUpdates,
14+
OGGraphCounterQueryTypeChanges,
15+
OGGraphCounterQueryTypeContextID,
16+
OGGraphCounterQueryTypeGraphID,
17+
OGGraphCounterQueryTypeContextThreadUpdating,
18+
OGGraphCounterQueryTypeThreadUpdating,
19+
OGGraphCounterQueryTypeContextNeedsUpdate,
20+
OGGraphCounterQueryTypeNeedsUpdate,
21+
OGGraphCounterQueryTypeMainThreadUpdates,
22+
OGGraphCounterQueryTypeCreatedNodes,
23+
OGGraphCounterQueryTypeSubgraphs,
24+
OGGraphCounterQueryTypeCreatedSubgraphs,
25+
} OG_SWIFT_NAME(OGGraphRef.CounterQueryType);
26+
27+
#endif /* OGGraphCounterQueryType_h */

Sources/OpenGraphCxx/include/OpenGraph/OpenGraph-umbrella.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@
88
#include <OpenGraph/OGChangedValueFlags.h>
99
#include <OpenGraph/OGClosure.h>
1010
#include <OpenGraph/OGComparison.h>
11-
#include <OpenGraph/OGCounterQueryType.h>
1211
#include <OpenGraph/OGDebugServer.h>
1312
#include <OpenGraph/OGGraph.h>
1413
#include <OpenGraph/OGGraphContext.h>
14+
#include <OpenGraph/OGGraphCounterQueryType.h>
1515
#include <OpenGraph/OGGraphDescription.h>
1616
#include <OpenGraph/OGGraphTracing.h>
1717
#include <OpenGraph/OGInputOptions.h>

Sources/OpenGraphShims/GraphShims.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ public typealias OGAttributeInfo = AGAttributeInfo
88
public typealias OGAttributeType = AGAttributeType
99
public typealias OGCachedValueOptions = AGCachedValueOptions
1010
public typealias OGChangedValueFlags = AGChangedValueFlags
11-
public typealias OGCounterQueryType = AGCounterQueryType
11+
public typealias OGGraphCounterQueryType = AGCounterQueryType
1212
public typealias OGInputOptions = AGInputOptions
1313
public typealias OGTypeApplyOptions = AGTypeApplyOptions
1414
public typealias OGUniqueID = AGUniqueID

Tests/OpenGraphCompatibilityTests/GraphShims.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ public typealias OGAttributeInfo = AGAttributeInfo
88
public typealias OGAttributeType = AGAttributeType
99
public typealias OGCachedValueOptions = AGCachedValueOptions
1010
public typealias OGChangedValueFlags = AGChangedValueFlags
11-
public typealias OGCounterQueryType = AGCounterQueryType
11+
public typealias OGGraphCounterQueryType = AGCounterQueryType
1212
public typealias OGInputOptions = AGInputOptions
1313
public typealias OGTypeApplyOptions = AGTypeApplyOptions
1414
public typealias OGUniqueID = AGUniqueID

0 commit comments

Comments
 (0)