@Test public void consumerToComponent() { Edge actual = Edge.from(Component.of("phoenix", "superhero"), Consumer.by(Component.of("cyclop", "superhero"))); Edge expected = Edge.create("superhero:cyclop-to-superhero:phoenix", "superhero:cyclop", "superhero:phoenix"); Assert.assertEquals(expected, actual); }
public static Edge from(Component component, Consumer consumer) { String to = component.asString().toLowerCase(); String from = consumer.getComponent().asString().toLowerCase(); return Edge.create(from + "-to-" + to, from, to); }
Edge { public static Edge from(Component component, Consumer consumer) { String to = component.asString().toLowerCase(); String from = consumer.getComponent().asString().toLowerCase(); return Edge.create(from + "-to-" + to, from, to); } }
Edge { public static Edge from(Component component, Consumer consumer) { String to = component.asString().toLowerCase(); String from = consumer.getComponent().asString().toLowerCase(); return Edge.create(from + "-to-" + to, from, to); }  }
Edge { public static Edge from(Component component, Consumer consumer) { String to = component.asString().toLowerCase(); String from = consumer.getComponent().asString().toLowerCase(); return Edge.create(from + "-to-" + to, from, to); }  static Edge to(Component component, Dependency dependency); static Edge from(Component component, Consumer consumer); }
Edge { public static Edge from(Component component, Consumer consumer) { String to = component.asString().toLowerCase(); String from = consumer.getComponent().asString().toLowerCase(); return Edge.create(from + "-to-" + to, from, to); }  static Edge to(Component component, Dependency dependency); static Edge from(Component component, Consumer consumer);  }