private static String createModelEntryList ( CtClass clazz ) throws NotFoundException , CannotCompileException { StringBuilder builder = new StringBuilder ( ) ; CtClass tempClass = clazz ; while ( tempClass != null ) { for ( CtField field : tempClass . getDeclaredFields ( ) ) { String property = field . getName ( ) ; if ( property . equals ( TAIL_FIELD ) || property . equals ( LOGGER_FIELD ) || JavassistUtils . hasAnnotation ( field , IgnoredModelField . class . getName ( ) ) ) { builder . append ( createTrace ( String . format ( "Skip property '%s' of the model" , property ) ) ) ; continue ; } builder . append ( handleField ( field , clazz ) ) ; } tempClass = tempClass . getSuperclass ( ) ; } return builder . toString ( ) ; }
Generates the list of OpenEngSBModelEntries which need to be added . Also adds the entries of the super classes .