@Test void verifyEventTypeBeingGenerated() { final String channelName = "github"; final String processId = "the_cool_project"; final String type = DataEventAttrBuilder.toType(channelName, processId); assertThat(type).isNotBlank().contains(processId).contains(channelName).startsWith(AbstractDataEvent.TYPE_PREFIX); }
public static String toType(final String channelName, final ProcessInstance process) { Objects.requireNonNull(process); Objects.requireNonNull(channelName); return String.format(AbstractDataEvent.TYPE_FORMAT, process.getProcessId().toLowerCase(), channelName.toLowerCase()); }
DataEventAttrBuilder { public static String toType(final String channelName, final ProcessInstance process) { Objects.requireNonNull(process); Objects.requireNonNull(channelName); return String.format(AbstractDataEvent.TYPE_FORMAT, process.getProcessId().toLowerCase(), channelName.toLowerCase()); } }
DataEventAttrBuilder { public static String toType(final String channelName, final ProcessInstance process) { Objects.requireNonNull(process); Objects.requireNonNull(channelName); return String.format(AbstractDataEvent.TYPE_FORMAT, process.getProcessId().toLowerCase(), channelName.toLowerCase()); } private  DataEventAttrBuilder(); }
DataEventAttrBuilder { public static String toType(final String channelName, final ProcessInstance process) { Objects.requireNonNull(process); Objects.requireNonNull(channelName); return String.format(AbstractDataEvent.TYPE_FORMAT, process.getProcessId().toLowerCase(), channelName.toLowerCase()); } private  DataEventAttrBuilder(); static String toSource(final ProcessInstance process); static String toType(final String channelName, final ProcessInstance process); static String toType(final String channelName, final String processId); }
DataEventAttrBuilder { public static String toType(final String channelName, final ProcessInstance process) { Objects.requireNonNull(process); Objects.requireNonNull(channelName); return String.format(AbstractDataEvent.TYPE_FORMAT, process.getProcessId().toLowerCase(), channelName.toLowerCase()); } private  DataEventAttrBuilder(); static String toSource(final ProcessInstance process); static String toType(final String channelName, final ProcessInstance process); static String toType(final String channelName, final String processId);  }