|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
String parsing missing.
I just attempted to mess with strings and have noticed that a lot of standard string functions are missing, such as replace all, split, etc. Is there a reason strings have heavily reduced functionality with the robot templates? More importantly, is there a way to get that functionality back? I noticed that regular java projects have a libraries folder with JDK inside, and the templates don't. Is this the culprit?
|
|
#2
|
|||
|
|||
|
Re: String parsing missing.
FRC robot programs use the Squawk JVM which is a derivative of a pretty old version of Java ME. This results in a lot of missing classes or functions you may be used to from using Java SE on the desktop.
|
|
#3
|
||||
|
||||
|
Re: String parsing missing.
The JVM that runs on the cRIO doesn't have all the niceties that Java SE has (what's running on your desktop). We run on a version of Java ME.
You can write your own utilities functions to perform string operations. Example string split function Last edited by otherguy : 02-05-2014 at 11:34 PM. Reason: changed jre to jvm |
|
#4
|
||||||
|
||||||
|
Re: String parsing missing.
The 2015 control system will be using Java SE Embedded, so it will have the things you're missing.
|
|
#5
|
|||||
|
|||||
|
Re: String parsing missing.
Having to use an old version of java drives me crazy, the lack of ENUMS and other commonly used tools gets frustrating after a while. I'm glad to hear that we'll be upgrading next year.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|