org.eclipse.jface.text.source.Annotation.isPersistent()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(2.1k)|赞(0)|评价(0)|浏览(97)

本文整理了Java中org.eclipse.jface.text.source.Annotation.isPersistent()方法的一些代码示例,展示了Annotation.isPersistent()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Annotation.isPersistent()方法的具体详情如下:
包路径:org.eclipse.jface.text.source.Annotation
类名称:Annotation
方法名:isPersistent

Annotation.isPersistent介绍

[英]Returns whether this annotation is persistent.
[中]返回此批注是否持久。

代码示例

代码示例来源:origin: org.eclipse/org.eclipse.ui.editors

public boolean isTemporary(Annotation annotation) {
  return !annotation.isPersistent();
}

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.editors

/**
 * {@inheritDoc}
 *
 * @deprecated assumed to always return <code>true</code>
 */
@Deprecated
@Override
public boolean isTemporary(Annotation annotation) {
  return !annotation.isPersistent();
}

代码示例来源:origin: org.eclipse.platform/org.eclipse.jface.text

private void skip() {
  boolean temp= (fStyle & TEMPORARY) != 0;
  boolean pers= (fStyle & PERSISTENT) != 0;
  boolean ignr= (fStyle & IGNORE_BAGS) != 0;
  while (fIterator.hasNext()) {
    Annotation next= fIterator.next();
    if (next.isMarkedDeleted())
      continue;
    if (ignr && (next instanceof AnnotationBag))
      continue;
    fNext= next;
    Object annotationType= next.getType();
    if (fType == null || fType.equals(annotationType) || !fConfiguredAnnotationTypes.contains(annotationType) && isSubtype(annotationType)) {
      if (temp && pers) return;
      if (pers && next.isPersistent()) return;
      if (temp && !next.isPersistent()) return;
    }
  }
  fNext= null;
}

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jface.text

private void skip() {
  boolean temp= (fStyle & TEMPORARY) != 0;
  boolean pers= (fStyle & PERSISTENT) != 0;
  boolean ignr= (fStyle & IGNORE_BAGS) != 0;
  while (fIterator.hasNext()) {
    Annotation next= fIterator.next();
    if (next.isMarkedDeleted())
      continue;
    if (ignr && (next instanceof AnnotationBag))
      continue;
    fNext= next;
    Object annotationType= next.getType();
    if (fType == null || fType.equals(annotationType) || !fConfiguredAnnotationTypes.contains(annotationType) && isSubtype(annotationType)) {
      if (temp && pers) return;
      if (pers && next.isPersistent()) return;
      if (temp && !next.isPersistent()) return;
    }
  }
  fNext= null;
}

相关文章