{"id":37261628,"url":"https://github.com/sunchaserinfo/doctrine-pgsql-ip","last_synced_at":"2026-01-15T23:11:44.795Z","repository":{"id":36937366,"uuid":"231673474","full_name":"sunchaserinfo/doctrine-pgsql-ip","owner":"sunchaserinfo","description":"Doctrine type handlers for PostgreSQL's inet and cidr","archived":false,"fork":false,"pushed_at":"2024-04-30T07:00:25.000Z","size":17,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-12T15:52:07.336Z","etag":null,"topics":["cidr","doctrine","inet","ip-address","postgresql"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sunchaserinfo.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-01-03T22:08:28.000Z","updated_at":"2024-05-01T14:38:57.000Z","dependencies_parsed_at":"2022-08-24T21:00:14.314Z","dependency_job_id":null,"html_url":"https://github.com/sunchaserinfo/doctrine-pgsql-ip","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/sunchaserinfo/doctrine-pgsql-ip","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sunchaserinfo%2Fdoctrine-pgsql-ip","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sunchaserinfo%2Fdoctrine-pgsql-ip/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sunchaserinfo%2Fdoctrine-pgsql-ip/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sunchaserinfo%2Fdoctrine-pgsql-ip/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sunchaserinfo","download_url":"https://codeload.github.com/sunchaserinfo/doctrine-pgsql-ip/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sunchaserinfo%2Fdoctrine-pgsql-ip/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28419193,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T10:47:48.104Z","status":"ssl_error","status_checked_at":"2026-01-14T10:46:19.031Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6: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":["cidr","doctrine","inet","ip-address","postgresql"],"created_at":"2026-01-15T23:11:44.304Z","updated_at":"2026-01-15T23:11:44.787Z","avatar_url":"https://github.com/sunchaserinfo.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# IP Address types for Doctrine\n\nThis library adds support for `cidr` and `inet` types of PostgreSQL in Doctrine using the [rlanvin/php-ip] library.\n\n[rlanvin/php-ip]: https://github.com/rlanvin/php-ip\n\n## Installation\n\n    composer require sunchaser/doctrine-pgsql-ip\n\n## Usage\n\n1. Register types in Doctrine\n\n   ```php\n   \u003c?php\n   \n   use Doctrine\\DBAL\\Types\\Type;\n   use SunChaser\\Doctrine\\PgSql\\InetType;\n   use SunChaser\\Doctrine\\PgSql\\CidrType;\n\n   Type::addType(InetType::NAME, InetType::class);\n   Type::addType(CidrType::NAME, CidrType::class);\n   ```\n\n2. Add type handling for schema operations\n\n   ```php\n   \u003c?php\n\n   use Doctrine\\DBAL\\Connection;\n   use SunChaser\\Doctrine\\PgSql\\InetType;\n   use SunChaser\\Doctrine\\PgSql\\CidrType;\n   \n   /** @var Connection $conn */\n   $conn-\u003egetDatabasePlatform()-\u003eregisterDoctrineTypeMapping(InetType::PG_TYPE, InetType::NAME);\n   $conn-\u003egetDatabasePlatform()-\u003eregisterDoctrineTypeMapping(CidrType::PG_TYPE, CidrType::NAME);\n   ```\n\n`inet` accepts and retrieves both `\\PhpIP\\IP` for individual addresses\nand `\\PhpIP\\IPBlock` for network masks.\nPlease check the type when retrieving the data.\n\n`cidr` accepts and retrieves only `\\PhpIP\\IPBlock`.\n\n## Upgrade\n\nChanges in 3.0:\n\n* Requirements were bumped to PHP 8.1 and Doctrine DBAL 4.0\n\nChanges in 2.0:\n\n* `leth/ip-address` was replaced with `rlanvin/php-ip`\n* Requirements were bumped to PHP 8.0 and Doctrine DBAL 3.0\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsunchaserinfo%2Fdoctrine-pgsql-ip","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsunchaserinfo%2Fdoctrine-pgsql-ip","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsunchaserinfo%2Fdoctrine-pgsql-ip/lists"}