Package org.apache.syncope.common.to

Examples of org.apache.syncope.common.to.AbstractSysInfoTO


public class AddETagFilter implements ContainerResponseFilter {

    @Override
    public void filter(final ContainerRequestContext reqCtx, final ContainerResponseContext resCtx) throws IOException {
        if (resCtx.getEntity() instanceof AbstractSysInfoTO && resCtx.getEntityTag() == null) {
            AbstractSysInfoTO sysInfo = (AbstractSysInfoTO) resCtx.getEntity();
            String etagValue = sysInfo.getETagValue();
            if (StringUtils.isNotBlank(etagValue)) {
                resCtx.getHeaders().add(HttpHeaders.ETAG, new EntityTag(etagValue).toString());
            }
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.syncope.common.to.AbstractSysInfoTO

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.