public class ValidationBindHandler extends AbstractBindHandler
BindHandler は、バインドされた結果に Validators を適用します。DEFAULT| コンストラクターと説明 |
|---|
ValidationBindHandler(BindHandler parent, org.springframework.validation.Validator... validators) |
ValidationBindHandler(org.springframework.validation.Validator... validators) |
cloneSE, equalsSE, finalizeSE, getClassSE, hashCodeSE, notifySE, notifyAllSE, toStringSE, waitSE, waitSE, waitSEonCreatepublic ValidationBindHandler(org.springframework.validation.Validator... validators)
public ValidationBindHandler(BindHandler parent, org.springframework.validation.Validator... validators)
public <T> Bindable<T> onStart(ConfigurationPropertyName name, Bindable<T> target, BindContext context)
BindHandlerBindHandler 内の onStart AbstractBindHandler の onStart T - バインド可能なソース型 name - バインドされている要素の名前 target - バインドされているアイテム context - バインドコンテキスト null の場合があります)public ObjectSE onSuccess(ConfigurationPropertyName name, Bindable<?> target, BindContext context, ObjectSE result)
BindHandlerBindHandler 内の onSuccess AbstractBindHandler の onSuccess name - バインドされている要素の名前 target - バインドされているアイテム context - バインドコンテキスト result - バインドされた結果 (非 null)null の場合があります)public ObjectSE onFailure(ConfigurationPropertyName name, Bindable<?> target, BindContext context, ExceptionSE error) throws ExceptionSE
BindHandlerBindHandler.onSuccess(org.springframework.boot.context.properties.source.ConfigurationPropertyName, org.springframework.boot.context.properties.bind.Bindable<?>, org.springframework.boot.context.properties.bind.BindContext, java.lang.Object) または BindHandler.onCreate(org.springframework.boot.context.properties.source.ConfigurationPropertyName, org.springframework.boot.context.properties.bind.Bindable<?>, org.springframework.boot.context.properties.bind.BindContext, java.lang.Object) 呼び出しからの失敗を含む)。実装は、例外を飲み込み、代替結果を返すことを選択できます。BindHandler 内の onFailure AbstractBindHandler の onFailure name - バインドされている要素の名前 target - バインドされているアイテム context - バインドコンテキスト error - エラーの原因 (例外が発生した場合、再スローされる可能性があります)null の場合があります)。ExceptionSE - バインディングが有効でない場合 public void onFinish(ConfigurationPropertyName name, Bindable<?> target, BindContext context, ObjectSE result) throws ExceptionSE
BindHandlerBindHandler.onFailure(org.springframework.boot.context.properties.source.ConfigurationPropertyName, org.springframework.boot.context.properties.bind.Bindable<?>, org.springframework.boot.context.properties.bind.BindContext, java.lang.Exception) から結果を取得した場合でも、バインディングが失敗した場合、このメソッドは呼び出されません。BindHandler 内の onFinish AbstractBindHandler の onFinish name - バインドされている要素の名前 target - バインドされているアイテム context - バインドコンテキスト result - バインドされた結果 (null の場合があります)ExceptionSE - バインディングが有効でない場合 Copyright © 2019 Pivotal Software, Inc.. All rights reserved.