2 repository-uri
Transfers data between Go types by matching fields, methods, and tags at runtime without manual assignment.
Distinct from Reflection-Based Data Binding: Distinct from Reflection-Based Data Binding: focuses on data transfer between types rather than request payload binding.
Explore 2 awesome GitHub repositories matching web development · Reflection-Based Data Mappers. Refine with filters or upvote what's useful.
Copier is a Go library that deep copies data between structs, maps, and slices using reflection-based field mapping and struct tag controls. At its core, it automatically transfers values by matching source and destination fields by name, type, and methods, creating fully independent copies of nested data structures to prevent shared references and unintended mutations. The library distinguishes itself through tag-driven copy rules that give developers fine-grained control over the copying process. Struct tags can enforce mandatory field copying, exclude specific fields from transfer, or map
Transfers data between Go types by matching fields, methods, and tags at runtime.
YYModel este o bibliotecă de mapare a modelelor JSON și un mapper de date bidirecțional conceput pentru a transforma datele JSON brute în obiecte model structurate și invers. Funcționează ca un parser JSON type-safe care utilizează coerciția automată a tipurilor pentru a preveni blocarea aplicațiilor cauzată de tipuri de date incompatibile în timpul procesului de parsare. Framework-ul utilizează introspecția la runtime pentru a mapa cheile JSON la proprietățile modelului pe baza regulilor de denumire și a configurațiilor explicite. Suportă instanțierea obiectelor model imbricate prin parcurgerea recursivă a ierarhiei de date și oferă un strat de traducere consistent atât pentru serializare, cât și pentru deserializare. Suprafața sa de capabilități acoperă logica de mapare a datelor pentru legarea cheilor nepotrivite la proprietăți și un flux de lucru de serializare care standardizează obiectele de tip dată folosind formatul ISO8601. Instrumentul transformă dicționarele brute în obiecte structurate folosind o abordare bazată pe schemă pentru a asigura siguranța tipurilor pentru transmisia în rețea sau stocarea locală.
Uses runtime introspection and reflection to instantiate nested models and map data based on predefined naming rules.