- Common ways to obtain BlockSourceCodeVisitor
private void myMethod () {BlockSourceCodeVisitor b =
BlockSourceCodeVisitor blockSourceCodeVisitor;Object[] object;blockSourceCodeVisitor.visitln(object)
- Smart code suggestions by Codota
}
@Override protected void generateContentChecks( BlockSourceCodeVisitor mv ) { String ctrlDesc = membraneDesc.getDescriptor(); String contentClassName = JuliacHelper.getContentClassName(ctrlDesc,contentDesc); if( contentClassName != null ) { InterfaceType[] its = ct.getFcInterfaceTypes(); for (int i = 0; i < its.length; i++) { if( ! its[i].isFcClientItf() ) { String signature = its[i].getFcItfSignature(); BlockSourceCodeVisitor then = mv.visitIf( "!",signature,".class.isAssignableFrom(", contentClassName,".class)"); then.visitVar( "String","msg","\""+contentClassName,"should implement", signature+"\""); then.visitIns( "throw","new", InstantiationException.class.getName()+"(msg)"); then.visitEnd(); } } } }