internal TransactionLogFile(TransactionLogFiles logFiles, TransactionLogFilesContext context) { this._rotateAtSize = context.RotationThreshold; this._context = context; this._logFiles = logFiles; this._readerLogVersionBridge = new ReaderLogVersionBridge(logFiles); }
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: //ORIGINAL LINE: public org.neo4j.kernel.impl.transaction.log.ReadableLogChannel getReader(org.neo4j.kernel.impl.transaction.log.LogPosition position, org.neo4j.kernel.impl.transaction.log.LogVersionBridge logVersionBridge) throws java.io.IOException public override ReadableLogChannel GetReader(LogPosition position, LogVersionBridge logVersionBridge) { PhysicalLogVersionedStoreChannel logChannel = _logFiles.openForVersion(position.LogVersion); logChannel.Position(position.ByteOffset); return(new ReadAheadLogChannel(logChannel, logVersionBridge)); }
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: //ORIGINAL LINE: private int transactionCount() throws java.io.IOException private int TransactionCount() { return(AggregateLogData(version => { int counter = 0; LogVersionBridge bridge = channel => channel; LogVersionedStoreChannel versionedStoreChannel = _files.openForVersion(version); using (ReadableLogChannel channel = new ReadAheadLogChannel(versionedStoreChannel, bridge, 1000)) { using (PhysicalTransactionCursor <ReadableLogChannel> physicalTransactionCursor = new PhysicalTransactionCursor <ReadableLogChannel>(channel, new VersionAwareLogEntryReader <>())) { while (physicalTransactionCursor.Next()) { counter++; } } } return counter; })); }
public ReadAheadLogChannel(LogVersionedStoreChannel startingChannel, LogVersionBridge bridge, int readAheadSize) : base(startingChannel, readAheadSize) { this._bridge = bridge; }
public ReadAheadLogChannel(LogVersionedStoreChannel startingChannel, LogVersionBridge bridge) : this(startingChannel, bridge, DefaultReadAheadSize) { }