Fix an issue where the RIM java generator was creating illegal transitions when the RIM was not properly formed (target states not found).