public class HubAutoMatch<TYPE,PROPTYPE> extends HubListenerAdapter implements Serializable
HubListener.InsertLocation
Modifier and Type | Field and Description |
---|---|
protected boolean |
bManuallyCalled |
protected Method |
getMethod |
protected Hub |
hub |
protected Hub |
hubMaster |
protected OAObject |
objStop |
protected String |
property |
protected Method |
setMethod |
protected String |
stopProperty |
Constructor and Description |
---|
HubAutoMatch() |
HubAutoMatch(Hub<TYPE> hub,
String property,
Hub<PROPTYPE> hubMaster) |
HubAutoMatch(Hub<TYPE> hub,
String property,
Hub<PROPTYPE> hubMaster,
boolean bManuallyCalled)
Create new HubAutoMatch that will automatically create objects in a Hub with references that match the objects in a master hub.
|
HubAutoMatch(Hub<TYPE> hub,
String property,
Hub<PROPTYPE> hubMaster,
OAObject objStop,
String stopProperty) |
Modifier and Type | Method and Description |
---|---|
protected void |
_update(boolean bCheckInSync) |
void |
afterAdd(HubEvent e)
HubListener interface method, used to listen to changes to master Hub.
|
void |
afterInsert(HubEvent e)
HubListener interface method, used to listen to changes to master Hub.
|
void |
afterRemove(HubEvent e)
HubListener interface method, used to listen to changes to master Hub.
|
void |
close()
Closes HubAutoMatch.
|
protected TYPE |
createNewObject(Object obj) |
protected void |
finalize() |
boolean |
getEnabled() |
void |
init(Hub<TYPE> hub,
String property,
Hub<PROPTYPE> hubMaster,
OAObject objStop,
String stopProperty) |
boolean |
okToRemove(Object obj,
Object propertyValue)
Called before removing an object that does not have a matching value.
|
void |
onNewList(HubEvent e)
HubListener interface method, used to listen to changes to master Hub.
|
void |
setEnabled(boolean b) |
protected void |
setProperty(String property) |
void |
setServerSideOnly(boolean b)
This needs to be set to true if it is only created on the server, but client applications will be using the same Hub that is
filtered.
|
void |
update() |
afterChangeActiveObject, afterDelete, afterLoad, afterMove, afterNewList, afterPropertyChange, afterRemoveAll, afterSave, afterSort, beforeAdd, beforeDelete, beforeInsert, beforeMove, beforePropertyChange, beforeRefresh, beforeRemove, beforeRemoveAll, beforeSave, beforeSelect, getDescription, getListener, getLocation, getName, setLocation
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getAllowAdd, getAllowDelete, getAllowEnabled, getAllowRemove, getAllowRemoveAll, getAllowVisible, isValidAdd, isValidDelete, isValidPropertyChange, isValidRemove, isValidRemoveAll
protected Hub hub
protected Hub hubMaster
protected String property
protected boolean bManuallyCalled
protected OAObject objStop
protected String stopProperty
protected transient Method getMethod
protected transient Method setMethod
public HubAutoMatch(Hub<TYPE> hub, String property, Hub<PROPTYPE> hubMaster, boolean bManuallyCalled)
hubMaster
- hub that has all objects to useproperty
- property in hub that has same type as objects in hubMaster.bManuallyCalled
- set to true if the update method will be manually called. This is used in cases where the hubMaster could be
generating events that should not affect the matching. For example, if the hubMaster is controlled by a
HubMerger and objects are added/removed.public HubAutoMatch(Hub<TYPE> hub, String property, Hub<PROPTYPE> hubMaster, OAObject objStop, String stopProperty)
stopProperty
- propertyPath from hubMaster that is used to stop if truepublic HubAutoMatch()
public void init(Hub<TYPE> hub, String property, Hub<PROPTYPE> hubMaster, OAObject objStop, String stopProperty)
public void setServerSideOnly(boolean b)
public void close()
protected void finalize() throws Throwable
protected void setProperty(String property)
public void update()
protected void _update(boolean bCheckInSync)
public boolean okToRemove(Object obj, Object propertyValue)
public void afterInsert(HubEvent e)
afterInsert
in interface HubListener
afterInsert
in class HubListenerAdapter
public void afterAdd(HubEvent e)
afterAdd
in interface HubListener
afterAdd
in class HubListenerAdapter
Hub.add
public void afterRemove(HubEvent e)
afterRemove
in interface HubListener
afterRemove
in class HubListenerAdapter
public void onNewList(HubEvent e)
onNewList
in interface HubListener
onNewList
in class HubListenerAdapter
public void setEnabled(boolean b)
public boolean getEnabled()
Copyright © 1999–2025 ViaOA. All rights reserved.