示例#1
0
        public ValueModel(SourceSnapshot source, ParsedValue <string> value)
        {
            var location = new Location(source, value.Span);

            Value    = value.ValueOrDefault;
            Type     = TypesOfValue.Path; // FIXME: Дичь какая-то. Зачем это?
            Comments = new CommentBlockModel(location);
        }
示例#2
0
        public object Clone()
        {
            var clone = new CommentBlockModel(Location);

            clone.Comments.AddRange(Comments);

            return(clone);
        }
示例#3
0
        protected Model(
            ModelType modelType,
            int id,
            Nitra.Location?location,
            [NotNull] string name,
            [NotNull] string path)
        {
            ModelType = modelType;
            Id        = id;
            Comments  = new CommentBlockModel(location);
            Name      = name;
            FilePath  = path;

            CreateBackReferenceObjects();
        }
示例#4
0
 public ValueModel([CanBeNull] object value, TypesOfValue type, Location location)
 {
     Value    = value;
     Type     = type;
     Comments = new CommentBlockModel(location);
 }
示例#5
0
 public ReferenceModel([NotNull] TRefereedModel referred)
 {
     _modelId = referred.Id;
     Model    = referred;
     Comments = new CommentBlockModel();
 }
示例#6
0
 // deferred initialization
 // ReSharper disable once NotNullMemberIsNotInitialized
 public ReferenceModel(int id, Location referenceLocation)
 {
     _modelId = id;
     Comments = new CommentBlockModel(referenceLocation);
 }
示例#7
0
 // deferred initialization
 // ReSharper disable once NotNullMemberIsNotInitialized
 public ReferenceModel(int id)
 {
     _modelId = id;
     Comments = new CommentBlockModel();
 }