use of eu.ggnet.dwoss.redtape.ee.api.LegacyLocalBridge in project dwoss by gg-net.
the class UnitSupporterOperation method isRefurbishIdAvailable.
/**
* Returns true if supplied refurbishId is available, meaning not jet in the database.
*
* @param refurbishId the refubishedId
* @return true if available.
*/
@Override
public boolean isRefurbishIdAvailable(String refurbishId) {
UniqueUnit uniqueUnit = new UniqueUnitEao(uuEm).findByIdentifier(UniqueUnit.Identifier.REFURBISHED_ID, refurbishId);
if (uniqueUnit != null)
return false;
if (bridgeInstance.isUnsatisfied())
return true;
LegacyLocalBridge bridge = bridgeInstance.get();
L.info("Using LegacyBridge ({})", bridge.localName());
return bridge.isUnitIdentifierAvailable(refurbishId);
}
Aggregations