mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-19 01:31:17 -10:00
Adding reference source for System.Data System.Data.DataSetExtensions System.Data.Entity System.Data.Entity.Design System.Data.Linq System.Data.SqlXml System.ServiceModel System.ServiceModel.Activation System.ServiceModel.Activities System.ServiceModel.Channels System.ServiceModel.Discovery System.ServiceModel.Internals System.ServiceModel.Routing System.ServiceModel.WasHosting System.ServiceModel.Web System.Web System.Web.ApplicationServices System.Web.DynamicData System.Web.Entity System.Web.Entity.Design System.Web.Extensions System.Web.Mobile System.Web.Routing System.Web.Services System.Xml System.Xml.Linq
44 lines
1.4 KiB
C#
44 lines
1.4 KiB
C#
namespace System.Web.Routing {
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
|
|
// Represents a segment of a URL that is not a separator. It contains subsegments such as literals and parameters.
|
|
internal sealed class ContentPathSegment : PathSegment {
|
|
public ContentPathSegment(IList<PathSubsegment> subsegments) {
|
|
Subsegments = subsegments;
|
|
}
|
|
|
|
public bool IsCatchAll {
|
|
get {
|
|
//
|
|
return Subsegments.Any<PathSubsegment>(seg => (seg is ParameterSubsegment) && (((ParameterSubsegment)seg).IsCatchAll));
|
|
}
|
|
}
|
|
|
|
public IList<PathSubsegment> Subsegments {
|
|
get;
|
|
private set;
|
|
}
|
|
|
|
#if ROUTE_DEBUGGING
|
|
public override string LiteralText {
|
|
get {
|
|
List<string> s = new List<string>();
|
|
foreach (PathSubsegment subsegment in Subsegments) {
|
|
s.Add(subsegment.LiteralText);
|
|
}
|
|
return String.Join(String.Empty, s.ToArray());
|
|
}
|
|
}
|
|
|
|
public override string ToString() {
|
|
List<string> s = new List<string>();
|
|
foreach (PathSubsegment subsegment in Subsegments) {
|
|
s.Add(subsegment.ToString());
|
|
}
|
|
return "[ " + String.Join(", ", s.ToArray()) + " ]";
|
|
}
|
|
#endif
|
|
}
|
|
}
|