All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.netgrif.application.engine.importer.service.IModelValidator Maven / Gradle / Ivy

Go to download

System provides workflow management functions including user, role and data management.

There is a newer version: 6.3.3
Show newest version
package com.netgrif.application.engine.importer.service;


import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.util.Collection;

public interface IModelValidator {
    default void validateAttribute(Object attr, String attrName) {
        Logger log = LoggerFactory.getLogger(IModelValidator.class);

        if (attr instanceof Collection && !((Collection) attr).isEmpty()) {
            log.warn("Data attribute [" + attrName + "] is deprecated.");
        }

        if (!(attr instanceof Collection) && attr != null) {
            log.warn("Data attribute [" + attrName + "] is deprecated.");
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy