protected override async Task <Method> AssignUpsertedReferences(Method record)
        {
            record.DecoratorList = await _decoratorLists.UpsertAsync(record.DecoratorList);

            record.DecoratorListId = record.DecoratorList?.DecoratorListId ?? record.DecoratorListId;
            record.Block           = await _blocks.UpsertAsync(record.Block);

            record.BlockId = record.Block?.BlockId ?? record.BlockId;
            record.DocumentationComment = await _documentationComments.UpsertAsync(record.DocumentationComment);

            record.DocumentationCommentId = record.DocumentationComment?.DocumentationCommentId ?? record.DocumentationCommentId;
            record.Identifier             = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId  = record.Identifier?.IdentifierId ?? record.IdentifierId;
            record.ParameterList = await _parameterLists.UpsertAsync(record.ParameterList);

            record.ParameterListId = record.ParameterList?.ParameterListId ?? record.ParameterListId;
            record.Type            = await _identifiers.UpsertAsync(record.Type);

            record.TypeId            = record.Type?.IdentifierId ?? record.TypeId;
            record.TypeParameterList = await _typeParameterLists.UpsertAsync(record.TypeParameterList);

            record.TypeParameterListId = record.TypeParameterList?.TypeParameterListId ?? record.TypeParameterListId;
            return(record);
        }
        protected override async Task <Method> AssignUpsertedReferences(Method record)
        {
            record.ArrowClauseExpressionValue = await _expressions.UpsertAsync(record.ArrowClauseExpressionValue);

            record.ArrowClauseExpressionValueId = record.ArrowClauseExpressionValue?.ExpressionId ?? record.ArrowClauseExpressionValueId;
            record.AttributeListCollection      = await _attributeLists.UpsertAsync(record.AttributeListCollection);

            record.AttributeListCollectionId = record.AttributeListCollection?.AttributeListCollectionId ?? record.AttributeListCollectionId;
            record.Block = await _blocks.UpsertAsync(record.Block);

            record.BlockId = record.Block?.BlockId ?? record.BlockId;
            record.ConstraintClauseList = await _constraintClauseList.UpsertAsync(record.ConstraintClauseList);

            record.ConstraintClauseListId   = record.ConstraintClauseList?.ConstraintClauseListId ?? record.ConstraintClauseListId;
            record.DocumentationCommentList = await _documentationCommentLists.UpsertAsync(record.DocumentationCommentList);

            record.DocumentationCommentListId = record.DocumentationCommentList?.DocumentationCommentListId ?? record.DocumentationCommentListId;
            record.Identifier = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId = record.Identifier?.IdentifierId ?? record.IdentifierId;
            record.ModifierList = await _modifierLists.UpsertAsync(record.ModifierList);

            record.ModifierListId = record.ModifierList?.ModifierListId ?? record.ModifierListId;
            record.ParameterList  = await _parameterLists.UpsertAsync(record.ParameterList);

            record.ParameterListId = record.ParameterList?.ParameterListId ?? record.ParameterListId;
            record.Type            = await _identifiers.UpsertAsync(record.Type);

            record.TypeId            = record.Type?.IdentifierId ?? record.TypeId;
            record.TypeParameterList = await _typeParameterLists.UpsertAsync(record.TypeParameterList);

            record.TypeParameterListId = record.TypeParameterList?.TypeParameterListId ?? record.TypeParameterListId;
            return(record);
        }
        protected override async Task <Project> AssignUpsertedReferences(Project record)
        {
            record.Name = await _strings.UpsertAsync(record.Name);

            record.NameId = record.Name?.AsciiStringReferenceId ?? record.NameId;
            record.PathRelativeToSolution = await _strings.UpsertAsync(record.PathRelativeToSolution);

            record.PathRelativeToSolutionId = record.PathRelativeToSolution?.AsciiStringReferenceId ?? record.PathRelativeToSolutionId;
            return(record);
        }
        protected override async Task <TypeParameter> AssignUpsertedReferences(TypeParameter record)
        {
            record.ExtendsConstraint = await _identifiers.UpsertAsync(record.ExtendsConstraint);

            record.ExtendsConstraintId = record.ExtendsConstraint?.IdentifierId ?? record.ExtendsConstraintId;
            record.Identifier          = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId = record.Identifier?.IdentifierId ?? record.IdentifierId;
            return(record);
        }
        protected override async Task <MsBuildItemAttribute> AssignUpsertedReferences(MsBuildItemAttribute record)
        {
            record.Attribute = await _strings.UpsertAsync(record.Attribute);

            record.AttributeId = record.Attribute?.AsciiStringReferenceId ?? record.AttributeId;
            record.Value       = await _strings.UpsertAsync(record.Value);

            record.ValueId = record.Value?.AsciiStringReferenceId ?? record.ValueId;
            return(record);
        }
