Documentation ¶
Overview ¶
Package csv has the implementation of the file interface for csv files
Index ¶
- type CSV
- func (c CSV) ID() uint
- func (c *CSV) IdentifyColumns(columns []interpreter.ColumnNode) ([]interpreter.ColumnNode, error)
- func (c *CSV) Store(a *config.AppContext) (*brainModels.Dataset, error)
- func (c *CSV) UpdateStatus(a *config.AppContext) error
- func (c *CSV) Upload(a *config.AppContext, table interpreter.TableNode, appendData bool, ...) error
- func (c *CSV) Validate() ([]error, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CSV ¶
type CSV struct { //Filename is the name of the file Filename string //Name is the dataset name Name string //Resource holds the db instance of the underlying file Resource db.FileUpload //Table is the underlying octopus table node Table *interpreter.TableNode }
CSV handles the fiels of csv type
func (*CSV) IdentifyColumns ¶
func (c *CSV) IdentifyColumns(columns []interpreter.ColumnNode) ([]interpreter.ColumnNode, error)
IdentifyColumns will identify the columns in the file and store them in the database
func (*CSV) Store ¶
func (c *CSV) Store(a *config.AppContext) (*brainModels.Dataset, error)
Store stores the csv info to database
func (*CSV) UpdateStatus ¶
func (c *CSV) UpdateStatus(a *config.AppContext) error
UpdateStatus updates the status of the file upload in db
Click to show internal directories.
Click to hide internal directories.