![]() |
|
SageTV Studio Discussion related to the SageTV Studio application produced by SageTV. Questions, issues, problems, suggestions, etc. relating to the Studio software application should be posted here. |
![]() |
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
Can someone help a poor newbie
"WeatherIcons\\Images\\" + tv_sage_weather_WeatherDotCom_getCurrentCondition(WeatherInstance, "curr_icon") + ".png"
Can someone explain to me what's going on in this line... hopefully then it will all click. |
#2
|
|||
|
|||
I know nothing about studio, but based on programming background, it appears it's calling a function called tv_sage_weather_WeatherDotCom_getCurrentCondition() with the parameters of WeatherInstance, "curr_icon" to get the current conditions image name.
Find that function (or whatever it's called in studio) and you'll see how it works. |
#3
|
||||
|
||||
The expression: "tv_sage_weather_WeatherDotCom_getCurrentCondition(WeatherInstance, "curr_icon")" is calling a custom java function called "getCurrentCondition" and passing it the parameters "WeatherInstance" and "curr_icon". That function is not part of the SageAPI, so it is not documented, but it apparently returns a string (and if you don't know what a string is, it is just a variable that contains text - a collection of letters and numbers).
The three strings are than concatenated (joined) together by the plus (+) operators. So if the function returned "rain", you would get "WeatherIcons\\Images\\rain.png". The double slashes are because java uses the slash as an escape character, so you need to put an extra one in to make it get treated as text.
__________________
Server: Ryzen 2400G with integrated graphics, ASRock X470 Taichi Motherboard, HDMI output to Vizio 1080p LCD, Win10-64Bit (Professional), 16GB RAM Capture Devices (7 tuners): Colossus (x1), HDHR Prime (x2),USBUIRT (multi-zone) Source: Comcast/Xfinity X1 Cable Primary Client: Server Other Clients: (1) HD200, (1) HD300 Retired Equipment: MediaMVP, PVR150 (x2), PVR150MCE, HDHR, HVR-2250, HD-PVR |
#4
|
|||
|
|||
Thanks so much!
I have seen the light! |
#5
|
||||
|
||||
While it's true that Studio code, like Java and other C-derived languages, uses backslash as an escape character in string literals, you should not get the idea that Studio expression code is Java. There are important differences (such as the use of underscores instead of dots in fully-qualified method names).
__________________
-- Greg |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Poor hd playback. | utekineir | SageTV Beta Test Software | 8 | 12-14-2006 07:41 AM |
Poor picture? | Merlin | SageTV Software | 12 | 11-23-2006 01:30 AM |
Poor TV out Quality | Mav | SageTV Software | 17 | 09-17-2005 07:33 AM |
Frustrated! Poor Live TV quality (newbie) | bo989 | Hardware Support | 64 | 12-20-2004 01:24 PM |
Poor Audio | leswilkinson | SageTV Software | 0 | 08-02-2004 01:13 PM |