PTP
Release 7.0

org.eclipse.ptp.pldt.common.util
Class AnalysisUtil

java.lang.Object
  extended by org.eclipse.ptp.pldt.common.util.AnalysisUtil

public class AnalysisUtil
extends java.lang.Object

Various utility methods for project


Method Summary
static org.eclipse.cdt.core.parser.ParserLanguage getLanguageFromFile(org.eclipse.core.resources.IFile file)
          Given a C/C++ source, decide if it is C or C++.
static boolean validForAnalysis(java.lang.String filename, boolean isCPP)
          Is the given filename a valid file for analysis processing?
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

validForAnalysis

public static boolean validForAnalysis(java.lang.String filename,
                                       boolean isCPP)
Is the given filename a valid file for analysis processing?
Currently this means, is it a .c or .cpp etc file, or .h or .hpp?
Don't pollute this with fortran info - currently fortran processing is in a completely different action.

Parameters:
filename -
Returns:

getLanguageFromFile

public static org.eclipse.cdt.core.parser.ParserLanguage getLanguageFromFile(org.eclipse.core.resources.IFile file)
Given a C/C++ source, decide if it is C or C++.

Parameters:
file - must be either C or CPP file
Returns:

PTP
Release 7.0

Copyright (c) 2011 IBM Corporation and others. All Rights Reserved.