Package org.erlide.engine

Examples of org.erlide.engine.IErlangEngine


    String oldName = null;
    moduleName = unquoted;
    do {
      {
        oldName = moduleName;
        IErlangEngine _instance = ErlangEngine.getInstance();
        ModelFindService _modelFindService = _instance.getModelFindService();
        String _resolveMacroValue = _modelFindService.resolveMacroValue(moduleName, module);
        moduleName = _resolveMacroValue;
      }
    } while((!moduleName.equals(oldName)));
    String _fun_1 = res.getFun();
View Full Code Here


@SuppressWarnings("all")
public class OpenUtils {
  private final ModelFindService modelFindService;
 
  public OpenUtils() {
    IErlangEngine _instance = ErlangEngine.getInstance();
    ModelFindService _modelFindService = _instance.getModelFindService();
    this.modelFindService = _modelFindService;
  }
View Full Code Here

      Integer _valueOf = Integer.valueOf(_substring_2);
      arity = (_valueOf).intValue();
      String _substring_3 = name.substring(0, p);
      name = _substring_3;
    }
    IErlangEngine _instance = ErlangEngine.getInstance();
    ModelUtilService _modelUtilService = _instance.getModelUtilService();
    SearchPatternFactory _searchPatternFactory = new SearchPatternFactory(_modelUtilService);
    return _searchPatternFactory.getSearchPattern(searchFor, moduleName, name, arity, limitTo, module);
  }
View Full Code Here

      _xifexpression = IErlElementLocator.Scope.ALL_PROJECTS;
    } else {
      _xifexpression = IErlElementLocator.Scope.REFERENCED_PROJECTS;
    }
    final IErlElementLocator.Scope scope = _xifexpression;
    IErlangEngine _instance = ErlangEngine.getInstance();
    final IErlElementLocator model = _instance.getModel();
    return this.findOpenResult(openResult, module, project, element, model, scope, editor);
  }
View Full Code Here

              Object _adapter_1 = a.getAdapter(IResource.class);
              o = _adapter_1;
              boolean _tripleNotEquals = (o != null);
              if (_tripleNotEquals) {
                final IResource resource = ((IResource) o);
                IErlangEngine _instance = ErlangEngine.getInstance();
                IErlModel _model = _instance.getModel();
                final IErlElement element = _model.findElement(resource);
                parent = element;
              }
            }
            boolean _tripleNotEquals_1 = (parent != null);
View Full Code Here

    OtpErlangObject res2 = null;
    String moduleName = null;
    final IErlImport ei = module.findImport(erlangFunction);
    boolean _tripleNotEquals_1 = (ei != null);
    if (_tripleNotEquals_1) {
      IErlangEngine _instance = ErlangEngine.getInstance();
      final IErlModel model = _instance.getModel();
      String _importModule = ei.getImportModule();
      moduleName = _importModule;
      IErlangEngine _instance_1 = ErlangEngine.getInstance();
      OpenService _service = _instance_1.<OpenService>getService(OpenService.class);
      IResource _resource = module.getResource();
      OtpErlangList _pathVars = model.getPathVars(_resource);
      ErlangProjectProperties _properties = erlProject.getProperties();
      String _externalModules = _properties.getExternalModules();
      OtpErlangObject _sourceFromModule = _service.getSourceFromModule(_pathVars, moduleName, _externalModules);
      res2 = _sourceFromModule;
    }
    if ((res2 instanceof OtpErlangString)) {
      boolean _tripleNotEquals_2 = (moduleName != null);
      if (_tripleNotEquals_2) {
        final String modulePath = ((OtpErlangString)res2).stringValue();
        IErlangEngine _instance_2 = ErlangEngine.getInstance();
        final IErlElementLocator model_1 = _instance_2.getModel();
        return this.modelFindService.findFunction(model_1, erlProject, module, moduleName, modulePath, erlangFunction, scope);
      }
    }
    IErlangEngine _instance_3 = ErlangEngine.getInstance();
    ModelFindService _modelFindService = _instance_3.getModelFindService();
    final Collection<IErlModule> allIncludedFiles = _modelFindService.findAllIncludedFiles(module);
    for (final IErlModule includedModule : allIncludedFiles) {
      {
        final IErlFunction function = includedModule.findFunction(erlangFunction);
        boolean _tripleNotEquals_3 = (function != null);
View Full Code Here

    }
    return false;
  }
 
  private IErlElement findExternalCallOrType(final IErlModule module, final ExternalCallOpenResult res, final IErlProject project, final IErlElement element, final IErlElementLocator.Scope scope) throws CoreException {
    IErlangEngine _instance = ErlangEngine.getInstance();
    final IErlElementLocator model = _instance.getModel();
    boolean _isTypeDefOrRecordDef = this.isTypeDefOrRecordDef(res, element);
    if (_isTypeDefOrRecordDef) {
      String _mod = res.getMod();
      String _fun = res.getFun();
      String _path = res.getPath();
View Full Code Here

public class BeamLocator implements IBeamLocator {

    @Override
    public IFile findModuleBeam(final IProject project, final String module)
            throws ErlModelException {
        final IErlangEngine engine = ErlangEngine.getInstance();
        if (engine == null) {
            ErlLogger.warn("Erlang engine was not created!");
            return null;
        }
        final IErlProject erlProject = engine.getModel().getErlangProject(project);
        if (erlProject == null) {
            ErlLogger.warn("Project " + project + " is not in erlang model...");
            return null;
        }
        final IFolder r = project.getFolder(erlProject.getProperties().getOutputDir());
View Full Code Here

    IWorkspace _workspace = this.getWorkspace();
    return _workspace.getRoot();
  }
 
  protected IErlModel getModel() {
    IErlangEngine _instance = ErlangEngine.getInstance();
    return _instance.getModel();
  }
View Full Code Here

      _and = _exists;
    }
    if (_and) {
      file.delete(true, null);
    }
    IErlangEngine _instance = ErlangEngine.getInstance();
    String _stateDir = _instance.getStateDir();
    final IPath stateDir = new Path(_stateDir);
    final List<String> cacheExts = Collections.<String>unmodifiableList(CollectionLiterals.<String>newArrayList(".noparse", ".refs", ".scan"));
    for (final String ext : cacheExts) {
      {
        final IPath p = stateDir.append((scannerName + ext));
View Full Code Here

TOP

Related Classes of org.erlide.engine.IErlangEngine

Copyright © 2018 www.massapicom. 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.