AyCode.Core/AyCode.Interfaces
Loretta 17daf0fef2 Document AcBinary wire format, sync docs, update conventions
- Add BINARY_FORMAT.md: full AcBinary wire format spec (markers, encoding, options, protocol, interactions)
- Reference BINARY_FORMAT.md from GLOSSARY.md, Binaries/README.md, and Serializers/Binaries/README.md; add new glossary terms
- Clarify and expand config options tables to match new doc
- Add/clarify LLM maintenance rules: always sync .md files with code, auto-fix discrepancies
- Update root README.md: AyCode.Core targets .NET 9, not 10; stress doc/code sync
- Add code reuse and doc sync conventions to copilot-instructions.md and CONVENTIONS.md
- Add docs/ folder and BINARY_FORMAT.md to solution as Solution Items
- Minor clarifications and cross-links in ARCHITECTURE.md and other docs
2026-03-29 09:11:57 +02:00
..
Addresses Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Entities Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
EntityComment Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Enums Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Groups Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Locations Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Logins Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
MediaInfo Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Messages Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Profiles Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
ServiceProviders Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
StorageHandlers Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
TimeStampInfo Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
Users Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00
AyCode.Interfaces.csproj Add .targets file 2025-08-31 13:07:34 +02:00
IAcModelDtoBase.cs SerializeObjectExtensions, IAcModelDtoBase improvements 2024-11-17 16:56:01 +01:00
ICustomForeignKey.cs improvements, fixes 2025-11-26 09:42:00 +01:00
IOwnerId.cs Implement UserModels; Add AcProfileBase; improvements, fixes, etc... 2023-12-18 23:07:53 +01:00
README.md Document AcBinary wire format, sync docs, update conventions 2026-03-29 09:11:57 +02:00

README.md

AyCode.Interfaces

Domain interface contracts for the AyCode platform. Defines the shape of entities, DTOs, relationships, and service contracts. All interfaces are composable — small, single-responsibility interfaces are combined via inheritance to build up complex types.

Folder Structure

Folder Purpose
Addresses/ Address entity, DTO, relation, and foreign key interfaces
Entities/ Base entity interfaces: IEntity, IEntityGuid, IEntityInt, soft-delete support
EntityComment/ IEntityComment — adds Comment property
Enums/ IMessageTypes — message type enum container
Groups/ IGroupBase — base group entity (Guid + timestamps)
Locations/ ILocationBase — read-only lat/lng/address
Logins/ Login service contracts: Logout, Registration, ChangePassword, ForgotPassword
MediaInfo/ Media metadata: thumbnail URL, user media ID
Messages/ Email message system: message, recipient, sender service interfaces
Profiles/ User profile: name, full name, media, address, DTOs
ServiceProviders/ Company/service provider entity and relationship interfaces
StorageHandlers/ ISecureStorageHandler — async secure key-value storage
TimeStampInfo/ Created/Modified timestamps, ITimeStampDisableAutoSet marker
Users/ User entity, base, token, email, password, company relations, DTOs

Root Interfaces

  • IOwnerId.csGuid OwnerId property.
  • IAcModelDtoBase.cs — Base DTO interface (IEntityGuid); generic version adds CreateMainEntity().
  • ICustomForeignKey.cs — Generic marker for custom foreign keys (int/Guid variants).

Design Patterns

  • Composition over inheritance — Small interfaces (ITimeStampInfo, IAcEmailAddress, IPassword) are mixed in as needed.
  • Generic relationsIAcXxxRelation<T> pattern for navigation properties and collections.
  • Separate FK interfacesIAcXxxForeignKey for type-safe foreign key declarations.
  • DTO hierarchyDtoBase interfaces separate from full entity interfaces.
  • Soft delete — Optional via IAcSoftRemoveEntity / IAcSoftRemoveEntityGuid / IAcSoftRemoveEntityInt.

Dependencies

Dependency Purpose
AyCode.Core Core library (IId<T>, IForeignKey, enums, error codes)