yijunyu/c-to-rust huggingface dataset:
// Original:
public ModifySpotFleetRequestResult modifySpotFleetRequest(ModifySpotFleetRequestRequest request) {request = beforeClientExecution(request);return executeModifySpotFleetRequest(request);}

// Translation:
public virtual ModifySpotFleetRequestResponse ModifySpotFleetRequest(ModifySpotFleetRequestRequest request){var options = new InvokeOptions();options.RequestMarshaller = ModifySpotFleetRequestRequestMarshaller.Instance;options.ResponseUnmarshaller = ModifySpotFleetRequestResponseUnmarshaller.Instance;return Invoke<ModifySpotFleetRequestResponse>(request, options);}
// Original:
public UncalcedRecord() {_reserved = 0;}

// Translation:
public UncalcedRecord(){_reserved = 0;}
// Original:
public static PageOrder valueOf(int value){return _table[value];}

// Translation:
public static PageOrder ValueOf(int value){return _table[value];}
// Original:
public static CellValue valueOf(boolean booleanValue) {return booleanValue ? TRUE : FALSE;}

// Translation:
public static CellValue ValueOf(bool boolValue){return boolValue ? TRUE : FALSE;}
// Original:
public void write(String str) {buf.append(str);}

// Translation:
public override void write(string str){buf.append(str);}
// Original:
public void addListener(HSSFListener lsnr, short sid) {List<HSSFListener> list = _records.computeIfAbsent(Short.valueOf(sid), k -> new ArrayList<>(1));list.add(lsnr);}

// Translation:
public void AddListener(IHSSFListener lsnr, short sid){IList list = null;Object obj = records[sid];if (obj != null){list = (IList)obj;}else{list = new ArrayList(1);   list.Add(lsnr);records[sid]=list;}}
// Original:
public GetMeetingResult getMeeting(GetMeetingRequest request) {request = beforeClientExecution(request);return executeGetMeeting(request);}

// Translation:
public virtual GetMeetingResponse GetMeeting(GetMeetingRequest request){var options = new InvokeOptions();options.RequestMarshaller = GetMeetingRequestMarshaller.Instance;options.ResponseUnmarshaller = GetMeetingResponseUnmarshaller.Instance;return Invoke<GetMeetingResponse>(request, options);}
// Original:
public void stopTimer() {stop = true;}

// Translation:
public void StopTimer(){stop = true;}
// Original:
public AttachLoadBalancerTargetGroupsResult attachLoadBalancerTargetGroups(AttachLoadBalancerTargetGroupsRequest request) {request = beforeClientExecution(request);return executeAttachLoadBalancerTargetGroups(request);}

// Translation:
public virtual AttachLoadBalancerTargetGroupsResponse AttachLoadBalancerTargetGroups(AttachLoadBalancerTargetGroupsRequest request){var options = new InvokeOptions();options.RequestMarshaller = AttachLoadBalancerTargetGroupsRequestMarshaller.Instance;options.ResponseUnmarshaller = AttachLoadBalancerTargetGroupsResponseUnmarshaller.Instance;return Invoke<AttachLoadBalancerTargetGroupsResponse>(request, options);}
// Original:
public GetQueryLoggingConfigResult getQueryLoggingConfig(GetQueryLoggingConfigRequest request) {request = beforeClientExecution(request);return executeGetQueryLoggingConfig(request);}

// Translation:
public virtual GetQueryLoggingConfigResponse GetQueryLoggingConfig(GetQueryLoggingConfigRequest request){var options = new InvokeOptions();options.RequestMarshaller = GetQueryLoggingConfigRequestMarshaller.Instance;options.ResponseUnmarshaller = GetQueryLoggingConfigResponseUnmarshaller.Instance;return Invoke<GetQueryLoggingConfigResponse>(request, options);}
// Original:
public ListIterator<E> listIterator() {Object[] snapshot = elements;return new CowIterator<E>(snapshot, 0, snapshot.length);}

