Exemplo n.º 1
0
        /// <summary>
        /// Deserializes an instance of <see cref="SandboxObserverDescriptor"/>.
        /// </summary>
        public static SandboxObserverDescriptor Deserialize(BuildXLReader reader)
        {
            Contract.Requires(reader != null);

            return(new SandboxObserverDescriptor()
            {
                WarningRegex = reader.ReadNullable(r => ExpandedRegexDescriptor.Deserialize(r)),
                LogOutputToConsole = reader.ReadBoolean(),
                LogErrorToConsole = reader.ReadBoolean()
            });
        }
Exemplo n.º 2
0
 /// <summary>
 /// Checks for equality.
 /// </summary>
 public bool Equals(ExpandedRegexDescriptor descriptor)
 {
     return(!(descriptor is null) &&
            (ReferenceEquals(this, descriptor) ||
             (string.Equals(Pattern, descriptor.Pattern) && Options == descriptor.Options)));
 }