1 package org.apache.ojb.broker.core.proxy; 2 3 17 18 import java.io.Serializable ; 19 import java.util.Set ; 20 21 import org.apache.ojb.broker.Identity; 22 import org.apache.ojb.broker.ManageableCollection; 23 import org.apache.ojb.broker.PBKey; 24 import org.apache.ojb.broker.query.Query; 25 26 33 public interface ProxyFactory extends Serializable 34 { 35 40 public abstract Class getIndirectionHandlerClass(); 41 42 47 public abstract void setIndirectionHandlerClass(Class indirectionHandlerClass); 48 49 54 public abstract Class getDefaultIndirectionHandlerClass(); 55 56 57 61 public abstract Class getIndirectionHandlerBaseClass(); 62 63 64 71 public abstract IndirectionHandler createIndirectionHandler(PBKey pbKey, Identity id); 72 73 78 public abstract Class getListProxyClass(); 79 80 87 public abstract void setListProxyClass(Class listProxyClass); 88 89 94 public abstract Class getSetProxyClass(); 95 96 101 public abstract void setSetProxyClass(Class setProxyClass); 102 103 108 public abstract Class getCollectionProxyClass(); 109 110 115 public abstract void setCollectionProxyClass(Class collectionProxyClass); 116 117 124 public abstract ManageableCollection createCollectionProxy(PBKey brokerKey, Query query, Class collectionClass); 125 126 127 public OJBProxy createProxy(Class baseClass, IndirectionHandler handler) throws Exception ; 128 129 130 136 public Object getRealObject(Object objectOrProxy); 137 138 144 public Object getRealObjectIfMaterialized(Object objectOrProxy); 145 146 152 public Class getRealClass(Object objectOrProxy); 153 158 public boolean isNormalOjbProxy(Object proxyOrObject); 159 160 165 public boolean isVirtualOjbProxy(Object proxyOrObject); 166 167 171 public boolean isProxy(Object proxyOrObject); 172 173 180 public IndirectionHandler getIndirectionHandler(Object obj); 181 182 189 public boolean isMaterialized(Object object); 190 191 192 195 public CollectionProxy getCollectionProxy(Object item); 196 197 202 public boolean isCollectionProxy(Object item); 203 204 213 public String toString(Object proxy); 214 215 220 boolean interfaceRequiredForProxyGeneration(); 221 } 222 | Popular Tags |