File: AllTestRecord.cs

package info (click to toggle)
avro-java 1.8.2-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid, trixie
  • size: 12,784 kB
  • sloc: java: 58,236; ansic: 27,618; cpp: 15,332; cs: 12,876; python: 10,443; xml: 6,338; php: 3,836; ruby: 3,158; perl: 1,656; sh: 733; lex: 203; yacc: 140; makefile: 7
file content (209 lines) | stat: -rw-r--r-- 5,228 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
// ------------------------------------------------------------------------------
// <auto-generated>
//    Generated by avrogen.exe, version 0.9.0.0
//    Changes to this file may cause incorrect behavior and will be lost if code
//    is regenerated
// </auto-generated>
// ------------------------------------------------------------------------------
namespace org.apache.avro.test
{
	using System;
	using System.Collections.Generic;
	using System.Text;
	using Avro;
	using Avro.Specific;
	
	public partial class AllTestRecord : ISpecificRecord
	{
		private static Schema _SCHEMA = Avro.Schema.Parse(@"{""type"":""record"",""name"":""AllTestRecord"",""namespace"":""org.apache.avro.test"",""fields"":[{""name"":""booleanTest"",""type"":""boolean""},{""name"":""intTest"",""type"":""int""},{""name"":""longTest"",""type"":""long""},{""name"":""floatTest"",""type"":""float""},{""name"":""doubleTest"",""type"":""double""},{""name"":""bytesTest"",""type"":""bytes""},{""name"":""stringTest"",""type"":""string""},{""name"":""enumTest"",""type"":{""type"":""enum"",""name"":""AllEnum"",""namespace"":""org.apache.avro.test"",""symbols"":[""FOO"",""BAR""]}},{""name"":""fixedTest"",""type"":{""type"":""fixed"",""name"":""FixedTest"",""namespace"":""org.apache.avro.test"",""size"":10}},{""name"":""arrayTest"",""type"":{""type"":""array"",""items"":""long""}},{""name"":""mapTest"",""type"":{""type"":""map"",""values"":""long""}},{""name"":""nestedTest"",""type"":[""AllTestRecord"",""null""]}]}");
		private bool _booleanTest;
		private int _intTest;
		private long _longTest;
		private float _floatTest;
		private double _doubleTest;
		private byte[] _bytesTest;
		private string _stringTest;
		private org.apache.avro.test.AllEnum _enumTest;
		private org.apache.avro.test.FixedTest _fixedTest;
		private IList<System.Int64> _arrayTest;
		private IDictionary<string,System.Int64> _mapTest;
		private org.apache.avro.test.AllTestRecord _nestedTest;
		public virtual Schema Schema
		{
			get
			{
				return AllTestRecord._SCHEMA;
			}
		}
		public bool booleanTest
		{
			get
			{
				return this._booleanTest;
			}
			set
			{
				this._booleanTest = value;
			}
		}
		public int intTest
		{
			get
			{
				return this._intTest;
			}
			set
			{
				this._intTest = value;
			}
		}
		public long longTest
		{
			get
			{
				return this._longTest;
			}
			set
			{
				this._longTest = value;
			}
		}
		public float floatTest
		{
			get
			{
				return this._floatTest;
			}
			set
			{
				this._floatTest = value;
			}
		}
		public double doubleTest
		{
			get
			{
				return this._doubleTest;
			}
			set
			{
				this._doubleTest = value;
			}
		}
		public byte[] bytesTest
		{
			get
			{
				return this._bytesTest;
			}
			set
			{
				this._bytesTest = value;
			}
		}
		public string stringTest
		{
			get
			{
				return this._stringTest;
			}
			set
			{
				this._stringTest = value;
			}
		}
		public org.apache.avro.test.AllEnum enumTest
		{
			get
			{
				return this._enumTest;
			}
			set
			{
				this._enumTest = value;
			}
		}
		public org.apache.avro.test.FixedTest fixedTest
		{
			get
			{
				return this._fixedTest;
			}
			set
			{
				this._fixedTest = value;
			}
		}
		public IList<System.Int64> arrayTest
		{
			get
			{
				return this._arrayTest;
			}
			set
			{
				this._arrayTest = value;
			}
		}
		public IDictionary<string,System.Int64> mapTest
		{
			get
			{
				return this._mapTest;
			}
			set
			{
				this._mapTest = value;
			}
		}
		public org.apache.avro.test.AllTestRecord nestedTest
		{
			get
			{
				return this._nestedTest;
			}
			set
			{
				this._nestedTest = value;
			}
		}
		public virtual object Get(int fieldPos)
		{
			switch (fieldPos)
			{
			case 0: return this.booleanTest;
			case 1: return this.intTest;
			case 2: return this.longTest;
			case 3: return this.floatTest;
			case 4: return this.doubleTest;
			case 5: return this.bytesTest;
			case 6: return this.stringTest;
			case 7: return this.enumTest;
			case 8: return this.fixedTest;
			case 9: return this.arrayTest;
			case 10: return this.mapTest;
			case 11: return this.nestedTest;
			default: throw new AvroRuntimeException("Bad index " + fieldPos + " in Get()");
			};
		}
		public virtual void Put(int fieldPos, object fieldValue)
		{
			switch (fieldPos)
			{
			case 0: this.booleanTest = (System.Boolean)fieldValue; break;
			case 1: this.intTest = (System.Int32)fieldValue; break;
			case 2: this.longTest = (System.Int64)fieldValue; break;
			case 3: this.floatTest = (System.Single)fieldValue; break;
			case 4: this.doubleTest = (System.Double)fieldValue; break;
			case 5: this.bytesTest = (System.Byte[])fieldValue; break;
			case 6: this.stringTest = (System.String)fieldValue; break;
			case 7: this.enumTest = (org.apache.avro.test.AllEnum)fieldValue; break;
			case 8: this.fixedTest = (org.apache.avro.test.FixedTest)fieldValue; break;
			case 9: this.arrayTest = (IList<System.Int64>)fieldValue; break;
			case 10: this.mapTest = (IDictionary<string,System.Int64>)fieldValue; break;
			case 11: this.nestedTest = (org.apache.avro.test.AllTestRecord)fieldValue; break;
			default: throw new AvroRuntimeException("Bad index " + fieldPos + " in Put()");
			};
		}
	}
}