// Translation:
public virtual java.util.ListIterator<E> listIterator(){object[] snapshot = elements;return new java.util.concurrent.CopyOnWriteArrayList.CowIterator<E>(snapshot, 0,snapshot.Length);}
// Original:
public CreateSnapshotResult createSnapshot(CreateSnapshotRequest request) {request = beforeClientExecution(request);return executeCreateSnapshot(request);}

// Translation:
public virtual CreateSnapshotResponse CreateSnapshot(CreateSnapshotRequest request){var options = new InvokeOptions();options.RequestMarshaller = CreateSnapshotRequestMarshaller.Instance;options.ResponseUnmarshaller = CreateSnapshotResponseUnmarshaller.Instance;return Invoke<CreateSnapshotResponse>(request, options);}
// Original:
public boolean hasObject(AnyObjectId objectId) {try {return getObjectDatabase().has(objectId);} catch (IOException e) {throw new UncheckedIOException(e);}}

// Translation:
public virtual bool HasObject(AnyObjectId objectId){try{return ObjectDatabase.Has(objectId);}catch (IOException){return false;}}
// Original:
public final void sort(int from, int to) {checkRange(from, to);mergeSort(from, to);}

// Translation:
public override sealed void Sort(int from, int to){CheckRange(from, to);MergeSort(from, to);}
// Original:
public <T extends EscherRecord> T getChildById( short recordId ) {for ( EscherRecord childRecord : this ) {if ( childRecord.getRecordId() == recordId ) {@SuppressWarnings( "unchecked" )final T result = (T) childRecord;return result;}}return null;}

// Translation:
public EscherRecord GetChildById(short recordId){for (IEnumerator iterator = _childRecords.GetEnumerator(); iterator.MoveNext(); ){EscherRecord escherRecord = (EscherRecord)iterator.Current;if (escherRecord.RecordId == recordId)return escherRecord;}return null;}
// Original:
public void serialize(LittleEndianOutput out) {out.writeShort(field_1_xBasis);out.writeShort(field_2_yBasis);out.writeShort(field_3_heightBasis);out.writeShort(field_4_scale);out.writeShort(field_5_indexToFontTable);}

// Translation:
public override void Serialize(ILittleEndianOutput out1){out1.WriteShort(field_1_xBasis);out1.WriteShort(field_2_yBasis);out1.WriteShort(field_3_heightBasis);out1.WriteShort(field_4_scale);out1.WriteShort(field_5_indexToFontTable);}
// Original:
public static String toHex(int value) {StringBuilder sb = new StringBuilder(8);writeHex(sb, value & 0xFFFFFFFFL, 8, "");return sb.toString();}

// Translation:
public static string ToHex(int value){return ToHex((long)value, 8);}
// Original:
public static Collection<Ref> sort(Collection<Ref> refs) {final List<Ref> r = new ArrayList<>(refs);Collections.sort(r, INSTANCE);return r;}

// Translation:
public static ICollection<Ref> Sort(ICollection<Ref> refs){IList<Ref> r = new AList<Ref>(refs);r.Sort(INSTANCE);return r;}
// Original:
public DescribeVpcsResult describeVpcs() {return describeVpcs(new DescribeVpcsRequest());}

// Translation:
public virtual DescribeVpcsResponse DescribeVpcs(){return DescribeVpcs(new DescribeVpcsRequest());}
// Original:
public ListProposalsResult listProposals(ListProposalsRequest request) {request = beforeClientExecution(request);return executeListProposals(request);}

// Translation:
public virtual ListProposalsResponse ListProposals(ListProposalsRequest request){var options = new InvokeOptions();options.RequestMarshaller = ListProposalsRequestMarshaller.Instance;options.ResponseUnmarshaller = ListProposalsResponseUnmarshaller.Instance;return Invoke<ListProposalsResponse>(request, options);}
// Original:
public void close() throws IOException {flush();output.close();}

