com.sap.hana.cloud.hcp.HCPServiceInfoCreator Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of spring-cloud-sap-connector Show documentation
Show all versions of spring-cloud-sap-connector Show documentation
Spring Cloud Connector for SAP HANA Cloud Platform (HCP)
package com.sap.hana.cloud.hcp;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.springframework.cloud.ServiceInfoCreator;
import org.springframework.cloud.service.ServiceInfo;
import com.sap.hana.cloud.hcp.service.common.ServiceData;
public abstract class HCPServiceInfoCreator implements ServiceInfoCreator
{
/**
* {@link Logger} instance used for logging/tracing.
*/
private final static Logger LOG = Logger.getLogger(HCPServiceInfoCreator.class.getName());
/**
* Returns whether or not this {@link ServiceInfoCreator} accepts the specified {@link ServiceData}.
*
* @return whether or not this {@link ServiceInfoCreator} accepts the specified {@link ServiceData}
*
* @see ServiceInfoCreator#accept(Object)
*/
public boolean accept(ServiceData serviceData)
{
boolean retVal = false;
if (LOG.isLoggable(Level.FINER))
{
LOG.entering(this.getClass().getName(), "accept", serviceData);
}
retVal = (serviceData == this.getServiceData());
if (LOG.isLoggable(Level.FINER))
{
LOG.exiting(this.getClass().getName(), "accept", retVal);
}
return retVal;
}
/**
* Returns the associated {@link ServiceData} element.
*
* @return The associated {@link ServiceData} element
*
* @see ServiceData
*/
abstract public ServiceData getServiceData();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy