THRIFT-551. java: Enumeration doesn't generate real enum in Java
This patch makes the compiler generate actual Enum classes.
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@882211 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/test/DebugProtoTest.thrift b/test/DebugProtoTest.thrift
index 5b2f672..549462e 100644
--- a/test/DebugProtoTest.thrift
+++ b/test/DebugProtoTest.thrift
@@ -252,6 +252,11 @@
void myMethod(4: string first, 3: i16 second, 2: i32 third, 1: i64 fourth);
}
+enum SomeEnum {
+ ONE
+ TWO
+}
+
union TestUnion {
/**
* A doc string
@@ -261,6 +266,7 @@
3: OneOfEach struct_field;
4: list<RandomStuff> struct_list;
5: i32 other_i32_field;
+ 6: SomeEnum enum_field;
}
union ComparableUnion {
diff --git a/test/ThriftTest.thrift b/test/ThriftTest.thrift
index 3517640..f16c02e 100644
--- a/test/ThriftTest.thrift
+++ b/test/ThriftTest.thrift
@@ -23,6 +23,9 @@
namespace perl ThriftTest
namespace csharp Thrift.Test
+/**
+ * Docstring!
+ */
enum Numberz
{
ONE = 1,