net.corda.core.contracts

## Class TransactionGraphSearch

- net.corda.core.contracts.TransactionGraphSearch

-     public class TransactionGraphSearch

  Given a map of transaction id to `class SignedTransaction`, performs a breadth first search of the dependency graph from the starting point down in order to find transactions that match the given query criteria.

  Currently, only one kind of query is supported: find any transaction that contains a command of the given type.

  In future, this should support restricting the search by time, and other types of useful query.

  See Also:
    `class SignedTransaction`

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `TransactionGraphSearch.Query`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `TransactionGraphSearch(ReadOnlyTransactionStorage transactions, java.util.List<net.corda.core.transactions.WireTransaction> startPoints)` Given a map of transaction id to `class SignedTransaction`, performs a breadth first search of the dependency graph from the starting point down in order to find transactions that match the given query criteria.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.List<net.corda.core.transactions.WireTransaction>` | `call()`
    `TransactionGraphSearch.Query` | `getQuery()`
    `java.util.List<net.corda.core.transactions.WireTransaction>` | `getStartPoints()`
    `ReadOnlyTransactionStorage` | `getTransactions()`
    `void` | `setQuery(TransactionGraphSearch.Query p)`

- - ### Constructor Detail

    - #### TransactionGraphSearch

          public TransactionGraphSearch(ReadOnlyTransactionStorage transactions,
                                        java.util.List<net.corda.core.transactions.WireTransaction> startPoints)

      Given a map of transaction id to `class SignedTransaction`, performs a breadth first search of the dependency graph from the starting point down in order to find transactions that match the given query criteria.

      Currently, only one kind of query is supported: find any transaction that contains a command of the given type.

      In future, this should support restricting the search by time, and other types of useful query.

      Parameters:
        `transactions` - map of transaction id to `class SignedTransaction`.
        `startPoints` - transactions to use as starting points for the search.
      See Also:
        `class SignedTransaction`

  - ### Method Detail

    - #### getQuery

          public TransactionGraphSearch.Query getQuery()

    - #### setQuery

          public void setQuery(TransactionGraphSearch.Query p)

    - #### call

          public java.util.List<net.corda.core.transactions.WireTransaction> call()

    - #### getTransactions

          public ReadOnlyTransactionStorage getTransactions()

    - #### getStartPoints

          public java.util.List<net.corda.core.transactions.WireTransaction> getStartPoints()