com.r3corda.core.contracts.clauses / SingleClause

# SingleClause

`abstract class SingleClause : Clause, SingleVerify`

A single verifiable clause. By default always matches, continues to the next clause when matched and errors if not matched.

### Constructors

<init> | `SingleClause()` A single verifiable clause. By default always matches, continues to the next clause when matched and errors if not matched.

### Properties

ifMatched | `open val ifMatched: MatchBehaviour` Behaviour if this clause is not matches
ifNotMatched | `open val ifNotMatched: MatchBehaviour` Behaviour if this clause is matched
requiredCommands | `open val requiredCommands: Set<Class<out CommandData>>` Classes for commands which must ALL be present in transaction for this clause to be triggered

### Inherited Functions

verify | `abstract fun verify(tx: TransactionForContract, commands: Collection<AuthenticatedObject<CommandData>>): Set<CommandData>` Verify the transaction matches the conditions from this clause. For example, a "no zero amount output" clause would check each of the output states that it applies to, looking for a zero amount, and throw IllegalStateException if any matched.

### Inheritors

ClauseVerifier | `class ClauseVerifier<S : LinearState> : SingleClause` Standard clause to verify the LinearState safety properties.
GroupClauseVerifier | `abstract class GroupClauseVerifier<S : ContractState, T : Any> : SingleClause`
InterceptorClause | `class InterceptorClause : SingleClause` A clause which intercepts calls to a wrapped clause, and passes them through verification only from a pre-clause. This is similar to an inceptor in aspect orientated programming.
NetClause | `open class NetClause<P> : SingleClause` Clause for netting contract states. Currently only supports obligation contract.
Timestamped | `class Timestamped : SingleClause`
VerifyLifecycle | `class VerifyLifecycle<P> : SingleClause, GroupClause<State<P>, Issued<Terms<P>>>` Obligation-specific clause for verifying that all states are in normal lifecycle. In a group clause set, this must be run after any lifecycle change clause, which is the only clause that involve non-standard lifecycle states on input/output.