// Translation:
public override void close(){throw new System.NotImplementedException();}
// Original:
public final T get() {return object;}

// Translation:
public T Get(){return m_object;}
// Original:
public BundleInstanceRequest(String instanceId, Storage storage) {setInstanceId(instanceId);setStorage(storage);}

// Translation:
public BundleInstanceRequest(string instanceId, Storage storage){_instanceId = instanceId;_storage = storage;}
// Original:
public void back(int delta) {if (delta == 1 && 0 <= prevPtr) {currPtr = prevPtr;prevPtr = -1;if (!eof())parseEntry();return;} else if (delta <= 0)throw new ArrayIndexOutOfBoundsException(delta);final int[] trace = new int[delta + 1];Arrays.fill(trace, -1);int ptr = 0;while (ptr != currPtr) {System.arraycopy(trace, 1, trace, 0, delta);trace[delta] = ptr;while (raw[ptr] != 0)ptr++;ptr += OBJECT_ID_LENGTH + 1;}if (trace[1] == -1)throw new ArrayIndexOutOfBoundsException(delta);prevPtr = trace[0];currPtr = trace[1];parseEntry();}

// Translation:
public override void Back(int delta){if (delta == 1 && 0 <= prevPtr){currPtr = prevPtr;prevPtr = -1;if (!Eof){ParseEntry();}return;}else{if (delta <= 0){throw Sharpen.Extensions.CreateIndexOutOfRangeException(delta);}}int[] trace = new int[delta + 1];Arrays.Fill(trace, -1);int ptr = 0;while (ptr != currPtr){System.Array.Copy(trace, 1, trace, 0, delta);trace[delta] = ptr;while (raw[ptr] != 0){ptr++;}ptr += Constants.OBJECT_ID_LENGTH + 1;}if (trace[1] == -1){throw Sharpen.Extensions.CreateIndexOutOfRangeException(delta);}prevPtr = trace[0];currPtr = trace[1];ParseEntry();}
// Original:
public String toString() {return "pred_"+ruleIndex+":"+predIndex;}

// Translation:
public override string ToString(){return "pred_" + ruleIndex + ":" + predIndex;}
// Original:
public PatternSyntaxException(String description, String pattern, int index) {this.desc = description;this.pattern = pattern;this.index = index;}

// Translation:
public PatternSyntaxException(string description, string pattern, int index){this.desc = description;this.pattern = pattern;this.index = index;}
// Original:
public AlphaAnimation(float from, float to) {mStartAlpha = from;mEndAlpha = to;mCurrentAlpha = from;}

// Translation:
public AlphaAnimation(float fromAlpha, float toAlpha){mFromAlpha = fromAlpha;mToAlpha = toAlpha;}
// Original:
public int doLogic() throws Exception {TaxonomyWriter taxonomyWriter = getRunData().getTaxonomyWriter();if (taxonomyWriter != null) {taxonomyWriter.commit();} else {throw new IllegalStateException("TaxonomyWriter is not currently open");}return 1;}

// Translation:
public override int DoLogic(){ITaxonomyWriter taxonomyWriter = RunData.TaxonomyWriter;if (taxonomyWriter != null){taxonomyWriter.Commit();}else{throw new InvalidOperationException("TaxonomyWriter is not currently open");}return 1;}
// Original:
public DeltaIndex(byte[] sourceBuffer) {src = sourceBuffer;DeltaIndexScanner scan = new DeltaIndexScanner(src, src.length);table = scan.table;tableMask = scan.tableMask;entries = new long[1 + countEntries(scan)];copyEntries(scan);}

// Translation:
public DeltaIndex(byte[] sourceBuffer){src = sourceBuffer;DeltaIndexScanner scan = new DeltaIndexScanner(src, src.Length);table = scan.table;tableMask = scan.tableMask;entries = new long[1 + CountEntries(scan)];CopyEntries(scan);}
// Original:
public int previousIndex() {return pos;}

