Comments for Synchronous Messages https://stuartmarks.wordpress.com Stuart Marks on Java, Software Systems, and other topics Fri, 10 Jan 2025 14:08:06 +0000 hourly 1 http://wordpress.com/ Comment on Detoxifying the JDK Source Code by Java 24 : quoi de neuf ? | Loic's Blog https://stuartmarks.wordpress.com/2024/12/12/detoxifying-the-jdk-source-code/#comment-5222 <![CDATA[Java 24 : quoi de neuf ? | Loic's Blog]]> Fri, 10 Jan 2025 14:08:06 +0000 http://stuartmarks.wordpress.com/?p=1950#comment-5222 <![CDATA[[…] Stuart Marks a écrit un article intéressant sur la suppression du Security Manager : Detoxifying the JDK Source Code. […]]]> <![CDATA[

[…] Stuart Marks a écrit un article intéressant sur la suppression du Security Manager : Detoxifying the JDK Source Code. […]

]]> Comment on Detoxifying the JDK Source Code by Java Weekly, Issue 573 - 라이프온룸 https://stuartmarks.wordpress.com/2024/12/12/detoxifying-the-jdk-source-code/#comment-5217 <![CDATA[Java Weekly, Issue 573 - 라이프온룸]]> Wed, 01 Jan 2025 08:01:27 +0000 http://stuartmarks.wordpress.com/?p=1950#comment-5217 <![CDATA[[…] JDK 소스 코드의 독성 제거하기 […]]]> <![CDATA[

[…] JDK 소스 코드의 독성 제거하기 […]

]]>
Comment on Detoxifying the JDK Source Code by Java Weekly, Issue 573 | Baeldung https://stuartmarks.wordpress.com/2024/12/12/detoxifying-the-jdk-source-code/#comment-5210 <![CDATA[Java Weekly, Issue 573 | Baeldung]]> Thu, 19 Dec 2024 22:10:07 +0000 http://stuartmarks.wordpress.com/?p=1950#comment-5210 <![CDATA[[…] Detoxifying the JDK Source Code […]]]> <![CDATA[

[…] Detoxifying the JDK Source Code […]

]]>
Comment on Scanner is a Weird but Useful Beast by Mark Y https://stuartmarks.wordpress.com/2020/04/14/scanner-is-a-weird-but-useful-beast/#comment-5107 <![CDATA[Mark Y]]> Wed, 15 May 2024 00:58:35 +0000 http://stuartmarks.wordpress.com/?p=1545#comment-5107 <![CDATA[In reply to <a href="https://stuartmarks.wordpress.com/2020/04/14/scanner-is-a-weird-but-useful-beast/#comment-3846">stuartmarks</a>. <!-- wp:paragraph --> <p>the combo is more flexible than if the two groups were split apart into two classes, because this lets you switch back and forth as needed… I’ve used this when I wanted to write a quick and dirty FIX protocol parser</p> <!-- /wp:paragraph --><!-- wp:paragraph --> <p><a href="https://en.m.wikipedia.org/wiki/Financial_Information_eXchange" rel="nofollow ugc">https://en.m.wikipedia.org/wiki/Financial_Information_eXchange</a></p> <!-- /wp:paragraph --><!-- wp:paragraph --> <p>First you can read the hard coded string (no need for tokens here)</p> <!-- /wp:paragraph --><!-- wp:paragraph --> <p>8=FIX.4.2 | 9=</p> <!-- /wp:paragraph --><!-- wp:paragraph --> <p>which gets right to the point where you need an integer, so you can use nextShort (with the proper delimiter) and then you can get the rest of the message(again no need for tokens)</p> <!-- /wp:paragraph --><!-- wp:paragraph --> <p>this barely qualifies as a parser; we have not even attempted to understand the message, but at least it’s good enough to break up a stream into messages at the proper message boundaries. </p> <!-- /wp:paragraph -->]]> <![CDATA[

In reply to stuartmarks.

the combo is more flexible than if the two groups were split apart into two classes, because this lets you switch back and forth as needed… I’ve used this when I wanted to write a quick and dirty FIX protocol parser

https://en.m.wikipedia.org/wiki/Financial_Information_eXchange

First you can read the hard coded string (no need for tokens here)

8=FIX.4.2 | 9=

which gets right to the point where you need an integer, so you can use nextShort (with the proper delimiter) and then you can get the rest of the message(again no need for tokens)

this barely qualifies as a parser; we have not even attempted to understand the message, but at least it’s good enough to break up a stream into messages at the proper message boundaries.

]]>
Comment on Oracle Code One 2019 by abhishekomp https://stuartmarks.wordpress.com/2019/09/27/oracle-code-one-2019/#comment-5015 <![CDATA[abhishekomp]]> Sat, 04 Nov 2023 22:54:16 +0000 http://stuartmarks.wordpress.com/?p=1532#comment-5015 <![CDATA[In reply to <a href="https://stuartmarks.wordpress.com/2019/09/27/oracle-code-one-2019/#comment-5014">stuartmarks</a>. Thanks a lot. You and your talks on topics related to Java is really awesome. retainAll() was super nice as well which serves as A ∩ B Thanks again.]]> <![CDATA[

