Пример #1
0
        private void addToken(string text)
        {
            string[] parts = text.Split(':');
            var      token = new TreeNodeToken
            {
                Type = parts[0].ToLower(),
                Path = parts[1]
            };

            _tokens.Add(token);
        }
        private static void addToken(TreeNode node, List<TreeNodeToken> actual)
        {
            string locator = node.Subject.GetPath().Locator;
            string typeName = node.Subject.GetType().Name.ToLower();
            var token = new TreeNodeToken
            {
                Path = locator,
                Type = typeName
            };

            actual.Add(token);
        }
Пример #3
0
        private static void addToken(TreeNode node, List <TreeNodeToken> actual)
        {
            string locator  = node.Subject.GetPath().Locator;
            string typeName = node.Subject.GetType().Name.ToLower();
            var    token    = new TreeNodeToken
            {
                Path = locator,
                Type = typeName
            };

            actual.Add(token);
        }
Пример #4
0
 public bool Equals(TreeNodeToken obj)
 {
     if (ReferenceEquals(null, obj))
     {
         return(false);
     }
     if (ReferenceEquals(this, obj))
     {
         return(true);
     }
     return(Equals(obj.Type, Type) && Equals(obj.Path, Path));
 }
 private void addToken(string text)
 {
     string[] parts = text.Split(':');
     var token = new TreeNodeToken
     {
         Type = parts[0].ToLower(),
         Path = parts[1]
     };
     _tokens.Add(token);
 }
 public bool Equals(TreeNodeToken obj)
 {
     if (ReferenceEquals(null, obj)) return false;
     if (ReferenceEquals(this, obj)) return true;
     return Equals(obj.Type, Type) && Equals(obj.Path, Path);
 }