Class PluginInstaller


  • @SpringBootApplication
    public class PluginInstaller
    extends javafx.application.Application
    Application to verify and install OpenPatrician plugins.
    Author:
    Andi Hotz, (c) Sahits GmbH, 2018 Created on Apr 15, 2018
    • Nested Class Summary

      • Nested classes/interfaces inherited from class javafx.application.Application

        javafx.application.Application.Parameters
    • Constructor Summary

      Constructors 
      Constructor Description
      PluginInstaller()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private javafx.scene.text.Text createErrorText​(java.lang.String content)  
      void init()  
      LocalStorage localStorage()  
      static void main​(java.lang.String[] args)  
      private void openFile​(java.io.File file)  
      void start​(javafx.stage.Stage stage)  
      (package private) void validateAndInstall​(java.lang.String tempDirPath, java.io.File jarFile)
      Validate the plugin and install it.
      (package private) boolean validatePluginClasses​(java.util.Set<java.lang.Class<?>> subTypes)
      Verify that no class in the plugin implements InitializingBean or has a method annotated with PostConstruct.
      • Methods inherited from class javafx.application.Application

        getHostServices, getParameters, getUserAgentStylesheet, launch, launch, notifyPreloader, setUserAgentStylesheet, stop
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • context

        private org.springframework.context.ApplicationContext context
      • rootGroup

        private javafx.scene.layout.Pane rootGroup
      • displayErrors

        boolean displayErrors
    • Constructor Detail

      • PluginInstaller

        public PluginInstaller()
    • Method Detail

      • main

        public static void main​(java.lang.String[] args)
      • init

        public void init()
        Overrides:
        init in class javafx.application.Application
      • start

        public void start​(javafx.stage.Stage stage)
        Specified by:
        start in class javafx.application.Application
      • openFile

        private void openFile​(java.io.File file)
      • createErrorText

        private javafx.scene.text.Text createErrorText​(java.lang.String content)
      • validateAndInstall

        void validateAndInstall​(java.lang.String tempDirPath,
                                java.io.File jarFile)
                         throws java.io.IOException,
                                javax.xml.bind.JAXBException
        Validate the plugin and install it.
        Parameters:
        tempDirPath -
        jarFile -
        Throws:
        java.io.IOException
        javax.xml.bind.JAXBException
      • validatePluginClasses

        boolean validatePluginClasses​(java.util.Set<java.lang.Class<?>> subTypes)
        Verify that no class in the plugin implements InitializingBean or has a method annotated with PostConstruct.
        Parameters:
        subTypes - set of all classes to be inspected
        Returns:
        true if all classes are valid.