An open API service indexing awesome lists of open source software.

https://github.com/autoframe/design-patterns

PHP design patterns used in Autoframe
https://github.com/autoframe/design-patterns

Last synced: about 1 year ago
JSON representation

PHP design patterns used in Autoframe

Awesome Lists containing this project

README

          

## Autoframe is a low level framework that is oriented on SOLID flexibility

[![Build Status](https://github.com/autoframe/design-patterns/workflows/PHPUnit-tests/badge.svg?branch=main)](https://github.com/autoframe/design-patterns/actions?query=branch:main)
[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)
![Packagist Version](https://img.shields.io/packagist/v/autoframe/design-patterns?label=packagist%20stable)
[![Downloads](https://img.shields.io/packagist/dm/autoframe/design-patterns.svg)](https://packagist.org/packages/autoframe/design-patterns)

*PHP design patterns*

### Singleton
- Namespace Autoframe\DesignPatterns\Singleton
- abstract class AfrSingletonAbstractClass
- implements AfrSingletonInterface
-
- AfrSingletonTrait provides interface implementation
- Methods:
- final public getInstance: self
- public hasInstance: bool
- final protected __construct: self
- final public __wakeup: @throws AfrException
- final public __clone: @throws AfrException

### Array Access Singleton object instance
- Namespace Autoframe\DesignPatterns\SingletonArray
- abstract class AfrSingletonArrAbstractClass
- implements AfrSingletonInterface, ArrayAccess, Iterator, Countable
- use AfrObjectArrayAccessTrait

### Array Access object instance
- Namespace Autoframe\DesignPatterns\ArrayAccess
- class AfrObjectArrayAccessClass
- implements ArrayAccess, Iterator, Countable

- AfrObjectArrayAccessTrait implements ArrayAccess, Iterator, Countable