# TimeoutPolicy (dapr-sdk-parent 1.10.0 API)

Package io.dapr.internal.resiliency

## Class TimeoutPolicy

- java.lang.Object
- - io.dapr.internal.resiliency.TimeoutPolicy

    public final class TimeoutPolicy
    extends Object

Timeout policy for SDK communication to Dapr API.

### Constructor Summary

Constructors
`TimeoutPolicy()` Instantiates a new timeout policy with default value.
`TimeoutPolicy​(Duration timeout)` Instantiates a new timeout policy with override value.

### Method Summary

All Methods Instance Methods Concrete Methods
`io.grpc.CallOptions` `apply​(io.grpc.CallOptions options)` Applies the timeout policy to a gRPC call options.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### TimeoutPolicy

    public TimeoutPolicy​(Duration timeout)

Instantiates a new timeout policy with override value.

Parameters:
  `timeout` - Override timeout value.

#### TimeoutPolicy

    public TimeoutPolicy()

Instantiates a new timeout policy with default value.

### Method Detail

#### apply

    public io.grpc.CallOptions apply​(io.grpc.CallOptions options)

Applies the timeout policy to a gRPC call options.

Parameters:
  `options` - Call options
Returns:
  Call options with retry policy applied