Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id F04E8200BD4 for ; Thu, 1 Dec 2016 23:34:41 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id EEDB2160B0B; Thu, 1 Dec 2016 22:34:41 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 427D2160B05 for ; Thu, 1 Dec 2016 23:34:41 +0100 (CET) Received: (qmail 31502 invoked by uid 500); 1 Dec 2016 22:34:40 -0000 Mailing-List: contact commits-help@beam.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@beam.incubator.apache.org Delivered-To: mailing list commits@beam.incubator.apache.org Received: (qmail 31493 invoked by uid 99); 1 Dec 2016 22:34:40 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 01 Dec 2016 22:34:40 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id EA0DEC03A5 for ; Thu, 1 Dec 2016 22:34:39 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -6.219 X-Spam-Level: X-Spam-Status: No, score=-6.219 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id x2isE7rJVZpw for ; Thu, 1 Dec 2016 22:34:39 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with SMTP id EB66B5F64B for ; Thu, 1 Dec 2016 22:34:37 +0000 (UTC) Received: (qmail 31344 invoked by uid 99); 1 Dec 2016 22:34:36 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 01 Dec 2016 22:34:36 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 8BA4FF16BC; Thu, 1 Dec 2016 22:34:36 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: tgroh@apache.org To: commits@beam.incubator.apache.org Date: Thu, 01 Dec 2016 22:34:37 -0000 Message-Id: <9171d033825b4b2c9fc62dbc076c0399@git.apache.org> In-Reply-To: <77a3cffce3534b1b8d2b89ac108ac988@git.apache.org> References: <77a3cffce3534b1b8d2b89ac108ac988@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [2/3] incubator-beam git commit: Reduce the visibility of TransformHierarchy Node Mutators archived-at: Thu, 01 Dec 2016 22:34:42 -0000 Reduce the visibility of TransformHierarchy Node Mutators These mutators should not be accessible when visiting the nodes. Project: http://git-wip-us.apache.org/repos/asf/incubator-beam/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-beam/commit/7c5c7910 Tree: http://git-wip-us.apache.org/repos/asf/incubator-beam/tree/7c5c7910 Diff: http://git-wip-us.apache.org/repos/asf/incubator-beam/diff/7c5c7910 Branch: refs/heads/master Commit: 7c5c7910c0b8cba8623a1c49fc24c51ea691dac3 Parents: 569e8d7 Author: Thomas Groh Authored: Thu Dec 1 13:22:11 2016 -0800 Committer: Thomas Groh Committed: Thu Dec 1 14:34:21 2016 -0800 ---------------------------------------------------------------------- .../java/org/apache/beam/sdk/runners/TransformHierarchy.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/7c5c7910/sdks/java/core/src/main/java/org/apache/beam/sdk/runners/TransformHierarchy.java ---------------------------------------------------------------------- diff --git a/sdks/java/core/src/main/java/org/apache/beam/sdk/runners/TransformHierarchy.java b/sdks/java/core/src/main/java/org/apache/beam/sdk/runners/TransformHierarchy.java index 662acc1..e9829cc 100644 --- a/sdks/java/core/src/main/java/org/apache/beam/sdk/runners/TransformHierarchy.java +++ b/sdks/java/core/src/main/java/org/apache/beam/sdk/runners/TransformHierarchy.java @@ -263,7 +263,7 @@ public class TransformHierarchy { /** * Adds an output to the transform node. */ - public void setOutput(POutput output) { + private void setOutput(POutput output) { checkState(!finishedSpecifying); checkState( this.output == null, "Tried to specify more than one output for %s", getFullName()); @@ -304,13 +304,14 @@ public class TransformHierarchy { return AppliedPTransform.of( getFullName(), getInput(), getOutput(), (PTransform) getTransform()); } + /** * Visit the transform node. * *

Provides an ordered visit of the input values, the primitive transform (or child nodes for * composite transforms), then the output values. */ - public void visit(PipelineVisitor visitor, Set visitedValues) { + private void visit(PipelineVisitor visitor, Set visitedValues) { if (!finishedSpecifying) { finishSpecifying(); } @@ -352,7 +353,7 @@ public class TransformHierarchy { * *

All inputs are finished first, then the transform, then all outputs. */ - public void finishSpecifying() { + private void finishSpecifying() { if (finishedSpecifying) { return; }