クラス SecurityDataFetcherExceptionResolver
java.lang.ObjectSE
org.springframework.graphql.execution.DataFetcherExceptionResolverAdapter
org.springframework.graphql.execution.SecurityDataFetcherExceptionResolver
- 実装済みのインターフェース一覧:
DataFetcherExceptionResolver
Spring Security 例外の
DataFetcherExceptionResolver。非反応トランスポート (Spring MVC HTTP エンドポイントなど) を使用するアプリケーションで使用します。- 導入:
- 1.0.0
- 作成者:
- Rob Winch, Rossen Stoyanchev
フィールド概要
クラス org.springframework.graphql.execution.DataFetcherExceptionResolverAdapter から継承されたフィールド
loggerコンストラクター概要
コンストラクター方法の概要
修飾子と型メソッド説明protected @Nullable graphql.GraphQLErrorresolveToSingleError(ThrowableSE ex, graphql.schema.DataFetchingEnvironment environment) このメソッドをオーバーライドして、例外を単一の GraphQL エラーに解決します。voidsetAuthenticationTrustResolver(org.springframework.security.authentication.AuthenticationTrustResolver trustResolver) 認証が匿名であるかどうかを確認するために使用するリゾルバーを設定します。これにより、AccessDeniedExceptionが「無認可」または「禁止」に分類されるかどうかが決まります。クラス org.springframework.graphql.execution.DataFetcherExceptionResolverAdapter から継承されたメソッド
isThreadLocalContextAware, resolveException, resolveToMultipleErrors, setThreadLocalContextAware
コンストラクターの詳細
SecurityDataFetcherExceptionResolver
public SecurityDataFetcherExceptionResolver()
方法の詳細
setAuthenticationTrustResolver
public void setAuthenticationTrustResolver(org.springframework.security.authentication.AuthenticationTrustResolver trustResolver) 認証が匿名であるかどうかを確認するために使用するリゾルバーを設定します。これにより、AccessDeniedExceptionが「無認可」または「禁止」に分類されるかどうかが決まります。- パラメーター:
trustResolver- 使用するリゾルバー
resolveToSingleError
protected @Nullable graphql.GraphQLError resolveToSingleError(ThrowableSE ex, graphql.schema.DataFetchingEnvironment environment) クラスからコピーされた説明:DataFetcherExceptionResolverAdapterこのメソッドをオーバーライドして、例外を単一の GraphQL エラーに解決します。- オーバーライド:
- クラス
DataFetcherExceptionResolverAdapterのresolveToSingleError - パラメーター:
ex- 解決する例外environment- 呼び出されたDataFetcherの環境- 戻り値:
- 解決されたエラー、または未解決の場合は
null