Examples of InstanceScope


Examples of org.eclipse.core.runtime.preferences.InstanceScope

    errorTable.put(state, msg, severity);
  }
 
  private void init() {
    fPreferenceService = Platform.getPreferencesService();
    fLookupOrder = new IScopeContext[] {new InstanceScope(), new DefaultScope()};
   
    if (fProject != null) {
      ProjectScope projectScope = new ProjectScope(fProject);
      if(projectScope.getNode(HTMLCorePlugin.getDefault().getBundle().getSymbolicName()).getBoolean(HTMLCorePreferenceNames.USE_PROJECT_SETTINGS, false))
        fLookupOrder = new IScopeContext[] {projectScope, new InstanceScope(), new DefaultScope()};
    }
   
    for (int i = 0; i < NodeType.MAX_TYPE; i++) {
      errTables[i] = new ErrorTable();
    }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

  private IPreferencesService fPreferencesService = null;
  private IScopeContext[] fScopes = null;

  private void loadPreferences(IFile file) {
    fScopes = new IScopeContext[]{new InstanceScope(), new DefaultScope()};

    fPreferencesService = Platform.getPreferencesService();
    if (file != null && file.isAccessible()) {
      ProjectScope projectScope = new ProjectScope(file.getProject());
      if (projectScope.getNode(PREFERENCE_NODE_QUALIFIER).getBoolean(JSPCorePreferenceNames.VALIDATION_USE_PROJECT_SETTINGS, false)) {
        fScopes = new IScopeContext[]{projectScope, new InstanceScope(), new DefaultScope()};
      }
    }
  }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

  private boolean isReservedTaglibPrefix(String name) {
    return fReservedPrefixes.get(name) != null;
  }
 
  private void loadPreferences(IFile file) {
    fScopes = new IScopeContext[]{new InstanceScope(), new DefaultScope()};

    fPreferencesService = Platform.getPreferencesService();
    if (file != null && file.isAccessible()) {
      ProjectScope projectScope = new ProjectScope(file.getProject());
      if (projectScope.getNode(PREFERENCE_NODE_QUALIFIER).getBoolean(JSPCorePreferenceNames.VALIDATION_USE_PROJECT_SETTINGS, false)) {
        fScopes = new IScopeContext[]{projectScope, new InstanceScope(), new DefaultScope()};
      }
    }

    fSeverityIncludeFileMissing = getMessageSeverity(JSPCorePreferenceNames.VALIDATION_DIRECTIVE_INCLUDE_FILE_NOT_FOUND);
    fSeverityIncludeFileNotSpecified = getMessageSeverity(JSPCorePreferenceNames.VALIDATION_DIRECTIVE_INCLUDE_NO_FILE_SPECIFIED);
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

    else {
      fProject = null;
    }

    if (!useProject) {
      fPreferences = new InstanceScope().getNode(PREFERENCE_NODE_QUALIFIER);
    }
  }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

    errorTable.put(state, msg, severity);
  }
 
  private void init() {
    fPreferenceService = Platform.getPreferencesService();
    fLookupOrder = new IScopeContext[] {new InstanceScope(), new DefaultScope()};
   
    if (fProject != null) {
      ProjectScope projectScope = new ProjectScope(fProject);
      if(projectScope.getNode(HTMLCorePlugin.getDefault().getBundle().getSymbolicName()).getBoolean(HTMLCorePreferenceNames.USE_PROJECT_SETTINGS, false))
        fLookupOrder = new IScopeContext[] {projectScope, new InstanceScope(), new DefaultScope()};
    }
   
    for (int i = 0; i < NodeType.MAX_TYPE; i++) {
      errTables[i] = new ErrorTable();
    }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

      // TLD
      else {
        try {
          final IJavaProject javaProject = JavaCore.create(file.getProject());
          if (javaProject.exists()) {
            IScopeContext[] scopes = new IScopeContext[]{new InstanceScope(), new DefaultScope()};
            ProjectScope projectScope = new ProjectScope(file.getProject());
            if (projectScope.getNode(PREFERENCE_NODE_QUALIFIER).getBoolean(JSPCorePreferenceNames.VALIDATION_USE_PROJECT_SETTINGS, false)) {
              scopes = new IScopeContext[]{projectScope, new InstanceScope(), new DefaultScope()};
            }
            Map[] problems = detectProblems(javaProject, file, scopes);
            for (int i = 0; i < problems.length; i++) {
              ValidatorMessage message = ValidatorMessage.create(problems[i].get(IMarker.MESSAGE).toString(), resource);
              message.setType(MARKER_TYPE);
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

        // only if so, return that value
        return node.getBoolean(JSPCorePreferenceNames.VALIDATE_FRAGMENTS, true);
      }
      // if not, return the workspace value
    }
    return new InstanceScope().getNode(qualifier).getBoolean(JSPCorePreferenceNames.VALIDATE_FRAGMENTS, true);
  }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

    }
    return IMessage.NORMAL_SEVERITY;
  }

  private void loadPreferences(IFile file) {
    fScopes = new IScopeContext[]{new InstanceScope(), new DefaultScope()};

    if (file != null && file.isAccessible()) {
      ProjectScope projectScope = new ProjectScope(file.getProject());
      if (projectScope.getNode(PREFERENCE_NODE_QUALIFIER).getBoolean(JSPCorePreferenceNames.VALIDATION_USE_PROJECT_SETTINGS, false)) {
        fScopes = new IScopeContext[]{projectScope, new InstanceScope(), new DefaultScope()};
      }
    }
  }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

        /*
         * If the host has no project specific line delimiter set, we do this
         * here, so it will be transfered to the clients.
         */
        IScopeContext[] scopeContexts = new IScopeContext[] {
            new ProjectScope(project), new InstanceScope() };
        IPreferencesService preferencesService = Platform
            .getPreferencesService();
        String platformLineDelimiter = System.getProperty("line.separator");
        String lineDelimiter = preferencesService.getString(
            Platform.PI_RUNTIME, Platform.PREF_LINE_SEPARATOR,
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.InstanceScope

  private int getProblemSeverity(String key, IScopeContext[] contexts) {
    return Platform.getPreferencesService().getInt(PREFERENCE_NODE_QUALIFIER, key, IMessage.NORMAL_SEVERITY, contexts);
  }

  private IScopeContext[] getScopeContexts(IStructuredDocument document) {
    IScopeContext[] scopes = new IScopeContext[]{new InstanceScope(), new DefaultScope()};
    final IFile file = getFile(document);
    if (file != null && file.exists()) {
      final IProject project = file.getProject();
      if (project.exists()) {
        ProjectScope projectScope = new ProjectScope(project);
        if (projectScope.getNode(PREFERENCE_NODE_QUALIFIER).getBoolean(JSPCorePreferenceNames.VALIDATION_USE_PROJECT_SETTINGS, false)) {
          scopes = new IScopeContext[]{projectScope, new InstanceScope(), new DefaultScope()};
        }
      }
    }
    return scopes;
  }
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.