diff --git a/core/src/main/kotlin/net/corda/core/node/services/VaultService.kt b/core/src/main/kotlin/net/corda/core/node/services/VaultService.kt index a9087e12af..55ce1a8284 100644 --- a/core/src/main/kotlin/net/corda/core/node/services/VaultService.kt +++ b/core/src/main/kotlin/net/corda/core/node/services/VaultService.kt @@ -410,6 +410,10 @@ interface VaultService { return _queryBy(criteria, PageSpecification(), Sort(emptySet()), contractStateType) } + fun queryBy(contractStateType: Class, paging: PageSpecification): Vault.Page { + return _queryBy(QueryCriteria.VaultQueryCriteria(), paging, Sort(emptySet()), contractStateType) + } + fun queryBy(contractStateType: Class, criteria: QueryCriteria, paging: PageSpecification): Vault.Page { return _queryBy(criteria, paging, Sort(emptySet()), contractStateType) } @@ -430,6 +434,10 @@ interface VaultService { return _trackBy(criteria, PageSpecification(), Sort(emptySet()), contractStateType) } + fun trackBy(contractStateType: Class, paging: PageSpecification): DataFeed, Vault.Update> { + return _trackBy(QueryCriteria.VaultQueryCriteria(), paging, Sort(emptySet()), contractStateType) + } + fun trackBy(contractStateType: Class, criteria: QueryCriteria, paging: PageSpecification): DataFeed, Vault.Update> { return _trackBy(criteria, paging, Sort(emptySet()), contractStateType) } @@ -451,6 +459,10 @@ inline fun VaultService.queryBy(criteria: QueryCrite return _queryBy(criteria, PageSpecification(), Sort(emptySet()), T::class.java) } +inline fun VaultService.queryBy(paging: PageSpecification): Vault.Page { + return _queryBy(QueryCriteria.VaultQueryCriteria(), paging, Sort(emptySet()), T::class.java) +} + inline fun VaultService.queryBy(criteria: QueryCriteria, paging: PageSpecification): Vault.Page { return _queryBy(criteria, paging, Sort(emptySet()), T::class.java) } @@ -467,6 +479,10 @@ inline fun VaultService.trackBy(): DataFeed VaultService.trackBy(paging: PageSpecification): DataFeed, Vault.Update> { + return _trackBy(QueryCriteria.VaultQueryCriteria(), paging, Sort(emptySet()), T::class.java) +} + inline fun VaultService.trackBy(criteria: QueryCriteria): DataFeed, Vault.Update> { return _trackBy(criteria, PageSpecification(), Sort(emptySet()), T::class.java) }