|
Mobile Tools for Java Release 1.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.mtj.core.model.preverifier.impl.StandardPreverifier
public class StandardPreverifier
A standard preverifier implementation. This preverifier requires the pre-verification binary and the available CLDC parameters to be specified. Once created, the preverifier may be stored and retrieved using the standard persistence mechanism.
| Field Summary |
|---|
| Fields inherited from interface org.eclipse.mtj.core.model.preverifier.IPreverifier |
|---|
BUILD_ARG_PREVERIFY_CLASSES, BUILD_ARG_PREVERIFY_LIBS, BUILD_ARG_PREVERIFY_TARGET, PREVERIFY_TARGET_PROJECT |
| Constructor Summary | |
|---|---|
StandardPreverifier()
|
|
| Method Summary | |
|---|---|
static String |
extractClassName(IJavaProject javaProject,
IResource resource)
Extract the class name from the specified IResource within the specified java project. |
static IPath |
extractResourcePath(IJavaProject javaProject,
IResource resource)
Extract the class path from the specified IResource within the specified java project. |
protected String[] |
getCLDCConfigurationParameters(IMidletSuiteProject midletProject)
Return the parameters to be used for controlling the CLDC pre-verification. |
StandardPreverifierParameters |
getParameters()
|
File |
getPreverifierExecutable()
|
protected void |
handleErrorReceived(String text,
List<PreverificationError> errorList)
Handle the arrival of text on the error stream. |
protected boolean |
isCLDC1_0(Version configVersion)
Return a boolean indicating whether the specified configuration is a 1.0 CLDC config. |
void |
loadUsing(IPersistenceProvider persistenceProvider)
Load the state of this object using the specified persistence state information. |
PreverificationError[] |
preverify(IMidletSuiteProject midletProject,
IResource[] toVerify,
IFolder outputFolder,
IProgressMonitor monitor)
Launch the preverification process on the specified resources. |
PreverificationError[] |
preverifyJarFile(IMidletSuiteProject midletProject,
File jarFile,
IFolder outputFolder,
IProgressMonitor monitor)
Launch the preverification process on the specified jar file. |
protected PreverificationError[] |
runPreverifier(String[] commandLine,
String[] environment,
IProgressMonitor monitor)
Run the preverifier program and capture the errors that occurred during pre-verification. |
void |
setParameters(StandardPreverifierParameters parameters)
|
void |
setPreverifierExecutable(File preverifierExecutable)
|
void |
storeUsing(IPersistenceProvider persistenceProvider)
Save the state of this object using the specified persistence state information. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public StandardPreverifier()
| Method Detail |
|---|
public static String extractClassName(IJavaProject javaProject,
IResource resource)
throws JavaModelException
javaProject - the java project to provide the relative nameresource - the resource to extract a class name
null if the resource name cannot
be converted for some reason.
JavaModelException
public static IPath extractResourcePath(IJavaProject javaProject,
IResource resource)
throws JavaModelException
javaProject - resource -
JavaModelException
public void loadUsing(IPersistenceProvider persistenceProvider)
throws PersistenceException
IPersistable
loadUsing in interface IPersistablePersistenceExceptionIPersistable.loadUsing(org.eclipse.mtj.core.persistence.IPersistenceProvider)
public PreverificationError[] preverify(IMidletSuiteProject midletProject,
IResource[] toVerify,
IFolder outputFolder,
IProgressMonitor monitor)
throws CoreException,
IOException
IPreverifier
preverify in interface IPreverifiermidletProject - The project in which the resources to be
pre-verified reside.toVerify - The resources to be pre-verified.outputFolder - The folder into which the output is to be placed.monitor - Progress monitor
CoreException
IOExceptionorg.eclipse.mtj.core.model.preverifier.IPreverifier#preverify(org.eclipse.mtj.core.model.project.IMidletSuiteProject,
org.eclipse.core.resources.IResource[],
org.eclipse.core.resources.IFolder,
org.eclipse.core.runtime.IProgressMonitor)
public PreverificationError[] preverifyJarFile(IMidletSuiteProject midletProject,
File jarFile,
IFolder outputFolder,
IProgressMonitor monitor)
throws CoreException,
IOException
IPreverifier
preverifyJarFile in interface IPreverifiermidletProject - The project in which the resources to be
pre-verified reside.jarFile - The jar file to be pre-verified.outputFolder - The folder into which the output is to be placed.monitor - Progress monitor
CoreException
IOExceptionorg.eclipse.mtj.core.model.preverifier.IPreverifier#preverifyJarFile(org.eclipse.mtj.core.model.project.IMidletSuiteProject,
java.io.File, org.eclipse.core.resources.IFolder,
org.eclipse.core.runtime.IProgressMonitor)public StandardPreverifierParameters getParameters()
public File getPreverifierExecutable()
public void setParameters(StandardPreverifierParameters parameters)
parameters - The parameters to set.public void setPreverifierExecutable(File preverifierExecutable)
preverifierExecutable - The preverifierExecutable to set.
public void storeUsing(IPersistenceProvider persistenceProvider)
throws PersistenceException
IPersistable
storeUsing in interface IPersistablePersistenceExceptionIPersistable.storeUsing(org.eclipse.mtj.core.persistence.IPersistenceProvider)
protected String[] getCLDCConfigurationParameters(IMidletSuiteProject midletProject)
throws CoreException
midletProject -
CoreException - if an error occurs working with the MIDlet project.protected boolean isCLDC1_0(Version configVersion)
configSpec -
protected PreverificationError[] runPreverifier(String[] commandLine,
String[] environment,
IProgressMonitor monitor)
throws CoreException
commandLine - environment -
CoreException
protected void handleErrorReceived(String text,
List<PreverificationError> errorList)
text - errorList -
|
Mobile Tools for Java Release 1.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||