Fixing bug in last rev of FieldType.getArrayType(), adding more tests to cover that, and replacing more switch blocks with algorithmically-determined cached state.