@Test public void testCreateSequenceHeaderWhenTheSourceIsEmpty() { String testKey = "TestKey1"; String result = underTest.createSequenceHeader(null, testKey); Assert.assertEquals(result, testKey); }
public String createSequenceHeader(final String headerSource, final String sequenceId) { String result = ""; if (headerSource == null) { result = sequenceId; } else { StringBuilder sb = new StringBuilder(headerSource); sb.append(SequenceConstants.SEQUENCE_KEY_SEPARATOR.getConstant()).append(sequenceId); result = sb.toString(); } return result; }
SequenceHeaderUtil { public String createSequenceHeader(final String headerSource, final String sequenceId) { String result = ""; if (headerSource == null) { result = sequenceId; } else { StringBuilder sb = new StringBuilder(headerSource); sb.append(SequenceConstants.SEQUENCE_KEY_SEPARATOR.getConstant()).append(sequenceId); result = sb.toString(); } return result; } }
SequenceHeaderUtil { public String createSequenceHeader(final String headerSource, final String sequenceId) { String result = ""; if (headerSource == null) { result = sequenceId; } else { StringBuilder sb = new StringBuilder(headerSource); sb.append(SequenceConstants.SEQUENCE_KEY_SEPARATOR.getConstant()).append(sequenceId); result = sb.toString(); } return result; }  }
SequenceHeaderUtil { public String createSequenceHeader(final String headerSource, final String sequenceId) { String result = ""; if (headerSource == null) { result = sequenceId; } else { StringBuilder sb = new StringBuilder(headerSource); sb.append(SequenceConstants.SEQUENCE_KEY_SEPARATOR.getConstant()).append(sequenceId); result = sb.toString(); } return result; }  String createSequenceHeader(final String headerSource, final String sequenceId); String[] resolveSequenceHeader(final String headerSource); }
SequenceHeaderUtil { public String createSequenceHeader(final String headerSource, final String sequenceId) { String result = ""; if (headerSource == null) { result = sequenceId; } else { StringBuilder sb = new StringBuilder(headerSource); sb.append(SequenceConstants.SEQUENCE_KEY_SEPARATOR.getConstant()).append(sequenceId); result = sb.toString(); } return result; }  String createSequenceHeader(final String headerSource, final String sequenceId); String[] resolveSequenceHeader(final String headerSource);  }