.NET Backend kursi
C# tilida ASP.NET Core bilan zamonaviy backend dasturlash. Tildan boshlab Entity Framework Core, JWT autentifikatsiya, RESTful API va Docker gacha.
Boshlang'ich → O'rta · 83 ta dars · ~3 oy
Mavzular: C# tili, OOP, LINQ, Async/Await, ASP.NET Core, Entity Framework Core, JWT Auth, REST API, Test, Docker
Kirish — .NET Ekosistemi
- .NET nima? — tarix, ekosistem, C# bilan munosabati
- O'rnatish — .NET SDK, VS Code, birinchi dastur
- Loyiha tuzilmasi — .csproj, namespace, using, Program.cs
- dotnet CLI — new, build, run, add, restore
C# Asoslari
- O'zgaruvchilar va ma'lumot turlari — int, string, bool, double, var (tez kunda)
- Operatorlar — arifmetik, taqqoslash, mantiqiy, bitwise (tez kunda)
- Console I/O — WriteLine, ReadLine, Format, Interpolation (tez kunda)
- String — metodlar, interpolation, verbatim, StringBuilder (tez kunda)
- Shartli operatorlar — if/else, switch, ternary (?:) (tez kunda)
- Sikllar — for, while, do-while, foreach, break, continue (tez kunda)
- Massivlar — bir o'lchamli, ko'p o'lchamli, params (tez kunda)
- Kolleksiyalar — List<T>, Dictionary<K,V>, HashSet<T>, Queue, Stack (tez kunda)
- Metodlar — parametr, qaytish turi, overloading, optional parametrlar (tez kunda)
- Null va Nullable — ?, ??, ?. operatorlari, null-safety (tez kunda)
- Exception — try/catch/finally, throw, custom exception (tez kunda)
OOP — Obyektga Yo'naltirilgan Dasturlash
- Class va Object — yaratish, new, this kalit so'zi (tez kunda)
- Constructor — parametrli, default, this(), chaining (tez kunda)
- Properties — get/set, auto-property, computed, init (tez kunda)
- Encapsulation — public, private, protected, internal (tez kunda)
- Inheritance — : operatori, base, virtual/override, sealed (tez kunda)
- Polymorphism — method overriding, method hiding (new) (tez kunda)
- Abstract class — abstract metodlar, yaratib bo'lmaydi (tez kunda)
- Interface — I prefix, implement, bir nechta interface (tez kunda)
- Static — static class, static metod va xususiyat, singleton (tez kunda)
- Record — immutable data, with expression, record struct (tez kunda)
C# Ilg'or Tushunchalar
- Generics — <T>, constraint (where), generic metod va class (tez kunda)
- Delegates va Events — Func, Action, EventHandler, multicast (tez kunda)
- Lambda — => sintaksis, closure, qisqartirishlar (tez kunda)
- LINQ — Where, Select, OrderBy, GroupBy, Join, Aggregate (tez kunda)
- Async/Await — Task, async metod, ConfigureAwait, CancellationToken (tez kunda)
- Extension methods — this parametri, IEnumerable extension (tez kunda)
- Pattern matching — is, switch expression, when, deconstruction (tez kunda)
- Tuples — (int, string), naming, deconstruction, ValueTuple (tez kunda)
- Attributes — [Attribute], built-in, custom attribute yaratish (tez kunda)
ASP.NET Core — Kirish
- ASP.NET Core nima? — Web API, MVC, Minimal API, Kestrel (tez kunda)
- Birinchi Web API — dotnet new webapi, run, test (tez kunda)
- Program.cs — WebApplication.CreateBuilder, middleware pipeline (tez kunda)
- Dependency Injection — AddSingleton, AddScoped, AddTransient, nima farqi (tez kunda)
- Middleware — nima, pipeline, tartib, custom middleware yaratish (tez kunda)
- Configuration — appsettings.json, environment, User Secrets, IOptions (tez kunda)
Web API — Controller va Routing
- Controller — [ApiController], [Route], ControllerBase (tez kunda)
- HTTP GET va POST — [HttpGet], [HttpPost], IActionResult (tez kunda)
- HTTP PUT, PATCH, DELETE — update va o'chirish (tez kunda)
- Route parametrlari — {id}, [FromRoute], [FromQuery], [FromBody] (tez kunda)
- DTO — nima uchun, Entity dan ajratish, request/response DTO (tez kunda)
- Validation — Data Annotations, ModelState, [Required], [Range] (tez kunda)
- FluentValidation — AbstractValidator, kuchli validatsiya qoidalari (tez kunda)
- HTTP Status kodlar — 200, 201, 400, 401, 404, Ok(), BadRequest() (tez kunda)
Entity Framework Core — Ma'lumotlar Bazasi
- EF Core nima? — ORM, DbContext, DbSet, qanday ishlaydi (tez kunda)
- O'rnatish va sozlash — NuGet, DbContext, connection string, PostgreSQL (tez kunda)
- Model va Migration — Entity yaratish, Add-Migration, Update-Database (tez kunda)
- CRUD — Add, Find, Update, Remove, SaveChangesAsync (tez kunda)
- LINQ bilan so'rov — Where, FirstOrDefault, Include, AsNoTracking (tez kunda)
- One-to-Many munosabat — navigation property, foreign key, Include (tez kunda)
- Many-to-Many munosabat — join table, pivot, EF Core 5+ (tez kunda)
- One-to-One munosabat — HasOne, WithOne, FK joylashuvi (tez kunda)
- Repository Pattern — IRepository<T>, GenericRepository, abstraktsiya (tez kunda)
Autentifikatsiya va Avtorizatsiya
- Password Hashing — BCrypt.Net, hash va verify, SALT_ROUNDS (tez kunda)
- JWT nima? — Header, Payload, Signature, qanday ishlaydi (tez kunda)
- JWT o'rnatish — JwtBearer, token yaratish, sozlash (tez kunda)
- [Authorize] va [AllowAnonymous] — route himoya qilish (tez kunda)
- Refresh Token — access + refresh juftligi, rotation strategy (tez kunda)
- Role-based Authorization — [Authorize(Roles)], Claims, Policy (tez kunda)
Ilg'or ASP.NET Core
- AutoMapper — DTO ↔ Entity mapping, Profile, ProjectTo (tez kunda)
- Global Exception Handling — middleware, ProblemDetails, RFC 7807 (tez kunda)
- Logging — ILogger, Serilog, sink, structured logging (tez kunda)
- In-memory Cache — IMemoryCache, sliding/absolute expiration (tez kunda)
- Redis Cache — StackExchange.Redis, IDistributedCache (tez kunda)
- CORS — policy, AllowAnyOrigin, specific origins, credentials (tez kunda)
- Rate Limiting — .NET 7+ built-in, Fixed/Sliding window, per user (tez kunda)
API Sifati va Dizayn
- RESTful best practices — naming, status codes, idempotency (tez kunda)
- Swagger/OpenAPI — Swashbuckle, XML comments, authentication UI (tez kunda)
- API Versioning — URL, header, query string versioning (tez kunda)
- Health Checks — /health endpoint, DbContext, Redis check (tez kunda)
- Minimal API — MapGet/Post, endpoint filter, GroupRouteBuilder (tez kunda)
Test
- Unit Test — xUnit, [Fact], [Theory], Assert metodlar (tez kunda)
- Mocking — Moq, Mock<T>, Setup, Verify, In-memory DB (tez kunda)
- Integration Test — WebApplicationFactory, HttpClient, test DB (tez kunda)
- Test best practices — AAA pattern, naming, coverage, TDD kirish (tez kunda)
Deploy
- Docker — Dockerfile, .dockerignore, image yaratish, container (tez kunda)
- docker-compose — API + PostgreSQL + Redis bir yerda (tez kunda)
- Environment va Secrets — production sozlamalar, .env, secret management (tez kunda)
- Yakuniy loyiha — To-Do API: CRUD + JWT + EF Core + Docker (tez kunda)