private void Init(int id, int step, PhysicalLocationVersionOne physicalLocation, string fullyQualifiedLogicalName, string logicalLocationKey, string module, int threadId, string message, AnnotatedCodeLocationKindVersionOne kind, TaintKindVersionOne taintKind, string target, IEnumerable <string> values, IDictionary <string, string> state, string targetKey, bool essential, AnnotatedCodeLocationImportanceVersionOne importance, string snippet, IEnumerable <AnnotationVersionOne> annotations, IDictionary <string, SerializedPropertyInfo> properties)
        {
            Id   = id;
            Step = step;
            if (physicalLocation != null)
            {
                PhysicalLocation = new PhysicalLocationVersionOne(physicalLocation);
            }

            FullyQualifiedLogicalName = fullyQualifiedLogicalName;
            LogicalLocationKey        = logicalLocationKey;
            Module    = module;
            ThreadId  = threadId;
            Message   = message;
            Kind      = kind;
            TaintKind = taintKind;
            Target    = target;
            if (values != null)
            {
                var destination_0 = new List <string>();
                foreach (var value_0 in values)
                {
                    destination_0.Add(value_0);
                }

                Values = destination_0;
            }

            if (state != null)
            {
                State = new Dictionary <string, string>(state);
            }
            TargetKey  = targetKey;
            Essential  = essential;
            Importance = importance;
            Snippet    = snippet;
            if (annotations != null)
            {
                var destination_1 = new List <AnnotationVersionOne>();
                foreach (var value_1 in annotations)
                {
                    if (value_1 == null)
                    {
                        destination_1.Add(null);
                    }
                    else
                    {
                        destination_1.Add(new AnnotationVersionOne(value_1));
                    }
                }

                Annotations = destination_1;
            }

            if (properties != null)
            {
                Properties = new Dictionary <string, SerializedPropertyInfo>(properties);
            }
        }
        public virtual PhysicalLocationVersionOne VisitPhysicalLocationVersionOne(PhysicalLocationVersionOne node)
        {
            if (node != null)
            {
                node.Region = VisitNullChecked(node.Region);
            }

            return(node);
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="PhysicalLocationVersionOne" /> class from the specified instance.
        /// </summary>
        /// <param name="other">
        /// The instance from which the new instance is to be initialized.
        /// </param>
        /// <exception cref="ArgumentNullException">
        /// Thrown if <paramref name="other" /> is null.
        /// </exception>
        public PhysicalLocationVersionOne(PhysicalLocationVersionOne other)
        {
            if (other == null)
            {
                throw new ArgumentNullException(nameof(other));
            }

            Init(other.Uri, other.UriBaseId, other.Region);
        }
Пример #4
0
        private void Init(PhysicalLocationVersionOne analysisTarget, PhysicalLocationVersionOne resultFile, string fullyQualifiedLogicalName, string logicalLocationKey, string decoratedName, IDictionary <string, SerializedPropertyInfo> properties)
        {
            if (analysisTarget != null)
            {
                AnalysisTarget = new PhysicalLocationVersionOne(analysisTarget);
            }

            if (resultFile != null)
            {
                ResultFile = new PhysicalLocationVersionOne(resultFile);
            }

            FullyQualifiedLogicalName = fullyQualifiedLogicalName;
            LogicalLocationKey        = logicalLocationKey;
            DecoratedName             = decoratedName;
            if (properties != null)
            {
                Properties = new Dictionary <string, SerializedPropertyInfo>(properties);
            }
        }
Пример #5
0
        private void Init(string id, string ruleId, string ruleKey, PhysicalLocationVersionOne physicalLocation, string message, NotificationLevelVersionOne level, int threadId, DateTime time, ExceptionDataVersionOne exception, IDictionary <string, SerializedPropertyInfo> properties)
        {
            Id      = id;
            RuleId  = ruleId;
            RuleKey = ruleKey;
            if (physicalLocation != null)
            {
                PhysicalLocation = new PhysicalLocationVersionOne(physicalLocation);
            }

            Message  = message;
            Level    = level;
            ThreadId = threadId;
            Time     = time;
            if (exception != null)
            {
                Exception = new ExceptionDataVersionOne(exception);
            }

            if (properties != null)
            {
                Properties = new Dictionary <string, SerializedPropertyInfo>(properties);
            }
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="AnnotatedCodeLocationVersionOne" /> class from the supplied values.
 /// </summary>
 /// <param name="id">
 /// An initialization value for the <see cref="P: Id" /> property.
 /// </param>
 /// <param name="step">
 /// An initialization value for the <see cref="P: Step" /> property.
 /// </param>
 /// <param name="physicalLocation">
 /// An initialization value for the <see cref="P: PhysicalLocation" /> property.
 /// </param>
 /// <param name="fullyQualifiedLogicalName">
 /// An initialization value for the <see cref="P: FullyQualifiedLogicalName" /> property.
 /// </param>
 /// <param name="logicalLocationKey">
 /// An initialization value for the <see cref="P: LogicalLocationKey" /> property.
 /// </param>
 /// <param name="module">
 /// An initialization value for the <see cref="P: Module" /> property.
 /// </param>
 /// <param name="threadId">
 /// An initialization value for the <see cref="P: ThreadId" /> property.
 /// </param>
 /// <param name="message">
 /// An initialization value for the <see cref="P: Message" /> property.
 /// </param>
 /// <param name="kind">
 /// An initialization value for the <see cref="P: Kind" /> property.
 /// </param>
 /// <param name="taintKind">
 /// An initialization value for the <see cref="P: TaintKind" /> property.
 /// </param>
 /// <param name="target">
 /// An initialization value for the <see cref="P: Target" /> property.
 /// </param>
 /// <param name="values">
 /// An initialization value for the <see cref="P: Values" /> property.
 /// </param>
 /// <param name="state">
 /// An initialization value for the <see cref="P: State" /> property.
 /// </param>
 /// <param name="targetKey">
 /// An initialization value for the <see cref="P: TargetKey" /> property.
 /// </param>
 /// <param name="essential">
 /// An initialization value for the <see cref="P: Essential" /> property.
 /// </param>
 /// <param name="importance">
 /// An initialization value for the <see cref="P: Importance" /> property.
 /// </param>
 /// <param name="snippet">
 /// An initialization value for the <see cref="P: Snippet" /> property.
 /// </param>
 /// <param name="annotations">
 /// An initialization value for the <see cref="P: Annotations" /> property.
 /// </param>
 /// <param name="properties">
 /// An initialization value for the <see cref="P: Properties" /> property.
 /// </param>
 public AnnotatedCodeLocationVersionOne(int id, int step, PhysicalLocationVersionOne physicalLocation, string fullyQualifiedLogicalName, string logicalLocationKey, string module, int threadId, string message, AnnotatedCodeLocationKindVersionOne kind, TaintKindVersionOne taintKind, string target, IEnumerable <string> values, IDictionary <string, string> state, string targetKey, bool essential, AnnotatedCodeLocationImportanceVersionOne importance, string snippet, IEnumerable <AnnotationVersionOne> annotations, IDictionary <string, SerializedPropertyInfo> properties)
 {
     Init(id, step, physicalLocation, fullyQualifiedLogicalName, logicalLocationKey, module, threadId, message, kind, taintKind, target, values, state, targetKey, essential, importance, snippet, annotations, properties);
 }
Пример #7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="LocationVersionOne" /> class from the supplied values.
 /// </summary>
 /// <param name="analysisTarget">
 /// An initialization value for the <see cref="P: AnalysisTarget" /> property.
 /// </param>
 /// <param name="resultFile">
 /// An initialization value for the <see cref="P: ResultFile" /> property.
 /// </param>
 /// <param name="fullyQualifiedLogicalName">
 /// An initialization value for the <see cref="P: FullyQualifiedLogicalName" /> property.
 /// </param>
 /// <param name="logicalLocationKey">
 /// An initialization value for the <see cref="P: LogicalLocationKey" /> property.
 /// </param>
 /// <param name="decoratedName">
 /// An initialization value for the <see cref="P: DecoratedName" /> property.
 /// </param>
 /// <param name="properties">
 /// An initialization value for the <see cref="P: Properties" /> property.
 /// </param>
 public LocationVersionOne(PhysicalLocationVersionOne analysisTarget, PhysicalLocationVersionOne resultFile, string fullyQualifiedLogicalName, string logicalLocationKey, string decoratedName, IDictionary <string, SerializedPropertyInfo> properties)
 {
     Init(analysisTarget, resultFile, fullyQualifiedLogicalName, logicalLocationKey, decoratedName, properties);
 }
Пример #8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NotificationVersionOne" /> class from the supplied values.
 /// </summary>
 /// <param name="id">
 /// An initialization value for the <see cref="P: Id" /> property.
 /// </param>
 /// <param name="ruleId">
 /// An initialization value for the <see cref="P: RuleId" /> property.
 /// </param>
 /// <param name="ruleKey">
 /// An initialization value for the <see cref="P: RuleKey" /> property.
 /// </param>
 /// <param name="physicalLocation">
 /// An initialization value for the <see cref="P: PhysicalLocation" /> property.
 /// </param>
 /// <param name="message">
 /// An initialization value for the <see cref="P: Message" /> property.
 /// </param>
 /// <param name="level">
 /// An initialization value for the <see cref="P: Level" /> property.
 /// </param>
 /// <param name="threadId">
 /// An initialization value for the <see cref="P: ThreadId" /> property.
 /// </param>
 /// <param name="time">
 /// An initialization value for the <see cref="P: Time" /> property.
 /// </param>
 /// <param name="exception">
 /// An initialization value for the <see cref="P: Exception" /> property.
 /// </param>
 /// <param name="properties">
 /// An initialization value for the <see cref="P: Properties" /> property.
 /// </param>
 public NotificationVersionOne(string id, string ruleId, string ruleKey, PhysicalLocationVersionOne physicalLocation, string message, NotificationLevelVersionOne level, int threadId, DateTime time, ExceptionDataVersionOne exception, IDictionary <string, SerializedPropertyInfo> properties)
 {
     Init(id, ruleId, ruleKey, physicalLocation, message, level, threadId, time, exception, properties);
 }
 public bool ValueEquals(PhysicalLocationVersionOne other) => ValueComparer.Equals(this, other);