public IWorkbenchContext getWorkbenchContext() { if(workbenchContext == null) { workbenchContext = new WorkbenchContext(); workbenchContext.setProject(getProject()); } return workbenchContext; }
public ManualValidatorsOperation(IProject project, Object[] changedResources) { super(project, shouldForce(changedResources), RegistryConstants.ATT_RULE_GROUP_DEFAULT, true); setEnabledValidators(ValidatorManager.getManager().getManualEnabledValidators(project)); } }
public ManualValidatorsOperation(IProject project) { super(project, DEFAULT_FORCE, RegistryConstants.ATT_RULE_GROUP_DEFAULT, true); setEnabledValidators(ValidatorManager.getManager().getManualEnabledValidators(project)); } public ManualValidatorsOperation(IProject project, Object[] changedResources) {
public ISchedulingRule getSchedulingRule(IValidationContext helper) { // don't know what to return here. my guess is that we want to return // the resource that is possibly being changed during our validation, // and since many resources in the project may be changed during this // validation, returning the project makes the most sense. return ((IWorkbenchContext) helper).getProject(); }
/** * Run all enabled validators on the project with the identified ruleGroup. * * IProject must exist and be open. * * If async is true, the validation will run all validators implementing IValidatorJob interface * in the background validation thread, if async is false, it would run in the main thread. * All validators implementing IValidator interface will run in in the main thread regardless of this flag. */ public EnabledValidatorsOperation(IProject project, IWorkbenchContext aWorkbenchContext, int ruleGroup, boolean force, boolean async) { this(project, aWorkbenchContext, ValidatorManager.getManager().getEnabledValidators(project), ruleGroup, force, async); }
protected void preValidate(WorkbenchReporter reporter) throws CoreException, OperationCanceledException { // Load the input. getFileDeltas(reporter.getProgressMonitor()); }
/** * Keeping this API around so as not to break existing code. * * @deprecated use isAutoValidate */ public boolean isAutoValidateChecked(IProject project, boolean isGlobalAutoBuildOn) { return isAutoValidate(project, isGlobalAutoBuildOn); }
public LocalizedMessage(int severity, String messageText, Object targetObject) { super(null, severity, null); setLocalizedMessage(messageText); setTargetObject(targetObject); }
public WorkbenchFileDelta(String aFileName, int aFileDelta, IResource resource) { super(aFileName, aFileDelta); setResource(resource); setObject(resource); }
/** * When the IProject is closing, perform any cleanup that needs to be done. When this method is * called, if the helper has cached any resources from the IProject, it should release those * resources. If you do not allocate resources in your helper, then this method should be a * no-op. */ public void closing() { closing(getProject()); }
/** * @see org.eclipse.wst.validation.internal.provisional.core.core.IReporter#removeAllMessages(IValidator) */ public void removeAllMessages(IValidator validator) { if (validator == null) { // getHelper could be null if the user cancelled before something // was fully initialized return; } removeAllMessages(validator, null); }
/** * When the IProject is being deleted, perform any cleanup that needs to be done. When this * method is called, if the helper has cached any resources from the IProject, it should release * those resources. If you do not allocate resources in your helper, then this method should be * a no-op. */ public void deleting() { deleting(getProject()); }
public static void removeMessageSubset(IResource resource, Class messageOwner, String groupName) { // Since the addMessage(Class, IMessage) is defaulted to the IProject, // remove the message subsets from the IProject removeMessageSubset(resource, new String[]{getUniqueId(messageOwner)}, null, groupName); }
public static void addMessage(IResource resource, Class clazz, IMessage message, String targetObjectName, String location,String markerId) { addMessage(resource, clazz, null, message, targetObjectName, location,markerId); // null = use the // default // ClassLoader // (class.getClassLoader()) }
public static void removeMessageSubset(IResource resource, String messageOwnerId, String groupName) { // Since the addMessage(Class, IMessage) is defaulted to the IProject, // remove the message subsets from the IProject removeMessageSubset(resource, new String[]{messageOwnerId}, null, groupName); }
/** * @deprecated Will be removed in Milestone 3. Use * EnabledIncrementalValidatorsOperation(IProject, IResourceDelta, int, boolean) * instead. */ public EnabledIncrementalValidatorsOperation(IProject project, Set validators, IResourceDelta delta, int ruleGroup) { this(project, delta, ruleGroup, DEFAULT_ASYNC); setEnabledValidators(validators); }
public static ValidatorManager getManager() { if (inst == null) { inst = new ValidatorManager(); } return inst; }
public static TaskListHelper getTaskList() { if (_taskListHelper == null) { _taskListHelper = new TaskListHelper(); } return _taskListHelper; }
/** * Given a symbolic name, load the MOF model which is identified by that name. * * For support of dynamic symbolic names, such as file names, read the comment above the * registerModel method. * * @see registerModel */ public Object loadModel(String symbolicName) { return loadModel(symbolicName, null); }
/** * Keeping this API around so as not to break existing code. * * @deprecated use isAutoValidate */ public boolean isAutoValidateChecked(IProject project) { return isAutoValidate(project); }