package com.changhong.epc.parsing.service.asset; import com.changhong.epc.bean.admin.AssetDepreciation; import com.changhong.epc.parsing.service.asset.account.AccountHandleImpl; import com.changhong.epc.parsing.service.asset.depreciation.DepreciationHandleImpl; import com.iemsoft.framework.cloud.core.tools.SpringUtil; public class AssetHandleFactory { public static AssetHandle getAssetHandle(AssetDepreciation assetDepreciation){ switch (assetDepreciation.getType()){ case ACCOUNT: return SpringUtil.getBean(AccountHandleImpl.class); case DEPRECIATION: return SpringUtil.getBean(DepreciationHandleImpl.class); } return null; } // public static void main(String... args){ // float f = 1; // f++; // System.out.println(Float.MAX_VALUE); // System.out.println(f); // } }