Example #1
0
        public static SignaturePart Alternatives([ItemNotNull][NotNull] IEnumerable <SignaturePart> parts, [CanBeNull] string name = null)
        {
            var result = AlternativesPart.From(parts);

            result.Name = name;
            return(result);
        }
Example #2
0
        public static SignaturePart From([NotNull] SignaturePart inner)
        {
            if (inner is AlternativesPart ap)
            {
                return(AlternativesPart.From(ap.Alternatives.Select(From)));
            }

            return(new QuotedPart(inner));
        }