code: @Override
      public Positions merge(Positions other) {
          if (other instanceof SinglePosition) {
              SinglePosition that = (SinglePosition) other;
              return builder().addSinglePosition(that).build();
          } else if (other instanceof LinearPositions) {
              LinearPositions that = (LinearPositions) other;
              return AreaPositions.builder().addLinearPosition(this).addLinearPosition(that).build();
          } else {
              return other.merge(this);
          }
      }
docs: Merge this LinearPositions with another one. If the given {@link Positions} is:
  - SinglePosition, it will return a new LinearPositions with the given SinglePosition appended.
  - LinearPositions, it will return a new AreaPosition composed by this and the given LinearPositions.
  - Any other, it delegates to the other the merge logic.
  
  @param other Positions instance to merge with.
  
  @return Positions results of merging.