{"id":264967,"date":"2015-09-04T16:06:02","date_gmt":"2015-09-04T12:06:02","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=264967"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=264967","title":{"rendered":"\u0421\u0430\u043c\u044b\u0439 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0438 \u0441\u0430\u043c\u044b\u0439 \u0441\u043b\u043e\u0436\u043d\u044b\u0439 Builder \u043d\u0430 Java"},"content":{"rendered":"<p>     \t<img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/763\/527\/356\/7635273567a5430da3f8bf365a0d0528.png\"\/><br \/>  \u041e\u0434\u0438\u043d \u0438\u0437 \u0447\u0430\u0441\u0442\u043e \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u043c\u044b\u0445 \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u0432 \u2014 \u043f\u0430\u0442\u0442\u0435\u0440\u043d Builder.<br \/>  \u0412 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u00ab\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e\u00bb \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430 \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u0430:  <\/p>\n<pre><code class=\"java\">MyClass my = MyClass.builder().first(1).second(2.0).third(&quot;3&quot;).build(); <\/code><\/pre>\n<p>\u041f\u0430\u0442\u0442\u0435\u0440\u043d \u043f\u0440\u043e\u0441\u0442 \u0438 \u043f\u043e\u043d\u044f\u0442\u0435\u043d \u043a\u0430\u043a \u0442\u0430\u0431\u0443\u0440\u0435\u0442, \u043d\u043e \u0447\u0443\u0432\u0441\u0442\u0432\u0443\u0435\u0442\u0441\u044f \u043a\u0430\u043a\u0430\u044f-\u0442\u043e \u043d\u0435\u0434\u043e\u0441\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0441\u0442\u044c \u2014 \u0442\u043e \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u043e\u0431\u044a\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0430\u043d\u0442\u0438\u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u043c, \u0442\u043e \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u0441\u043b\u0443\u0447\u0430\u0438 \u0438\u0433\u043d\u043e\u0440\u0438\u0440\u0443\u044e\u0442\u0441\u044f. \u0425\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0431\u044b \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u044d\u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442, \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u0432 \u043f\u0440\u0435\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u0441\u043b\u0443\u0447\u0430\u0438 \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0432 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0438 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0433\u0440\u0430\u043d\u0438\u0446\u044b \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u0430.<br \/>  \u0418\u0442\u0430\u043a, \u0440\u0430\u0441\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0438\u0445:<br \/>  <a name=\"habracut\"><\/a>  <\/p>\n<h1>\u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 builder \u0438\u043b\u0438 \u0420\u0435\u0430\u0431\u0438\u043b\u0438\u0442\u0430\u0446\u0438\u044f double brace initialization<\/h1>\n<p>  \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 builder, \u043f\u0440\u043e \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0447\u0430\u0441\u0442\u043e \u0437\u0430\u0431\u044b\u0432\u0430\u044e\u0442 \u2014 double brace initialization<br \/>  <a href=\"http:\/\/stackoverflow.com\/questions\/1958636\/what-is-double-brace-initialization-in-java\">http:\/\/stackoverflow.com\/questions\/1958636\/what-is-double-brace-initialization-in-java<\/a><br \/>  <a href=\"http:\/\/c2.com\/cgi\/wiki?DoubleBraceInitialization\">http:\/\/c2.com\/cgi\/wiki?DoubleBraceInitialization<\/a>.<br \/>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f double brace initialization \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0434\u0435\u043b\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:  <\/p>\n<pre><code class=\"java\">new MyClass() {{ first = 1; second = 2.0; third = &quot;3&quot;; }} <\/code><\/pre>\n<p>  \u0427\u0442\u043e \u043c\u044b \u0442\u0443\u0442 \u0432\u0438\u0434\u0438\u043c?  <\/p>\n<ol>\n<li>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u041d\u0430\u0440\u0443\u0448\u0435\u043d\u0438\u0435 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u0438 equals<\/b><\/p>\n<div class=\"spoiler_text\">\u0427\u0442\u043e \u0442\u0430\u043a\u043e\u0435 \u00ab\u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u044c equals\u00bb?<br \/>  \u0414\u0435\u043b\u043e \u0432 \u0442\u043e\u043c \u0447\u0442\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 equals \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a\u043e\u0439:  <\/p>\n<pre><code class=\"java\">@Override public boolean equals(Object obj) {     if(this == obj) return true;     if(!super.equals(obj)) return false;     if(getClass() != obj.getClass()) return false;     ... } <\/code><\/pre>\n<p>  \u0438 \u043f\u0440\u0438 \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0438 \u0441 \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u043d\u044b\u043c \u043a\u043b\u0430\u0441\u0441\u043e\u043c equals \u0431\u0443\u0434\u0435\u0442 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c false.<br \/>  \u041d\u043e \u043c\u044b \u0441\u043e\u0437\u0434\u0430\u0451\u043c \u0430\u043d\u043e\u043d\u0438\u043c\u043d\u044b\u0439 \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 \u0438 \u0432\u043c\u0435\u0448\u0438\u0432\u0430\u0435\u043c\u0441\u044f \u0432 \u0446\u0435\u043f\u043e\u0447\u043a\u0443 \u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f.  <\/div>\n<\/div>\n<\/li>\n<li>\u0412\u043e\u0437\u043c\u043e\u0436\u043d\u0430\u044f \u0443\u0442\u0435\u0447\u043a\u0430 \u043f\u0430\u043c\u044f\u0442\u0438, \u0442.\u043a. \u0430\u043d\u043e\u043d\u0438\u043c\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 \u0431\u0443\u0434\u0435\u0442 \u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0441\u0441\u044b\u043b\u043a\u0443 \u043d\u0430 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f.<\/li>\n<li>\u0418\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043f\u043e\u043b\u0435\u0439 \u0431\u0435\u0437 \u043f\u0440\u043e\u0432\u0435\u0440\u043e\u043a.<\/li>\n<\/ol>\n<p>  \u041a\u0440\u043e\u043c\u0435 \u0442\u043e\u0433\u043e, \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c immutable \u043e\u0431\u044a\u0435\u043a\u0442\u044b, \u0442\u0430\u043a \u043a\u0430\u043a \u043d\u0435\u043b\u044c\u0437\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c final \u043f\u043e\u043b\u0435\u0439.<\/p>\n<p>  \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u043e\u0431\u044b\u0447\u043d\u043e double brace initialization \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442 \u0434\u043b\u044f \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u043e\u0441\u0442\u0430\u0432\u043d\u044b\u0445 \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440.<br \/>  \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440:  <\/p>\n<pre><code class=\"java\">new TreeMap&lt;String, Object&gt;() {{ put(&quot;first&quot;, 1); put(second, 2.0); put(&quot;third&quot;, &quot;3&quot;); }} <\/code><\/pre>\n<p>\u0422\u0443\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u043c\u0435\u0442\u043e\u0434\u044b, \u0430 \u043d\u0435 \u043f\u0440\u044f\u043c\u043e\u0439 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043f\u043e\u043b\u044f\u043c \u0438 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u044c \u043f\u043e equals \u043e\u0431\u044b\u0447\u043d\u043e \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f.<\/p>\n<p>  \u0422\u0430\u043a \u043a\u0430\u043a \u0436\u0435 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u0430\u043a\u043e\u0439 \u043d\u0435\u043d\u0430\u0434\u0451\u0436\u043d\u044b\u0439 \u0445\u0430\u043a\u043e\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434?<\/p>\n<p>  \u0414\u0430 \u043e\u0447\u0435\u043d\u044c \u043f\u0440\u043e\u0441\u0442\u043e \u2014 \u0432\u044b\u0434\u0435\u043b\u0438\u0432 \u0434\u043b\u044f double brace initialization \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 \u0431\u0438\u043b\u0434\u0435\u0440\u0430.<\/p>\n<p>  \u041a\u043e\u0434 \u0442\u0430\u043a\u043e\u0433\u043e \u0431\u0438\u043b\u0434\u0435\u0440\u0430 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u0435\u0439 \u0441 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u043c\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u043c\u0438 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0438 \u043c\u0435\u0442\u043e\u0434\u044b \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u044f, \u043e\u0442\u0432\u0435\u0447\u0430\u044e\u0449\u0438\u0435 \u0437\u0430 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0438 \u0432\u044b\u0437\u043e\u0432 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440\u043e\u0432:  <\/p>\n<pre><code class=\"java\">public static class Builder {     public int    first  = -1        ;     public double second = Double.NaN;     public String third  = null      ;          public MyClass create() {         return new MyClass(             first ,             second,             third             );     } } <\/code><\/pre>\n<p>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435:  <\/p>\n<pre><code class=\"java\">new MyClass.Builder(){{ first = 1; third = &quot;3&quot;; }}.create() <\/code><\/pre>\n<p>  \u0427\u0442\u043e \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c?  <\/p>\n<ol>\n<li>Builder \u043d\u0435 \u0432\u043c\u0435\u0448\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0432 \u0446\u0435\u043f\u043e\u0447\u043a\u0443 \u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f \u2014 \u044d\u0442\u043e \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0441.<\/li>\n<li>Builder \u043d\u0435 \u0442\u0435\u0447\u0451\u0442 \u2014 \u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u0440\u0435\u043a\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u0441\u043b\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043e\u0431\u044a\u0435\u043a\u0442\u0430.<\/li>\n<li>Builder \u043c\u043e\u0436\u0435\u0442 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u2014 \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043e\u0431\u044a\u0435\u043a\u0442\u0430.<\/li>\n<\/ol>\n<p>  Voila! Double brace initialization \u0440\u0435\u0430\u0431\u0438\u043b\u0438\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0430.<\/p>\n<p>  \u0414\u043b\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f, Builder \u0440\u0430\u0437\u0434\u0435\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0430 \u0434\u0432\u0435 \u0447\u0430\u0441\u0442\u0438 (\u043e\u0434\u0438\u043d \u0441 \u043f\u043e\u043b\u044f\u043c\u0438, \u0434\u0440\u0443\u0433\u043e\u0439 \u2014 \u0441 \u043c\u0435\u0442\u043e\u0434\u043e\u043c \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f) \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"java\">public class MyBaseClass {      protected static class BuilderImpl {         public int    first  = -1        ;         public double second = Double.NaN;         public String third  = null      ;     }          public static class Builder extends BuilderImpl {                  public MyBaseClass create() {             return new MyBaseClass(                 first ,                 second,                 third                 );         }              }     ... } public class MyChildClass extends MyBaseClass {      protected static class BuilderImpl extends MyBaseClass.BuilderImpl {         public Object fourth = null;     }          public static class Builder extends BuilderImpl {         public MyChildClass create() {             return new MyChildClass(                 first ,                 second,                 third ,                 fourth                 );         }              }     ... } <\/code><\/pre>\n<p>  \u0415\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u044b \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b, \u043e\u043d\u0438 \u0431\u0443\u0434\u0443\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0442\u0430\u043a:  <\/p>\n<pre><code class=\"java\">public static class Builder {     public double second = Double.NaN;     public String third  = null      ;          public MyClass create(int first) {         return new MyClass(             first ,             second,             third             );     } } <\/code><\/pre>\n<p>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435:  <\/p>\n<pre><code class=\"java\">new MyClass.Builder(){{ third = &quot;3&quot;; }}.create(1) <\/code><\/pre>\n<p>  \u042d\u0442\u043e \u043d\u0430\u0441\u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u043e\u0441\u0442\u043e, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0445\u043e\u0442\u044c \u043a\u0430\u043a \u043f\u043e\u0441\u0442\u0440\u043e\u0438\u0442\u0435\u043b\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0439, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440:  <\/p>\n<pre><code class=\"java\">String fn = new fn(){{ first = 1; third = &quot;3&quot;; }}.invoke(); <\/code><\/pre>\n<p>  \u041f\u043e\u043b\u043d\u044b\u0439 \u043a\u043e\u0434 \u043d\u0430 <a href=\"https:\/\/github.com\/speaking-fish\/java-sf-builder-simple-example\">github<\/a><\/p>\n<p>  \u041f\u0435\u0440\u0435\u0439\u0434\u0451\u043c \u043a \u0441\u043b\u043e\u0436\u043d\u043e\u043c\u0443.<\/p>\n<h1>\u041c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u0441\u043b\u043e\u0436\u043d\u044b\u0439 Mega Builder<\/h1>\n<p>  \u0410 \u0447\u0442\u043e, \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043c\u043e\u0436\u043d\u043e \u0443\u0441\u043b\u043e\u0436\u043d\u0438\u0442\u044c? \u0410 \u0432\u043e\u0442 \u0447\u0442\u043e:<br \/>  \u0421\u0434\u0435\u043b\u0430\u0435\u043c Builder, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432 compile-time \u0431\u0443\u0434\u0435\u0442:  <\/p>\n<ol>\n<li>\u043d\u0435 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u043a\u043e\u043c\u0431\u0438\u043d\u0430\u0446\u0438\u0438 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432<\/li>\n<li>\u043d\u0435 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0442\u044c \u0441\u0442\u0440\u043e\u0438\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442 \u0435\u0441\u043b\u0438 \u043d\u0435 \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u044b \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432<\/li>\n<li>\u043d\u0435 \u0434\u043e\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e\u0439 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432<\/li>\n<\/ol>\n<p>  \u0427\u0442\u043e \u043d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e?<br \/>  \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430\u043c\u0438 \u0441\u043e\u0447\u0435\u0442\u0430\u043d\u0438\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432, \u0434\u043b\u044f \u0447\u0435\u0433\u043e \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u0434\u0435\u043b\u0435\u043c \u0434\u0435\u043a\u043e\u043c\u043f\u043e\u0437\u0438\u0446\u0438\u044e \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043d\u0430 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0443.<\/p>\n<p>  \u041d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0434\u043b\u044f \u043f\u0440\u0438\u0441\u0432\u043e\u0435\u043d\u0438\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 \u0438 \u0432\u043e\u0437\u0432\u0440\u0430\u0442\u0430 \u043d\u043e\u0432\u043e\u0433\u043e \u0431\u0438\u043b\u0434\u0435\u0440\u0430.<br \/>  \u041e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u043a\u0430\u043a-\u0442\u043e \u0442\u0430\u043a:  <\/p>\n<pre><code class=\"java\">public interface TransitionNAME&lt;T&gt; { T NAME(TYPE v); } <\/code><\/pre>\n<p>\u041f\u0440\u0438 \u044d\u0442\u043e\u043c NAME \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0440\u0430\u0437\u043d\u044b\u043c \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u2014 \u0432\u0435\u0434\u044c \u0438\u0445 \u043f\u043e\u0442\u043e\u043c \u043d\u0430\u0434\u043e \u0431\u0443\u0434\u0435\u0442 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u044f\u0442\u044c.<\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u0438 getter, \u0447\u0442\u043e\u0431\u044b \u043c\u044b \u043c\u043e\u0433\u043b\u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u043e\u0441\u043b\u0435 \u0442\u0430\u043a\u043e\u0433\u043e \u043f\u0440\u0438\u0441\u0432\u043e\u0435\u043d\u0438\u044f:  <\/p>\n<pre><code class=\"java\">public interface GetterNAME { TYPE NAME(); } <\/code><\/pre>\n<p>  \u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u043d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u0441\u0432\u044f\u0437\u043a\u0430 transition-getter, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c transition-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"java\">public interface TransitionNAME&lt;T extends GetterNAME&gt; { T NAME(TYPE v); } <\/code><\/pre>\n<p>\u042d\u0442\u043e \u0442\u0430\u043a\u0436\u0435 \u0434\u043e\u0431\u0430\u0432\u0438\u0442 \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u044f \u0432 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044f\u0445.<\/p>\n<p>  \u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u043e, \u043d\u0430\u0431\u043e\u0440\u044b \u043a\u0430\u043a\u0438\u0445 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432 \u043c\u044b \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u043c\u0441\u044f \u043f\u0435\u0440\u0435\u0431\u0438\u0440\u0430\u0442\u044c.<br \/>  \u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c\u0441\u044f \u0442\u0435\u043f\u0435\u0440\u044c, \u043a\u0430\u043a \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c.<\/p>\n<p>  \u0412\u043e\u0437\u044c\u043c\u0451\u043c \u0442\u0430\u043a\u043e\u0439 \u0436\u0435 \u043a\u0430\u043a \u0432 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 1-2-3 \u043a\u043b\u0430\u0441\u0441 \u0438 \u0440\u0430\u0441\u043f\u0438\u0448\u0435\u043c \u0434\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u0432\u0441\u0435 \u0441\u043e\u0447\u0435\u0442\u0430\u043d\u0438\u044f \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432. \u041f\u043e\u043b\u0443\u0447\u0438\u043c \u0437\u043d\u0430\u043a\u043e\u043c\u043e\u0435 \u0431\u0438\u043d\u0430\u0440\u043d\u043e\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0435:  <\/p>\n<pre><code class=\"java\">first second third -     -      - -     -      + -     +      - -     +      + +     -      - +     -      + +     +      - +     +      + <\/code><\/pre>\n<p>  \u0414\u043b\u044f \u0443\u0434\u043e\u0431\u0441\u0442\u0432\u0430 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u043c \u044d\u0442\u043e \u0432 \u0432\u0438\u0434\u0435 \u0434\u0435\u0440\u0435\u0432\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"java\">first second third -     -      -    \/ +     -      -    \/+ +     +      -    \/+\/+ +     +      +    \/+\/+\/+ +     -      +    \/+\/-\/+ -     +      -    \/-\/+ -     +      +    \/-\/+\/+ -     -      +    \/-\/-\/+ <\/code><\/pre>\n<p>  \u041f\u0440\u043e\u043c\u0430\u0440\u043a\u0438\u0440\u0443\u0435\u043c \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0441\u043e\u0447\u0435\u0442\u0430\u043d\u0438\u044f, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0442\u0430\u043a:  <\/p>\n<pre><code class=\"java\">first second third -     -      -    \/       * +     -      -    \/+      * +     +      -    \/+\/+    *  +     +      +    \/+\/+\/+ +     -      +    \/+\/-\/+  * -     +      -    \/-\/+ -     +      +    \/-\/+\/+  * -     -      +    \/-\/-\/+  * <\/code><\/pre>\n<p>  \u0423\u0434\u0430\u043b\u0438\u043c \u043b\u0438\u0448\u043d\u0438\u0435 \u0443\u0437\u043b\u044b \u2014 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0435 \u043d\u0435\u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0443\u0437\u043b\u044b \u0438 \u043f\u0443\u0441\u0442\u044b\u0435 \u0443\u0437\u043b\u044b.<br \/>  \u0412 \u043e\u0431\u0449\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u044d\u0442\u043e \u0446\u0438\u043a\u043b\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043f\u0440\u043e\u0446\u0435\u0441\u0441, \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u044e\u0449\u0438\u0439\u0441\u044f \u043f\u043e\u043a\u0430 \u0435\u0441\u0442\u044c \u0443\u0437\u043b\u044b \u0434\u043b\u044f \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f, \u043d\u043e \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0443 \u043d\u0430\u0441 \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u0438\u043d \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0439 \u043d\u0435\u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0439 \u0443\u0437\u0435\u043b.  <\/p>\n<pre><code class=\"java\">first second third -     -      -    \/       * +     -      -    \/+      * +     +      -    \/+\/+    *  +     -      +    \/+\/-\/+  * -     +      -    \/-\/+ -     +      +    \/-\/+\/+  * -     -      +    \/-\/-\/+  * <\/code><\/pre>\n<p>  \u041a\u0430\u043a \u0436\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u043e?<\/p>\n<p>  \u041d\u0430\u043c \u043d\u0443\u0436\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u043a\u0430\u0436\u0434\u043e\u0435 \u043f\u0440\u0438\u0441\u0432\u043e\u0435\u043d\u0438\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u043b\u043e \u043a \u0441\u043e\u043a\u0440\u0430\u0449\u0435\u043d\u0438\u044e \u043e\u0441\u0442\u0430\u0432\u0448\u0438\u0445\u0441\u044f \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f.<br \/>  \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043a\u0430\u0436\u0434\u043e\u0435 \u043f\u0440\u0438\u0441\u0432\u043e\u0435\u043d\u0438\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0447\u0435\u0440\u0435\u0437 transition-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0434\u043e\u043b\u0436\u043d\u043e \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u043d\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 builder-\u0430 \u043f\u043b\u044e\u0441 getter-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e transition \u043c\u0438\u043d\u0443\u0441 \u044d\u0442\u043e\u0442 transition-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441.<\/p>\n<p>  \u041d\u0430\u0440\u0438\u0441\u0443\u0435\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b:  <\/p>\n<pre><code class=\"java\">public interface Get_first  { int    first (); } public interface Get_second { double second(); } public interface Get_third  { String third (); }  public interface Trans_first &lt;T extends Get_first &gt; { T first (int    first ); } public interface Trans_second&lt;T extends Get_second&gt; { T second(double second); } public interface Trans_third &lt;T extends Get_third &gt; { T third (String third ); } <\/code><\/pre>\n<p>  \u0422\u0430\u0431\u043b\u0438\u0447\u043a\u0443 \u0441 \u044d\u0442\u0438\u043c \u0440\u0438\u0441\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u0443\u0434\u043e\u0431\u043d\u043e, \u0441\u043e\u043a\u0440\u0430\u0442\u0438\u043c \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u044b:  <\/p>\n<pre><code class=\"java\">public interface G_1 extends Get_first {} public interface G_2 extends Get_second{} public interface G_3 extends Get_third {}  public interface T_1&lt;T extends G_1&gt; extends Trans_first &lt;T&gt; {} public interface T_2&lt;T extends G_2&gt; extends Trans_second&lt;T&gt; {} public interface T_3&lt;T extends G_3&gt; extends Trans_third &lt;T&gt; {} <\/code><\/pre>\n<p>  \u041d\u0430\u0440\u0438\u0441\u0443\u0435\u043c \u0442\u0430\u0431\u043b\u0438\u0447\u043a\u0443 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u043e\u0432:  <\/p>\n<pre><code class=\"java\">public interface B     extends T_1&lt;B_1  &gt;, T_2&lt;B_2  &gt;, T_3&lt;B_3  &gt; {} \/\/ - - -    \/       * public interface B_1   extends             T_2&lt;B_1_2&gt;, T_3&lt;B_1_3&gt; {} \/\/ + - -    \/+      * public interface B_1_2 extends                                    {} \/\/ + + -    \/+\/+    * public interface B_1_3 extends                                    {} \/\/ + - +    \/+\/-\/+  * public interface B_2   extends T_1&lt;B_1_2&gt;,             T_3&lt;B_2_3&gt; {} \/\/          \/-\/+      public interface B_2_3 extends                                    {} \/\/ - + +    \/-\/+\/+  * public interface B_3   extends T_1&lt;B_1_3&gt;, T_2&lt;B_2_3&gt;             {} \/\/ - - +    \/-\/-\/+  * <\/code><\/pre>\n<p>  \u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c Built \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441:   <\/p>\n<pre><code class=\"java\">public interface Built { MyClass build(); } <\/code><\/pre>\n<p>  \u041f\u0440\u043e\u043c\u0430\u0440\u043a\u0438\u0440\u0443\u0435\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b, \u0433\u0434\u0435 \u0443\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u043a\u043b\u0430\u0441\u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c Built, \u0434\u043e\u0431\u0430\u0432\u0438\u043c getter-\u044b \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u043f\u043e\u043b\u0443\u0447\u0438\u0432\u0448\u0438\u0439\u0441\u044f Builder-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441:  <\/p>\n<pre><code class=\"java\">\/\/                                                  \u0442\u0440\u0430\u043d\u0437\u0438\u0442 \/\/                                                    |                           \u043c\u043e\u0436\u0435\u043c \u0441\u0442\u0440\u043e\u0438\u0442\u044c \/\/                                 \u0433\u0435\u0442\u0442\u0435\u0440\u044b            |                             | \/\/                                   |                |                             | \/\/                             -------------  ----------------------------------  ----- \/\/ \/\/                             first          first                                           first  \/\/                             |    second    |           second                              | second \/\/                             |    |    third|           |           third                   | | third \/\/                             |    |    |    |           |           |                       | | | public interface B     extends                T_1&lt;B_1  &gt;, T_2&lt;B_2  &gt;, T_3&lt;B_3  &gt;, Built {} \/\/ - - -    \/       * public interface B_1   extends G_1,                       T_2&lt;B_1_2&gt;, T_3&lt;B_1_3&gt;, Built {} \/\/ + - -    \/+      * public interface B_1_2 extends G_1, G_2,                                          Built {} \/\/ + + -    \/+\/+    *  public interface B_1_3 extends G_1,      G_3,                                     Built {} \/\/ + - +    \/+\/-\/+  * public interface B_2   extends      G_2,      T_1&lt;B_1_2&gt;,             T_3&lt;B_2_3&gt;        {} \/\/          \/-\/+      public interface B_2_3 extends      G_2, G_3,                                     Built {} \/\/ - + +    \/-\/+\/+  * public interface B_3   extends           G_3, T_1&lt;B_1_3&gt;, T_2&lt;B_2_3&gt;,             Built {} \/\/ - - +    \/-\/-\/+  *  public interface Builder extends B {} <\/code><\/pre>\n<p>  \u042d\u0442\u0438\u0445 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0439 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u043f\u043e \u043d\u0438\u043c \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0432 run-time \u0441\u043e\u043e\u0440\u0443\u0434\u0438\u0442\u044c proxy, \u043d\u0430\u0434\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0434\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u0432\u0448\u0438\u0435\u0441\u044f \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f, \u0434\u043e\u0431\u0430\u0432\u0438\u0432 \u0432 \u043d\u0438\u0445 \u043c\u0430\u0440\u043a\u0435\u0440\u043d\u044b\u0435 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u044b:  <\/p>\n<pre><code class=\"java\">public interface Built extends BuiltBase&lt;MyClass&gt; {}  public interface Get_first  extends GetBase { int    first (); } public interface Get_second extends GetBase { double second(); } public interface Get_third  extends GetBase { String third (); }  public interface Trans_first &lt;T extends Get_first &gt; extends TransBase { T first (int    first ); } public interface Trans_second&lt;T extends Get_second&gt; extends TransBase { T second(double second); } public interface Trans_third &lt;T extends Get_third &gt; extends TransBase { T third (String third ); } <\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0430\u0434\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u0437 Builder-\u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0441.<\/p>\n<p>  \u0422\u0443\u0442 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0434\u0432\u0430 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430 \u2014 \u0438\u043b\u0438 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u043e\u0434\u044b \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0431\u0438\u043b\u0434\u0435\u0440\u0430 \u0438 \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438-\u0442\u0438\u043f\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0438\u0437 \u043a\u0430\u0436\u0434\u043e\u0433\u043e builder-\u0430:  <\/p>\n<pre><code class=\"java\">public MyClass build(B     builder) { return new MyClass(-1             , Double.NaN      , null); } public MyClass build(B_1   builder) { return new MyClass(builder.first(), Double.NaN      , null); } public MyClass build(B_1_2 builder) { return new MyClass(builder.first(), builder.second(), null); } ... <\/code><\/pre>\n<p>  \u0438\u043b\u0438 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0431\u043e\u0431\u0449\u0451\u043d\u043d\u044b\u043c \u043c\u0435\u0442\u043e\u0434\u043e\u043c, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"java\">public MyClass build(BuiltValues values) {     return new MyClass(         \/\/ \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0438\u0437 values         ); } <\/code><\/pre>\n<p>  \u041d\u043e \u043a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f?<\/p>\n<p>  \u0412\u043e-\u043f\u0435\u0440\u0432\u044b\u0445 \u0443 \u043d\u0430\u0441 \u0435\u0441\u0442\u044c \u043f\u043e-\u043f\u0440\u0435\u0436\u043d\u0435\u043c\u0443 \u0435\u0441\u0442\u044c \u043d\u0430\u0431\u043e\u0440 builder-\u043a\u043b\u0430\u0441\u0441\u043e\u0432 \u0443 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0435\u0441\u0442\u044c \u043d\u0443\u0436\u043d\u044b\u0435 getter-\u044b.<br \/>  \u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043d\u0430\u0434\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u0435\u0441\u0442\u044c \u043b\u0438 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0443\u0436\u043d\u043e\u0433\u043e getter \u0438 \u0435\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u2014 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442\u044c \u0442\u0438\u043f \u043a \u043d\u0435\u043c\u0443 \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435:  <\/p>\n<pre><code class=\"java\">(values instanceof Get_first) ? ((Get_first) values).first() : -1 <\/code><\/pre>\n<p>  \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u043c\u043e\u0436\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043c\u0435\u0442\u043e\u0434 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u043d\u043e \u043e\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u043d\u0435\u0442\u0438\u043f\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c, \u0442\u0430\u043a \u043a\u0430\u043a \u043c\u044b \u043d\u0435 \u0441\u043c\u043e\u0436\u0435\u043c \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0442\u0438\u043f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0438\u0437 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0445 \u0442\u0438\u043f\u043e\u0432:  <\/p>\n<pre><code class=\"java\">Object getValue(final Class&lt; ? extends GetBase&gt; key); <\/code><\/pre>\n<p>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435:  <\/p>\n<pre><code class=\"java\">(Integer) values.getValue(Get_first.class) <\/code><\/pre>\n<p>  \u0414\u043b\u044f \u0442\u043e\u0433\u043e \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0442\u0438\u043f, \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0431\u044b \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043a\u043b\u0430\u0441\u0441\u044b \u0438 \u0441\u0432\u044f\u0437\u043a\u0438 \u043d\u0430\u043f\u043e\u0434\u043e\u0431\u0438\u0435:  <\/p>\n<pre><code class=\"java\">public interface TypedGetter&lt;T, GETTER&gt; { Class&lt;GETTER&gt; getterClass(); };  public static final Classed&lt;T&gt; GET_FIRST = new Classed&lt;Integer&gt;(Get_first.class); <\/code><\/pre>\n<p>  \u0422\u043e\u0433\u0434\u0430 \u043c\u0435\u0442\u043e\u0434 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043c\u043e\u0433 \u0431\u044b \u0431\u044b\u0442\u044c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"java\">public &lt;T, GETTER&gt; T get(TypedGetter&lt;T, GETTER&gt; typedGetter); <\/code><\/pre>\n<p>  \u041d\u043e \u043c\u044b \u043f\u043e\u043f\u044b\u0442\u0430\u0435\u043c\u0441\u044f \u043e\u0431\u043e\u0439\u0442\u0438\u0441\u044c \u0442\u0435\u043c \u0447\u0442\u043e \u0435\u0441\u0442\u044c \u2014 getter \u0438 transition \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430\u043c\u0438.<\/p>\n<p>  \u0422\u043e\u0433\u0434\u0430, \u0431\u0435\u0437 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u0438\u0439 \u0442\u0438\u043f\u043e\u0432, \u0432\u0435\u0440\u043d\u0443\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043c\u043e\u0436\u043d\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u0432\u0435\u0440\u043d\u0443\u0432 getter-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u0438\u043b\u0438 null, \u0435\u0441\u043b\u0438 \u0442\u0430\u043a\u043e\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 \u043d\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d \u0434\u043b\u044f \u0434\u0430\u043d\u043d\u043e\u0433\u043e builder:  <\/p>\n<pre><code class=\"java\">&lt;T extends GetBase&gt; T get(Class&lt;T&gt; key); <\/code><\/pre>\n<p>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435:  <\/p>\n<pre><code class=\"java\">(null == values.get(Get_second.class)) ? Double.NaN: values.get(Get_second.class).second() <\/code><\/pre>\n<p>  \u042d\u0442\u043e \u0443\u0436\u0435 \u043b\u0443\u0447\u0448\u0435. \u041d\u043e \u043c\u043e\u0436\u043d\u043e \u043b\u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u044f \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430, \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0432 \u0442\u0438\u043f?<\/p>\n<p>  \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u0442\u0438\u043f\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 getter-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441, \u043d\u043e \u0432\u0441\u0451 \u0440\u0430\u0432\u043d\u043e \u043f\u0440\u0438\u0434\u0451\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u043d\u0435\u0442\u0438\u043f\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e:  <\/p>\n<pre><code class=\"java\">&lt;T extends GetBase&gt; T get(Class&lt;T&gt; key, Object defaultValue); <\/code><\/pre>\n<p>  \u041d\u043e \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e transition-\u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c:  <\/p>\n<pre><code class=\"java\">&lt;T extends TransBase&gt; T getDefault(Class&lt; ? super T&gt; key); <\/code><\/pre>\n<p>  \u0418 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"java\">values.getDefault(Get_third.class).third(&quot;1&quot;).third() <\/code><\/pre>\n<p>  \u042d\u0442\u043e \u0432\u0441\u0451 \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0442\u0438\u043f\u043e\u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e \u0441\u043e\u043e\u0440\u0443\u0434\u0438\u0442\u044c \u0441 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c\u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430\u043c\u0438.<\/p>\n<p>  \u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043e\u0431\u043e\u0431\u0449\u0451\u043d\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0438\u043b\u043b\u044e\u0441\u0442\u0440\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u0435\u043d\u043d\u044b\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u043f\u0440\u043e\u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u0443\u0435\u043c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u0431\u0438\u043b\u0434\u0435\u0440:  <\/p>\n<pre><code class=\"java\">protected static final Builder __builder = MegaBuilder.newBuilder(     Builder.class, null,     new ClassBuilder&lt;Object, MyClass&gt;() {         @Override public MyClass build(Object context, BuiltValues values) {             return new MyClass(                 (values instanceof Get_first) ? ((Get_first) values).first() : -1,                 (null == values.get(Get_second.class)) ? Double.NaN: values.get(Get_second.class).second(),                 values.getDefault(Get_third.class).third(null).third()                 );         }     } );  public static Builder builder() { return __builder; } <\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0436\u043d\u043e \u0435\u0433\u043e \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c:  <\/p>\n<pre><code class=\"java\">builder()                              .build(); builder().first(1)                     .build(); builder().first(1).second(2)           .build(); builder().second(2  ).first (1).build(); builder().first(1)          .third(&quot;3&quot;).build(); builder().third (&quot;3&quot;).first (1).build();  builder()         .second(2).third(&quot;3&quot;).build(); builder().third (&quot;3&quot;).second(2).build(); builder()                   .third(&quot;3&quot;).build(); <\/code><\/pre>\n<p>  \u0421\u043a\u0430\u0447\u0430\u0442\u044c \u043a\u043e\u0434 \u0438 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043d\u0430 \u0440\u0430\u0431\u043e\u0442\u0443 context assist \u043c\u043e\u0436\u043d\u043e <a href=\"https:\/\/github.com\/speaking-fish\/java-sf-builder-mega\">\u043e\u0442\u0441\u044e\u0434\u0430<\/a><\/p>\n<p>  \u0412 \u0447\u0430\u0441\u0442\u043d\u043e\u0441\u0442\u0438:<br \/>  \u041a\u043e\u0434 \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u043c\u043e\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430: <a href=\"https:\/\/github.com\/speaking-fish\/java-sf-builder-mega\/blob\/master\/test\/com\/speakingfish\/common\/builder\/mega\/test\/MyClass.java\">MyClass.java<\/a><br \/>  \u041f\u0440\u0438\u043c\u0435\u0440 \u0441 generic-\u0442\u0438\u043f\u0430\u043c\u0438: <a href=\"https:\/\/github.com\/speaking-fish\/java-sf-builder-mega\/blob\/master\/test\/com\/speakingfish\/common\/builder\/mega\/test\/MyParameterizedClass.java\">MyParameterizedClass.java<\/a><br \/>  \u041f\u0440\u0438\u043c\u0435\u0440 \u043d\u0435-\u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e builder: <a href=\"https:\/\/github.com\/speaking-fish\/java-sf-builder-mega\/blob\/master\/test\/com\/speakingfish\/common\/builder\/mega\/test\/MyLocalClass.java\">MyLocalClass.java<\/a>.<\/p>\n<h1>\u0418\u0442\u043e\u0433\u043e<\/h1>\n<p>  <\/p>\n<ul>\n<li>Double brace initialization \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0445\u0430\u043a\u043e\u043c \u0438\u043b\u0438 \u0430\u043d\u0442\u0438\u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u043c, \u0435\u0441\u043b\u0438 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0431\u0438\u043b\u0434\u0435\u0440\u0430.<\/li>\n<li>\u0413\u043e\u0440\u0430\u0437\u0434\u043e \u043f\u0440\u043e\u0449\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u043c\u0438 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 + \u0442\u0438\u043f\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c\u0438 \u0434\u0435\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0440\u0430\u043c\u0438 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 (\u0441\u043c. \u0432 \u0442\u0435\u043a\u0441\u0442\u0435 \u043f\u0440\u0438\u043c\u0435\u0440 \u0441 TypedGetter) \u0447\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0431\u043e\u0440\u043a\u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432 \u0438\u043b\u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438-\u0442\u0438\u043f\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432, \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u044d\u0442\u043e \u0432\u043b\u0435\u0447\u0451\u0442 \u0437\u0430 \u0441\u043e\u0431\u043e\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u044b \u0441 reflection \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u0432\u044b\u0442\u0435\u043a\u0430\u044e\u0449\u0438\u043c\u0438.<\/li>\n<li>\u0421 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u0431\u044b \u0443\u043f\u0440\u043e\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u0434 proxy-\u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440\u0430, \u043d\u043e \u044d\u0442\u043e \u0443\u0441\u043b\u043e\u0436\u043d\u0438\u043b\u043e \u0431\u044b \u043e\u0431\u044a\u044f\u0432\u043b\u0435\u043d\u0438\u044f \u0438, \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u0443\u0445\u0443\u0434\u0448\u0438\u043b\u043e \u0431\u044b \u0432\u044b\u044f\u0432\u043b\u0435\u043d\u0438\u0435 \u043d\u0435\u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0439 \u0432 compile-time.<\/li>\n<li>\u041d\u0443 \u0438 \u043d\u0430\u043a\u043e\u043d\u0435\u0446, \u0432 \u0434\u0430\u043d\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u043c\u044b <s>\u043e\u043a\u043e\u043d\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0438 \u0431\u0435\u0441\u043f\u043e\u0432\u043e\u0440\u043e\u0442\u043d\u043e<\/s> \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043b\u0438 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0438 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0433\u0440\u0430\u043d\u0438\u0446\u0443 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u0430 Builder \u2014 \u0432\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0433\u0434\u0435-\u0442\u043e \u043c\u0435\u0436\u0434\u0443 \u043d\u0438\u043c\u0438.<\/li>\n<\/ul>\n<div class=\"clear\"><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/261163\/\"> http:\/\/habrahabr.ru\/post\/261163\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>     \t<img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/763\/527\/356\/7635273567a5430da3f8bf365a0d0528.png\"\/><br \/>  \u041e\u0434\u0438\u043d \u0438\u0437 \u0447\u0430\u0441\u0442\u043e \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u043c\u044b\u0445 \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u0432 \u2014 \u043f\u0430\u0442\u0442\u0435\u0440\u043d Builder.<br \/>  \u0412 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u00ab\u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e\u00bb \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430 \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u0430:  <\/p>\n<pre><code class=\"java\">MyClass my = MyClass.builder().first(1).second(2.0).third(&quot;3&quot;).build(); <\/code><\/pre>\n<p>\u041f\u0430\u0442\u0442\u0435\u0440\u043d \u043f\u0440\u043e\u0441\u0442 \u0438 \u043f\u043e\u043d\u044f\u0442\u0435\u043d \u043a\u0430\u043a \u0442\u0430\u0431\u0443\u0440\u0435\u0442, \u043d\u043e \u0447\u0443\u0432\u0441\u0442\u0432\u0443\u0435\u0442\u0441\u044f \u043a\u0430\u043a\u0430\u044f-\u0442\u043e \u043d\u0435\u0434\u043e\u0441\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0441\u0442\u044c \u2014 \u0442\u043e \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u043e\u0431\u044a\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0430\u043d\u0442\u0438\u043f\u0430\u0442\u0442\u0435\u0440\u043d\u043e\u043c, \u0442\u043e \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u0441\u043b\u0443\u0447\u0430\u0438 \u0438\u0433\u043d\u043e\u0440\u0438\u0440\u0443\u044e\u0442\u0441\u044f. \u0425\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0431\u044b \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u044d\u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442, \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u0432 \u043f\u0440\u0435\u0434\u0435\u043b\u044c\u043d\u044b\u0435 \u0441\u043b\u0443\u0447\u0430\u0438 \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0432 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0438 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0433\u0440\u0430\u043d\u0438\u0446\u044b \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0442\u0442\u0435\u0440\u043d\u0430.<br \/>  \u0418\u0442\u0430\u043a, \u0440\u0430\u0441\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0438\u0445:  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-264967","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/264967","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=264967"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/264967\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=264967"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=264967"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=264967"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}