PHPackages                             php-cs-fixer/accessible-object - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. php-cs-fixer/accessible-object

ActiveApplication[Utility &amp; Helpers](/categories/utility)

php-cs-fixer/accessible-object
==============================

A library to reveal object internals.

v1.2.0(9mo ago)11584.0k↑154.5%15MITPHPPHP ^5.6 || ^7.0 || ^8.0CI passing

Since Aug 7Pushed 8mo ago5 watchersCompare

[ Source](https://github.com/PHP-CS-Fixer/AccessibleObject)[ Packagist](https://packagist.org/packages/php-cs-fixer/accessible-object)[ RSS](/packages/php-cs-fixer-accessible-object/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (1)Versions (4)Used By (5)

💀 Deprecation notice
====================

[](#-deprecation-notice)

Accessing internals using this package makes it difficult for your IDE/SCA tools to track types properly. If you need to access internals, consider the following alternative:

```
$bar = \Closure::bind(static fn (Foo $object): string => $object->bar, null, Foo::class)($object);
```

AccessibleObject
================

[](#accessibleobject)

`AccessibleObject` is small class allowing you to easily access internals of any object. In general, it's bad practice to do so. While we strongly discourage you to using it, it may be helpful in debugging or testing old, sad, legacy projects.

Example
=======

[](#example)

```
