@Test public void gettingShouldReturnValueIfIndexFound() throws Exception { instance.add("nothing"); instance.add("guilherme"); Object value = accessor.getProperty(null, instance, 1); assertThat(value, is(Matchers.equalTo((Object) "guilherme"))); }
@Override public Object getProperty(Map context, Object target, Object value) throws OgnlException { try { return super.getProperty(context, target, value); } catch (IndexOutOfBoundsException ex) { return null; } }
ListAccessor extends ListPropertyAccessor { @Override public Object getProperty(Map context, Object target, Object value) throws OgnlException { try { return super.getProperty(context, target, value); } catch (IndexOutOfBoundsException ex) { return null; } } }
ListAccessor extends ListPropertyAccessor { @Override public Object getProperty(Map context, Object target, Object value) throws OgnlException { try { return super.getProperty(context, target, value); } catch (IndexOutOfBoundsException ex) { return null; } } ListAccessor(Converters converters); }
ListAccessor extends ListPropertyAccessor { @Override public Object getProperty(Map context, Object target, Object value) throws OgnlException { try { return super.getProperty(context, target, value); } catch (IndexOutOfBoundsException ex) { return null; } } ListAccessor(Converters converters); @Override Object getProperty(Map context, Object target, Object value); @Override @SuppressWarnings("unchecked") void setProperty(Map context, Object target, Object key, Object value); }
ListAccessor extends ListPropertyAccessor { @Override public Object getProperty(Map context, Object target, Object value) throws OgnlException { try { return super.getProperty(context, target, value); } catch (IndexOutOfBoundsException ex) { return null; } } ListAccessor(Converters converters); @Override Object getProperty(Map context, Object target, Object value); @Override @SuppressWarnings("unchecked") void setProperty(Map context, Object target, Object key, Object value);  }