/** * */ package org.gcube.accounting.datamodel.validations.validators; import java.io.Serializable; import org.gcube.accounting.datamodel.UsageRecord; import org.gcube.accounting.datamodel.decorators.DeprecatedAction; import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** * @author Luca Frosini (ISTI - CNR) http://www.lucafrosini.com/ * */ public class WarningAlert implements DeprecatedAction { private static Logger logger = LoggerFactory.getLogger(WarningAlert.class); /** * {@inheritDoc} */ @Override public Serializable manage(String key, Serializable manage, UsageRecord usageRecord) { logger.warn("The field {} is deprecated for the {}. Anyway the field will be included in the document", key, usageRecord.getClass().getSimpleName()); return manage; } }