Package oms3.util

Class Components


  • public class Components
    extends Object
    Basic component utility methods.
    Author:
    Olaf David
    • Method Detail

      • internalComponents0

        public static void internalComponents0​(Collection<Class<?>> comps,
                                               Class<?> model)
      • explore

        public static void explore​(Object comp)
      • figureOutConnect

        public static void figureOutConnect​(PrintStream w,
                                            Object... comps)
        Figure out connectivity and generate Java statements.
        Parameters:
        comps -
      • figureOutParamDeclarations

        public static void figureOutParamDeclarations​(PrintStream w,
                                                      Object... comps)
      • figureOutMapIn

        public static void figureOutMapIn​(PrintStream w,
                                          Object... comps)
      • figureOutMapIn0

        public static void figureOutMapIn0​(PrintStream w,
                                           Object... comps)
      • getComponentClasses

        public static List<Class<?>> getComponentClasses​(ClassLoader parent,
                                                         URL... jars)
                                                  throws IOException
        Get all components from a set of jar files.
        Parameters:
        parent - a parent ClassLoader to use. If null, the context classloader will be used.
        jars - the URLs of the jar to browse for components.
        Returns:
        the list of component classes in the jars.
        Throws:
        IOException
      • getDocumentation

        public static URL getDocumentation​(Class<?> comp)
        Get the documentation with the default locale
        Parameters:
        comp - The component to get the documentation from.
        Returns:
        the documentation URL or null if not available
      • getDocumentation

        public static URL getDocumentation​(Class<?> comp,
                                           Locale loc)
        Get the documentation as URL reference;
        Parameters:
        comp - The class to get the 'Documentation' tag from
        loc - The locale
        Returns:
        the URL of the documentation file, null if no documentation is available.
      • getDescription

        public static String getDescription​(Class<?> comp)
      • getDescription

        public static String getDescription​(Class<?> comp,
                                            Locale loc)
        Get the Component Description
        Parameters:
        comp - the component class
        loc - the locale
        Returns:
        the localized description