Coder Social home page Coder Social logo

javacsvreader's Introduction

JAVA CSV READER Library
FOR: Java based FRC robots. 
REQUIRED APIs: Standard FRC Java Lib (as of 2012) - not Standard API library.
DESCRIPTION: 
	This is a basic code that can be used to allow the robot to read CSV files (Character Seperated Values), and write them. This will allow for the program to contain an upper level of programming in which custom config files can be written to allow quick changes to robot properties and data. 

NOTES ON CSV STYLING:

At the begining of each document the user must include the file header data. This data is used to determine how the parser is to read the file. The format of the header is as follows: <DSV><Header_Delimiter><DSV><Line_Delimiter><DSV><Data_Delimiter><DSV> Where <DSV> represents a single any single character used to seperate the file header data. 

Headers: Headers are sets of related data in this CSV file. They are denoted by <Header_Delimiter> (see above) and directly followed by the data for the new header. Each Header denoting line MUST be formatted as follows: <Header_Delimiter>(JPDT)DescripterData,(JPDT)...etc...<Header_Delimiter> . For example, a new header is created by: #(String)Name,(int)Age,(double)Height Where # is the <Header_Delimiter> and String, int, double are the (JPDT) or (java Primitive Data type). (A Java Primitive data type are all data types that come wit h java. This program allows String to act as a JPDT). 

Data: Data within a given header is formated as follows: <Line_Delimiter>Data1,Data2,Data3,...etc . For example: ;Bob,12,4.5 Where ";" is the <Line_Delimiter> and Bob,12,4.5 are the data for the given header

EXAMPLE CSV FILE:

|#|;|,|
#(String)Name,(int)Age,(double)height
;Bob,12,3,2
;Larry,7,8.6
#(String)Device,(int)port
;Jag,3
;Relay,1
;Solenoid,2
#(String)Property,(String)Name,(double)value
;DistancePerCount,LeftEncoder,3.2333234
;MaxSpeed,MaxSpeed,3

NOTICE: each data set is seperated by a new line character (not shown). This includes any header data. 

javacsvreader's People

Contributors

camdenrobotics avatar laserswald avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.