Esempio n. 1
0
        private static bool IsCssMatchStyle(AttributeMatchStyle matchStyle)
        {
            switch (matchStyle)
            {
            case AttributeMatchStyle.Equal:
                return(true);

            default:
                return(false);
            }
        }
Esempio n. 2
0
        private static string XpathAttributeCondition(string name, string value, AttributeMatchStyle style = AttributeMatchStyle.Equal)
        {
            switch (style)
            {
            case AttributeMatchStyle.Equal:
                return(string.Format("[@{0}={1}]", name, value));

            case AttributeMatchStyle.Contains:
                return(string.Format("[contains(@{0},{1})]", name, value));

            default:
                throw new ArgumentOutOfRangeException("style");
            }
        }
Esempio n. 3
0
 public ScssAttribute(string name, string value, AttributeMatchStyle matchStyle)
 {
     Name       = name;
     Value      = value;
     MatchStyle = matchStyle;
 }
Esempio n. 4
0
 public ScssAttribute(string name, string value, AttributeMatchStyle matchStyle)
 {
     this.Name       = name;
     this.Value      = value;
     this.MatchStyle = matchStyle;
 }