### Question:
Pointer implements Serializable { public PointerTarget getTarget() throws JWNLException { if (null == target && null != source.getDictionary()) { Synset syn = source.getDictionary().getSynsetAt(targetIndex.pos, targetIndex.offset); target = (targetIndex.index == 0) ? syn : (null == syn ? null : syn.getWords().get(targetIndex.index - 1)); if (null != target && source.getDictionary().isEditable()) { targetIndex = null; } } return target; } Pointer(PointerTarget source, PointerType pointerType, POS targetPOS, long targetOffset, int targetIndex);  Pointer(PointerType pointerType, PointerTarget source, PointerTarget target); String toString(); int getSourceIndex(); PointerType getType(); boolean isLexical(); boolean isSemantic(); boolean isSymmetricTo(Pointer that); PointerTarget getSource(); PointerTarget getTarget(); void setTarget(PointerTarget target); Synset getTargetSynset(); long getTargetOffset(); int getTargetIndex(); POS getTargetPOS(); @Override boolean equals(Object o); @Override int hashCode();  }### Answer:
@Test public void testGetTargetNull() throws JWNLException { Synset s = new Synset(dictionary, POS.NOUN, 1); Pointer p = new Pointer(s, PointerType.ANTONYM, POS.NOUN, 3, 0); Assert.assertNull(p.getTarget()); }
@Test public void testGetTarget() throws JWNLException { dictionary.edit(); Synset s = dictionary.createSynset(POS.NOUN); Synset t = dictionary.createSynset(POS.NOUN); Pointer p = new Pointer(s, PointerType.ANTONYM, POS.NOUN, t.getOffset(), 0); Assert.assertEquals(t, p.getTarget()); }