Kofa's tech stuff
  • How to test what an application writes to the console

    Mar 28, 2012 · 1 min read  ·
    Share on:

    Suppose you have to unit-test some Java code that writes to the console. Here’s a way to do it: import java.io.BufferedReader; import java.io.File; import java.io.FileReader; import java.io.IOException; import java.io.PrintStream; public class StringPrintStream extends PrintStream { private final File file; …

    Read More
  • Reviewing / testing / refactoring code efficiently

    Nov 10, 2011 · 2 min read  ·
    Share on:

    Updated: you should check out this 40-minute presentation. The stuff below covers just one of his recommendations: testing code that changes often, in case your VCS is SVN. Reviews and refactoring take time - and there’s just never enough of that. Once I found a blog entry (sorry, I can’t seem to find it …

    Read More
  • Adobe's blurred image restoration

    Oct 17, 2011 · 0 min read  ·
    Share on:

    Read More
  • Controlling Java integer cache

    Apr 28, 2011 · 1 min read  ·
    Share on:

    Useful for autoboxing. By default, Integer.valueOf caches between -128 and 127 (min/max. of signed byte). However, you can increase this range by using: -XX:+AggressiveOpts and/or -Djava.lang.Integer.<wbr></wbr>IntegerCache.high when launching the VM. More details: …

    Read More
  • Kata is a Java girl

    Mar 31, 2011 · 1 min read  ·
    Share on:

    Our younger daughter, Kata, is a Java girl. If you ask her to put something down or stop playing with something, she just drops it and leaves it where it is. It’s out of scope, and will be managed by the garbage collector…

    Read More
  • Free RAW processors

    Mar 8, 2011 · 1 min read  ·
    Share on:

    Content was completely outdated. Check https://pixls.us/software/ instead.

    Read More
    • ««
    • «
    • 1
    • 2
    • »
    • »»

Recent Posts

  • Enforce https for Drupal
  • darktable styles
  • try-with-resources, suppressed Exceptions, and a peek at Java 9
  • Disassembling HotSpot-generated machine code
  • Full-screen HD streaming video playback in Firefox on Linux
  • Darktable, OpenCL, nVidia, Ubuntu 14.04, Mint 17
  • Outlook/Office 2013 too bright, waste space
  • Unit testing with static dependencies, e.g. Logger
Kofa's tech stuff

Copyright  KOFA'S TECH STUFF. All Rights Reserved