Esempio n. 6
0
        protected override async Task <DocumentationCommentAttribute> AssignUpsertedReferences(DocumentationCommentAttribute record)
        {
            record.Identifier = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId = record.Identifier?.IdentifierId ?? record.IdentifierId;
            record.Value        = await _identifiers.UpsertAsync(record.Value);

            record.ValueId = record.Value?.IdentifierId ?? record.ValueId;
            return(record);
        }
        protected override async Task <ConceptOneRequired> AssignUpsertedReferences(ConceptOneRequired record)
        {
            record.Concept1 = await _concepts.UpsertAsync(record.Concept1);

            record.Concept1Id = record.Concept1?.ConceptId ?? record.Concept1Id;
            record.Concept2   = await _concepts.UpsertAsync(record.Concept2);

            record.Concept2Id = record.Concept2?.ConceptId ?? record.Concept2Id;
            return(record);
        }
Esempio n. 8
0
        protected override async Task <ImportStatement> AssignUpsertedReferences(ImportStatement record)
        {
            record.ExportName = await _identifiers.UpsertAsync(record.ExportName);

            record.ExportNameId = record.ExportName?.IdentifierId ?? record.ExportNameId;
            record.ModuleName   = await _identifiers.UpsertAsync(record.ModuleName);

            record.ModuleNameId = record.ModuleName?.IdentifierId ?? record.ModuleNameId;
            return(record);
        }
Esempio n. 9
0
        protected override async Task <MsBuildTarget> AssignUpsertedReferences(MsBuildTarget record)
        {
            record.MsBuildTaskList = await _tasks.UpsertAsync(record.MsBuildTaskList);

            record.MsBuildTaskListId = record.MsBuildTaskList?.MsBuildTaskListId ?? record.MsBuildTaskListId;
            record.Name = await _strings.UpsertAsync(record.Name);

            record.NameId  = record.Name?.AsciiStringReferenceId ?? record.NameId;
            record.Outputs = await _strings.UpsertAsync(record.Outputs);

            record.OutputsId = record.Outputs?.AsciiStringReferenceId ?? record.OutputsId;
            return(record);
        }
Esempio n. 10
0
        protected override async Task <MsBuildProperty> AssignUpsertedReferences(MsBuildProperty record)
        {
            record.ElementName = await _strings.UpsertAsync(record.ElementName);

            record.ElementNameId = record.ElementName?.AsciiStringReferenceId ?? record.ElementNameId;
            record.ElementValue  = await _strings.UpsertAsync(record.ElementValue);

            record.ElementValueId   = record.ElementValue?.AsciiStringReferenceId ?? record.ElementValueId;
            record.MsBuildCondition = await _conditions.UpsertAsync(record.MsBuildCondition);

            record.MsBuildConditionId = record.MsBuildCondition?.MsBuildConditionId ?? record.MsBuildConditionId;
            return(record);
        }
Esempio n. 11
0
        protected override async Task <ConceptProperty> AssignUpsertedReferences(ConceptProperty record)
        {
            record.ImportNamespace = await _strings.UpsertAsync(record.ImportNamespace);

            record.ImportNamespaceId = record.ImportNamespace.AsciiStringReferenceId;
            record.Name = await _strings.UpsertAsync(record.Name);

            record.NameId = record.Name.AsciiStringReferenceId;
            record.Type   = await _strings.UpsertAsync(record.Type);

            record.TypeId = record.Type.AsciiStringReferenceId;
            return(record);
        }
