Interface IntentExtensionService


  • @Beta
    public interface IntentExtensionService
    Service for extending the capability of intent framework by adding additional compilers or/and installers.
    • Method Detail

      • registerCompiler

        <T extends Intent> void registerCompiler​(Class<T> cls,
                                                 IntentCompiler<T> compiler)
        Registers the specified compiler for the given intent class.
        Type Parameters:
        T - the type of intent
        Parameters:
        cls - intent class
        compiler - intent compiler
      • unregisterCompiler

        <T extends Intent> void unregisterCompiler​(Class<T> cls)
        Unregisters the compiler for the specified intent class.
        Type Parameters:
        T - the type of intent
        Parameters:
        cls - intent class
      • getCompilers

        Map<Class<? extends Intent>,​IntentCompiler<? extends Intent>> getCompilers()
        Returns immutable set of bindings of currently registered intent compilers.
        Returns:
        the set of compiler bindings
      • registerInstaller

        <T extends Intent> void registerInstaller​(Class<T> cls,
                                                  IntentInstaller<T> installer)
        Registers the specific installer for the given intent class.
        Type Parameters:
        T - the type of intent
        Parameters:
        cls - intent class
        installer - intent installer
      • unregisterInstaller

        <T extends Intent> void unregisterInstaller​(Class<T> cls)
        Unregisters the installer for the specific intent class.
        Type Parameters:
        T - the type of intent
        Parameters:
        cls - intent class
      • getInstallers

        Map<Class<? extends Intent>,​IntentInstaller<? extends Intent>> getInstallers()
        Returns immutable set of binding of currently registered intent installers.
        Returns:
        the set of installer bindings
      • getInstaller

        <T extends IntentIntentInstaller<T> getInstaller​(Class<T> cls)
        Returns the installer for specific installable intent.
        Type Parameters:
        T - the type of intent
        Parameters:
        cls - the type of intent
        Returns:
        the installer for specific installable intent