PHPackages                             inphp/annotation - 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. inphp/annotation

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

inphp/annotation
================

PHP注解

0.9.0(5y ago)016MITPHPPHP ^7.2

Since Nov 25Pushed 5y ago1 watchersCompare

[ Source](https://github.com/lulanyin/inphp-annotation)[ Packagist](https://packagist.org/packages/inphp/annotation)[ RSS](/packages/inphp-annotation/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

PHP 注解实现
========

[](#php-注解实现)

此组件是基于 Doctrine 的注解实现的，仅为了更快速实现自己的PHP注解

#### 安装

[](#安装)

```
composer require inphp/annitation

```

#### 使用

[](#使用)

```
//先初始化
\Inphp\Annotation\Annotation::start();

//处理类的注解 $class 是已初始化的类， $method 可选，是本次类需要执行的方法
\Inphp\Annotation\Annotation::process($class, $method);

//请遵循 IAnnotation，实现 process 接口
```

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity38

Early-stage or recently created project

 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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2000d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e7ba8f963b6d1a5d3ab8596777a2397367b19b013111e99f640e564045240178?d=identicon)[lanyin](/maintainers/lanyin)

---

Top Contributors

[![lulanyin](https://avatars.githubusercontent.com/u/5426155?v=4)](https://github.com/lulanyin "lulanyin (1 commits)")

---

Tags

annotationphp annotation

### Embed Badge

![Health badge](/badges/inphp-annotation/health.svg)

```
[![Health](https://phpackages.com/badges/inphp-annotation/health.svg)](https://phpackages.com/packages/inphp-annotation)
```

###  Alternatives

[koriym/attributes

An annotation/attribute reader

433.4M12](/packages/koriym-attributes)[hyperf/di

A DI for Hyperf.

182.8M594](/packages/hyperf-di)[gomachan46/state-machine

simple state machine with annotations for PHP, inspired by AASM known as a Ruby state machine.

1893.9k](/packages/gomachan46-state-machine)[marcin-orlowski/lombok-php

Never write boilerplate code for your data class again!

3118.6k1](/packages/marcin-orlowski-lombok-php)[antares/accessible

PHP library that allows you to define your class' getters, setters and constructor with docblock annotations.

123.9k1](/packages/antares-accessible)

PHPackages © 2026

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