All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.usc.file.operater.rules.ConvertFactory Maven / Gradle / Ivy

The newest version!
package org.usc.file.operater.rules;

/**
 * 转换工厂
 * 
 * @author ShunLi
 * @notes Created on 2010-12-11
* Revision of last commit:$Revision$
* Author of last commit:$Author$
* Date of last commit:$Date$
*

*/ public class ConvertFactory { public static ConvertRule createConvertRule(Rule rule) { ConvertRule cr = new SmallToBigConvertRule(); // Default if (Rule.SmallToBig == rule) { cr = new SmallToBigConvertRule(); } else if (Rule.BigToSmall == rule) { cr = new BigToSmallConvertRule(); // cr = new SimpleBigToSmallConvertRule(); // simple 支持百一下的文件,快速一点 } else if (Rule.Prefix == rule) { cr = new PrefixConvertRule(); } else if (Rule.Suffix == rule) { cr = new SuffixConvertRule(); } else if (Rule.Replace == rule) { cr = new ReplaceConvertRule(); } return cr; } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy