using System.Collections.Generic;
using System.Linq;
namespace Artemis.UI.Shared.Routing;
///
/// Represents a route at a certain path.
///
public class Route
{
///
/// Initializes a new instance of the class.
///
/// The path of the route.
public Route(string path)
{
Path = path;
Segments = path.Split('/').Select(s => new RouteSegment(s)).ToList();
}
///
/// Gets the path of the route.
///
public string Path { get; }
///
/// Gets the list of segments that makes up the path.
///
public List Segments { get; }
///
public override string ToString()
{
return Path;
}
}