net.corda.core.contracts

## Class StructuresKt

- net.corda.core.contracts.StructuresKt

-     public class StructuresKt

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static SecureHash` | `hash(ContractState $receiver)` Returns the SHA-256 hash of the serialised contents of this state (not cached!)
    `static <T extends ContractState> TransactionState<T>` | `with notary(T $receiver, Party newNotary)` Wraps the `interface ContractState` in a `class TransactionState` object
    `static <T extends ContractState> TransactionState<T>` | `withNotary(T $receiver, Party newNotary)`
    `static <T> Amount<T>` | `withoutIssuer(Amount<net.corda.core.contracts.Issued> $receiver)` Strips the issuer and returns an `class Amount` of the raw token directly. This is useful when you are mixing code that cares about specific issuers with code that will accept any, or which is imposing issuer constraints via some other mechanism and the additional type safety is not wanted.

- - ### Method Detail

    - #### with notary

          public static <T extends ContractState> TransactionState<T> with notary(T $receiver,
                                                                                  Party newNotary)

      Wraps the `interface ContractState` in a `class TransactionState` object

      See Also:
        `interface ContractState`, `class TransactionState`

    - #### withNotary

          public static <T extends ContractState> TransactionState<T> withNotary(T $receiver,
                                                                                 Party newNotary)

    - #### withoutIssuer

          public static <T> Amount<T> withoutIssuer(Amount<net.corda.core.contracts.Issued> $receiver)

      Strips the issuer and returns an `class Amount` of the raw token directly. This is useful when you are mixing code that cares about specific issuers with code that will accept any, or which is imposing issuer constraints via some other mechanism and the additional type safety is not wanted.

      See Also:
        `class Amount`

    - #### hash

          public static SecureHash hash(ContractState $receiver)

      Returns the SHA-256 hash of the serialised contents of this state (not cached!)