From 82c32f8c2507421d24ae2987652e02ed0875ab61 Mon Sep 17 00:00:00 2001 From: Yik Teng Hie Date: Tue, 7 Mar 2023 16:34:26 +0800 Subject: [PATCH] convention --- README.md | 12 +++++++++++- class-library.md | 3 +-- csharp-convention.md | 21 +++++++++++++++++++++ 3 files changed, 33 insertions(+), 3 deletions(-) create mode 100644 csharp-convention.md diff --git a/README.md b/README.md index 38adf59..2d97fb7 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,11 @@ * [Official Site](https://prismlibrary.com/) * Existing Mitech-wpf use `Prism 4.x`. The only official legacy reference is based on [Prism 6](https://prismlibrary.com/docs/wpf/legacy/Introduction.html) - * Its using `MEF Ioc (Dependency Injection)`. The `MEF DI` was removed from Prism 7.x and above. Only `Unity Dependency Injection` supported form Prism 7.x onward + * Its using `MEF Ioc (Dependency Injection)`. The `MEF DI` was removed from Prism 7.x and above. Only `Unity Dependency Injection` supported from Prism 7.x onward * **MEF** vs **Unity** Modularity [Quick Start](https://learn.microsoft.com/en-us/previous-versions/msp-n-p/ff921068(v=pandp.40)?redirectedfrom=MSDN) * The latest Prism Library is `8.1` * Prism 8 support NET 5 and dotnet Framework. Prism 6.x and below only DotNet Framework 4.8 and below. +* `Mitech-wpf` was migrated to Prism 6.3 on Feb 2023, as this is the last version to support `MEF DI` Container. ## Legacy Documentation - [Prism 4 Demo](https://www.codeproject.com/Articles/254120/Prism-4-MEF-Application). Migrated to Prism 6 [link](http://dev.mitech.com.sg:3000/playground/prism4-demo) @@ -34,6 +35,15 @@ - [Prism 5 to 6](https://github.com/PrismLibrary/Prism/wiki/Release-Notes---6.0.0) - Breaking Changes - Removed `Microsoft.Practices` from all namespaces + - Add Nuget `Prism.Mef 6.3` + ```bash + # .NET cli + > dotnet add package Prism.Mef --version 6.3.0 + + # Package Manager + PM> NuGet\Install-Package Prism.Mef -Version 6.3.0 + ``` + - Created new xmlns namespace `http://prismlibrary.com/` - Namespace changes ```cs diff --git a/class-library.md b/class-library.md index d2e9eb8..2045ad5 100644 --- a/class-library.md +++ b/class-library.md @@ -1,8 +1,7 @@ # Create New Class Library Guides ## Basic Dependencies -- Microsoft.Practices.Prism -- Microsoft.Practices.Prism.MefExtensions +- Prism.Mef 6.3 - Framework Assemblies - PresentationCore - PresentationFramework diff --git a/csharp-convention.md b/csharp-convention.md new file mode 100644 index 0000000..e449621 --- /dev/null +++ b/csharp-convention.md @@ -0,0 +1,21 @@ +# C-Charp Convention + +* [C# Framework version](https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/configure-language-version) +* [What's new](https://learn.microsoft.com/en-us/dotnet/csharp/whats-new) + +## Naming Convention +* [Microsoft](https://learn.microsoft.com/en-us/dotnet/csharp/fundamentals/coding-style/coding-conventions) + +| Object Name | Notation | Length | Plural | Prefix | Suffix | Abbreviation | Char Mask | Underscores | +|:--------------------------|:-----------|-------:|:-------|:-------|:-------|:-------------|:-------------------|:------------| +| Namespace name | PascalCase | 128 | Yes | Yes | No | No | [A-z][0-9] | No | +| Class name | PascalCase | 128 | No | No | Yes | No | [A-z][0-9] | No | +| Constructor name | PascalCase | 128 | No | No | Yes | No | [A-z][0-9] | No | +| Method name | PascalCase | 128 | Yes | No | No | No | [A-z][0-9] | No | +| Method arguments | camelCase | 128 | Yes | No | No | Yes | [A-z][0-9] | No | +| Local variables | camelCase | 50 | Yes | No | No | Yes | [A-z][0-9] | No | +| Constants name | PascalCase | 50 | No | No | No | No | [A-z][0-9] | No | +| Field name | camelCase | 50 | Yes | No | No | Yes | [A-z][0-9] | Yes | +| Properties name | PascalCase | 50 | Yes | No | No | Yes | [A-z][0-9] | No | +| Delegate name | PascalCase | 128 | No | No | Yes | Yes | [A-z] | No | +| Enum type name | PascalCase | 128 | Yes | No | No | No | [A-z] | No | \ No newline at end of file