Conversation
- Create detailed README with installation and usage instructions - Add GitFlow workflow documentation with branching strategy - Include comprehensive API documentation and examples - Add MIT license and proper .gitignore configuration - Document commit conventions and development processes
- Replace static HashData calls with Create/ComputeHash pattern for SHA256 - Replace static HashData calls with Create/ComputeHash pattern for MD5 - Add proper using statements for disposable hash algorithm instances
- Upgrade coverlet.collector from 6.0.0 to 10.0.1 - Upgrade Microsoft.NET.Test.Sdk from 17.8.0 to 18.6.0 - Upgrade xunit from 2.5.3 to 2.9.3 - Upgrade xunit.runner.visualstudio from 2.5.3 to 3.1.5 - Add proper IncludeAssets and PrivateAssets metadata for packages
- Remove .mono/ directories containing Visual Studio telemetry data - Add .mono/ to .gitignore to prevent future tracking - Clean up repository from IDE-specific files
- Add CONTRIBUTING.md with detailed development guidelines - Add CODE_OF_CONDUCT.md for community standards - Add SECURITY.md for vulnerability reporting and policies - Add CHANGELOG.md with version history and release process - Enhance README.md with additional badges and improved structure - Add GitHub issue templates (bug report, feature request, security) - Create GitHub PR template for standardized contributions - Establish proper repository structure for open source collaboration These changes establish PowerCSharp as a professional, well-formed GitHub repository following best practices for open source projects and community collaboration.
feat: Add comprehensive repository documentation and improve development infrastructure
- Add System.Linq.Dynamic.Core for dynamic LINQ expression parsing - Add Microsoft.AspNetCore.WebUtilities for URL query string manipulation - Add Microsoft.Extensions.Configuration.Abstractions and Binder for configuration support - Add System.Text.Json for JSON processing capabilities - Configure framework-specific package versions for net8.0 and netstandard2.0 compatibility
…g support - Implement service provider interface for dynamically filtering entities using Dynamic Expressions - Support predicate-based filtering with SetFilter and GetFilter methods - Enable flexible runtime filter configuration for LINQ queries - Provide foundation for IEnumerableExtensions dynamic filtering capabilities
…support - Implement service provider interface for dynamically ordering entities using Dynamic Expressions - Support multiple ordering delegates with ascending/descending flags - Enable flexible runtime order configuration for LINQ queries - Provide foundation for IEnumerableExtensions dynamic ordering capabilities - Use List of tuples containing Func delegates and boolean descending flags
- Implement base interface for application configuration options - Define ConfigSectionPath property for configuration section identification - Support configuration binding patterns in ConfigurationExtensions - Enable strongly-typed configuration access with section path specification - Provide foundation for configuration management in PowerCSharp extensions
- Implement RemoveAll extension method for IList collections - Support predicate-based removal of multiple elements - Perform reverse iteration to avoid index shifting issues during removal - Return count of removed elements for operation feedback - Provide efficient bulk removal capability for list operations
- Implement comprehensive HTTP status code validation methods - Support success status checking (2xx range) for both HttpStatusCode and int - Add caching status detection for NotModified responses - Provide client error (4xx) and server error (5xx) categorization - Include redirect status (3xx) and general error detection methods - Enable robust HTTP response handling with status code classification
…ation utilities - Implement Mid method for substring extraction from specified index - Add FirstCharToLowerCase for proper string case transformation - Provide ToCamelCase conversion for PascalCase to camelCase formatting - Include NormalizeKey for JSON key sanitization and camelCase conversion - Support AsAscii method for non-ASCII character removal - Add IsValidUrl validation for absolute HTTP/HTTPS URL checking - Merge functionality from both Domain and Infrastructure extension sources - Ensure .NET Standard 2.0 compatibility with Substring instead of range syntax
…erations - Implement FromHierarchy method for processing hierarchical structures - Support custom continuation conditions and next item functions - Add CopyPropertiesTo method for property mapping between objects - Enable automatic property copying based on name and type compatibility - Support both generic and specific property mapping scenarios - Provide reflection-based property manipulation utilities - Include comprehensive null checking and graceful error handling
…sion - Implement ThrowOnNull method for null argument validation - Add TryGetBool method for flexible boolean conversion from various types - Support boolean parsing from strings including true/false and numeric values - Handle numeric types with zero/non-zero boolean conversion - Include Map method for object property mapping between different types - Provide reflection-based property copying with type compatibility checking - Merge functionality from both Domain and Infrastructure extension sources - Ensure robust error handling for type conversion failures
- Implement IsDefault method for default value comparison against generic types - Add GetGenericTypeName method for extracting generic type names with parameters - Support type name formatting with angle bracket notation for generic arguments - Handle both generic and non-generic type name extraction - Provide comprehensive type introspection utilities for generic types - Enable proper generic type identification and naming conventions
- Implement CloneAsync method for asynchronous stream content duplication - Support optional destination stream parameter with MemoryStream fallback - Enable stream copying with proper position reset for destination stream - Provide asynchronous operations for better performance with large streams - Include comprehensive null checking and graceful error handling - Support various stream cloning scenarios for retry and backup operations
- Implement GetExpressionDelegate method for parsing string expressions into predicates - Support dynamic LINQ expression compilation with error handling fallback - Add GetOrderDelegates method for parsing ordering expressions into delegates - Include OrderClause helper class for ordering parameter management - Support multiple ordering clauses with ascending/descending flags - Provide CreateKeySelector private method for property-based key selector creation - Enable runtime LINQ query building from string expressions - Ensure graceful error handling for invalid expression parsing
- Implement Filter method for dynamic collection filtering using IDynamicFilterProvider - Support predicate-based filtering with null-safe provider handling - Add Order method for dynamic collection ordering using IDynamicOrderProvider - Support multiple ordering delegates with ascending and descending flags - Enable runtime LINQ query configuration through provider interfaces - Provide comprehensive null checking and graceful fallback behavior - Include proper error handling for missing or invalid filter/order providers
- Implement Get method for safe property access by name in JsonElement - Support null-safe property retrieval with nullable return type - Add Get method for array element access by index in JsonElement - Include proper bounds checking for array index operations - Provide robust JSON element navigation utilities - Enable safe JSON data extraction without exception throwing - Support both object property and array element access patterns
…ccess - Implement TryGetPropertyCaseInsensitive method for property name matching - Support case-insensitive property search in JsonElement objects - Add proper null argument validation for property name parameter - Include boolean return value indicating property existence - Provide out parameter for property value when found - Enable robust JSON property access regardless of case sensitivity - Support flexible JSON data parsing with case-insensitive matching
- Implement Flatten method for transforming XElement into Dictionary representation - Support hierarchical XML structure conversion to key-value pairs - Add attribute collection with property name as key and attribute value as value - Include nested element processing with recursive flattening - Handle both element content and child elements in _value entries - Provide robust XML to dictionary conversion for data processing - Enable XML data structure manipulation and analysis capabilities
- Implement GetConcreteType method for finding implementations of interface types - Support interface type validation with null checking and interface verification - Add assembly scanning for concrete type discovery across loaded assemblies - Include filtering for non-abstract and non-interface types only - Provide graceful error handling for assembly access failures - Enable dynamic type resolution for interface-based programming patterns - Support dependency injection and factory pattern implementations - Return first available concrete implementation when multiple exist
- Implement AddParameter method for adding query parameters to URIs - Support query string parameter addition using QueryHelpers from Microsoft.AspNetCore.WebUtilities - Enable URI modification without losing existing query parameters - Provide robust URL manipulation for HTTP request building - Include proper URI builder usage for safe URI construction - Support dynamic query string assembly for web API operations
- Implement Clone method for synchronous HttpRequestMessage deep cloning - Support header copying without validation to preserve custom headers - Add content cloning with proper byte array copying and header preservation - Implement CloneAsync method for asynchronous cloning with cancellation support - Enable retry scenarios where HttpRequestMessage instances need to be recreated - Include comprehensive null checking and graceful error handling - Ensure .NET Standard 2.0 compatibility with appropriate API usage - Support both synchronous and asynchronous cloning operations
…nding - Implement GetOptions method for strongly-typed configuration binding - Support IAppOptions interface with configurable section path parameter - Add comprehensive null checking and argument validation - Include proper exception handling for configuration binding failures - Enable flexible configuration section specification - Provide robust error messages for binding operation failures - Support Microsoft.Extensions.Configuration binding patterns - Ensure .NET Standard 2.0 compatibility with appropriate exception handling
- Add GenericExtensions with hierarchical processing and property copying - Update README.md with comprehensive extension method descriptions - Add detailed usage examples for HTTP, LINQ, JSON, XML, and object extensions - Expand PowerCSharp.Extensions package description in documentation
- Add detailed method signatures and examples for Objects & Types extensions - Document GenericExtensions, ObjectExtensions, GenericTypeExtensions, and TypeExtensions - Add StreamExtensions with CloneAsync method documentation - Document enhanced StringExtensions with new utility methods - Add interface documentation for IDynamicFilterProvider, IDynamicOrderProvider, and IAppOptions - Include framework support, dependencies, thread safety, and performance considerations - Add comprehensive error handling documentation
feat: migrate and expand comprehensive extension methods for PowerCSharp.Extensions
- Remove StringExtensions.cs from PowerCSharp.Core package - Move core string methods to PowerCSharp.Extensions.Strings namespace - Consolidate IsNullOrWhiteSpace, SafeSubstring, and ToTitleCase methods - Maintain existing functionality while centralizing string utilities
- Add null check for object parameter in Serialize method
- Return empty JSON object "{}" when null is passed
- Maintain existing functionality for non-null objects
- Remove unused using statements (System.Linq, System.Net.Mail) - Add blank line for better code readability in WriteFile method - Simplify division operation in FormatFileSize method - Maintain existing functionality while improving code style
- Remove unused System.IO using statement - Add braces for single-line if statements for consistency - Use fully qualified MailAddress type instead of System.Net.Mail.MailAddress - Extract boolean expressions to variables for better readability - Maintain existing functionality while improving code style
- Remove unused using statements (System.IO, System.Linq, System.Net.Mail) - Add ToRadians method for degree to radian conversion - Add ToDegrees method for radian to degree conversion - Add IsEven method to check if number is even - Add IsOdd method to check if number is odd
- Delete UnitTest1.cs from PowerCSharp.Extensions.Tests - Delete UnitTest1.cs from PowerCSharp.Helpers.Tests - Remove boilerplate test classes marked as "To Be Implemented"
- Add DateTimeExtensionsTests.cs with 18 test cases - Test GetAge method for various scenarios (birthday today/not yet) - Test IsWeekend method for Saturday, Sunday, Monday, Friday - Test FirstDayOfMonth method for various months including edge cases - Test LastDayOfMonth method for months with 30/31 days and February leap/non-leap years - Cover all major DateTime extension functionality with comprehensive test coverage
- Add EnumerableExtensionsTests.cs with 21 test cases - Test FirstOrDefaultSafe method for valid lists, empty lists, null lists, and custom defaults - Test IsNullOrEmpty method for various scenarios including edge cases with zero and null items - Test Page method for valid parameters, edge cases, and boundary conditions - Cover all major Enumerable extension functionality with comprehensive test coverage - Include tests for both integer and string collections
- Add EnvironmentHelperTests.cs with 13 test cases - Test GetEnvironmentVariable method for existing, non-existing, and empty variables - Test IsDevelopment method for ASPNETCORE_ENVIRONMENT and DOTNET_ENVIRONMENT variables - Test GetSafeMachineName method for valid machine name format - Test GetApplicationVersion method for valid version format - Include proper environment variable setup and cleanup in tests - Cover all major EnvironmentHelper functionality with comprehensive test coverage
- Add JsonHelperTests.cs with 11 test cases - Test SafeSerialize method for valid objects and null objects - Test SafeDeserialize method for valid JSON, invalid JSON, null, and empty strings - Test PrettyPrint method for valid JSON, invalid JSON, null, and complex objects - Include TestObject helper class for serialization testing - Cover all major JsonHelper functionality with comprehensive test coverage
- Add MathHelperTests.cs with 18 test cases - Test Clamp method for values below min, above max, and in range - Test IsInRange method for boundary conditions and edge cases - Test Percentage method for normal calculation and zero total edge case - Test ToRadians and ToDegrees methods for accurate angle conversions - Test IsEven and IsOdd methods for various number scenarios - Cover all MathHelper functionality with comprehensive test coverage including new methods
- Add ValidationHelperTests.cs with 16 test cases - Test IsValidEmail method for valid emails, invalid emails, null, empty, and whitespace - Test IsNumeric method for valid numbers, non-numeric strings, null, and empty strings - Test IsValidUrl method for HTTP/HTTPS URLs, invalid URLs, FTP URLs, and null values - Cover all ValidationHelper functionality with comprehensive test coverage - Include edge cases and boundary condition testing
- Update PowerCSharp.Core package version from 1.0.0 to 0.1.0 - Update PowerCSharp.Extensions package version from 1.0.0 to 0.1.0 - Update PowerCSharp.Helpers package version from 1.0.0 to 0.1.0 - Update PowerCSharp.Utilities package version from 1.0.0 to 0.1.0
- Replace basic Hello World endpoint with detailed API information - Add /demo/string endpoint showcasing string extensions (ToTitleCase, SafeSubstring, IsNullOrWhiteSpace) - Add /demo/validation endpoint for email, numeric, and URL validation - Add /demo/json endpoint for serialization and pretty printing - Add /demo/crypto endpoint for SHA256, MD5, and random string generation - Add /demo/environment endpoint for machine name, development mode, and version info - Add /demo/math endpoint for clamp, range, percentage, and angle conversions - Add /demo/datetime endpoint for age calculation, weekend detection, and month boundaries - Add /demo/collection endpoint for pagination and safe operations - Include all PowerCSharp namespaces and demonstrate comprehensive library features
- Add PowerCSharp.Utilities project to solution with Debug and Release configurations - Add PowerCSharp.Core project to solution with Debug and Release configurations - Configure build configurations for both projects - Organize projects under appropriate solution folders
- Add comprehensive v0.1.0 changelog entry with all features and improvements - Document all packages: Core, Extensions, Utilities, and Helpers - Include testing infrastructure and cross-platform support details - Update README.md badge to reflect v0.1.0 version - Remove previous v1.0.0 changelog entry - Maintain changelog format following Keep a Changelog standards
- Add ServiceCollectionExtensions.cs with AddSwaggerServices method - Configure EndpointsApiExplorer for minimal API support - Set up SwaggerGen with v1 API documentation - Include XML comments for enhanced API documentation - Enable automatic XML comment inclusion from assembly
- Add WebApplicationExtensions.cs with UseSwaggerUI and MapPowerCSharpDemoEndpoints methods - Configure Swagger UI with custom endpoint and route prefix - Map comprehensive demo endpoints for all PowerCSharp features - Add /demo/string endpoint showcasing string extensions - Add /demo/validation endpoint for email, numeric, and URL validation - Add /demo/json endpoint for serialization and pretty printing - Add /demo/crypto endpoint for SHA256, MD5, and random string generation - Add /demo/environment endpoint for system information - Add /demo/math endpoint for mathematical operations - Add /demo/datetime endpoint for date utilities - Add /demo/collection endpoint for pagination and safe operations - Redirect root endpoint to Swagger UI for better developer experience
- Replace inline endpoint mapping with extension method calls - Use AddSwaggerServices() for cleaner service configuration - Use MapPowerCSharpDemoEndpoints() for organized endpoint registration - Use UseSwaggerUI() for middleware configuration - Reduce Program.cs from 134 lines to 16 lines - Improve code organization and maintainability - Move all demo logic to dedicated extension classes
- Add Swashbuckle.AspNetCore package version 10.1.7 for OpenAPI support - Enable XML documentation file generation for API comments - Suppress CS1591 warning for missing XML comments on public types - Configure project to generate documentation for Swagger integration - Maintain existing PowerCSharp project references
- Add using PowerCSharp.Helpers to EnvironmentHelperTests.cs - Add using PowerCSharp.Helpers and System.Text.Json to JsonHelperTests.cs - Add using Xunit to both test files - Fix missing namespace references for proper test compilation
- Update PowerCSharp.Core description to focus on foundation and base classes - Update PowerCSharp.Extensions to include strings in the feature list - Move string extensions from Core to Extensions package in changelog - Update README to reflect string extensions are now in PowerCSharp.Extensions - Remove PowerCSharp.Core from string usage examples - Update section title from "New string utilities" to "Additional string utilities"�
feat: prepare v0.1.0 release with comprehensive testing and demo infrastructure
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PowerCSharp v0.1.0 Initial Release
Features Added
Quality Assurance
Ready for Production
This release establishes PowerCSharp as a production-ready C# utility library.