if (!CodeScanner.getFieldsRead(mtd).isEmpty() || !CodeScanner.getFieldsWritten(mtd).isEmpty() || !CodeScanner.getCallSites(mtd).isEmpty()) { if (analysisDriver == null) { analysisDriver = getAnalysisDriver(mtd, options, cache, cha);
@Override public Iterator<FieldReference> iterateFieldsRead(CGNode node) { SSAInstruction[] statements = getIR(node).getInstructions(); return CodeScanner.getFieldsRead(statements).iterator(); }
@Override public Iterator<FieldReference> iterateFieldsWritten(CGNode node) { SSAInstruction[] statements = getIR(node).getInstructions(); return CodeScanner.getFieldsWritten(statements).iterator(); }
/** * @throws IllegalArgumentException if m is null */ public static Collection<FieldReference> getFieldsRead(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getFieldsRead(sm.getStatements()); } else { return getFieldsReadFromShrikeBT((ShrikeCTMethod) m); } }
/** * @throws IllegalArgumentException if m is null */ public static Collection<FieldReference> getFieldsWritten(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getFieldsWritten(sm.getStatements()); } else { return getFieldsWrittenFromShrikeBT((ShrikeCTMethod) m); } }
/** * @throws IllegalArgumentException if m is null */ public static Collection<CallSiteReference> getCallSites(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getCallSites(sm.getStatements()); } else { return getCallSitesFromShrikeBT((IBytecodeMethod) m); } }
@Override public Iterator<CallSiteReference> iterateCallSites(CGNode node) { if (node == null) { throw new IllegalArgumentException("node is null"); } try { return CodeScanner.getCallSites(node.getMethod()).iterator(); } catch (InvalidClassFileException e) { e.printStackTrace(); Assertions.UNREACHABLE(); return null; } }
public static Set getCaughtExceptions(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getCaughtExceptions(sm.getStatements()); } else { return getShrikeBTCaughtExceptions((ShrikeCTMethod) m); } }
/** * get the element types of the arrays that m may update */ public static Collection<TypeReference> getArraysWritten(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getArraysWritten(sm.getStatements()); } else { return getArraysWrittenFromShrikeBT((ShrikeCTMethod) m); } }
public Set getCaughtExceptions(CGNode node) { SSAInstruction[] statements = getIR(node).getInstructions(); return CodeScanner.getCaughtExceptions(statements); }
@Override public Iterator<FieldReference> iterateFieldsRead(CGNode node) { SSAInstruction[] statements = getIR(node).getInstructions(); return CodeScanner.getFieldsRead(statements).iterator(); }
@Override public Iterator<FieldReference> iterateFieldsWritten(CGNode node) { SSAInstruction[] statements = getIR(node).getInstructions(); return CodeScanner.getFieldsWritten(statements).iterator(); }
/** * @throws IllegalArgumentException if m is null */ public static Collection<FieldReference> getFieldsRead(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getFieldsRead(sm.getStatements()); } else { return getFieldsReadFromShrikeBT((ShrikeCTMethod) m); } }
/** * @throws IllegalArgumentException if m is null */ public static Collection<FieldReference> getFieldsWritten(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getFieldsWritten(sm.getStatements()); } else { return getFieldsWrittenFromShrikeBT((ShrikeCTMethod) m); } }
/** * @throws IllegalArgumentException if m is null */ public static Collection<CallSiteReference> getCallSites(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getCallSites(sm.getStatements()); } else { return getCallSitesFromShrikeBT((IBytecodeMethod) m); } }
@Override public Iterator<CallSiteReference> iterateCallSites(CGNode node) { if (node == null) { throw new IllegalArgumentException("node is null"); } try { return CodeScanner.getCallSites(node.getMethod()).iterator(); } catch (InvalidClassFileException e) { e.printStackTrace(); Assertions.UNREACHABLE(); return null; } }
public static Set getCaughtExceptions(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getCaughtExceptions(sm.getStatements()); } else { return getShrikeBTCaughtExceptions((ShrikeCTMethod) m); } }
/** * get the element types of the arrays that m may update */ public static Collection<TypeReference> getArraysWritten(IMethod m) throws InvalidClassFileException { if (m == null) { throw new IllegalArgumentException("m is null"); } if (m.isWalaSynthetic()) { SyntheticMethod sm = (SyntheticMethod) m; return getArraysWritten(sm.getStatements()); } else { return getArraysWrittenFromShrikeBT((ShrikeCTMethod) m); } }
public Set getCaughtExceptions(CGNode node) { SSAInstruction[] statements = getIR(node).getInstructions(); return CodeScanner.getCaughtExceptions(statements); }
@Override public Iterator<FieldReference> iterateFieldsRead(CGNode node) { if (node == null) { throw new IllegalArgumentException("node is null"); } try { return CodeScanner.getFieldsRead(node.getMethod()).iterator(); } catch (InvalidClassFileException e) { e.printStackTrace(); Assertions.UNREACHABLE(); return null; } }