//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: //ORIGINAL LINE: void perform(io.netty.channel.ChannelHandlerContext ctx) throws java.io.IOException internal virtual void Perform(ChannelHandlerContext ctx) { CheckPointer checkPointer = _checkPointerSupplier.get(); Resource checkPointLock = _mutex.storeCopy(() => checkPointer.TryCheckPoint(new SimpleTriggerInfo("Store copy"))); Future <Void> completion = null; try { using (RawCursor <StoreResource, IOException> resources = _resourceStreamFactory.create()) { while (resources.Next()) { StoreResource resource = resources.get(); _protocol.stream(ctx, resource); } completion = _protocol.end(ctx, SUCCESS); } } finally { if (completion != null) { completion.addListener(f => checkPointLock.close()); } else { checkPointLock.Close(); } } }
public override void Close() { if (_resource != null) { _resource.close(); _resource = null; } }
protected internal AbstractTraverserIterator(Resource resource) { this._resource = resource; }