1 19 20 package org.apache.cayenne; 21 22 import org.apache.cayenne.access.DataContext; 23 24 29 public interface DataObject extends Persistent { 30 31 public static final long DEFAULT_VERSION = Long.MIN_VALUE; 32 33 39 public DataContext getDataContext(); 40 41 46 public void setDataContext(DataContext ctxt); 47 48 54 public void writePropertyDirectly(String propertyName, Object val); 55 56 61 public Object readPropertyDirectly(String propertyName); 62 63 106 public Object readNestedProperty(String path); 107 108 113 public Object readProperty(String propName); 114 115 124 public void writeProperty(String propertyName, Object value); 125 126 129 public void addToManyTarget(String relationshipName, DataObject target, boolean setReverse); 130 131 134 public void removeToManyTarget(String relationshipName, DataObject target, boolean unsetReverse); 135 136 147 public void setToOneTarget( 148 String relationshipName, 149 DataObject value, 150 boolean setReverse); 151 152 157 public void fetchFinished(); 158 159 164 public long getSnapshotVersion(); 165 166 169 public void setSnapshotVersion(long snapshotVersion); 170 } 171 | Popular Tags |