{"id":33018431,"url":"https://github.com/Wisembly/Totem","last_synced_at":"2025-11-16T14:00:37.601Z","repository":{"id":11566481,"uuid":"14053855","full_name":"Wisembly/Totem","owner":"Wisembly","description":"Changeset calculator between two states of a data","archived":false,"fork":false,"pushed_at":"2023-04-25T15:55:24.000Z","size":148,"stargazers_count":77,"open_issues_count":5,"forks_count":6,"subscribers_count":11,"default_branch":"1.x","last_synced_at":"2025-08-20T12:51:53.854Z","etag":null,"topics":["changes","changeset","php"],"latest_commit_sha":null,"homepage":"http://wisembly.github.io/Totem","language":"PHP","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/Wisembly.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":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2013-11-01T20:57:44.000Z","updated_at":"2025-02-03T01:08:39.000Z","dependencies_parsed_at":"2024-01-12T10:26:07.736Z","dependency_job_id":"72c757f1-7fa6-4c4c-8081-943a7f5992cd","html_url":"https://github.com/Wisembly/Totem","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/Wisembly/Totem","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wisembly%2FTotem","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wisembly%2FTotem/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wisembly%2FTotem/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wisembly%2FTotem/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Wisembly","download_url":"https://codeload.github.com/Wisembly/Totem/tar.gz/refs/heads/1.x","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wisembly%2FTotem/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":284719042,"owners_count":27052182,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-11-16T02:00:05.974Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["changes","changeset","php"],"created_at":"2025-11-13T18:00:39.568Z","updated_at":"2025-11-16T14:00:37.582Z","avatar_url":"https://github.com/Wisembly.png","language":"PHP","readme":"Totem\n=====\n[![License](https://poser.pugx.org/wisembly/totem/license.png)](https://packagist.org/packages/wisembly/totem)\n[![Build Status](https://travis-ci.org/Wisembly/Totem.png?branch=master)](https://travis-ci.org/Wisembly/Totem)\n[![Latest Stable Version](https://poser.pugx.org/wisembly/totem/v/stable.png)](https://packagist.org/packages/wisembly/totem)\n[![Total Downloads](https://poser.pugx.org/wisembly/totem/downloads.png)](https://packagist.org/packages/wisembly/totem)\n[![Scrutinizer Quality Score](https://scrutinizer-ci.com/g/Taluu/Totem/badges/quality-score.png?s=b71f67e353a379e19b651697285ffed18d6f1554)](https://scrutinizer-ci.com/g/Taluu/Totem/)\n[![Coverage Status](https://img.shields.io/coveralls/Wisembly/Totem.svg)](https://coveralls.io/r/Wisembly/Totem?branch=master)\n[![SensioLabsInsight](https://insight.sensiolabs.com/projects/82271056-a3c2-4e0b-adff-8219fa198035/mini.png)](https://insight.sensiolabs.com/projects/82271056-a3c2-4e0b-adff-8219fa198035)\n\n```\n       \\\\\\\\////\n        |.)(.|\n        | || |   Changeset calculator between two state of a data\n        \\(__)/   Compatibile with PHP 7.3, 7.4 or 8.0\n        |-..-|\n        |o\\/o|\n   .----\\    /----.\n  / / / |~~~~| \\ \\ \\\n / / / /|::::|\\ \\ \\ \\\n'-'-'-'-|::::|-'-'-'-'\n       (((^^)))\n        \u003e\u003e\u003e\u003c\u003c\u003c   Snapshots currently natively supported :\n        ||||||   - Array\n        (o)(o)   - Object\n        | /\\ |   - Collection\n        (====)\n       _(_,__)\n      (___\\___)\n```\n\nDocumentation\n=============\nFor any pieces of document, please look for the docs/ directory. You may also \ncheck up [the compiled version](http://totem.readthedocs.org/en/latest/index.html)\n\nInstallation\n============\nYou have multiple ways to install Totem. If you are unsure what to do, go with\n[the archive release](#archive-release).\n\n### Archive Release\n1. Download the most recent release from the [release page](https://github.com/Wisembly/Totem/releases)\n2. Unpack the archive\n3. Move the files somewhere in your project\n\n### Development version\n1. Install Git\n2. `git clone git://github.com/Wisembly/Totem.git`\n\n### Via Composer\n1. Install composer in your project: `curl -s http://getcomposer.org/installer | php`\n2. Create a `composer.json` file (or update it) in your project root:\n\n    ```javascript\n\n      {\n        \"require\": {\n          \"wisembly/totem\": \"^1.4\"\n        }\n      }\n    ```\n\n3. Install via composer : `php composer.phar install`\n\nBasic Usage\n===========\n```php\n\u003c?php\n\nuse Totem\\Snapshot\\ArraySnapshot;\n\n$array = ['foo' =\u003e 'bar', 'baz' =\u003e 'qux'];\n$snapshot = new ArraySnapshot($array); // Totem\\Snapshot\\ArraySnapshot\n\n$array['foo'] = 'fubar';\n$set = $snapshot-\u003ediff(new ArraySnapshot($array)); // Totem\\Set\n\nvar_dump($set-\u003ehasChanged('foo'),\n         $set-\u003egetChange('foo')-\u003egetOld(),\n         $set-\u003egetChange('foo')-\u003egetNew(),\n         $set-\u003ehasChanged('bar'));\n\n/* \n * expected result :\n *\n * bool(true)\n * string(3) \"bar\"\n * string(5) \"fubar\"\n * bool(false)\n */\n```\n\nRunning Tests\n=============\n1. Install phpunit if not already installed\n2. Run phpunit on the project\n\n","funding_links":[],"categories":["数据结构和存储","数据结构和存储 Data Structure and Storage","数据结构和存储( Data Structure and Storage )"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FWisembly%2FTotem","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FWisembly%2FTotem","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FWisembly%2FTotem/lists"}