code: @Nullable
    String getId() {
      ImmutableList<String> parts = getSegments();
  
      if (!parts.isEmpty()) {
        return parts.get(parts.size() - 1);
      } else {
        return null;
      }
    }
docs: The Path's id (last component).
  
  @return The last component of the Path or null if the path points to the root.