org.pentaho.platform.dataaccess.datasource.wizard.service.impl
Class CsvDatasourceServiceImpl

java.lang.Object
  extended by org.pentaho.platform.engine.core.system.PentahoBase
      extended by org.pentaho.platform.dataaccess.datasource.wizard.service.impl.CsvDatasourceServiceImpl
All Implemented Interfaces:
com.google.gwt.user.client.rpc.RemoteService, Serializable, ILogger, ICsvDatasourceService

public class CsvDatasourceServiceImpl
extends PentahoBase
implements ICsvDatasourceService

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.pentaho.platform.engine.core.system.PentahoBase
EMPTYLOGID, LOGID_MASK1, LOGID_MASK2, LOGID_SEPARATOR
 
Fields inherited from interface org.pentaho.platform.api.engine.ILogger
ACTIVITY_LOG, DEBUG, ERROR, FATAL, INFO, INSTANCE_LOG, SESSION_LOG, SOLUTION_LOG, TRACE, UNKNOWN, WARN
 
Constructor Summary
CsvDatasourceServiceImpl()
           
 
Method Summary
 String getEncoding(String fileName)
           
 org.apache.commons.logging.Log getLogger()
           
 List<String> getPreviewRows(String filename, boolean isFirstRowHeader, int rows, String encoding)
           
 FileInfo[] getStagedFiles()
           
 List<String> listDatasourceNames()
           
 FileTransformStats stageData(ModelInfo modelInfo, boolean truncateTable)
           
 ModelInfo stageFile(String fileName, String delimiter, String enclosure, boolean isFirstRowHeader, String encoding)
           
 
Methods inherited from class org.pentaho.platform.engine.core.system.PentahoBase
debug, debug, error, error, fatal, fatal, genLogIdFromInfo, genLogIdFromInfo, genLogIdFromSession, getLoggingLevel, getLogId, getObjectName, info, info, setLoggingLevel, setLogId, trace, trace, warn, warn
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CsvDatasourceServiceImpl

public CsvDatasourceServiceImpl()
Method Detail

getLogger

public org.apache.commons.logging.Log getLogger()
Specified by:
getLogger in class PentahoBase

getEncoding

public String getEncoding(String fileName)
Specified by:
getEncoding in interface ICsvDatasourceService

stageFile

public ModelInfo stageFile(String fileName,
                           String delimiter,
                           String enclosure,
                           boolean isFirstRowHeader,
                           String encoding)
                    throws Exception
Specified by:
stageFile in interface ICsvDatasourceService
Throws:
Exception

getStagedFiles

public FileInfo[] getStagedFiles()
                          throws Exception
Specified by:
getStagedFiles in interface ICsvDatasourceService
Throws:
Exception

stageData

public FileTransformStats stageData(ModelInfo modelInfo,
                                    boolean truncateTable)
                             throws Exception
Specified by:
stageData in interface ICsvDatasourceService
Throws:
Exception

getPreviewRows

public List<String> getPreviewRows(String filename,
                                   boolean isFirstRowHeader,
                                   int rows,
                                   String encoding)
                            throws Exception
Specified by:
getPreviewRows in interface ICsvDatasourceService
Throws:
Exception

listDatasourceNames

public List<String> listDatasourceNames()
                                 throws IOException
Specified by:
listDatasourceNames in interface ICsvDatasourceService
Throws:
IOException