3,427 reputation
723
bio website hierax.org
location Minneapolis, MN
age 35
visits member for 2 years, 11 months
seen 9 hours ago

I love software development, and technology of all kinds. I have a boy and a girl and a beautiful wife, all of whom I adore. I practice Southern Chinese Kung Fu, and hope that my kids will too. I write code and play boardgames in my spare time.

I currently work as a JEE engineer in Edina, MN.


Dec
11
comment Usage of magic strings/numbers
The result of a judgement call can vary even between mature developers, so even arbitrary coding guidelines are meant to improve readability through consistency. This is unrelated to the fact that creating a constant NumberTen makes no sense.
Nov
20
comment Is it okay to test multiple similar files in one functional test
The if test at the end didn't make sense; fixed now. The getAllFiles() method would contain the logic to figure out what files need to be tested. I don't know of a way to create tests dynamically, but I'm sure you could do it with CGLib or similar if you really wanted to.
Oct
25
comment I need to create an employee schedule/appointments program, but I don't know how to set it up
Good point; I assumed 1 on 1 as well.
Oct
25
comment I need to create an employee schedule/appointments program, but I don't know how to set it up
I would keep two foreign keys on the appointments table: trainer_id, customer_id. An appointment is always exactly 1 trainer, and optionally 1 customer, so trainers have some set of appointment rows (created automatically each week/month based on settings?), and customers get linked to an appointment when they reserve one.
Oct
4
comment Java convention for if/else if order
When the difference in efficiency is negligible as in this case, readability is most important. Simplifying conditionals by extracting and naming their components is a great way to improve readability.
Oct
2
comment Refactoring two classes from third-party library that could have extended a base class
What's your goal for the refactoring? I can see that you might want to avoid writing too many copies of the two blocks shown in your question, but unless there are lots more object types that you want to abstract away, it doesn't seem like a very pressing problem.
Sep
30
comment Design Issue: Service layer/ trying to maintain RESTful architecture
Indeed. My earlier comment simplifies the topic, but I think my point follows from the idempotancy of PUT.
Sep
30
comment Design Issue: Service layer/ trying to maintain RESTful architecture
I don't have experience with this situation, so just a note: when the client knows the resource's ID (i.e. Customers/id, Orders/id), inserts/update should use PUT rather than POST. stackoverflow.com/questions/630453/put-vs-post-in-rest
Sep
27
comment Should I combine similar functions even though they are slightly different?
Using a boolean parameter is indeed not the best solution. I'll update the answer, although I think Carl's answer is more specific to the OP's question.
Sep
20
comment Correct comment to put for boolean function arguments that are “false”?
Good catch, thanks.
Sep
17
comment More efficient way to paginate search results
Please provide more detail in your answer about the content of the link. "Always quote the most relevant part of an important link, in case the target site is unreachable or goes permanently offline." programmers.stackexchange.com/help/how-to-answer
Sep
16
comment How to Track File Uploads and Return Upload Status with REST?
Are the uploads happening in a browser?
Sep
13
comment Why can't SQL return joined tables in a nested format?
Hibernate will retrieve the root entity and certain collections in a single query when the eager fetch mode is used for those collections; in that case it does the reduction of root entity properties in memory. Other ORMs can likely do the same.
Sep
13
comment Is over-engineering a warning sign?
@Nim - I think Karl's point is that what you consider overengineering, other interviewers may consider a good representation of the interviewee's grasp of OOD. The reference to pseudo-code may not be as explicit as you think in describing the type of approach that you expect.
Sep
12
comment project with 2 types of interfaces performing different jobs, should they use the same BLL and DAL?
I don't have experience with VS, but I would try splitting each of those libraries into 2. One with base functionality, and one with advanced functionality. The desktop app would depend on only the base library, and the webapp would depend on both the base and advanced functionality libraries.
Sep
12
comment project with 2 types of interfaces performing different jobs, should they use the same BLL and DAL?
How to achieve it depends on entirely on your build system.
Sep
12
comment project with 2 types of interfaces performing different jobs, should they use the same BLL and DAL?
Is your business and data access logic so unique as to warrant the extra work? Even if so, it should be possible to include only the modules or packages that the desktop app requires at build time.
Sep
12
comment Performance related doubt in Java with Hibernate
If you're in doubt, don't make any guesses. Professionals back up their hunches with data.
Sep
10
comment XSLT and possible alternatives
XPath can be used within XSLT to retrieve nodes, attributes, text, etc from an XML document.
Sep
10
comment How to elegantly work with a lot of print functions?
I tried to improve the grammar, but I'm unclear on the meaning of your second GUI-related requirement.