package com.fs.fssync.sink.impl;

import com.fs.fssync.sink.AbstractCdcSinkStrategy;
import com.fs.store.domain.FsExpress;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.io.Serializable;

@Slf4j
@Component
public class FsExpressSinkStrategy extends AbstractCdcSinkStrategy<FsExpress> implements Serializable {

    @Override
    public boolean canHandle(String table) {
        return "fs_express".equals(table);
    }

    @Override
    public Class<FsExpress> getEntityClass() {
        return FsExpress.class;
    }

    @Override
    public String getKeyPrefix() {
        return "fs:express:";
    }

    @Override
    protected String getIdField() {
        return "omsCode";
    }
}
