Unanswered Questions
446 questions with no upvoted or accepted answers
6
votes
0
answers
128
views
Android component animatable on its height
I'd like to have a code review for a component which is supposed to be animatable on its height. It's supposed to be a transitioning element.
I find it quite laggy on my phone.
...
6
votes
0
answers
815
views
Pseudo-parallel depth-first search
I'm writing a small program that generates a file containing an adjancency matrix, it then reads from that file, constructs a graph and does something like a parallel depth-first search (dfs) on it.
...
6
votes
0
answers
2k
views
Implement two level caching using spring's cache abstraction Cache and CacheManager
Details about spring's caching framework are here. When I was reading this link, I thought the composite cache mentioned there was one that used levels of caching based on the order given to the ...
5
votes
0
answers
106
views
Dial's heap in Java for integer priority queues
(The entire project is here.)
Intro
I have this priority queue data structure for non-negative integer priority keys. I recall that it is called Dial's heap.
Code
Implementation
...
5
votes
0
answers
158
views
Java OOP Hangman revision #4 includes UML
This is a continuation of this question. In the game the player chooses a topic and then gets a random word (or words) from that topic to guess.
I've repartitioned the code into objects several times,...
5
votes
0
answers
1k
views
Exception handling: using @JsonProperty value to make error message
If the validation in RestController fails, I need to handle MethodArgumentNotValidException and provide an errorMessage, that ...
5
votes
0
answers
66
views
Fragment of code with Android MVP that checks login credentials via REST API
I'm learning MVP for Android and am wondering if that piece of code that I wrote is correct in terms of this pattern or maybe is completely messed up.
I'm wondering if there can be return type other ...
5
votes
0
answers
1k
views
Mahjong hand completeness checking algorithm
As a summer project, I have been working on a small-scale, console-based version of Mahjong (the Rummy-like hand completion game, and not the solitaire version). While having prior knowledge of the ...
5
votes
0
answers
2k
views
Mouse wheel scrolling for nested scrollable Swing components
By default, mouse wheel scrolling in Java Swing behaves differently than in web browsers. In Swing, when you have an inner scrollable component and an outer scrollable component, the mouse wheel ...
5
votes
0
answers
2k
views
Android audio recording using AudioRecord and ByteBuffer
I'm developing an audio recorder app for android using AudioRecord class to have a low level access to audio samples.
...
5
votes
0
answers
238
views
Drawing the Mandelbrot with multiple threads in rust
The code below draws the mandelbrot set for { z | z∈ ℂ, -2.2 ≤ Re(z) ≤ 0.6, -1.4 ≤ Im(z) ≤ 1.4} into a 300×300px png image. For each pixel,
if the sequence {zi} is found to ...
5
votes
0
answers
382
views
Optimizing Graph Algorithms for Floyd Warshall and Johnson Algorithm
I am trying to implement and compare Floyd Warshall and Johnson Algorithm(for Sparse Graphs). I have written the following code which produces correct output values for the all pair shortest paths. ...
5
votes
0
answers
141
views
Writing service/network layer for mobile apps
I have an app that gets and posts blog posts to and from a server.
Right now I have a network client object which is passed into a service object. The service object is created and called from an ...
5
votes
0
answers
187
views
Concurrent Queue using Ada SPARK with the Ravenscar profile
See here: https://gitlab.com/linted/linted/blob/162b5e9fba53a90b3c6d78e214776e069c3c722b/src/ada-core/src/linted-queues.adb
The code implements a concurrent queue.
It can't allocate memory or use ...
5
votes
0
answers
141
views
User role Observable
I have a service with these methods:
Observable<User> getUsers();
Observable<Role> getUserRoles(String userId);
For each user, I want to get her ...