/*
* Created on 2004/08/13
* Author aki@www.xucker.jpn.org
* License Apache2.0 or Common Public License
*/
package org.jpn.xucker.wmatopcm;
import java.io.File;
import org.jpn.xucker.commons.swt.series.ResultData;
import org.jpn.xucker.commons.swt.series.wfs.WrapperExecuter;
/**
*
*
*/
public class WmaToPcmExecuter extends WrapperExecuter{
/* (non-Javadoc)
* @see org.jpn.xucker.commons.swt.series.wfs.WrapperExecuter#setResultValue(org.jpn.xucker.commons.swt.series.ResultData, java.lang.String, java.io.File, java.io.File, java.io.File)
*/
protected void setResultValue(ResultData result, String rootPath, File outputDir, File input, File output) {
// TODO Auto-generated method stub
if(output.exists()){
result.setValue(resultLabel[0],"");
}else{
result.setValue(resultLabel[0],"s");
}
result.setValue(resultLabel[1],output.getName());
result.setValue(resultLabel[2],output.getParent());
}
/* (non-Javadoc)
* @see org.jpn.xucker.commons.swt.series.wfs.WrapperExecuter#createArgs(java.io.File, java.io.File)
*/
protected String[] createArgs(File inputFile, File outputFile) {
String args[]=null;
if (isTrueValue(WmaToPcmWrapper.WAVE_FORMAT_EXTENSIVE)) {
args = new String[] { commandPath, inputFile.getAbsolutePath(),
outputFile.getAbsolutePath(), "-ext" };
} else {
args = new String[] { commandPath, inputFile.getAbsolutePath(),
outputFile.getAbsolutePath() };
}
return args;
}
}
|