aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/google/protobuf/compiler/objectivec/objectivec_field.h
diff options
context:
space:
mode:
authorGravatar Thomas Van Lenten <thomasvl@google.com>2015-05-21 17:14:52 -0400
committerGravatar Thomas Van Lenten <thomasvl@google.com>2015-05-22 14:27:31 -0400
commit1dcc329427fd103a0abd96ab787270f5d0a31861 (patch)
treecf1c52df0e1effa3d0985a3406a71c38c3a4e487 /src/google/protobuf/compiler/objectivec/objectivec_field.h
parentc3480926f98eb7c45224daae5cf0373e120b3b8d (diff)
Objective C Second Alpha Drop
- Style fixups in the code. - map<> serialization fixes and more tests. - Autocreation of map<> fields (to match repeated fields). - @@protoc_insertion_point(global_scope|imports). - Fixup proto2 syntax extension support. - Move all startup code to +initialize so it happen on class usage and not app startup. - Have generated headers use forward declarations and move imports into generated code, reduces what is need at compile time to speed up compiled and avoid pointless rippling of rebuilds.
Diffstat (limited to 'src/google/protobuf/compiler/objectivec/objectivec_field.h')
-rw-r--r--src/google/protobuf/compiler/objectivec/objectivec_field.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/google/protobuf/compiler/objectivec/objectivec_field.h b/src/google/protobuf/compiler/objectivec/objectivec_field.h
index c65e73b2..130a52dd 100644
--- a/src/google/protobuf/compiler/objectivec/objectivec_field.h
+++ b/src/google/protobuf/compiler/objectivec/objectivec_field.h
@@ -65,6 +65,8 @@ class FieldGenerator {
virtual void GenerateCFunctionDeclarations(io::Printer* printer) const;
virtual void GenerateCFunctionImplementations(io::Printer* printer) const;
+ virtual void DetermineForwardDeclarations(set<string>* fwd_decls) const;
+
void SetOneofIndexBase(int index_base);
string variable(const char* key) const {
@@ -79,7 +81,7 @@ class FieldGenerator {
string raw_field_name() const { return variable("raw_field_name"); }
protected:
- FieldGenerator(const FieldDescriptor* descriptor);
+ explicit FieldGenerator(const FieldDescriptor* descriptor);
virtual void FinishInitialization(void);
virtual bool WantsHasProperty(void) const = 0;
@@ -101,7 +103,7 @@ class SingleFieldGenerator : public FieldGenerator {
virtual void GeneratePropertyImplementation(io::Printer* printer) const;
protected:
- SingleFieldGenerator(const FieldDescriptor* descriptor);
+ explicit SingleFieldGenerator(const FieldDescriptor* descriptor);
virtual bool WantsHasProperty(void) const;
private:
@@ -117,7 +119,7 @@ class ObjCObjFieldGenerator : public SingleFieldGenerator {
virtual void GeneratePropertyDeclaration(io::Printer* printer) const;
protected:
- ObjCObjFieldGenerator(const FieldDescriptor* descriptor);
+ explicit ObjCObjFieldGenerator(const FieldDescriptor* descriptor);
private:
GOOGLE_DISALLOW_EVIL_CONSTRUCTORS(ObjCObjFieldGenerator);
@@ -133,7 +135,7 @@ class RepeatedFieldGenerator : public ObjCObjFieldGenerator {
virtual void GeneratePropertyImplementation(io::Printer* printer) const;
protected:
- RepeatedFieldGenerator(const FieldDescriptor* descriptor);
+ explicit RepeatedFieldGenerator(const FieldDescriptor* descriptor);
virtual void FinishInitialization(void);
virtual bool WantsHasProperty(void) const;
@@ -144,7 +146,7 @@ class RepeatedFieldGenerator : public ObjCObjFieldGenerator {
// Convenience class which constructs FieldGenerators for a Descriptor.
class FieldGeneratorMap {
public:
- FieldGeneratorMap(const Descriptor* descriptor);
+ explicit FieldGeneratorMap(const Descriptor* descriptor);
~FieldGeneratorMap();
const FieldGenerator& get(const FieldDescriptor* field) const;