public class P2PGridBasisFederationDao extends Object implements DataDao, FederationDao
Constructor and Description |
---|
P2PGridBasisFederationDao(FederationDao dao,
DaoContext context)
The constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addFederation(Federation federation) |
void |
addFederation(String sourceGridId,
String targetGridId) |
void |
clear() |
void |
deleteFederation(String sourceGridId,
String targetGridId) |
void |
deleteFederationsOf(String gridId) |
Federation |
getFederation(String sourceGridId,
String targetGridId) |
boolean |
isFederationExist(String sourceGridId,
String targetGridId) |
List<Federation> |
list() |
List<Federation> |
listFederationsFrom(String sourceGridId) |
List<Federation> |
listFederationsToward(String targetGridId) |
List<String> |
listSourceGridIds(String targetGridId) |
List<String> |
listTargetGridIds(String sourceGridId) |
void |
removeEntityListener() |
void |
setConnected(String sourceGridId,
String targetGridId,
boolean isRequesting) |
void |
setEntityListener() |
void |
setRequesting(String sourceGridId,
String targetGridId,
boolean isRequesting) |
boolean |
updateDataSource(Data data) |
boolean |
updateDataTarget(Data data) |
public P2PGridBasisFederationDao(FederationDao dao, DaoContext context)
dao
- public void setEntityListener()
setEntityListener
in interface DataDao
public void removeEntityListener()
removeEntityListener
in interface DataDao
public boolean updateDataSource(Data data) throws DataDaoException, UnmatchedDataTypeException
updateDataSource
in interface DataDao
DataDaoException
UnmatchedDataTypeException
public boolean updateDataTarget(Data data) throws DataDaoException, UnmatchedDataTypeException
updateDataTarget
in interface DataDao
DataDaoException
UnmatchedDataTypeException
public void clear() throws DaoException
clear
in interface FederationDao
DaoException
public boolean isFederationExist(String sourceGridId, String targetGridId) throws DaoException
isFederationExist
in interface FederationDao
DaoException
public Federation getFederation(String sourceGridId, String targetGridId) throws FederationNotFoundException, DaoException
getFederation
in interface FederationDao
FederationNotFoundException
DaoException
public void addFederation(Federation federation) throws FederationAlreadyExistsException, DaoException
addFederation
in interface FederationDao
FederationAlreadyExistsException
DaoException
public void addFederation(String sourceGridId, String targetGridId) throws FederationAlreadyExistsException, DaoException
addFederation
in interface FederationDao
FederationAlreadyExistsException
DaoException
public void deleteFederation(String sourceGridId, String targetGridId) throws FederationNotFoundException, DaoException
deleteFederation
in interface FederationDao
FederationNotFoundException
DaoException
public void deleteFederationsOf(String gridId) throws DaoException
deleteFederationsOf
in interface FederationDao
DaoException
public List<String> listSourceGridIds(String targetGridId) throws DaoException
listSourceGridIds
in interface FederationDao
DaoException
public List<String> listTargetGridIds(String sourceGridId) throws DaoException
listTargetGridIds
in interface FederationDao
DaoException
public List<Federation> listFederationsFrom(String sourceGridId) throws DaoException
listFederationsFrom
in interface FederationDao
DaoException
public List<Federation> listFederationsToward(String targetGridId) throws DaoException
listFederationsToward
in interface FederationDao
DaoException
public List<Federation> list() throws DaoException
list
in interface FederationDao
DaoException
public void setRequesting(String sourceGridId, String targetGridId, boolean isRequesting) throws DaoException
setRequesting
in interface FederationDao
DaoException
public void setConnected(String sourceGridId, String targetGridId, boolean isRequesting) throws DaoException
setConnected
in interface FederationDao
DaoException