public void markAsSpent ( TransactionInput input ) { checkState ( availableForSpending ) ; availableForSpending = false ; spentBy = input ; if ( parent != null ) if ( log . isDebugEnabled ( ) ) log . debug ( "Marked {}:{} as spent by {}" , getParentTransactionHash ( ) , getIndex ( ) , input ) ; else if ( log . isDebugEnabled ( ) ) log . debug ( "Marked floating output as spent by {}" , input ) ; }
Sets this objects availableForSpending flag to false and the spentBy pointer to the given input . If the input is null it means this output was signed over to somebody else rather than one of our own keys .