Re: Consistent Placement

2017-01-27 Thread Eugene Kirpichov
Hi Jesse, +1 to Dan - I think it makes sense to return the specific type corresponding to the given transform (e.g. returning Combine.Globally from Combine.globally()), because it very often serves as a builder for adding more parameters. You mentioned users extending transform classes. I

Re: Consistent Placement

2017-01-27 Thread Dan Halperin
On Fri, Jan 27, 2017 at 8:41 AM, Jesse Anderson wrote: > @dan I thought you were talking about the transform class definition: > public static class GroupedValues > extends PTransform > >, >

Re: Consistent Placement

2017-01-27 Thread Jesse Anderson
@dan I thought you were talking about the transform class definition: public static class GroupedValues extends PTransform >, PCollection>> { On Fri, Jan 27, 2017 at 11:30 AM Dan Halperin

Re: Consistent Placement

2017-01-27 Thread Dan Halperin
Hi Jesse, can you specifically say which functions on Combine and Count you're thinking of? I believe these transforms are consistent with the "principle of least visibility" -- make nothing more public than it needs to be. Look at Combine.globally

Re: Consistent Placement

2017-01-27 Thread Jesse Anderson
One con to making transform classes be private would be that it is a breaking change. If anyone uses that class directly or extends that class, we'd be breaking that. On Fri, Jan 27, 2017 at 9:37 AM Jesse Anderson wrote: > Continuing a discussion

Consistent Placement

2017-01-27 Thread Jesse Anderson
Continuing a discussion Dan, Kenn, and I were having here since the bug is closed. They pointed out three things: - Where the private constructor gets placed in the class - Where the code samples of how to use the class get placed (in the