示例#1
0
 public override bool Equals(object obj)
 {
     if (!(obj is PathEntry))
     {
         return(false);
     }
     return(((PathEntry)obj).ActualPath.ToLower() == ActualPath.ToLower());
 }
示例#2
0
        public override IEnumerable <IPathSegment> GetSegements()
        {
            var segments = new List <IPathSegment>();

            foreach (string segment in ActualPath.Split(SeperatorSymbol.ToCharArray()))
            {
                segments.Add(CreatePathSegment(segment));
            }

            return(segments);
        }
示例#3
0
        public override IEnumerable <IPathSegment> GetSegements()
        {
            var segments = new List <IPathSegment>();

            foreach (string segment in ActualPath.Split(NodeSeperatorSymbol.ToCharArray()))
            {
                string[] nestedSegments = segment.Split(AttributeSeperatorSymbol.ToCharArray());

                if (nestedSegments.Length >= 1)
                {
                    segments.Add(CreatePathSegment(nestedSegments[0]));
                }

                if (nestedSegments.Length >= 2)
                {
                    segments.Add(CreateAttributePathSegment(nestedSegments[1]));
                }
            }

            return(segments);
        }
示例#4
0
 public override IEnumerable <IPathSegment> GetSegements()
 {
     return(ActualPath.Split(SeperatorSymbol.ToCharArray()).Select(CreatePathSegment).ToList());
 }
示例#5
0
 public override int GetHashCode()
 {
     return(ActualPath.ToLower().GetHashCode());
 }