当前位置: 首页>>代码示例>>Java>>正文


Java Dirtyable类代码示例

本文整理汇总了Java中org.apache.gora.persistency.Dirtyable的典型用法代码示例。如果您正苦于以下问题:Java Dirtyable类的具体用法?Java Dirtyable怎么用?Java Dirtyable使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


Dirtyable类属于org.apache.gora.persistency包,在下文中一共展示了Dirtyable类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: checkIfMutableFieldAndDirty

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
private boolean checkIfMutableFieldAndDirty(Field field) {
  if (field.pos() == 0)
    return false;
  switch (field.schema().getType()) {
  case RECORD:
  case MAP:
  case ARRAY:
    Object value = get(field.pos());
    return !(value instanceof Dirtyable) || value==null ? false : ((Dirtyable) value).isDirty();
  case UNION:
    value = get(field.pos());
    return !(value instanceof Dirtyable) || value==null ? false : ((Dirtyable) value).isDirty();
  default:
    break;
  }
  return false;
}
 
开发者ID:jianglibo,项目名称:gora-boot,代码行数:18,代码来源:PersistentBase.java

示例2: isDirty

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
@Override
public boolean isDirty() {
  boolean anyDirty = false;
  for (T value : this) {
    anyDirty = anyDirty || (value instanceof Dirtyable) ? ((Dirtyable) value).isDirty():false;
  }
  return anyDirty || dirtyFlag.isDirty();
}
 
开发者ID:jianglibo,项目名称:gora-boot,代码行数:9,代码来源:DirtyCollectionWrapper.java

示例3: clearDirty

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
@Override
public void clearDirty() {
  for (T value : this) {
    if (value instanceof Dirtyable)
      ((Dirtyable) value).clearDirty();
  }
  dirtyFlag.clearDirty();
}
 
开发者ID:jianglibo,项目名称:gora-boot,代码行数:9,代码来源:DirtyCollectionWrapper.java

示例4: clearDirynessIfFieldIsDirtyable

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
private void clearDirynessIfFieldIsDirtyable(int fieldIndex) {
  if (fieldIndex == 0)
    return;
  Object value = get(fieldIndex);
  if (value instanceof Dirtyable) {
    ((Dirtyable) value).clearDirty();
  }
}
 
开发者ID:jianglibo,项目名称:gora-boot,代码行数:9,代码来源:PersistentBase.java

示例5: isDirty

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
@Override
public boolean isDirty() {
  boolean anyDirty = false;
  for (V v : this.values()) {
    anyDirty = anyDirty || (v instanceof Dirtyable) ? ((Dirtyable) v)
        .isDirty() : false;
  }
  return anyDirty || dirtyFlag.isDirty();
}
 
开发者ID:jianglibo,项目名称:gora-boot,代码行数:10,代码来源:DirtyMapWrapper.java

示例6: clearDirty

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
@Override
public void clearDirty() {
  for (V v : this.values()) {
    if (v instanceof Dirtyable)
      ((Dirtyable) v).clearDirty();
  }
  dirtyFlag.clearDirty();
}
 
开发者ID:jianglibo,项目名称:gora-boot,代码行数:9,代码来源:DirtyMapWrapper.java

示例7: checkIfMutableFieldAndDirty

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
private boolean checkIfMutableFieldAndDirty(Field field) {
  switch (field.schema().getType()) {
  case RECORD:
  case MAP:
  case ARRAY:
    Object value = get(field.pos());
    return !(value instanceof Dirtyable) || value==null ? false : ((Dirtyable) value).isDirty();
  case UNION:
    value = get(field.pos());
    return !(value instanceof Dirtyable) || value==null ? false : ((Dirtyable) value).isDirty();
  default:
    break;
  }
  return false;
}
 
开发者ID:apache,项目名称:gora,代码行数:16,代码来源:PersistentBase.java

示例8: clearDirynessIfFieldIsDirtyable

import org.apache.gora.persistency.Dirtyable; //导入依赖的package包/类
private void clearDirynessIfFieldIsDirtyable(int fieldIndex) {
  Object value = get(fieldIndex);
  if (value instanceof Dirtyable) {
    ((Dirtyable) value).clearDirty();
  }
}
 
开发者ID:apache,项目名称:gora,代码行数:7,代码来源:PersistentBase.java


注:本文中的org.apache.gora.persistency.Dirtyable类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。