Package com.google.dart.engine.internal.cache

Examples of com.google.dart.engine.internal.cache.SourceEntry


    boolean hintsEnabled = options.getHint();
    AnalysisContextStatisticsImpl statistics = new AnalysisContextStatisticsImpl();
    synchronized (cacheLock) {
      MapIterator<Source, SourceEntry> iterator = cache.iterator();
      while (iterator.moveNext()) {
        SourceEntry sourceEntry = iterator.getValue();
        if (sourceEntry instanceof DartEntry) {
          Source source = iterator.getKey();
          DartEntry dartEntry = (DartEntry) sourceEntry;
          SourceKind kind = dartEntry.getValue(DartEntry.SOURCE_KIND);
          // get library independent values
View Full Code Here


    return new TypeProviderImpl(coreElement);
  }

  @Override
  public boolean isClientLibrary(Source librarySource) {
    SourceEntry sourceEntry = getReadableSourceEntry(librarySource);
    if (sourceEntry instanceof DartEntry) {
      DartEntry dartEntry = (DartEntry) sourceEntry;
      return dartEntry.getValue(DartEntry.IS_CLIENT) && dartEntry.getValue(DartEntry.IS_LAUNCHABLE);
    }
    return false;
View Full Code Here

    return disposed;
  }

  @Override
  public boolean isServerLibrary(Source librarySource) {
    SourceEntry sourceEntry = getReadableSourceEntry(librarySource);
    if (sourceEntry instanceof DartEntry) {
      DartEntry dartEntry = (DartEntry) sourceEntry;
      return !dartEntry.getValue(DartEntry.IS_CLIENT)
          && dartEntry.getValue(DartEntry.IS_LAUNCHABLE);
    }
View Full Code Here

    synchronized (cacheLock) {
      // TODO(brianwilkerson) This does not lock against the other context's cacheLock.
      MapIterator<Source, SourceEntry> iterator = cache.iterator();
      while (iterator.moveNext()) {
        Source newSource = iterator.getKey();
        SourceEntry existingEntry = getReadableSourceEntry(newSource);
        if (existingEntry == null) {
          // TODO(brianwilkerson) Decide whether we really need to copy the info.
          cache.put(newSource, iterator.getValue().getWritableCopy());
        } else {
          // TODO(brianwilkerson) Decide whether/how to merge the entries.
View Full Code Here

TOP

Related Classes of com.google.dart.engine.internal.cache.SourceEntry

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.