// Translation:
public int previousIndex(){return pos;}
// Original:
public QueryMaker getQueryMaker() {return getRunData().getQueryMaker(this);}

// Translation:
public override IQueryMaker GetQueryMaker(){return RunData.GetQueryMaker(this);}
// Original:
public JapaneseTokenizerFactory(Map<String,String> args) {super(args);mode = Mode.valueOf(get(args, MODE, JapaneseTokenizer.DEFAULT_MODE.toString()).toUpperCase(Locale.ROOT));userDictionaryPath = args.remove(USER_DICT_PATH);userDictionaryEncoding = args.remove(USER_DICT_ENCODING);discardPunctuation = getBoolean(args, DISCARD_PUNCTUATION, true);discardCompoundToken = getBoolean(args, DISCARD_COMPOUND_TOKEN, true);nbestCost = getInt(args, NBEST_COST, 0);nbestExamples = args.remove(NBEST_EXAMPLES);if (!args.isEmpty()) {throw new IllegalArgumentException("Unknown parameters: " + args);}}

// Translation:
public JapaneseTokenizerFactory(IDictionary<string, string> args): base(args){Enum.TryParse(Get(args, MODE, JapaneseTokenizer.DEFAULT_MODE.ToString()), true, out mode);userDictionaryPath = Get(args, USER_DICT_PATH);userDictionaryEncoding = Get(args, USER_DICT_ENCODING);discardPunctuation = GetBoolean(args, DISCARD_PUNCTUATION, true);if (args.Count > 0){throw new ArgumentException("Unknown parameters: " + args);}}
// Original:
public Long longValue(String key) {String value = responseMap.get(key);if (null == value || 0 == value.length()) {return null;}return Long.valueOf(responseMap.get(key));}

// Translation:
public long? LongValue(string key){if (null != DictionaryUtil.Get(ResponseDictionary, key)){return long.Parse(DictionaryUtil.Get(ResponseDictionary, key));}return null;}
// Original:
public GetLibraryRequest() {super("CloudPhoto", "2017-07-11", "GetLibrary", "cloudphoto");setProtocol(ProtocolType.HTTPS);}

// Translation:
public GetLibraryRequest(): base("CloudPhoto", "2017-07-11", "GetLibrary", "cloudphoto", "openAPI"){Protocol = ProtocolType.HTTPS;}
// Original:
public short getFontOfFormattingRun(int index) {FormatRun r = _string.getFormatRun(index);return r.getFontIndex();}

// Translation:
public short GetFontOfFormattingRun(int index){UnicodeString.FormatRun r = _string.GetFormatRun(index);return r.FontIndex;}
// Original:
public int fillFields(byte[] data, int offset, EscherRecordFactory recordFactory) {int bytesRemaining = readHeader( data, offset );int pos            = offset + 8;int size           = 0;field_1_shapeIdMax     =  LittleEndian.getInt( data, pos + size );size+=4;size+=4;field_3_numShapesSaved =  LittleEndian.getInt( data, pos + size );size+=4;field_4_drawingsSaved  =  LittleEndian.getInt( data, pos + size );size+=4;field_5_fileIdClusters.clear();int numIdClusters = (bytesRemaining-size) / 8;for (int i = 0; i < numIdClusters; i++) {int drawingGroupId = LittleEndian.getInt( data, pos + size );int numShapeIdsUsed = LittleEndian.getInt( data, pos + size + 4 );FileIdCluster fic = new FileIdCluster(drawingGroupId, numShapeIdsUsed);field_5_fileIdClusters.add(fic);maxDgId = Math.max(maxDgId, drawingGroupId);size += 8;}bytesRemaining -= size;if (bytesRemaining != 0) {throw new RecordFormatException("Expecting no remaining data but got " + bytesRemaining + " byte(s).");}return 8 + size;}

