I’m using Java Swing to make a UI and the idea is to make it look like the native OS (in this case, Windows). I’ve used: And everything is good so far, except for one little detail. I’m trying to use the arrow buttons to hide/show a JTextArea like the ones described in MS’s documentati…
Is this considered a cyclic dependency (is this good practice)?
Hi I am a new Java programmer and have a small question about class design. I understand that something like this is a cyclic dependency and is probably not a way to structure a project: public class …
How can I insert an array into a specific array element using Jolt
Question/problem How can I use Jolt to insert an array into a specific object in an array? input The objects have a common set of attributes, but support optional attributes. Specific objects need to get these optional attributes depending on their specific position in the array, i.e. second ([1]). These opti…
How to force LocalDateTime Month to be 3 letters long
My goal is to use LocalDateTime and display a month with exactly 3 letters. For the English language, this is easy: The result is as expected: For the German language (as above, only with Locale.GERMAN), the result is unexpected: While the abbreviations are all common in german, “März”, “Jun…
Children of CollapsingToolbarLayout with different collapse modes
I would like to create a CollapsingToolbarLayout that contains two views (one below the other – like a LinearLayout manner). The problem is that i would like these views to have different collapse modes – upper one parallax, the other – none. When I put them in one LinearLayout I can only se…
Document created even after NoHostAvailableException
I am trying to execute multiple BatchSatements in parallel with ExecutorService of Java. I want to know whether my query is successfully executed. I have gone through: how do I find out if the update query was successful or not in Cassandra Datastax It’s saying if no exception is there, we can consider …
Transforming compass direction output
I have directional outputs which are both flipped and + – as appose to genuine compass outputs. I want to convert these using math to give me the correct output. I am pretty sure this can be done using trigonometric functions, i would welcome any advice i have drawn a quick sketch excuse the rough jotti…
Custom validation with javax.validation
I’m trying to make a custom java validation annotation and returns me Request processing failed; nested exception is javax.validation.ConstraintDeclarationException: HV000144: Cross parameter …
Is it possible to open 2 microphones in Android at same time with Oboe library?
I’m trying to open 2 microphone streams with google’s Oboe library like this, for each microphone: oboe::AudioStreamBuilder builder; builder.setChannelCount(channelCount) ->…
JDA ChannelManager setname Channel view online stats
After joining discord, the channel should refresh and show the new number of players online. After executing twice, the channel does not refresh again. public void onGuildMemberJoin(@Nonnull …