public static List < StartContainerConfig > getContainers ( Class clazz ) { if ( ! cacheSCC . containsKey ( clazz ) ) { cacheSCC . put ( clazz , new ArrayList <> ( 1 ) ) ; ContainerStart cs = ( ContainerStart ) clazz . getAnnotation ( ContainerStart . class ) ; if ( cs != null ) { cacheSCC . get ( clazz ) . add ( fromContainerStart ( cs ) ) ; } Containers c = ( Containers ) clazz . getAnnotation ( com . vectorprint . report . itext . annotations . Containers . class ) ; if ( c != null ) { for ( ContainerStart s : c . containers ( ) ) { cacheSCC . get ( clazz ) . add ( fromContainerStart ( s ) ) ; } } } return cacheSCC . get ( clazz ) ; }
Find a datamapping to start a container based on class annotation uses static cache .