Files
java-design-patterns/property/index.md
T

26 lines
579 B
Markdown
Raw Normal View History

2015-08-13 23:54:40 +02:00
---
layout: pattern
title: Property
folder: property
permalink: /patterns/property/
2015-08-20 21:40:07 +02:00
categories: Creational
2015-12-28 15:52:44 +02:00
tags:
- Java
- Difficulty-Beginner
2015-08-13 23:54:40 +02:00
---
## Intent
Create hierarchy of objects and new objects using already existing
2015-08-13 23:54:40 +02:00
objects as parents.
![alt text](./etc/property.png "Property")
## Applicability
Use the Property pattern when
2015-08-13 23:54:40 +02:00
* when you like to have objects with dynamic set of fields and prototype inheritance
## Real world examples
2015-08-13 23:54:40 +02:00
* [JavaScript](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Inheritance_and_the_prototype_chain) prototype inheritance