Package com.litecoding.smali2java.renderer.SmaliRenderer

Examples of com.litecoding.smali2java.renderer.SmaliRenderer.SmaliBlock


import com.litecoding.smali2java.entity.smali.SmaliMethod;
import com.litecoding.smali2java.renderer.SmaliRenderer.SmaliBlock;

public class JavaRenderer {
  public static List<Renderable> generateJavaEntities(SmaliMethod smaliMethod) {
    SmaliBlock block = null;
    Comment errorComment = null;
   
    try {
      block = SmaliRenderer.generateBlocks(smaliMethod);
     
      System.out.println("===[BEGIN OF BLOCK CHAIN]===");
      SmaliRenderer.printBlockChain(block);
      System.out.println("===[END OF BLOCK CHAIN]===");
      System.out.println();
    } catch(Exception e) {
      System.out.println("Exception while generating block");
      e.printStackTrace();
     
      StringWriter sw = new StringWriter();
      e.printStackTrace(new PrintWriter(sw));
      errorComment = new Comment(sw.toString());
    }
   
    List<Renderable> entities = new ArrayList<Renderable>();
    if(errorComment != null) {
      entities.add(errorComment);
      return entities;
    }
   
    if(!block.isPlain()) {
      //for this time we don't support block chains
      entities.add(new Comment("Can't render chain of blocks"));
      return entities;
    }
   
View Full Code Here

TOP

Related Classes of com.litecoding.smali2java.renderer.SmaliRenderer.SmaliBlock

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.