Why Apple users seems odd sometimes
29-Oct-07Some Apple users are happy about a “goto line xy” function in a shitty text editor: Leopard Love: “Go To” in TextEdit
Some Apple users are happy about a “goto line xy” function in a shitty text editor: Leopard Love: “Go To” in TextEdit
Some more or less unordered thoughts and impressions of the latest iteration of Apples Mac OS X, nicknamed Leopard: Despite all the naysayers who warn you “don’t upgrade, make a clean install”, i’ve updated two Intel Macs to today without much hassle. In both cases, the famous “Welcome Movie Thingy” crashed 🙁 Hurray, good first […]
After presenting a working InputStream on a ByteBuffer, i have to more readers for you out there. First, the StringBufferReader to efficient read data from a StringBuffer. One can use new java.io.StringReader(sb.toString()) but that would convert the whole StringBuffer (sb) to a string, loosing a whole lotta memory if the string is just big enough. […]
This example is plain wrong. The InputStream will cause an endless loop as it always returns a value >= 0. Working code as follows: private static InputStream _newInputStream(final ByteBuffer buf) { return new InputStream() { public synchronized int read() throws IOException { return buf.hasRemaining() ? buf.get() : -1; } public synchronized int read(byte[] bytes, […]
With the current and latest Oracle JDBC Drivers it’s possible to retrieve one automatically generated key based on a sequence or any other arbitrary value (autogenerated-keys or identity columns in other databases). Certainly it isn’t as simple as just use using Statement.html#getGeneratedKeys() as it simply returns an emtpy resultset. After browsing around, i saw that […]