// Translation:
public override int FillFields(byte[] data, int offset, IEscherRecordFactory recordFactory){int bytesRemaining = ReadHeader(data, offset);int pos = offset + 8;int size = 0;field_1_shapeIdMax = LittleEndian.GetInt(data, pos + size); size += 4;int field_2_numIdClusters = LittleEndian.GetInt(data, pos + size); size += 4;field_3_numShapesSaved = LittleEndian.GetInt(data, pos + size); size += 4;field_4_drawingsSaved = LittleEndian.GetInt(data, pos + size); size += 4;field_5_fileIdClusters = new FileIdCluster[(bytesRemaining - size) / 8];  for (int i = 0; i < field_5_fileIdClusters.Length; i++){field_5_fileIdClusters[i] = new FileIdCluster(LittleEndian.GetInt(data, pos + size), LittleEndian.GetInt(data, pos + size + 4));maxDgId = Math.Max(maxDgId, field_5_fileIdClusters[i].DrawingGroupId);size += 8;}bytesRemaining -= size;if (bytesRemaining != 0)throw new RecordFormatException("Expecting no remaining data but got " + bytesRemaining + " byte(s).");return 8 + size + bytesRemaining;}
// Original:
public void encode(int[] values, int valuesOffset, byte[] blocks,int blocksOffset, int iterations) {for (int i = 0; i < iterations; ++i) {final long block = encode(values, valuesOffset);valuesOffset += valueCount;blocksOffset = writeLong(block, blocks, blocksOffset);}}

// Translation:
public override void Encode(long[] values, int valuesOffset, byte[] blocks, int blocksOffset, int iterations){for (int i = 0; i < iterations; ++i){long block = Encode(values, valuesOffset);valuesOffset += valueCount;blocksOffset = WriteInt64(block, blocks, blocksOffset);}}
// Original:
public GetTerminologyResult getTerminology(GetTerminologyRequest request) {request = beforeClientExecution(request);return executeGetTerminology(request);}

// Translation:
public virtual GetTerminologyResponse GetTerminology(GetTerminologyRequest request){var options = new InvokeOptions();options.RequestMarshaller = GetTerminologyRequestMarshaller.Instance;options.ResponseUnmarshaller = GetTerminologyResponseUnmarshaller.Instance;return Invoke<GetTerminologyResponse>(request, options);}
// Original:
public void serialize(LittleEndianOutput out) {out.writeShort(_character);out.writeShort(_fontIndex);}

// Translation:
public void Serialize(ILittleEndianOutput out1){out1.WriteShort(_character);out1.WriteShort(_fontIndex);}
// Original:
public void serialize(LittleEndianOutput out) {out.writeShort(field_1_options);}

// Translation:
public override void Serialize(ILittleEndianOutput out1){out1.WriteShort(field_1_options);}
// Original:
public SearchFacesResult searchFaces(SearchFacesRequest request) {request = beforeClientExecution(request);return executeSearchFaces(request);}

// Translation:
public virtual SearchFacesResponse SearchFaces(SearchFacesRequest request){var options = new InvokeOptions();options.RequestMarshaller = SearchFacesRequestMarshaller.Instance;options.ResponseUnmarshaller = SearchFacesResponseUnmarshaller.Instance;return Invoke<SearchFacesResponse>(request, options);}
// Original:
public int getPositionIncrementGap(String fieldName) {return getWrappedAnalyzer(fieldName).getPositionIncrementGap(fieldName);}

// Translation:
public override int GetPositionIncrementGap(string fieldName){return GetWrappedAnalyzer(fieldName).GetPositionIncrementGap(fieldName);}
// Original:
public DescribeSchemaResult describeSchema(DescribeSchemaRequest request) {request = beforeClientExecution(request);return executeDescribeSchema(request);}

// Translation:
public virtual DescribeSchemaResponse DescribeSchema(DescribeSchemaRequest request){var options = new InvokeOptions();options.RequestMarshaller = DescribeSchemaRequestMarshaller.Instance;options.ResponseUnmarshaller = DescribeSchemaResponseUnmarshaller.Instance;return Invoke<DescribeSchemaResponse>(request, options);}
// Original:
@Override public int size() {return BoundedMap.this.size();}

