congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
Module.getState
Code IndexAdd Tabnine to your IDE (free)

How to use
getState
method
in
com.bc.ceres.core.runtime.Module

Best Java code snippets using com.bc.ceres.core.runtime.Module.getState (Showing top 2 results out of 315)

origin: bcdev/beam

public static <T> List<T> loadExecutableExtensions(ModuleContext moduleContext,
                          String extensionPointId,
                          String elementName,
                          Class<T> extensionType) {
  Module module = moduleContext.getModule();
  ExtensionPoint extensionPoint = module.getExtensionPoint(extensionPointId);
  ConfigurationElement[] configurationElements = extensionPoint.getConfigurationElements();
  List<T> executableExtensions = new ArrayList<>(32);
  for (ConfigurationElement configurationElement : configurationElements) {
    ConfigurationElement[] children = configurationElement.getChildren(elementName);
    for (ConfigurationElement child : children) {
      try {
        ModuleState moduleState = child.getDeclaringExtension().getDeclaringModule().getState();
        if (moduleState.isOneOf(ModuleState.STARTING, ModuleState.RESOLVED)) {
          T executableExtension = child.createExecutableExtension(extensionType);
          executableExtensions.add(executableExtension);
        }
      } catch (CoreException e) {
        moduleContext.getLogger().log(Level.SEVERE, e.getMessage(), e);
      }
    }
  }
  return executableExtensions;
}
origin: bcdev/beam

private void registerHelpSets(ModuleContext moduleContext) {
  this.helpSetRegistry = new TreeNode<>("");
  ExtensionPoint hsExtensionPoint = moduleContext.getModule().getExtensionPoint("helpSets");
  Extension[] hsExtensions = hsExtensionPoint.getExtensions();
  for (Extension extension : hsExtensions) {
    ConfigurationElement confElem = extension.getConfigurationElement();
    ConfigurationElement[] helpSetElements = confElem.getChildren("helpSet");
    for (ConfigurationElement helpSetElement : helpSetElements) {
      final Module declaringModule = extension.getDeclaringModule();
      if (declaringModule.getState().is(ModuleState.RESOLVED)) {
        registerHelpSet(helpSetElement, declaringModule);
      }
    }
  }
  addNodeToHelpSys(helpSetRegistry);
}
com.bc.ceres.core.runtimeModulegetState

Popular methods of Module

  • getSymbolicName
  • getClassLoader
  • getExtensionPoint
  • getName
  • getResource
  • getVersion
  • getCopyright
  • loadClass

Popular in Java

  • Finding current android device location
  • onCreateOptionsMenu (Activity)
  • getSupportFragmentManager (FragmentActivity)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • FileReader (java.io)
    A specialized Reader that reads from a file in the file system. All read requests made by calling me
  • Callable (java.util.concurrent)
    A task that returns a result and may throw an exception. Implementors define a single method with no
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
  • Join (org.hibernate.mapping)
  • 14 Best Plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now