Skip navigation links
A B C E F G H L N R S T W 

A

allocate() - Static method in class com.github.phantomthief.scope.ScopeKey
 

B

beginScope() - Static method in class com.github.phantomthief.scope.Scope
正常应该优先使用 Scope.supplyWithNewScope(com.github.phantomthief.util.ThrowableSupplier<T, X>) 或者 Scope.runWithNewScope(com.github.phantomthief.util.ThrowableRunnable<X>) 手工使用beginScope和endScope的场景只有在: 上面两个方法当需要抛出多个正交异常时会造成不必要的try/catch代码 开始scope和结束scope不在一个代码块中

C

callWithRetry(long, RetryPolicy, ThrowableSupplier<ListenableFuture<T>, X>) - Method in class com.github.phantomthief.scope.ScopeAsyncRetry
带重试的调用
callWithRetry(long, RetryPolicy, ThrowableSupplier<ListenableFuture<T>, X>, FutureCallback<T>) - Method in class com.github.phantomthief.scope.ScopeAsyncRetry
 
close() - Method in interface com.github.phantomthief.scope.LongCostTrack
 
com.github.phantomthief.scope - package com.github.phantomthief.scope
 
createScopeAsyncRetry(ScheduledExecutorService) - Static method in class com.github.phantomthief.scope.ScopeAsyncRetry
Deprecated.
createScopeAsyncRetry(ScheduledExecutorService, Executor) - Static method in class com.github.phantomthief.scope.ScopeAsyncRetry
 

E

endScope() - Static method in class com.github.phantomthief.scope.Scope
 

F

fastThreadLocalEnabled() - Static method in class com.github.phantomthief.scope.Scope
 

G

get(ScopeKey<T>) - Method in class com.github.phantomthief.scope.Scope
 
get() - Method in class com.github.phantomthief.scope.ScopeKey
 
getCurrentScope() - Static method in class com.github.phantomthief.scope.Scope
 

H

hedge() - Method in interface com.github.phantomthief.scope.RetryPolicy
返回true则不cancel任何一次重试,重试过程中任何一次返回成功都拿来做最终结果 返回false则开始下一次重试时,之前超时的请求就算后来结果成功返回也没有用

L

LongCostTrack - Interface in com.github.phantomthief.scope
当请求结束时,调用close() 关闭追踪

N

NO_RETRY - Static variable in interface com.github.phantomthief.scope.RetryPolicy
 
noRetry() - Static method in interface com.github.phantomthief.scope.RetryPolicy
 

R

retry(int) - Method in interface com.github.phantomthief.scope.RetryPolicy
 
retryNTimes(int) - Static method in interface com.github.phantomthief.scope.RetryPolicy
 
retryNTimes(int, long) - Static method in interface com.github.phantomthief.scope.RetryPolicy
 
retryNTimes(int, long, boolean) - Static method in interface com.github.phantomthief.scope.RetryPolicy
 
RetryPolicy - Interface in com.github.phantomthief.scope
 
runAsyncWithCurrentScope(Runnable, Executor) - Static method in class com.github.phantomthief.scope.ScopeUtils
 
runAsyncWithCurrentScope(Runnable, ListeningExecutorService) - Static method in class com.github.phantomthief.scope.ScopeUtils
 
runWithExistScope(Scope, ThrowableRunnable<X>) - Static method in class com.github.phantomthief.scope.Scope
 
runWithNewScope(ThrowableRunnable<X>) - Static method in class com.github.phantomthief.scope.Scope
 

S

Scope - Class in com.github.phantomthief.scope
自定义Scope,支持如下功能: 开启一个自定义的Scope,在Scope范围内,可以通过 Scope 各个方法读写数据 可以通过 Scope.supplyWithExistScope(com.github.phantomthief.scope.Scope, com.github.phantomthief.util.ThrowableSupplier<T, X>) 或者 Scope.runWithExistScope(com.github.phantomthief.scope.Scope, com.github.phantomthief.util.ThrowableRunnable<X>) 绑定已经存在的scope 举个栗子:
Scope() - Constructor for class com.github.phantomthief.scope.Scope
 
ScopeAsyncRetry - Class in com.github.phantomthief.scope
支持 Scope 级联,并且支持单次调用独立设置超时的异步重试封装
ScopeKey<T> - Class in com.github.phantomthief.scope
强类型数据读写的封装
ScopeUtils - Class in com.github.phantomthief.scope
 
set(ScopeKey<T>, T) - Method in class com.github.phantomthief.scope.Scope
 
set(T) - Method in class com.github.phantomthief.scope.ScopeKey
 
shared() - Static method in class com.github.phantomthief.scope.ScopeAsyncRetry
共享的 ScopeAsyncRetry 实例
supplyAsyncWithCurrentScope(Supplier<U>, ExecutorService) - Static method in class com.github.phantomthief.scope.ScopeUtils
 
supplyAsyncWithCurrentScope(Supplier<U>, ListeningExecutorService) - Static method in class com.github.phantomthief.scope.ScopeUtils
 
supplyWithExistScope(Scope, ThrowableSupplier<T, X>) - Static method in class com.github.phantomthief.scope.Scope
 
supplyWithNewScope(ThrowableSupplier<T, X>) - Static method in class com.github.phantomthief.scope.Scope
 

T

trackLongCost(Duration, Consumer<Duration>) - Static method in class com.github.phantomthief.scope.ScopeUtils
 
triggerGetOnTimeout() - Method in interface com.github.phantomthief.scope.RetryPolicy
 
tryEnableFastThreadLocal() - Static method in class com.github.phantomthief.scope.Scope
 

W

withDefaultValue(boolean) - Static method in class com.github.phantomthief.scope.ScopeKey
 
withDefaultValue(int) - Static method in class com.github.phantomthief.scope.ScopeKey
 
withDefaultValue(long) - Static method in class com.github.phantomthief.scope.ScopeKey
 
withDefaultValue(double) - Static method in class com.github.phantomthief.scope.ScopeKey
 
withDefaultValue(String) - Static method in class com.github.phantomthief.scope.ScopeKey
 
withDefaultValue(T) - Static method in class com.github.phantomthief.scope.ScopeKey
 
withInitializer(Supplier<T>) - Static method in class com.github.phantomthief.scope.ScopeKey
 
A B C E F G H L N R S T W 
Skip navigation links

Copyright © 2019. All rights reserved.