// Translation:
public override int size(){return this._enclosing.size();}
// Original:
public MutableEntry cloneEntry() {final MutableEntry r = new MutableEntry();ensureId();r.idBuffer.fromObjectId(idBuffer);r.offset = offset;return r;}

// Translation:
public virtual PackIndex.MutableEntry CloneEntry(){PackIndex.MutableEntry r = new PackIndex.MutableEntry();EnsureId();r.idBuffer.FromObjectId(idBuffer);r.offset = offset;return r;}
// Original:
public OperateEquipmentRequest() {super("industry-brain", "2018-07-12", "OperateEquipment");setProtocol(ProtocolType.HTTPS);setMethod(MethodType.POST);}

// Translation:
public OperateEquipmentRequest(): base("industry-brain", "2018-07-12", "OperateEquipment"){Protocol = ProtocolType.HTTPS;Method = MethodType.POST;}
// Original:
public boolean add(E e) {synchronized (mutex) {return delegate().add(e);}}

// Translation:
public virtual bool add(E @object){lock (mutex){return c.add(@object);}}
// Original:
public boolean equals( Object o ){if ( this == o ) {return true;}if ( !( o instanceof EscherSimpleProperty ) ) {return false;}final EscherSimpleProperty escherSimpleProperty = (EscherSimpleProperty) o;if ( propertyValue != escherSimpleProperty.propertyValue ) {return false;}if ( getId() != escherSimpleProperty.getId() ) {return false;}return true;}

// Translation:
public override bool Equals(Object o){if (this == o) return true;if (!(o is EscherSimpleProperty)) return false;EscherSimpleProperty escherSimpleProperty = (EscherSimpleProperty)o;if (propertyValue != escherSimpleProperty.propertyValue) return false;if (Id != escherSimpleProperty.Id) return false;return true;}
// Original:
public final FloatBuffer asFloatBuffer() {return FloatToByteBufferAdapter.asFloatBuffer(this);}

// Translation:
public sealed override java.nio.FloatBuffer asFloatBuffer(){return java.nio.FloatToByteBufferAdapter.asFloatBuffer(this);}
// Original:
public void removeThumbnail() {remove1stProperty(PropertyIDMap.PID_THUMBNAIL);}

// Translation:
public void RemoveThumbnail(){MutableSection s = (MutableSection)FirstSection;s.RemoveProperty(PropertyIDMap.PID_THUMBNAIL);}
// Original:
public static int compareIgnoreCase(String a, String b) {for (int i = 0; i < a.length() && i < b.length(); i++) {int d = toLowerCase(a.charAt(i)) - toLowerCase(b.charAt(i));if (d != 0)return d;}return a.length() - b.length();}

// Translation:
public static int CompareIgnoreCase(string a, string b){for (int i = 0; i < a.Length && i < b.Length; i++){int d = ToLowerCase(a[i]) - ToLowerCase(b[i]);if (d != 0){return d;}}return a.Length - b.Length;}
// Original:
public ViewDefinitionRecord(RecordInputStream in) {rwFirst = in.readUShort();rwLast = in.readUShort();colFirst = in.readUShort();colLast = in.readUShort();rwFirstHead = in.readUShort();rwFirstData = in.readUShort();colFirstData = in.readUShort();iCache = in.readUShort();reserved = in.readUShort();sxaxis4Data = in.readUShort();ipos4Data = in.readUShort();cDim = in.readUShort();cDimRw = in.readUShort();cDimCol = in.readUShort();cDimPg = in.readUShort();cDimData = in.readUShort();cRw = in.readUShort();cCol = in.readUShort();grbit = in.readUShort();itblAutoFmt = in.readUShort();int cchName = in.readUShort();int cchData = in.readUShort();name = StringUtil.readUnicodeString(in, cchName);dataField = StringUtil.readUnicodeString(in, cchData);}