Esempio n. 12
0
        protected override async Task <File> AssignUpsertedReferences(File record)
        {
            record.FileContent = await _fileContent.UpsertAsync(record.FileContent);

            record.FileContentId = record.FileContent?.FileContentId ?? record.FileContentId;
            record.Name          = await _strings.UpsertAsync(record.Name);

            record.NameId = record.Name?.AsciiStringReferenceId ?? record.NameId;
            record.Path   = await _strings.UpsertAsync(record.Path);

            record.PathId = record.Path?.AsciiStringReferenceId ?? record.PathId;
            return(record);
        }
        protected override async Task <Parameter> AssignUpsertedReferences(Parameter record)
        {
            record.AttributeListCollection = await _attributeLists.UpsertAsync(record.AttributeListCollection);

            record.AttributeListCollectionId = record.AttributeListCollection?.AttributeListCollectionId ?? record.AttributeListCollectionId;
            record.DefaultValue = await _expressions.UpsertAsync(record.DefaultValue);

            record.DefaultValueId = record.DefaultValue?.ExpressionId ?? record.DefaultValueId;
            record.Identifier     = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId = record.Identifier?.IdentifierId ?? record.IdentifierId;
            record.Type         = await _identifiers.UpsertAsync(record.Type);

            record.TypeId = record.Type?.IdentifierId ?? record.TypeId;
            return(record);
        }
        protected override async Task <Expression> AssignUpsertedReferences(Expression record)
        {
            record.Text = await _strings.UpsertAsync(record.Text);

            record.TextId = record.Text?.AsciiMaxStringReferenceId ?? record.TextId;
            return(record);
        }
        protected override async Task <UsingDirective> AssignUpsertedReferences(UsingDirective record)
        {
            record.Identifier = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId = record.Identifier?.IdentifierId ?? record.IdentifierId;
            return(record);
        }
        protected override async Task <ProjectFile> AssignUpsertedReferences(ProjectFile record)
        {
            record.File = await _files.UpsertAsync(record.File);

            record.FileId = record.File?.FileId ?? record.FileId;
            return(record);
        }
        protected override async Task <MsBuildConditionalConstructOtherwiseElement> AssignUpsertedReferences(MsBuildConditionalConstructOtherwiseElement record)
        {
            record.MsBuildConditionalContructItemGroupPropertyGroupSection = await _sections.UpsertAsync(record.MsBuildConditionalContructItemGroupPropertyGroupSection);

            record.MsBuildConditionalContructItemGroupPropertyGroupSectionId = record.MsBuildConditionalContructItemGroupPropertyGroupSection?.MsBuildConditionalContructItemGroupPropertyGroupSectionId ?? record.MsBuildConditionalContructItemGroupPropertyGroupSectionId;
            return(record);
        }
Esempio n. 18
0
        protected override async Task <AttributeArgumentListExpression> AssignUpsertedReferences(AttributeArgumentListExpression record)
        {
            record.Expression = await _strings.UpsertAsync(record.Expression);

            record.ExpressionId = record.Expression?.AsciiMaxStringReferenceId ?? record.ExpressionId;
            return(record);
        }
        protected override async Task <MsBuildPropertyGroupList> AssignUpsertedReferences(MsBuildPropertyGroupList record)
        {
            record.ListIdentifier = await _strings.UpsertAsync(record.ListIdentifier);

            record.ListIdentifierId = record.ListIdentifier?.AsciiStringReferenceId ?? record.ListIdentifierId;
            return(record);
        }
Esempio n. 20
0
        protected async Task <IActionResult> PutRecord(TRecord record)
        {
            _logger.LogInformation("Upserting (if exists update, else insert) record");
            var result = await _upsertService.UpsertAsync(record);

            return(OkOrNoContent(record));
        }
        protected override async Task <DocumentationCommentAttributeList> AssignUpsertedReferences(DocumentationCommentAttributeList record)
        {
            record.ListIdentifier = await _strings.UpsertAsync(record.ListIdentifier);

            record.ListIdentifierId = record.ListIdentifier?.AsciiStringReferenceId ?? record.ListIdentifierId;
            return(record);
        }
        protected override async Task <InterfaceDeclaration> AssignUpsertedReferences(InterfaceDeclaration record)
        {
            record.DecoratorList = await _decoratorLists.UpsertAsync(record.DecoratorList);

            record.DecoratorListId = record.DecoratorList?.DecoratorListId ?? record.DecoratorListId;
            record.ExtendsList     = await _baseLists.UpsertAsync(record.ExtendsList);

            record.ExtendsListId        = record.ExtendsList?.BaseListId ?? record.ExtendsListId;
            record.DocumentationComment = await _documentationComments.UpsertAsync(record.DocumentationComment);

            record.DocumentationCommentId = record.DocumentationComment?.DocumentationCommentId ?? record.DocumentationCommentId;
            record.Identifier             = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId        = record.Identifier?.IdentifierId ?? record.IdentifierId;
            record.ImportStatementList = await _importStatementLists.UpsertAsync(record.ImportStatementList);

            record.ImportStatementListId = record.ImportStatementList?.ImportStatementListId ?? record.ImportStatementListId;
            record.MethodList            = await _methodLists.UpsertAsync(record.MethodList);

            record.MethodListId = record.MethodList?.MethodListId ?? record.MethodListId;
            record.Namespace    = await _namespaces.UpsertAsync(record.Namespace);

            record.NamespaceId  = record.Namespace?.NamespaceId ?? record.NamespaceId;
            record.PropertyList = await _propertyLists.UpsertAsync(record.PropertyList);

            record.PropertyListId    = record.PropertyList?.PropertyListId ?? record.PropertyListId;
            record.TypeParameterList = await _typeParameterLists.UpsertAsync(record.TypeParameterList);

            record.TypeParameterListId = record.TypeParameterList?.TypeParameterListId ?? record.TypeParameterListId;
            return(record);
        }
        protected override async Task <Argument> AssignUpsertedReferences(Argument record)
        {
            record.Identifier = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId = record.Identifier?.IdentifierId ?? record.IdentifierId;
            return(record);
        }
