When I use an application like Eclipse or Word, I occasionally see a JCheckBox that is neither selected nor deselected- it has a sort of 'minus' icon:
What does this mean? Is there a purpose for it, and if so, how do I achieve it in Java?
Usually, this kind of checkbox is used in a tree view (a checkbox which contains a subset of checkboxes) to indicate that it has been partially selected.
For example, when you are in the SDK page in Android Studio, you have a bunch of checkboxes for the different versions of the SDK, and each version is composed of the sources, the build tools, etc. When you select all the elements inside a version, the version's checkbox will have a normal tick, however if you select only the sources inside a version, the checkbox of that version will be a minus or some other icons. You could also find this in installers when there are optional features, like Notepad++ and many others.
As for implementing it in Java, I don't think there are any built-in solutions in Swing, you will either have to write it yourself like in the post that camickr put in the comments, or you will have to use other libraries like JavaFX or other third-parties.