joetesta
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-07-2016
01:14 PM
Default values?
What is the default value of a boolean? I know I can create a simple test app and find out myself, but why doesn't the documentation state clearly somewhere what the default value of a boolean is? Would be just lovely if this page told me:
https://sdkdocs.roku.com/display/sdkdoc ... +and+Types
I would like to know so that I know whether or not to initiate the boolean or not:
https://sdkdocs.roku.com/pages/viewpage ... Id=1608549
If not specified, the default value for the field type is used
https://sdkdocs.roku.com/display/sdkdoc ... +and+Types
I would like to know so that I know whether or not to initiate the boolean or not:
https://sdkdocs.roku.com/pages/viewpage ... Id=1608549
If not specified, the default value for the field type is used
aspiring
4 REPLIES 4
EnTerr
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-07-2016
01:25 PM
Re: Default values?
There is no "default value" concept in BrightScript, i don't think.
This is a scenography issue, so take it up with the RSG guy 😛
As a rule of thumb though, i'd expect the "zero-ish" value to be default, e.g. [ ], { }, False, "", invalid...
This is a scenography issue, so take it up with the RSG guy 😛
As a rule of thumb though, i'd expect the "zero-ish" value to be default, e.g. [ ], { }, False, "", invalid...


Roku Employee
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-07-2016
01:31 PM
Re: Default values?
BrightScript itself doesn't have any concept of default values.
For Scene Graph fields, however, the default value would be false (0, "", empty, and so on for other types).
EnTerr beat me to it 😉 ... what he said. 😮
For Scene Graph fields, however, the default value would be false (0, "", empty, and so on for other types).
EnTerr beat me to it 😉 ... what he said. 😮
joetesta
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-07-2016
01:45 PM
Re: Default values?
Thanks guys -
I love how you guys always imply that I'm making this stuff up 🙂
https://sdkdocs.roku.com/pages/viewpage ... Id=1608549
My guess would have been what you said (false) but I wanted a doc to link to.
I love how you guys always imply that I'm making this stuff up 🙂
https://sdkdocs.roku.com/pages/viewpage ... Id=1608549
If not specified, the default value for the field type is used
My guess would have been what you said (false) but I wanted a doc to link to.
aspiring
EnTerr
Roku Guru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-07-2016
02:39 PM
Re: Default values?
"joetesta" wrote:
Thanks guys - I love how you guys always imply that I'm making this stuff up 🙂
https://github.com/rokudev/docs/issues , maybe that will help.