Examples of createMarker()


Examples of org.eclipse.core.resources.IResource.createMarker()

    }

    private void addClasspathMarker(String message, int severity) throws CoreException {
        IResource resource = DefaultBuildErrorDetailsHandler.getDefaultResource(getProject());

        IMarker marker = resource.createMarker(BndtoolsConstants.MARKER_BND_CLASSPATH_PROBLEM);
        marker.setAttribute(IMarker.SEVERITY, severity);
        marker.setAttribute(IMarker.MESSAGE, message);
    }

    private int iStatusSeverityToIMarkerSeverity(IStatus status) {
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

        if (resource == null || !resource.exists())
            resource = project;

        project.deleteMarkers(BndtoolsConstants.MARKER_BND_CLASSPATH_PROBLEM, true, IResource.DEPTH_INFINITE);
        for (String error : errors) {
            IMarker marker = resource.createMarker(BndtoolsConstants.MARKER_BND_CLASSPATH_PROBLEM);
            marker.setAttribute(IMarker.SEVERITY, IMarker.SEVERITY_ERROR);
            marker.setAttribute(IMarker.MESSAGE, error);
        }
    }
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

    }

    private void addClasspathMarker(String message, int severity) throws CoreException {
        IResource resource = DefaultBuildErrorDetailsHandler.getDefaultResource(getProject());

        IMarker marker = resource.createMarker(BndtoolsConstants.MARKER_BND_CLASSPATH_PROBLEM);
        marker.setAttribute(IMarker.SEVERITY, severity);
        marker.setAttribute(IMarker.MESSAGE, message);
    }

    private void addClasspathMarker(IStatus status) throws CoreException {
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

        if (resource == null || !resource.exists())
            resource = project;

        project.deleteMarkers(BndtoolsConstants.MARKER_BND_CLASSPATH_PROBLEM, true, IResource.DEPTH_INFINITE);
        for (String error : errors) {
            IMarker marker = resource.createMarker(BndtoolsConstants.MARKER_BND_CLASSPATH_PROBLEM);
            marker.setAttribute(IMarker.SEVERITY, IMarker.SEVERITY_ERROR);
            marker.setAttribute(IMarker.MESSAGE, error);
        }
    }
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

        IResource resource = module.getCorrespondingResource();
        if (resource == null) {
            resource = ResourcesPlugin.getWorkspace().getRoot();
            setPath = true;
        }
        final IMarker marker = resource.createMarker(type);
        marker.setAttribute(IMarker.CHAR_START, offset);
        marker.setAttribute(IMarker.CHAR_END, offset + length);
        if (setPath) {
            marker.setAttribute(PATH_ATTRIBUTE, module.getFilePath());
        }
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

            if (file != null) {
                resource = file;
            } else {
                resource = ResourcesPlugin.getWorkspace().getRoot();
            }
            final IMarker marker = resource.createMarker(markerKind);
            marker.setAttribute(IMarker.MESSAGE, message);
            marker.setAttribute(IMarker.SEVERITY, severity);
            marker.setAttribute(IMarker.LINE_NUMBER, lineNumber >= 0 ? lineNumber : 1);
            String myPath = path;
            if (path == null) {
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

      sevMarker = IMarker.SEVERITY_INFO;

    // Create the marker
    // TODO: create markers according to the type of the analysis
    try {
      IMarker marker = resource.createMarker(Crystal.MARKER_DEFAULT);
      marker.setAttribute(IMarker.CHAR_START, node.getStartPosition());
      marker.setAttribute(IMarker.CHAR_END, node.getStartPosition() + node.getLength());
      marker.setAttribute(IMarker.MESSAGE, prefix + ": " + problemDescription);
      marker.setAttribute(IMarker.PRIORITY, IMarker.PRIORITY_NORMAL);
      marker.setAttribute(IMarker.SEVERITY, sevMarker);
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

      sevMarker = IMarker.SEVERITY_INFO;

    // Create the marker
    // TODO: create markers according to the type of the analysis
    try {
      IMarker marker = resource.createMarker(Crystal.MARKER_DEFAULT);
      marker.setAttribute(IMarker.CHAR_START, node.getStartPosition());
      marker.setAttribute(IMarker.CHAR_END, node.getStartPosition() + node.getLength());
      marker.setAttribute(IMarker.MESSAGE, "[" + analysisName + "]: " + problemDescription);
      marker.setAttribute(IMarker.PRIORITY, IMarker.PRIORITY_NORMAL);
      marker.setAttribute(IMarker.SEVERITY, sevMarker);
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

      String filePath = buildError.getFilePath().toString();
      IResource resource = getProject().findMember(filePath);
      if(resource == null)
        continue;
     
      IMarker dubMarker = resource.createMarker(getBuildProblemId());
     
      dubMarker.setAttribute(IMarker.SEVERITY, IMarker.SEVERITY_ERROR);
      dubMarker.setAttribute(IMarker.MESSAGE, buildError.getErrorMessage());
     
      int line = buildError.getFileLineNumber();
View Full Code Here

Examples of org.eclipse.core.resources.IResource.createMarker()

        XPath aPath2 = new XPath("/aone/atwo");

        XPath bPath1 = new XPath("/bone");
        XPath bPath2 = new XPath("/bone/btwo");

        IMarker marker1 = resource.createMarker(IMarker.PROBLEM);
        marker1.setAttribute(XPath.class.getName(), aPath2.getExternalForm());
        IMarker marker2 = resource.createMarker(IMarker.PROBLEM);
        marker2.setAttribute(XPath.class.getName(), aPath1.getExternalForm());
        IMarker marker3 = resource.createMarker(IMarker.PROBLEM);
        marker3.setAttribute(XPath.class.getName(), bPath2.getExternalForm());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.