PHPackages                             sebastian/peek-and-poke - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. sebastian/peek-and-poke

AbandonedArchivedLibrary[Testing &amp; Quality](/categories/testing)

sebastian/peek-and-poke
=======================

Proxy for accessing non-public attributes and methods of an object

36154.4k↑315.4%8[1 issues](https://github.com/sebastianbergmann/peek-and-poke/issues)6PHP

Since Aug 6Pushed 10y ago1 watchersCompare

[ Source](https://github.com/sebastianbergmann/peek-and-poke)[ Packagist](https://packagist.org/packages/sebastian/peek-and-poke)[ RSS](/packages/sebastian-peek-and-poke/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (1)Used By (6)

[![Build Status](https://camo.githubusercontent.com/fe673b4278c973155b5a0cf6d2f1d5e5b63e879bfd0a0e3c3d8e586ea364c9ee/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f73656261737469616e626572676d616e6e2f7065656b2d616e642d706f6b652f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/sebastianbergmann/peek-and-poke)

Peek and Poke Proxy
===================

[](#peek-and-poke-proxy)

Proxy for accessing non-public attributes and methods of an object.

Installation
------------

[](#installation)

To add Peek and Poke Proxy as a local, per-project dependency to your project, simply add a dependency on `sebastian/peek-and-poke` to your project's `composer.json` file. Here is a minimal example of a `composer.json` file that just defines a dependency on Peek and Poke Proxy 1.0:

```
{
    "require": {
        "sebastian/peek-and-poke": "1.0.*"
    }
}
```

Usage
-----

[](#usage)

```
class Foo
{
    private $bar = 'baz';

    private function notPublic()
    {
        print __METHOD__ . PHP_EOL;
    }
}

$foo   = new Foo;
$proxy = new SebastianBergmann\PeekAndPoke\Proxy($foo);

print $proxy->bar . PHP_EOL;
$proxy->notPublic();
```

```
baz
Foo::notPublic

```

###  Health Score

32

—

LowBetter than 69% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity42

Moderate usage in the ecosystem

Community17

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1089?v=4)[Sebastian Probst Eide](/maintainers/sebastian)[@sebastian](https://github.com/sebastian)

---

Top Contributors

[![sebastianbergmann](https://avatars.githubusercontent.com/u/25218?v=4)](https://github.com/sebastianbergmann "sebastianbergmann (14 commits)")

### Embed Badge

![Health badge](/badges/sebastian-peek-and-poke/health.svg)

```
[![Health](https://phpackages.com/badges/sebastian-peek-and-poke/health.svg)](https://phpackages.com/packages/sebastian-peek-and-poke)
```

###  Alternatives

[dms/phpunit-arraysubset-asserts

This package provides ArraySubset and related asserts once deprecated in PHPUnit 8

14228.7M340](/packages/dms-phpunit-arraysubset-asserts)[orchestra/workbench

Workbench Companion for Laravel Packages Development

8219.1M69](/packages/orchestra-workbench)[phpbenchmark/phpbenchmark

Easy to use benchmark toolkit for your PHP-application. This library contains classes for comparing algorithms as well as benchmarking application responses

8011.5k2](/packages/phpbenchmark-phpbenchmark)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
