Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit876994a

Browse files
committed
Merge pull requestsymfony#3300 from xabbuh/expression-component-cache-tweaks
some tweaks to the Expression Language cache chapter
2 parents134a7e3 +7e1e4a2 commit876994a

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

‎components/expression_language/caching.rst

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,15 @@ compiled/evaluated quicker.
1313
The Workflow
1414
------------
1515

16-
Both ``evaluate`` and ``compile`` need to do some things before each can
17-
provide the return values. For ``evaluate``, this overhead is even bigger.
16+
Both:method:`Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage::evaluate`
17+
and ``compile()`` need to do some things before each can provide the return
18+
values. For ``evaluate()``, this overhead is even bigger.
1819

19-
Both methods need to tokenize and parse the expression. This is done by the
20+
Both methods need to tokenize and parse the expression. This is done by the
2021
:method:`Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage::parse`
2122
method. It returns a:class:`Symfony\\Component\\ExpressionLanguage\\ParsedExpression`.
22-
Now, the ``compile`` method just returns the string conversion of this object.
23-
The ``evaluate`` method needs to loop through the "nodes" (pieces of an
23+
Now, the ``compile()`` method just returns the string conversion of this object.
24+
The ``evaluate()`` method needs to loop through the "nodes" (pieces of an
2425
expression saved in the ``ParsedExpression``) and evaluate them on the fly.
2526

2627
To save time, the ``ExpressionLanguage`` caches the ``ParsedExpression`` so
@@ -40,14 +41,14 @@ in the object using the constructor::
4041

4142
..note::
4243

43-
The `DoctrineBridge`_has aParserCache implementation using the
44+
The `DoctrineBridge`_provides aParser Cache implementation using the
4445
`doctrine cache library`_, which gives you caching for all sorts of cache
45-
strategies, like Apc, Filesystem andApc.
46+
strategies, like Apc, Filesystem andMemcached.
4647

4748
Using Parsed and Serialized Expressions
4849
---------------------------------------
4950

50-
Both ``evaluate`` and ``compile`` can handle ``ParsedExpression`` and
51+
Both ``evaluate()`` and ``compile()`` can handle ``ParsedExpression`` and
5152
``SerializedParsedExpression``::
5253

5354
use Symfony\Component\ExpressionLanguage\ParsedExpression;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp