Package com.android.dx.dex.code

Examples of com.android.dx.dex.code.SwitchData


      }
      else if (instructions.get(i) instanceof SwitchData)
      {
        // If a switch-statement is enclosed by a try-block, we
        // will also require splitting.
        SwitchData switchData= (SwitchData) instructions.get(i);
        CodeAddress[] caseTargets= switchData.getTargets();
        for (CodeAddress caseTarget : caseTargets)
        {
          targets.put(caseTarget.getAddress(), new Target(caseTarget.getAddress(), true));
        }
      }
View Full Code Here


    Map<Integer, SwitchData> result= new HashMap<Integer, SwitchData>();
    for (int i= 0; i < instructions.size(); ++i)
    {
      if (instructions.get(i) instanceof SwitchData)
      {
        SwitchData switchData= (SwitchData) instructions.get(i);
        result.put(switchData.getAddress(), switchData);
      }
    }
    return result;
  }
View Full Code Here

      dexInstruction= new Element(sanitizeInstructionName(instructionName), NS_DEX);
      addRegistersAsAttributes(targetInsn.getRegisters(), dexInstruction);

      if (instructionName.equals("packed-switch") || instructionName.equals("sparse-switch"))
      {
        SwitchData switchData= switchDataBlocks.get(targetInsn.getTargetAddress());
        if (switchData == null)
        {
          Log.error(TAG, "DEXmlvmOutputProcess: Couldn't find SwitchData block.");
          System.exit(-1);
        }
        IntList cases= switchData.getCases();
        CodeAddress[] caseTargets= switchData.getTargets();

        // Sanity check.
        if (cases.size() != caseTargets.length)
        {
          Log.error(TAG, "DEXmlvmOutputProcess: SwitchData size mismatch: cases vs targets.");
View Full Code Here

TOP

Related Classes of com.android.dx.dex.code.SwitchData

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.