//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @SuppressWarnings("resource") @Override public void createCommands(java.util.Collection<org.neo4j.storageengine.api.StorageCommand> commands, org.neo4j.storageengine.api.txstate.ReadableTransactionState txState, org.neo4j.storageengine.api.StorageReader storageReader, org.neo4j.storageengine.api.lock.ResourceLocker locks, long lastTransactionIdWhenStarted, org.neo4j.storageengine.api.txstate.TxStateVisitor_Decorator additionalTxStateVisitor) throws org.neo4j.internal.kernel.api.exceptions.TransactionFailureException, org.neo4j.internal.kernel.api.exceptions.schema.CreateConstraintFailureException, org.neo4j.internal.kernel.api.exceptions.schema.ConstraintValidationException //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public override void CreateCommands(ICollection <StorageCommand> commands, ReadableTransactionState txState, StorageReader storageReader, ResourceLocker locks, long lastTransactionIdWhenStarted, Org.Neo4j.Storageengine.Api.txstate.TxStateVisitor_Decorator additionalTxStateVisitor) { if (txState != null) { // We can make this cast here because we expected that the storageReader passed in here comes from // this storage engine itself, anything else is considered a bug. And we do know the inner workings // of the storage statements that we create. RecordStorageCommandCreationContext creationContext = (( RecordStorageReader )storageReader).CommandCreationContext; TransactionRecordState recordState = creationContext.CreateTransactionRecordState(_integrityValidator, lastTransactionIdWhenStarted, locks); // Visit transaction state and populate these record state objects TxStateVisitor txStateVisitor = new TransactionToRecordStateVisitor(recordState, _schemaState, _schemaStorage, _constraintSemantics); CountsRecordState countsRecordState = new CountsRecordState(); txStateVisitor = additionalTxStateVisitor.apply(txStateVisitor); txStateVisitor = new TransactionCountingStateVisitor(txStateVisitor, storageReader, txState, countsRecordState); using (TxStateVisitor visitor = txStateVisitor) { txState.Accept(visitor); } // Convert record state into commands recordState.ExtractCommands(commands); countsRecordState.ExtractCommands(commands); } }
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: //ORIGINAL LINE: private org.neo4j.kernel.impl.transaction.log.PhysicalTransactionRepresentation transactionRepresentationOf(TransactionRecordState tx) throws org.neo4j.internal.kernel.api.exceptions.TransactionFailureException private PhysicalTransactionRepresentation TransactionRepresentationOf(TransactionRecordState tx) { IList <StorageCommand> commands = new List <StorageCommand>(); tx.ExtractCommands(commands); return(new PhysicalTransactionRepresentation(commands)); }