Examples of SourceEntry


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

      ResolveAngularComponentTemplateTask task) throws AnalysisException {
    Source source = task.getSource();
    AnalysisException thrownException = task.getException();
    HtmlEntry htmlEntry = null;
    synchronized (cacheLock) {
      SourceEntry sourceEntry = cache.get(source);
      if (sourceEntry == null) {
        throw new ObsoleteSourceAnalysisException(source);
      } else if (!(sourceEntry instanceof HtmlEntry)) {
        // This shouldn't be possible because we should never have performed the task if the source
        // didn't represent an HTML file, but check to be safe.
View Full Code Here

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

      throws AnalysisException {
    Source source = task.getSource();
    AnalysisException thrownException = task.getException();
    HtmlEntry htmlEntry = null;
    synchronized (cacheLock) {
      SourceEntry sourceEntry = cache.get(source);
      if (sourceEntry == null) {
        throw new ObsoleteSourceAnalysisException(source);
      } else if (!(sourceEntry instanceof HtmlEntry)) {
        // This shouldn't be possible because we should never have performed the task if the source
        // didn't represent an HTML file, but check to be safe.
View Full Code Here

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

    Source unitSource = task.getSource();
    Source librarySource = task.getLibrarySource();
    AnalysisException thrownException = task.getException();
    DartEntry dartEntry = null;
    synchronized (cacheLock) {
      SourceEntry sourceEntry = cache.get(unitSource);
      if (sourceEntry == null) {
        throw new ObsoleteSourceAnalysisException(unitSource);
      } else if (!(sourceEntry instanceof DartEntry)) {
        // This shouldn't be possible because we should never have performed the task if the source
        // didn't represent a Dart file, but check to be safe.
View Full Code Here

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

  private HtmlEntry recordResolveHtmlTaskResults(ResolveHtmlTask task) throws AnalysisException {
    Source source = task.getSource();
    AnalysisException thrownException = task.getException();
    HtmlEntry htmlEntry = null;
    synchronized (cacheLock) {
      SourceEntry sourceEntry = cache.get(source);
      if (sourceEntry == null) {
        throw new ObsoleteSourceAnalysisException(source);
      } else if (!(sourceEntry instanceof HtmlEntry)) {
        // This shouldn't be possible because we should never have performed the task if the source
        // didn't represent an HTML file, but check to be safe.
View Full Code Here

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

  private DartEntry recordScanDartTaskResults(ScanDartTask task) throws AnalysisException {
    Source source = task.getSource();
    AnalysisException thrownException = task.getException();
    DartEntry dartEntry = null;
    synchronized (cacheLock) {
      SourceEntry sourceEntry = cache.get(source);
      if (sourceEntry == null) {
        throw new ObsoleteSourceAnalysisException(source);
      } else if (!(sourceEntry instanceof DartEntry)) {
        // This shouldn't be possible because we should never have performed the task if the source
        // didn't represent a Dart file, but check to be safe.
View Full Code Here

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

   *
   * @param source the source that has been added
   * @return {@code true} if the new source is a Dart file
   */
  private boolean sourceAvailable(Source source) {
    SourceEntry sourceEntry = cache.get(source);
    if (sourceEntry == null) {
      sourceEntry = createSourceEntry(source, true);
    } else {
      sourceChanged(source);
      sourceEntry = cache.get(source);
View Full Code Here

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

   * <b>Note:</b> This method must only be invoked while we are synchronized on {@link #cacheLock}.
   *
   * @param source the source that has been changed
   */
  private void sourceChanged(Source source) {
    SourceEntry sourceEntry = cache.get(source);
    if (sourceEntry == null || sourceEntry.getModificationTime() == getModificationStamp(source)) {
      // Either we have removed this source, in which case we don't care that it is changed, or we
      // have already invalidated the cache and don't need to invalidate it again.
      return;
    }
    if (sourceEntry instanceof HtmlEntry) {
View Full Code Here

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

   * <b>Note:</b> This method must only be invoked while we are synchronized on {@link #cacheLock}.
   *
   * @param source the source that has been deleted
   */
  private void sourceDeleted(Source source) {
    SourceEntry sourceEntry = cache.get(source);
    if (sourceEntry instanceof HtmlEntry) {
      HtmlEntryImpl htmlCopy = ((HtmlEntry) sourceEntry).getWritableCopy();
      invalidateAngularResolution(htmlCopy);
      htmlCopy.recordContentError(new AnalysisException("This source was marked as being deleted"));
      cache.put(source, htmlCopy);
View Full Code Here

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

   * <b>Note:</b> This method must only be invoked while we are synchronized on {@link #cacheLock}.
   *
   * @param source the source that has been removed
   */
  private void sourceRemoved(Source source) {
    SourceEntry sourceEntry = cache.get(source);
    if (sourceEntry instanceof HtmlEntry) {
      HtmlEntryImpl htmlCopy = ((HtmlEntry) sourceEntry).getWritableCopy();
      invalidateAngularResolution(htmlCopy);
    } else if (sourceEntry instanceof DartEntry) {
      HashSet<Source> libraries = new HashSet<Source>();
View Full Code Here

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

    ArrayList<Source> missingSources = new ArrayList<Source>();
    synchronized (cacheLock) {
      MapIterator<Source, SourceEntry> iterator = cache.iterator();
      while (iterator.moveNext()) {
        Source source = iterator.getKey();
        SourceEntry sourceEntry = iterator.getValue();
        long sourceTime = getModificationStamp(source);
        if (sourceTime != sourceEntry.getModificationTime()) {
          changedSources.add(source);
        }
        if (sourceEntry.getException() != null) {
          if (!exists(source)) {
            missingSources.add(source);
          }
        }
      }
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.