FilteredNavigationRecordImpl implements FilteredNavigationRecord, Serializable { @Override public FilteredNavigationRecord clone() { try { return (FilteredNavigationRecord) super.clone(); } catch (CloneNotSupportedException e) { return null; } } FilteredNavigationRecordImpl(final String name,
                                        final String code,
                                        final String value,
                                        final int count);  FilteredNavigationRecordImpl(final String name,
                                        final String displayName,
                                        final String code,
                                        final String value,
                                        final String displayValue,
                                        final int count,
                                        final int rank,
                                        final String type,
                                        final String template); @Override String getCode(); @Override void setCode(final String code); @Override String getValue(); @Override void setValue(final String value); @Override int getCount(); @Override void setCount(final int itemsCount); @Override void setName(final String name); @Override String getName(); @Override String getDisplayName(); @Override void setDisplayName(final String displayName); @Override int getRank(); @Override void setRank(final int rank); @Override String getType(); @Override void setType(final String type); @Override String getTemplate(); @Override void setTemplate(final String template); @Override String getDisplayValue(); @Override void setDisplayValue(final String displayValue); @Override FilteredNavigationRecord clone(); @Override boolean equals(Object o); @Override int hashCode();  }
@Test public void testClone() throws Exception { final FilteredNavigationRecordImpl original = new FilteredNavigationRecordImpl( "name", "displayName", "code", "value", "displayValue", 0, 0, "type", "template"); final FilteredNavigationRecord clone = original.clone(); assertNotSame(original, clone); assertEquals(original, clone); clone.setCount(20); clone.setName("new name"); clone.setCode("new code"); assertEquals("name", original.getName()); assertEquals("code", original.getCode()); assertEquals(0, original.getCount()); assertEquals("new name", clone.getName()); assertEquals("new code", clone.getCode()); assertEquals(20, clone.getCount()); }