In reply to stuartmarks.

Thanks a lot. You and your talks on topics related to Java is really awesome. retainAll() was super nice as well which serves as A ∩ B
Thanks again.

]]>
Comment on Oracle Code One 2019 by stuartmarks https://stuartmarks.wordpress.com/2019/09/27/oracle-code-one-2019/#comment-5014 <![CDATA[stuartmarks]]> Sat, 04 Nov 2023 17:16:52 +0000 http://stuartmarks.wordpress.com/?p=1532#comment-5014 <![CDATA[In reply to <a href="https://stuartmarks.wordpress.com/2019/09/27/oracle-code-one-2019/#comment-5013">Abhishek</a>. Hi, thanks for watching my old talk! I guess I never uploaded that file. I've done so now. Here's a link to that file. (I've also updated the post to include the link.) https://stuartmarks.files.wordpress.com/2019/09/ccc.jshell.txt]]> <![CDATA[

In reply to Abhishek.

Hi, thanks for watching my old talk! I guess I never uploaded that file. I’ve done so now. Here’s a link to that file. (I’ve also updated the post to include the link.)

https://stuartmarks.files.wordpress.com/2019/09/ccc.jshell.txt

]]>
Comment on Oracle Code One 2019 by Abhishek https://stuartmarks.wordpress.com/2019/09/27/oracle-code-one-2019/#comment-5013 <![CDATA[Abhishek]]> Sat, 04 Nov 2023 13:51:38 +0000 http://stuartmarks.wordpress.com/?p=1532#comment-5013 <![CDATA[Hello Stuart, It was a good learning about the comparator behavior with TreeSet via your talk on Corner Cases. I was looking for the script you used during this talk, would you help locate them. Thanks]]> <![CDATA[

Hello Stuart,
It was a good learning about the comparator behavior with TreeSet via your talk on Corner Cases. I was looking for the script you used during this talk, would you help locate them.
Thanks

]]>
Comment on Incompatibilities with JDK 15 CharSequence.isEmpty by Polishing Diamonds in Java - SoatDev IT Consulting https://stuartmarks.wordpress.com/2020/09/22/incompatibilities-with-jdk-15-charsequence-isempty/#comment-4965 <![CDATA[Polishing Diamonds in Java - SoatDev IT Consulting]]> Sat, 15 Jul 2023 19:08:56 +0000 http://stuartmarks.wordpress.com/?p=1593#comment-4965 <![CDATA[[…] Incompatibilities with JDK 15 CharSequence.isEmpty […]]]> <![CDATA[

[…] Incompatibilities with JDK 15 CharSequence.isEmpty […]

]]>
Comment on The Importance of Writing Stuff Down by Polishing Diamonds in Java - SoatDev IT Consulting https://stuartmarks.wordpress.com/2023/02/22/the-importance-of-writing-stuff-down/#comment-4964 <![CDATA[Polishing Diamonds in Java - SoatDev IT Consulting]]> Sat, 15 Jul 2023 19:06:23 +0000 http://stuartmarks.wordpress.com/?p=1758#comment-4964 <![CDATA[[…] The Importance of Writing Stuff Down […]]]> <![CDATA[

[…] The Importance of Writing Stuff Down […]

]]>
Comment on The Importance of Writing Stuff Down by stuartmarks https://stuartmarks.wordpress.com/2023/02/22/the-importance-of-writing-stuff-down/#comment-4951 <![CDATA[stuartmarks]]> Mon, 22 May 2023 21:51:37 +0000 http://stuartmarks.wordpress.com/?p=1758#comment-4951 <![CDATA[In reply to <a href="https://stuartmarks.wordpress.com/2023/02/22/the-importance-of-writing-stuff-down/#comment-4949">Antonio Lago</a>. Right, the idea of SequencedCollection elements having successors and predecessors is mostly for definitional purposes. There aren't any such operations in the APIs, as you noted. You might look at NavigableSet, which has higher(E) and lower(E) methods that let you find the adjacent elements. NavigableMap has similar methods for finding adjacent keys and entries, given a key. Using these APIs you can "iterate" through a NavigableSet or NavigableMap without using an explicit Iterator object.]]> <![CDATA[

In reply to Antonio Lago.

Right, the idea of SequencedCollection elements having successors and predecessors is mostly for definitional purposes. There aren’t any such operations in the APIs, as you noted.

You might look at NavigableSet, which has higher(E) and lower(E) methods that let you find the adjacent elements. NavigableMap has similar methods for finding adjacent keys and entries, given a key. Using these APIs you can “iterate” through a NavigableSet or NavigableMap without using an explicit Iterator object.

]]>