{"id":35284963,"url":"https://github.com/rodriados/reflector","last_synced_at":"2026-04-02T18:26:14.088Z","repository":{"id":240886207,"uuid":"792676723","full_name":"rodriados/reflector","owner":"rodriados","description":"A simple reflection framework for C++17","archived":false,"fork":false,"pushed_at":"2026-03-29T20:48:18.000Z","size":54,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-03-29T22:26:23.160Z","etag":null,"topics":["cpp","framework","reflection"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rodriados.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":"support/pack.py","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-04-27T08:48:42.000Z","updated_at":"2026-03-29T07:03:36.000Z","dependencies_parsed_at":"2025-01-27T01:26:13.069Z","dependency_job_id":"7a6215b7-ba80-4b16-b26f-3204543658cb","html_url":"https://github.com/rodriados/reflector","commit_stats":null,"previous_names":["rodriados/reflector"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/rodriados/reflector","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rodriados%2Freflector","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rodriados%2Freflector/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rodriados%2Freflector/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rodriados%2Freflector/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rodriados","download_url":"https://codeload.github.com/rodriados/reflector/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rodriados%2Freflector/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31312859,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-02T12:59:32.332Z","status":"ssl_error","status_checked_at":"2026-04-02T12:54:48.875Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpp","framework","reflection"],"created_at":"2025-12-30T15:15:33.862Z","updated_at":"2026-04-02T18:26:14.080Z","avatar_url":"https://github.com/rodriados.png","language":"C++","readme":"# Reflector\n![license MIT](https://img.shields.io/badge/license-MIT-lightgrey.svg)\n![version 1.0](https://img.shields.io/badge/version-1.0-green.svg)\n\nA simple struct reflection framework for C++17.\n\n## Motivation\nSeveral programming languages provide tools and features for a type to be introspected\nwithin the code itself, which might be useful in many diverse ways. Unfortunately,\nC++17 provides very limited interfaces to explore or iterate over the properties\nof a struct. This library comes in handy to widen the possibilities up when introspecting\na type in compile-time.\n\nPlease, keep in mind that the \"features\" exploited by this library to automatically\nextract the types of a struct may not be well-defined and vary a lot between different\ncompilers versions. Therefore, it is prefereable to use the manually-provided reflection\ninterface.\n\n## Features\n\n- **Header-only**: Include a single header and you are ready to go.\n- **Automatic Field Registration**: No extra boilerplate code for POD structs.\n- **Template Metaprogramming**: Leverages compile-time evaluation for efficiency.\n- **Compile-time Reflection**: All field values and offsets are mapped at compile time.\n\n## Install\n**Reflector** is a single-header library. To use it:\n- Either **copy the header** by downloading `reflector.h` from the\n[latest release](https://github.com/rodriados/reflector/releases/latest) and including\nit directly in your project.\n- Or use **CMake integration** to install via CMake for project or system-wide use.\n**Reflector** depends on the [SuperTuple](https://github.com/rodriados/supertuple)\nlibrary for creating memory-aligned tuples with raw C++ structs.\n\n## Usage\n**Reflector** provides a generic reflector type, `reflector::reflection_t`, to reflect\nover any POD type. Below is an example of usage.\n\n## Example\nIf automatic reflection is possible with your configuration, it is as easy as:\n```cpp\n#include \u003creflector/api.h\u003e\n\nstruct point_t { int x, y; };\n\nconst auto point = point_t {3, 4};\nconst auto r = reflector::reflection_t(point);\nconst auto x = r.get\u003c0\u003e(); // x == 3\n```\n\n## License\n\n**Reflector** is licensed under the MIT License. See\n[LICENSE](https://github.com/rodriados/reflector/blob/main/LICENSE) for details.\n\n## Contributing\n\nContributions are welcome! Please submit issues or pull requests via the\n[GitHub repository](https://github.com/rodriados/reflector). Ensure code follows\nC++17 standards and includes appropriate tests.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frodriados%2Freflector","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frodriados%2Freflector","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frodriados%2Freflector/lists"}