MCPcopy Create free account
hub / github.com/grpc/grpc-java / withDeadline

Method withDeadline

api/src/main/java/io/grpc/CallOptions.java:167–171  ·  view source on GitHub ↗

Returns a new CallOptions with the given absolute deadline. This is mostly used for propagating an existing deadline. #withDeadlineAfter is the recommended way of setting a new deadline, @param deadline the deadline or null for unsetting the deadline.

(@Nullable Deadline deadline)

Source from the content-addressed store, hash-verified

165 * @param deadline the deadline or {@code null} for unsetting the deadline.
166 */
167 public CallOptions withDeadline(@Nullable Deadline deadline) {
168 Builder builder = toBuilder(this);
169 builder.deadline = deadline;
170 return builder.build();
171 }
172
173 /**
174 * Returns a new {@code CallOptions} with a deadline that is after the given {@code duration} from

Callers 2

mutationMethod · 0.95
withDeadlineAfterMethod · 0.95

Calls 2

toBuilderMethod · 0.95
buildMethod · 0.95

Tested by 1

mutationMethod · 0.76