接口 AliasRegistry

所有已知实现类:
DefaultAliasRegistry, StandardTypeLocator

public interface AliasRegistry
Common interface for managing aliases. Serves as a super-interface for cn.taketoday.beans.factory.support.BeanDefinitionRegistry.
从以下版本开始:
4.0
作者:
Juergen Hoeller, TODAY 2021/9/30 22:38
  • 方法概要

    修饰符和类型
    方法
    说明
    Return the aliases for the given name, if defined.
    Return the aliases list for the given name, if defined.
    boolean
    Determine whether the given name is defined as an alias (as opposed to the name of an actually registered component).
    void
    registerAlias(String name, String alias)
    Given a name, register an alias for it.
    void
    Remove the specified alias from this registry.
  • 方法详细资料

    • registerAlias

      void registerAlias(String name, String alias)
      Given a name, register an alias for it.
      参数:
      name - the canonical name
      alias - the alias to be registered
      抛出:
      IllegalStateException - if the alias is already in use and may not be overridden
    • removeAlias

      void removeAlias(String alias)
      Remove the specified alias from this registry.
      参数:
      alias - the alias to remove
      抛出:
      IllegalStateException - if no such alias was found
    • isAlias

      boolean isAlias(String name)
      Determine whether the given name is defined as an alias (as opposed to the name of an actually registered component).
      参数:
      name - the name to check
      返回:
      whether the given name is an alias
    • getAliases

      String[] getAliases(String name)
      Return the aliases for the given name, if defined.
      参数:
      name - the name to check for aliases
      返回:
      the aliases, or an empty array if none
    • getAliasList

      List<String> getAliasList(String name)
      Return the aliases list for the given name, if defined.
      参数:
      name - the name to check for aliases
      返回:
      the aliases, or an empty array-list if none