// Translation:
public ViewDefinitionRecord(RecordInputStream in1){rwFirst = in1.ReadUShort();rwLast = in1.ReadUShort();colFirst = in1.ReadUShort();colLast = in1.ReadUShort();rwFirstHead = in1.ReadUShort();rwFirstData = in1.ReadUShort();colFirstData = in1.ReadUShort();iCache = in1.ReadUShort();reserved = in1.ReadUShort();sxaxis4Data = in1.ReadUShort();ipos4Data = in1.ReadUShort();cDim = in1.ReadUShort();cDimRw = in1.ReadUShort();cDimCol = in1.ReadUShort();cDimPg = in1.ReadUShort();cDimData = in1.ReadUShort();cRw = in1.ReadUShort();cCol = in1.ReadUShort();grbit = in1.ReadUShort();itblAutoFmt = in1.ReadUShort();int cchName = in1.ReadUShort();int cchData = in1.ReadUShort();name = StringUtil.ReadUnicodeString(in1, cchName);dataField = StringUtil.ReadUnicodeString(in1, cchData);}
// Original:
public FormatRecord(RecordInputStream in) {field_1_index_code = in.readShort();int field_3_unicode_len = in.readUShort();field_3_hasMultibyte = (in.readByte() & 0x01) != 0;if (field_3_hasMultibyte) {field_4_formatstring = readStringCommon(in, field_3_unicode_len, false);} else {field_4_formatstring = readStringCommon(in, field_3_unicode_len, true);}}

// Translation:
public FormatRecord(RecordInputStream in1){field_1_index_code = in1.ReadShort();int field_3_unicode_len = in1.ReadShort();field_3_hasMultibyte = (in1.ReadByte() & (byte)0x01) != 0;if (field_3_hasMultibyte){field_4_formatstring = in1.ReadUnicodeLEString(field_3_unicode_len);}else{field_4_formatstring = in1.ReadCompressedUnicode(field_3_unicode_len);}}
// Original:
public DescribeBrokerResult describeBroker(DescribeBrokerRequest request) {request = beforeClientExecution(request);return executeDescribeBroker(request);}

// Translation:
public virtual DescribeBrokerResponse DescribeBroker(DescribeBrokerRequest request){var options = new InvokeOptions();options.RequestMarshaller = DescribeBrokerRequestMarshaller.Instance;options.ResponseUnmarshaller = DescribeBrokerResponseUnmarshaller.Instance;return Invoke<DescribeBrokerResponse>(request, options);}
// Original:
public void reset() {if ( getInputStream()!=null ) getInputStream().seek(0);_errHandler.reset(this);_ctx = null;_syntaxErrors = 0;matchedEOF = false;setTrace(false);_precedenceStack.clear();_precedenceStack.push(0);ATNSimulator interpreter = getInterpreter();if (interpreter != null) {interpreter.reset();}}

// Translation:
public virtual void Reset(){if (((ITokenStream)InputStream) != null){((ITokenStream)InputStream).Seek(0);}_errHandler.Reset(this);_ctx = null;_syntaxErrors = 0;#if !PORTABLETrace = false;#endif_precedenceStack.Clear();_precedenceStack.Add(0);ATNSimulator interpreter = Interpreter;if (interpreter != null){interpreter.Reset();}}
// Original:
public boolean remove(Object o) {final RevFlag flag = (RevFlag) o;if ((mask & flag.mask) == 0)return false;mask &= ~flag.mask;for (int i = 0; i < active.size(); i++)if (active.get(i).mask == flag.mask)active.remove(i);return true;}

// Translation:
public override bool Remove(object o){RevFlag flag = (RevFlag)o;if ((mask & flag.mask) == 0){return false;}mask &= ~flag.mask;for (int i = 0; i < active.Count; i++){if (active[i].mask == flag.mask){active.Remove(i);}}return true;}