package com.ningdatech.carapi.homepage.entity.model;

import com.ningdatech.cache.model.cache.CacheHashKey;
import com.ningdatech.cache.model.cache.CacheKeyBuilder;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

/**
 * @author CMM
 * @since 2023/07/06 10:47
 */
@Component
@Slf4j
@Data
@AllArgsConstructor
@NoArgsConstructor
public class MyCacheHashKey implements CacheKeyBuilder {

    private String prefix;

    @Override
    public String getPrefix() {
        return this.prefix;
    }

    @Override
    public CacheHashKey hashKey(Object... suffix) {
        return CacheKeyBuilder.super.hashKey(suffix);
    }
}
