mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-05-14 18:35:42 +02:00
unifies indentation
This commit is contained in:
parent
d779b1e86a
commit
6e937055cf
@ -28,4 +28,3 @@ class Pool
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -51,4 +51,3 @@ class Processor
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -6,4 +6,3 @@ The **object pool pattern** is a software creational design pattern that uses a
|
||||
Object pooling can offer a significant performance boost in situations where the cost of initializing a class instance is high, the rate of instantiation of a class is high, and the number of instances in use at any one time is low. The pooled object is obtained in predictable time when creation of the new objects (especially over network) may take variable time.
|
||||
|
||||
However these benefits are mostly true for objects that are expensive with respect to time, such as database connections, socket connections, threads and large graphic objects like fonts or bitmaps. In certain situations, simple object pooling (that hold no external resources, but only occupy memory) may not be efficient and could decrease performance.
|
||||
|
||||
|
@ -19,4 +19,3 @@ class Worker
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -14,4 +14,3 @@ $processor->process('image5.jpg');
|
||||
$processor->process('image6.jpg');
|
||||
$processor->process('image7.jpg');
|
||||
$processor->process('image8.jpg');
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user