クラス MethodSecurityMetadataSourceAdvisor
java.lang.ObjectSE
org.springframework.aop.support.AbstractPointcutAdvisor
org.springframework.security.access.intercept.aopalliance.MethodSecurityMetadataSourceAdvisor
- 実装済みのインターフェース一覧:
SerializableSE、org.springframework.aop.Advisor、org.springframework.aop.PointcutAdvisor、org.springframework.beans.factory.Aware、org.springframework.beans.factory.BeanFactoryAware、org.springframework.core.Ordered
@NullUnmarked
@DeprecatedSE
public class MethodSecurityMetadataSourceAdvisor
extends org.springframework.aop.support.AbstractPointcutAdvisor
implements org.springframework.beans.factory.BeanFactoryAware
使用すべきではありません。
MethodSecurityMetadataSource によって駆動されるアドバイザー。パブリック(非セキュア)メソッドから MethodInterceptor を除外するために使用されます。AOP フレームワークはアドバイスの計算をキャッシュするため、これは通常、MethodInterceptor を実行して、実行する作業がないことを確認するよりも高速です。
このクラスでは、Spring の DefaultAdvisorAutoProxyCreator を使用することもできます。これにより、セキュリティが必要なオブジェクトごとに ProxyFactoryBean をセットアップするよりも構成が簡単になります。後処理はアプリケーションコンテキストに対してのみ自動化されるため、自動プロキシは BeanFactory 実装ではサポートされていないことに注意してください。
Spring の TransactionAttributeSourceAdvisor に基づいています。
- 関連事項:
フィールド概要
インターフェース org.springframework.aop.Advisor から継承されたフィールド
EMPTY_ADVICEインターフェース org.springframework.core.Ordered から継承されたフィールド
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCEコンストラクター概要
コンストラクターコンストラクター説明MethodSecurityMetadataSourceAdvisor(StringSE adviceBeanName, MethodSecurityMetadataSource attributeSource, StringSE attributeSourceBeanName) 使用すべきではありません。アドバイザーをアドバイスから切り離したい状況のための代替コンストラクター。方法の概要
修飾子と型メソッド説明org.aopalliance.aop.Advice使用すべきではありません。org.springframework.aop.Pointcut使用すべきではありません。voidsetBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) 使用すべきではありません。クラス org.springframework.aop.support.AbstractPointcutAdvisor から継承されたメソッド
equals, getOrder, hashCode, setOrderクラス java.lang.ObjectSE から継承されたメソッド
clone, finalize, getClass, notify, notifyAll, toString, wait, waitSE, waitSEインターフェース org.springframework.aop.Advisor から継承されたメソッド
isPerInstance
コンストラクターの詳細
MethodSecurityMetadataSourceAdvisor
public MethodSecurityMetadataSourceAdvisor(StringSE adviceBeanName, MethodSecurityMetadataSource attributeSource, StringSE attributeSourceBeanName) 使用すべきではありません。アドバイザーをアドバイスから切り離したい場合の代替コンストラクター。代わりに、アドバイス Bean 名を設定する必要があります。これにより、インターセプター (および AuthenticationManager) の積極的なインスタンス化が防止されます。たとえば、SEC-773 を参照してください。Bean ファクトリ検索による直列化をサポートするために、直接参照ではなく metadataSourceBeanName が使用されます。- パラメーター:
adviceBeanName- MethodSecurityInterceptor の名前 BeanattributeSource- SecurityMetadataSource (インターセプターで使用されているものと同じである必要があります)attributeSourceBeanName- attributeSource の Bean 名 (直列化に必要)
メソッドの詳細
getPointcut
public org.springframework.aop.Pointcut getPointcut()使用すべきではありません。- 次で指定:
- インターフェース
org.springframework.aop.PointcutAdvisorのgetPointcut
getAdvice
public org.aopalliance.aop.Advice getAdvice()使用すべきではありません。- 次で指定:
- インターフェース
org.springframework.aop.AdvisorのgetAdvice
setBeanFactory
public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) throws org.springframework.beans.BeansException 使用すべきではありません。- 次で指定:
- インターフェース
org.springframework.beans.factory.BeanFactoryAwareのsetBeanFactory - 例外:
org.springframework.beans.BeansException
EnableMethodSecurityを使用するか、インターセプターを直接公開してください