-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* prep work to use a different interface per generator * more prep for foreign keys * pkg updates * initial work to split out the core gen model * fix break in build * fixed issue with analyzer causing codegen to fail Microsoft.CodeAnalysis.Analyzers 3.3.2 is using a v2 roslyn dll * #128 debug filename change * remove some redundant logic from old gen model * more cleanup * test coverage * stylecop and versioning * removed some async work
- Loading branch information
Showing
102 changed files
with
1,090 additions
and
371 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/Dhgms.Nucleotide.Generators/Features/Cqrs/CommandFactoryInterfaceGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/Dhgms.Nucleotide.Generators/Features/Cqrs/CommandInterfaceGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/Dhgms.Nucleotide.Generators/Features/Cqrs/QueryFactoryInterfaceGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/Dhgms.Nucleotide.Generators/Features/Cqrs/QueryInterfaceGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
src/Dhgms.Nucleotide.Generators/Features/Database/ForiegnKeyInterfaceFeatureFlags.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Text; | ||
|
||
namespace Dhgms.Nucleotide.Generators.Features.Database | ||
{ | ||
public sealed class ForiegnKeyInterfaceFeatureFlags | ||
{ | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
src/Dhgms.Nucleotide.Generators/Features/Database/ForiegnKeyInterfaceGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
using Dhgms.Nucleotide.Generators.Generators; | ||
using Dhgms.Nucleotide.Generators.Models; | ||
|
||
namespace Dhgms.Nucleotide.Generators.Features.Database | ||
{ | ||
public abstract class ForiegnKeyInterfaceGenerator : BaseGenerator<ForiegnKeyInterfaceFeatureFlags, ForiegnKeyInterfaceGeneratorProcessor, IEntityGenerationModel> | ||
{ | ||
/// <inheritdoc /> | ||
protected override string GetNamespace() | ||
{ | ||
return "Database"; | ||
} | ||
} | ||
} |
49 changes: 49 additions & 0 deletions
49
src/Dhgms.Nucleotide.Generators/Features/Database/ForiegnKeyInterfaceGeneratorProcessor.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
using System; | ||
using Dhgms.Nucleotide.Generators.GeneratorProcessors; | ||
using Dhgms.Nucleotide.Generators.Models; | ||
using Microsoft.CodeAnalysis.CSharp.Syntax; | ||
|
||
namespace Dhgms.Nucleotide.Generators.Features.Database | ||
{ | ||
public sealed class ForiegnKeyInterfaceGeneratorProcessor : BaseInterfaceLevelCodeGeneratorProcessor<IEntityGenerationModel> | ||
{ | ||
/// <inheritdoc /> | ||
protected override string[] GetClassPrefixes() | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override string GetClassSuffix() | ||
{ | ||
return "ForeignKey"; | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override string[] GetInterfaceSummary(IEntityGenerationModel entityDeclaration) | ||
{ | ||
return new[] | ||
{ | ||
$"Represents a foreign key relationship to the {entityDeclaration.ClassName} entity." | ||
}; | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override PropertyDeclarationSyntax[] GetPropertyDeclarations(IEntityGenerationModel entityGenerationModel, string prefix) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override MethodDeclarationSyntax[] GetMethodDeclarations(string className, string prefix) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override string[] GetBaseInterfaces(IEntityGenerationModel entityGenerationModel, string prefix) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
} | ||
} |
6 changes: 6 additions & 0 deletions
6
src/Dhgms.Nucleotide.Generators/Features/Database/ReferencedByEntityFeatureFlags.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
namespace Dhgms.Nucleotide.Generators.Features.Database | ||
{ | ||
public sealed class ReferencedByEntityFeatureFlags | ||
{ | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
src/Dhgms.Nucleotide.Generators/Features/Database/ReferencedByEntityGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
using Dhgms.Nucleotide.Generators.Generators; | ||
using Dhgms.Nucleotide.Generators.Models; | ||
|
||
namespace Dhgms.Nucleotide.Generators.Features.Database | ||
{ | ||
public abstract class ReferencedByEntityGenerator : BaseGenerator<ReferencedByEntityFeatureFlags, ReferencedByEntityGeneratorProcessor, IEntityGenerationModel> | ||
{ | ||
/// <inheritdoc /> | ||
protected override string GetNamespace() | ||
{ | ||
return "Database"; | ||
} | ||
} | ||
} |
49 changes: 49 additions & 0 deletions
49
src/Dhgms.Nucleotide.Generators/Features/Database/ReferencedByEntityGeneratorProcessor.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
using System; | ||
using Dhgms.Nucleotide.Generators.GeneratorProcessors; | ||
using Dhgms.Nucleotide.Generators.Models; | ||
using Microsoft.CodeAnalysis.CSharp.Syntax; | ||
|
||
namespace Dhgms.Nucleotide.Generators.Features.Database | ||
{ | ||
public sealed class ReferencedByEntityGeneratorProcessor : BaseInterfaceLevelCodeGeneratorProcessor<IEntityGenerationModel> | ||
{ | ||
/// <inheritdoc /> | ||
protected override string[] GetClassPrefixes() | ||
{ | ||
return null; | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override string GetClassSuffix() | ||
{ | ||
return "ReferencedByEntity"; | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override string[] GetInterfaceSummary(IEntityGenerationModel entityDeclaration) | ||
{ | ||
return new[] | ||
{ | ||
"Represents a entity", | ||
}; | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override PropertyDeclarationSyntax[] GetPropertyDeclarations(IEntityGenerationModel entityGenerationModel, string prefix) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override MethodDeclarationSyntax[] GetMethodDeclarations(string className, string prefix) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
|
||
/// <inheritdoc /> | ||
protected override string[] GetBaseInterfaces(IEntityGenerationModel entityGenerationModel, string prefix) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
...Dhgms.Nucleotide.Generators/Features/EntityFramework/EntityFrameworkDbContextGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/Dhgms.Nucleotide.Generators/Features/Model/KeyedModelInterfaceGenerator.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.