Browse by Tags

All Tags » Java (RSS)

Data Structures and Algorithms: new free eBook available (first draft)

I've been looking at this for a while: Data Structures and Algorithms: Annotated reference with examples . It's only in "first draft" stage at the moment, but the authors would love your feedback (as would I). Somehow I've managed...
Posted by skeet | with no comments
Filed under: , ,

Automatic lambda expressions

This morning I happened to show a colleague (Malcolm Rowe) the neat trick of using nullable types and the null-coalescing operator (??) to implement compound comparisons in C#. He asked whether it wouldn't have been nicer to make this a library feature...
Posted by skeet | 2 comment(s)
Filed under: ,

The Beauty of Closures

Fairly soon I'm going to write a blog post comparing the different proposals under consideration for Java 7 when it comes to closures. I thought it would be worth writing some background material on it first though, so I've put an article on the...
Posted by skeet | 5 comment(s)
Filed under: ,

Programming "in" a language vs programming "into" a language

I'm currently reading Steve McConnell's Code Complete (for the first time - yes, I know that's somewhat worrying) and there was one section was disturbed me a little. For those of you with a copy to hand, it's in section 4.3, discussing...
Posted by skeet | 15 comment(s)
Filed under: , , , ,

Macros, and languages within languages

Ian Griffiths mailed me about macros, and explained how LISP macros were very different to C/C++ macros, working at a language level instead of at a text level. I won't pretend to understand all about what would be possible and what wouldn't,...
Posted by skeet | 10 comment(s)
Filed under: , , ,

Java isn't an acronym

Just a quickie while I remember. A pet peeve of mine has surfaced again recently, while reading some CVs. Java, the programming language, is just written "Java". It's not an acronym. There's no need to write it as "JAVA". That...
Posted by skeet | 7 comment(s)
Filed under:

Why hasn't Microsoft bought JetBrains yet?

For those of you who aren't aware, JetBrains is the company behind IntelliJ IDEA, the Java IDE which I've heard amazing things about (I've tried it a couple of times but never got into it - I think I need an expert sitting beside me to point...
Posted by skeet | 3 comment(s)
Filed under: , ,

Sheer Evil: Rethrowing exceptions in Java

This morning, I was looking through some code and I was annoyed (yet again) at Java's exception hierarchy, particularly when it comes to checked exceptions. Just as a reminder, everything that can be thrown in Java derives from Throwable . The predefined...
Posted by skeet | 14 comment(s)
Filed under:

Wacky Ideas 3: Object life-cycle support

No, don't leave yet! This isn't another article about non-deterministic finalization, RAII etc. That's what we almost always think of when someone mentions the object life-cycle, but I'm actually interested in the other end of the cycle - the "near birth...
Posted by skeet | with no comments
Filed under: , ,

Wacky Ideas 2: Class interfaces

(Disclaimer: I'm 99% sure I've heard someone smarter than me talking about this before, so it's definitely not original. I thought it worth pursuing though.) One of the things I love about Java and C# over C/C++ is the lack of .h files. Getting everything...
Posted by skeet | 5 comment(s)
Filed under: , ,

Wacky Ideas 1: Inheritance is dead, long live mix-ins!

(Warning: I've just looked up "mix-in" on Wikipedia and their definition isn't quite what I'm used to. Apologies if I'm using the wrong terminology. What I think of as a mix-in is a proxy object which is used to do a lot of the work the class doing the...
Posted by skeet | with no comments
Filed under: , ,

What would make a good Java book?

So, Groovy in Action has been out for a little while, and I'm missing it - or rather, book writing. I'd like my next project to be a solo effort, almost certainly on Java. However, I'm interested in hearing what you good folks think would make a good...
Posted by skeet | 3 comment(s)
Filed under: ,

Groovy 1.0 released

Groovy 1.0 has finally been released, and is available for download from the Groovy home page . For those of you who didn't read my last blog post on it, Groovy is a dynamic language which runs on the Java platform and integrates very nicely with Java...
Posted by skeet | with no comments
Filed under:

Everything old is new again

I feel I'm too young to be making this kind of statement, but the sense of deja vu I get when reading about the layouts in WPF makes me nearly laugh out loud. Of all the things I can remember about Java 1.0 (this was before any number of things we take...
Posted by skeet | with no comments
Filed under: ,

Groovy

Updated 7th August 2006 - It looks like closures aren't meant to require K&R bracing after all. Hoorah! Examples changed appropriately. One of my tasks at work is to investigate new languages and technologies and report back what use we might make...
Posted by skeet | 2 comment(s)
Filed under: ,

Inheritance Tax

Introduction There aren't many technical issues that my technical lead (Stuart) and I disagree on. However, one of them is inheritance and making things virtual. Stuart tends to favour making things virtual on the grounds that you never know when you...
Posted by skeet | 4 comment(s)
Filed under: ,

Bringing Subversion and Fitnesse together

I've recently started working with Subversion (a version control system) and FitNesse (the Fit acceptance testing framework based in a wiki). FitNesse has a primitive version control system built into it, where it builds zip files of previous versions...
Posted by skeet | 4 comment(s)
Filed under: ,

Visual Studio vs Eclipse

I often see people in newsgroups saying how wonderful Visual Studio is, and they often claim it's the "best IDE in the world". Strangely enough, most go silent when I ask how many other IDEs they've used for a significant amount of time. I'm not going...
Posted by skeet | 86 comment(s)
Filed under: , ,

New (to me) threading paradigms

In the last couple of days, I've been reading up on CSPs (Communicating Sequential Processes) and the Microsoft Research project CCR (Concurrency and Coordination Runtime). I suspect that the latter is really a new look at the former, but I don't have...
Posted by skeet | with no comments
Filed under: ,

System.Random (and java.util.Random)

This is as much a "before you forget about it" post as anything else. Both Java and .NET have Random classes, which allow you to get random numbers within a certain range etc. Unless you specify otherwise, both are seeded with the current time. Neither...
Posted by skeet | 5 comment(s)
Filed under: ,
More Posts Next page »