@@ -0,0 +1,1923 @@
+/*%0A * Bach - Java Shell Builder%0A * Copyright (C) 2020 Christian Stein%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A *     https://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A * See the License for the specific language governing permissions and%0A * limitations under the License.%0A */%0A%0Apackage de.sormuras.bach.project;%0A%0Aimport de.sormuras.bach.Scribe;%0Aimport de.sormuras.bach.internal.Factory;%0Aimport java.util.Objects;%0Aimport java.util.StringJoiner;%0A%0A/**%0A * A name of a Java module.%0A *%0A * @see Module#getName()%0A */%0Apublic final class ModuleName implements Comparable%3CModuleName%3E, Scribe %7B%0A%0A  private final String name;%0A%0A  public ModuleName(String name) %7B%0A    this.name = Objects.requireNonNull(name);%0A  %7D%0A%0A  public String name() %7B%0A    return name;%0A  %7D%0A%0A  @Override%0A  public boolean equals(Object o) %7B%0A    if (this == o) return true;%0A    if (o == null %7C%7C getClass() != o.getClass()) return false;%0A    ModuleName that = (ModuleName) o;%0A    return name.equals(that.name);%0A  %7D%0A%0A  @Override%0A  public int hashCode() %7B%0A    return Objects.hash(name);%0A  %7D%0A%0A  @Override%0A  public String toString() %7B%0A    return new StringJoiner(%22, %22, ModuleName.class.getSimpleName() + %22%5B%22, %22%5D%22)%0A        .add(%22name='%22 + name + %22'%22)%0A        .toString();%0A  %7D%0A%0A  //%0A  // Factory API%0A  //%0A%0A  @Factory%0A  public static ModuleName of(String name) %7B%0A    return new ModuleName(name);%0A  %7D%0A%0A  //%0A  // Normal API%0A  //%0A%0A  @Override%0A  public int compareTo(ModuleName other) %7B%0A    return name.compareTo(other.name);%0A  %7D%0A%0A  @Override%0A  public void scribe(Scroll scroll) %7B%0A    scroll.add(%22ModuleName.of%22, name);%0A  %7D%0A%7D%0A

Introduce module name record