### Question:
ListType extends AbstractType { @Override public boolean isAssignableFrom(Class<?> clazz) { if (super.isAssignableFrom(clazz)) { return true; } if (clazz.isArray()) { return elementType.isAssignableFrom(clazz.getComponentType()); } return false; } ListType();  ListType(final String id, final String name, final Type elementType); Type getElementType(); void setElementType(Type elementType); @Override boolean isAssignableFrom(Class<?> clazz); Object convertToTypedObject(final Object source); boolean isAssignableValue(Object source); @Override boolean isValid();  }### Answer:
@Test public void testIsAssignableFrom() throws Exception { ListType stringListType = new ListType("string[]", "string[]", PrimitiveType.STRING); assertTrue(stringListType.isAssignableFrom(TypedList.class)); assertTrue(stringListType.isAssignableFrom(List.class)); assertTrue(stringListType.isAssignableFrom(String[].class)); assertFalse(stringListType.isAssignableFrom(Map.class)); ListType stringListType2 = new ListType("string[][]", "string[][]", stringListType); assertTrue(stringListType2.isAssignableFrom(TypedList.class)); assertTrue(stringListType2.isAssignableFrom(List.class)); assertTrue(stringListType2.isAssignableFrom(String[][].class)); assertFalse(stringListType2.isAssignableFrom(Map.class)); assertFalse(stringListType2.isAssignableFrom(String[].class)); ListType integerListType = new ListType("integer[]", "integer[]", PrimitiveType.INTEGER); assertTrue(integerListType.isAssignableFrom(int[].class)); assertTrue(integerListType.isAssignableFrom(Integer[].class)); assertTrue(integerListType.isAssignableFrom(byte[].class)); assertTrue(integerListType.isAssignableFrom(short[].class)); assertFalse(integerListType.isAssignableFrom(long[].class)); assertFalse(integerListType.isAssignableFrom(float[].class)); }