mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-08-06 15:06:31 +02:00
docs: improve Chinese Translation of SimpleFactory
This commit is contained in:
@@ -4,12 +4,12 @@ msgstr ""
|
||||
"Project-Id-Version: DesignPatternsPHP 1.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2015-05-29 12:18+0200\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"PO-Revision-Date: 2022-01-07 17:41+0800\n"
|
||||
"Last-Translator: Aspirant Zhang <admin@aspirantzhang.com>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Language: zh_CN\n"
|
||||
|
||||
#: ../../Creational/SimpleFactory/README.rst:2
|
||||
msgid "Simple Factory"
|
||||
@@ -21,23 +21,18 @@ msgstr "目的"
|
||||
|
||||
#: ../../Creational/SimpleFactory/README.rst:7
|
||||
msgid "SimpleFactory is a simple factory pattern."
|
||||
msgstr "简单的创建对象型工厂模式"
|
||||
msgstr "SimpleFactory 是一个简单的工厂模式。"
|
||||
|
||||
#: ../../Creational/SimpleFactory/README.rst:9
|
||||
msgid ""
|
||||
"It differs from the static factory because it is NOT static and as you know:"
|
||||
" static => global => evil!"
|
||||
"It differs from the static factory because it is not static. Therefore, "
|
||||
"you can have multiple factories, differently parameterized, you can "
|
||||
"subclass it and you can mock it. It always should be preferred over a "
|
||||
"static factory!"
|
||||
msgstr ""
|
||||
"和静态工厂模式不同,简单工厂是非静态的,正如你了解的那样:"
|
||||
"静态 => 全局 => 恶魔"
|
||||
|
||||
#: ../../Creational/SimpleFactory/README.rst:12
|
||||
msgid ""
|
||||
"Therefore, you can have multiple factories, differently parametrized, you "
|
||||
"can subclass it and you can mock-up it."
|
||||
msgstr ""
|
||||
"因此,你可以使用该工厂的多个实例,通过传递参数使它们各不相同,"
|
||||
"你可以通过继承扩展工厂来改变工厂的行为,并用它来创建测试时会使用到的模拟对象(mock)"
|
||||
"它不同于静态工厂,因为它不是静态的。"
|
||||
"因此,您可以拥有多个工厂,可以有不同的参数,可以进行子类化,也可以模拟。"
|
||||
"它总是比静态工厂更受欢迎!"
|
||||
|
||||
#: ../../Creational/SimpleFactory/README.rst:16
|
||||
msgid "UML Diagram"
|
||||
|
Reference in New Issue
Block a user