@Test public void testParent() { assertThat(empty.parent()).isNull(); assertThat(single.parent()).isEqualTo(empty); assertThat(dual.parent()).isEqualTo(WorkspaceFamily.parse("hello")); }
@Override public WorkspaceFamily parent() { switch (getCount()) { case 0: return null; case 1: return EMPTY; default: return new WorkspaceFamily(Arrays.copyOf(data, data.length - 1)); } }
WorkspaceFamily implements Id { @Override public WorkspaceFamily parent() { switch (getCount()) { case 0: return null; case 1: return EMPTY; default: return new WorkspaceFamily(Arrays.copyOf(data, data.length - 1)); } } }
WorkspaceFamily implements Id { @Override public WorkspaceFamily parent() { switch (getCount()) { case 0: return null; case 1: return EMPTY; default: return new WorkspaceFamily(Arrays.copyOf(data, data.length - 1)); } } private  WorkspaceFamily(String[] data); }
WorkspaceFamily implements Id { @Override public WorkspaceFamily parent() { switch (getCount()) { case 0: return null; case 1: return EMPTY; default: return new WorkspaceFamily(Arrays.copyOf(data, data.length - 1)); } } private  WorkspaceFamily(String[] data); @NonNull static WorkspaceFamily of(@NonNull Id id); @NonNull static WorkspaceFamily parse(@NonNull String input); @Override String get(int index); @Override WorkspaceFamily extend(String tail); @Override WorkspaceFamily parent(); @Override int getCount(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString(); @Override String[] toArray(); }
WorkspaceFamily implements Id { @Override public WorkspaceFamily parent() { switch (getCount()) { case 0: return null; case 1: return EMPTY; default: return new WorkspaceFamily(Arrays.copyOf(data, data.length - 1)); } } private  WorkspaceFamily(String[] data); @NonNull static WorkspaceFamily of(@NonNull Id id); @NonNull static WorkspaceFamily parse(@NonNull String input); @Override String get(int index); @Override WorkspaceFamily extend(String tail); @Override WorkspaceFamily parent(); @Override int getCount(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString(); @Override String[] toArray(); static final WorkspaceFamily SA_MULTI; static final WorkspaceFamily SA_DOC_X13; static final WorkspaceFamily SA_DOC_TRAMOSEATS; static final WorkspaceFamily SA_SPEC_X13; static final WorkspaceFamily SA_SPEC_TRAMOSEATS; static final WorkspaceFamily MOD_DOC_REGARIMA; static final WorkspaceFamily MOD_DOC_TRAMO; static final WorkspaceFamily MOD_SPEC_REGARIMA; static final WorkspaceFamily MOD_SPEC_TRAMO; static final WorkspaceFamily UTIL_CAL; static final WorkspaceFamily UTIL_VAR; }