{"id":21323180,"url":"https://github.com/schwarzit/crystal-map","last_synced_at":"2026-03-12T17:30:37.225Z","repository":{"id":21797805,"uuid":"92849438","full_name":"SchwarzIT/crystal-map","owner":"SchwarzIT","description":"framework to generate map based entities classes / classes for named map interaction / parsing of complex classes to map structures","archived":false,"fork":false,"pushed_at":"2025-12-04T14:03:51.000Z","size":6975,"stargazers_count":14,"open_issues_count":2,"forks_count":2,"subscribers_count":15,"default_branch":"main","last_synced_at":"2025-12-07T22:11:49.719Z","etag":null,"topics":["couchbase-lite","entityframework","java","kotlin","mapping","wrapper-library"],"latest_commit_sha":null,"homepage":"","language":"Kotlin","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/SchwarzIT.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":".github/CODEOWNERS","security":null,"support":null,"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":"2017-05-30T15:47:23.000Z","updated_at":"2025-05-26T11:39:57.000Z","dependencies_parsed_at":"2024-01-12T13:48:22.722Z","dependency_job_id":"09a5eae1-5e2d-48a5-b07d-4fcfdb7ce22d","html_url":"https://github.com/SchwarzIT/crystal-map","commit_stats":null,"previous_names":[],"tags_count":94,"template":false,"template_full_name":null,"purl":"pkg:github/SchwarzIT/crystal-map","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SchwarzIT%2Fcrystal-map","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SchwarzIT%2Fcrystal-map/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SchwarzIT%2Fcrystal-map/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SchwarzIT%2Fcrystal-map/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SchwarzIT","download_url":"https://codeload.github.com/SchwarzIT/crystal-map/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SchwarzIT%2Fcrystal-map/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30435104,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-12T14:34:45.044Z","status":"ssl_error","status_checked_at":"2026-03-12T14:09:33.793Z","response_time":114,"last_error":"SSL_read: 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":["couchbase-lite","entityframework","java","kotlin","mapping","wrapper-library"],"created_at":"2024-11-21T20:21:16.216Z","updated_at":"2026-03-12T17:30:37.205Z","avatar_url":"https://github.com/SchwarzIT.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![](https://jitpack.io/v/SchwarzIT/andcouchbaseentity.svg)](https://jitpack.io/#SchwarzIT/andcouchbaseentity)\n[![Build Status](https://github.com/SchwarzIT/andcouchbaseentity/actions/workflows/android_pre_hook.yml/badge.svg)\n[![codecov](https://codecov.io/gh/SchwarzIT/andcouchbaseentity/branch/master/graph/badge.svg)](https://codecov.io/gh/SchwarzIT/andcouchbaseentity)\n\n![CrystalMap Logo](./crystal-map-logo-303x253.png)\n\nA Framework for all Mapheads out there\n\n## What is this Framework about?\n\n* generate pojos for easy map interactions (@MapWrapper)\n* entity framework for all databases which represents it's data in maps (@Entity)\n* serialise/deserialise objects of complex classes in maps (@Mapper)\n\n\n## Quick View\n\n### @Entity / @MapWrapper\n\n```kotlin\n@Entity(database = \"mydb_db\")\n@Fields(\n        Field(name = \"type\", type = String::class, defaultValue = \"product\", readonly = true),\n        Field(name = \"name\", type = String::class),\n        Field(name = \"comments\", type = UserComment::class, list = true),\n        Field(name = \"image\", type = Blob::class),\n        Field(name = \"identifiers\", type = String::class, list = true)\n)\n@Queries(\n        Query(fields = [\"type\"])\n)\nopen class Product\n```\n\n```kotlin\n@MapWrapper\n@Fields(\n        Field(name = \"comment\", type = String::class),\n        Field(name = \"user\", type = String::class, defaultValue = \"anonymous\"),\n        Field(\"age\", type = Integer::class, defaultValue = \"0\")\n)\nopen class UserComment\n```\n#### Result\n\n```kotlin\n        ProductEntity\n                .create()\n                .builder()\n                .setName(\"Beer\")\n                .setComments(listOf(UserCommentWrapper\n                        .create()\n                        .builder()\n                        .setComment(\"very awesome\")\n                        .exit()))\n                .setImage(Blob(\"image/jpeg\", resources.openRawResource(R.raw.ic_kaufland_placeholder)))\n                .exit()\n                .save()\n\n        val allEntitiesOfType = ProductEntity.findByType()\n        val resultOfAComplexQuery = ProductEntity.someComplexQuery(\"foo\")\n```\n\n### @Mapper\n\n```kotlin\n@Mapper\nclass MyViewModel : ViewModel() {\n\n    @Mapify\n    var innerObjectList: List\u003cMyMapifyableTest\u003e = listOf(MyMapifyableTest(simple))\n\n    @Mapify\n    var innerObjectMap: Map\u003cString, MyMapifyableTest\u003e = mapOf(\"test\" to MyMapifyableTest(simple))\n\n    @Mapify\n    var testSerializable: TestSerializable = TestSerializable(simple, 5)\n\n    @Mapify(nullableIndexes = [0])\n    var product: ProductEntity? = null\n\n    @Mapify\n    var booleanValue: Boolean = true\n\n    @Mapify(nullableIndexes = [0])\n    var bigDecimalValue: BigDecimal? = null\n}\n```\n#### Result\n\n ``` kotlin\n\n   // This is generated by the Annotation Processor\n   val mapper = MyViewModelMapper()\n   val oldObj = ViewModelProvider(this).get(MyViewModel::class.java)\n\n   // Save obj to Map\n   val mapToPersist = mapper.toMap(oldObj)\n\n   val newObj = ViewModelProvider(this).get(MyViewModel::class.java)\n   // restore obj\n   mapper.fromMap(newObj, mapToPersist)\n\n ```\n\n\n\n## Implementation\n\n### [**Setup**](https://github.com/SchwarzIT/andcouchbaseentity/wiki/%5B1%5D-Setup)\n\n### [**Entity \u0026 MapWrapper**](https://github.com/SchwarzIT/andcouchbaseentity/wiki/%5B2%5D-Entity---MapWrapper)\n\n### [**Mapper**](https://github.com/SchwarzIT/andcouchbaseentity/wiki/%5B3%5D-Mapper)\n\n### [**Cookbook (more useful features with examples)**](https://github.com/SchwarzIT/andcouchbaseentity/wiki/%5B5%5D-Cookbook)\n\n### [**Migration (from old legacy version of andcouchbasentity)**](https://github.com/SchwarzIT/crystal-map/wiki/Migration)\n  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fschwarzit%2Fcrystal-map","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fschwarzit%2Fcrystal-map","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fschwarzit%2Fcrystal-map/lists"}