@Override
    @SuppressWarnings("unchecked")
    public void write(JmeExporter ex) throws IOException {
        OutputCapsule output = ex.getCapsule(this);

        output.write(name, "name", null);
        output.write(attachedNode, "attachedNode", null);
        output.write(targetGeometry, "targetGeometry", null);
        output.write(initialTransform, "initialTransform", new Transform());
        output.write(inverseModelBindMatrix, "inverseModelBindMatrix", new Matrix4f());
        output.writeSavableArrayList(new ArrayList(children), "children", null);
    }
Serialize this Joint to the specified exporter, for example when saving
to a J3O file.

@param ex the exporter to write to (not null)
@throws IOException from the exporter
jme3-core/src/main/java/com/jme3/anim/Joint.java