Esempio n. 24
0
        protected override async Task <Constructor> AssignUpsertedReferences(Constructor record)
        {
            record.AttributeListCollection = await _attributeLists.UpsertAsync(record.AttributeListCollection);

            record.AttributeListCollectionId = record.AttributeListCollection?.AttributeListCollectionId ?? record.AttributeListCollectionId;
            record.Block = await _blocks.UpsertAsync(record.Block);

            record.BlockId = record.Block?.BlockId ?? record.BlockId;
            record.ConstructorBaseInitializer = await _constructorBaseInitializers.UpsertAsync(record.ConstructorBaseInitializer);

            record.ConstructorBaseInitializerId = record.ConstructorBaseInitializer?.ConstructorBaseInitializerId ?? record.ConstructorBaseInitializerId;
            record.DocumentationCommentList     = await _documentationCommentLists.UpsertAsync(record.DocumentationCommentList);

            record.DocumentationCommentListId = record.DocumentationCommentList?.DocumentationCommentListId ?? record.DocumentationCommentListId;
            record.Identifier = await _identifiers.UpsertAsync(record.Identifier);

            record.IdentifierId = record.Identifier?.IdentifierId ?? record.IdentifierId;
            record.ModifierList = await _modifierLists.UpsertAsync(record.ModifierList);

            record.ModifierListId = record.ModifierList?.ModifierListId ?? record.ModifierListId;
            record.ParameterList  = await _parameterLists.UpsertAsync(record.ParameterList);

            record.ParameterListId = record.ParameterList?.ParameterListId ?? record.ParameterListId;
            return(record);
        }
Esempio n. 25
0
        protected override async Task <MsBuildConditionalConstructWhenElementList> AssignUpsertedReferences(MsBuildConditionalConstructWhenElementList record)
        {
            record.ListIdentifier = await _strings.UpsertAsync(record.ListIdentifier);

            record.ListIdentifierId = record.ListIdentifier?.AsciiStringReferenceId ?? record.ListIdentifierId;
            return(record);
        }
Esempio n. 26
0
        protected override async Task <MsBuildCondition> AssignUpsertedReferences(MsBuildCondition record)
        {
            record.Condition = await _strings.UpsertAsync(record.Condition);

            record.ConditionId = record.Condition?.AsciiStringReferenceId ?? record.ConditionId;
            return(record);
        }
        protected override async Task <StatementList> AssignUpsertedReferences(StatementList record)
        {
            record.ListIdentifier = await _strings.UpsertAsync(record.ListIdentifier);

            record.ListIdentifierId = record.ListIdentifier?.AsciiStringReferenceId ?? record.ListIdentifierId;
            return(record);
        }
Esempio n. 28
0
        protected override async Task <AttributeListCollection> AssignUpsertedReferences(AttributeListCollection record)
        {
            record.ListIdentifier = await _strings.UpsertAsync(record.ListIdentifier);

            record.ListIdentifierId = record.ListIdentifier?.AsciiStringReferenceId ?? record.ListIdentifierId;
            return(record);
        }
        protected override async Task <Identifier> AssignUpsertedReferences(Identifier record)
        {
            record.Name = await _strings.UpsertAsync(record.Name);

            record.NameId = record.Name?.AsciiStringReferenceId ?? record.NameId;
            return(record);
        }
Esempio n. 30
0
        protected override async Task <DocumentationComment> AssignUpsertedReferences(DocumentationComment record)
        {
            record.Text = await _strings.UpsertAsync(record.Text);

            record.TextId = record.Text?.AsciiMaxStringReferenceId ?? record.TextId;
            return(record);
        }