Version 7.4.0 Build 16
Whenever I call the function below, it works as expected, with the exception that I get a WARN in the Bookmap Log. What do I need to do to get rid of the WARNing. I haven't found any documentation to help on this.
20240111 23:13:11.091(UTC) INFO: [SoundAlertsManager] Obtained: Layer1ApiSoundAlertMessage [textInfo='20240111.18:13:11 : HLine2 6412808779270 8 at 4747.00 ended', showPopup=false, repeatCount=1, repeatDelay=null, alertId='Y1enhPYpRhC9VEZerHauwg==', source=class velox.api.layer1.simplified.demo.RB_CVDImbalancev6, metadata=ESH4.CME@RITHMIC, alias='null', alertDeclarationId='null', priority=0, additionalInfo='null', isCancelMessage=false]
20240111 23:13:11.091(UTC) WARN: Alert message does not specify a linked alert declaration. Messages without declarations will be deprecated in future releases.
public void liquidityLineEndAlert(long t, int mapId, String orderId, long size1, int price1) {
if (settings.enableAlerts == YesNo.YES) {
Date tDate = new Date(t / 1000000);
String str = df2.format(tDate) + String.format(" : HLine%d %s %d at %.2f ended",
mapId, orderId, size1, (double) price1 / 4);
byte[] alertSound = null;
String str2;
if (price1 % 4 == 0)
str2 = String.format("%d at %d ended", size1, price1 / 4);
else if (price1 % 2 == 0)
str2 = String.format("%d at %.1f ended", size1, (double) price1 / 4);
else
str2 = String.format("%d at %.2f ended", size1, (double) price1 / 4);
alertSound = SoundSynthHelper.synthesize(str2);
Layer1ApiSoundAlertMessage msg = new Layer1ApiSoundAlertMessage(alertSound, str, 1, null,
(a, s) -> {
}, this.getClass(), alias);
api.sendUserMessage(msg);
}
}
Layer1ApiSoundAlertMessage WARN message help
-
- Posts: 43
- Joined: Mon Feb 08, 2021 5:37 pm
- Been thanked: 1 time
-
- Site Admin
- Posts: 279
- Joined: Mon Jun 11, 2018 11:44 am
- Has thanked: 2 times
- Been thanked: 31 times
-
- Posts: 43
- Joined: Mon Feb 08, 2021 5:37 pm
- Been thanked: 1 time
Re: Layer1ApiSoundAlertMessage WARN message help
Thank you, but is there any documentation on the group of API's that are used? I can cut and paste from the examples, and play around with modifying them to meet my needs, but I don't understand the calls in the example.
-
- Posts: 552
- Joined: Mon Jul 09, 2018 11:18 am
- Has thanked: 25 times
- Been thanked: 86 times
Re: Layer1ApiSoundAlertMessage WARN message help
You can unzip the javadoc from "C:\Program Files\Bookmap\lib\bm-l1api-javadoc.jar" (this is the location for Windows) and find some info there. If you have questions about API you may also ask them in the Discord Bookmap API channel.
https://discord.com/channels/7965002039 ... 9483396147
https://discord.com/channels/7965002039 ... 9483396147
-
- Site Admin
- Posts: 279
- Joined: Mon Jun 11, 2018 11:44 am
- Has thanked: 2 times
- Been thanked: 31 times
Re: Layer1ApiSoundAlertMessage WARN message help
Not sure I follow the question. There is a quite detailed readme at the link I sent.
-
- Posts: 43
- Joined: Mon Feb 08, 2021 5:37 pm
- Been thanked: 1 time
Re: Layer1ApiSoundAlertMessage WARN message help
I hadn't looked at the Readme. Sorry, thanks. You can close this item now.