package com.persagy.adm.server.backstage.service.impl;

import com.persagy.dmp.common.constant.DigitalObjectType;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

/**
 * 默认的数据处理类
 * @author : lijie
 * Update By 2022/1/22 17:20
 */
@Component
@Slf4j
@RequiredArgsConstructor
public class DefaultDataHandler extends AbstractDataHandler {
    /**
     * 获得对象分类
     * @param classCode :对象类型编码
     * @return : java.lang.String
     * @author : lijie
     * Update By 2022/1/22 17:21
     */
    @Override
    protected String getObjectType(String classCode) {
        return classCode.length()==4? DigitalObjectType.SYSTEM.getIndex():DigitalObjectType.EQUIPMENT.getIndex();
    }
}
