private void processHooks ( Set < ExecutableElement > hookMethodsFromInterfaces ) { ElementFilter . methodsIn ( component . getEnclosedElements ( ) ) . stream ( ) . filter ( method -> isHookMethod ( component , method , hookMethodsFromInterfaces ) ) // Created hook is already added by createCreatedHook . filter ( method -> ! "created" . equals ( method . getSimpleName ( ) . toString ( ) ) ) . forEach ( method -> { String exposedMethodName = exposeExistingJavaMethodToJs ( method ) ; String methodName = method . getSimpleName ( ) . toString ( ) ; optionsBuilder . addStatement ( "options.addHookMethod($S, p.$L)" , methodName , exposedMethodName ) ; } ) ; }
Process hook methods from the Component Class .