New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 775753 link

Starred by 0 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Feature



Sign in to add a comment

Classes which have a factory should have private/protected constructors

Project Member Reported by khorimoto@chromium.org, Oct 18 2017

Issue description

Currently, such classes have public constructors, which leaks visibility.
 
Owner: ----
Status: Available (was: Assigned)
Owner: jordynass@chromium.org
Status: Assigned (was: Available)
Project Member

Comment 3 by bugdroid1@chromium.org, Jan 29 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/0deb5531a31adbddf24918b8159c102bf20bd81d

commit 0deb5531a31adbddf24918b8159c102bf20bd81d
Author: Jordy Greenblatt <jordynass@chromium.org>
Date: Mon Jan 29 01:21:40 2018

[CrOS Tether] Make constructors protected (instead of public) for
classes with factories.

At the moment we have classes with factory methods that have public
constructors. Because the constructors only have to been visible to the
factory and unittests, they should be protected.

Bug:  775753 
Change-Id: I410b5c40446b8957c4f08840069b12a870d8c93f
Reviewed-on: https://chromium-review.googlesource.com/883612
Reviewed-by: Kyle Horimoto <khorimoto@chromium.org>
Commit-Queue: Kyle Horimoto <khorimoto@chromium.org>
Cr-Commit-Position: refs/heads/master@{#532299}
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/asynchronous_shutdown_object_container_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/asynchronous_shutdown_object_container_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/asynchronous_shutdown_object_container_impl_unittest.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/ble_advertiser_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/ble_advertiser_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/ble_advertiser_impl_unittest.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/ble_scanner_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/ble_scanner_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/ble_scanner_impl_unittest.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/connect_tethering_operation.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/connect_tethering_operation.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/crash_recovery_manager_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/crash_recovery_manager_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/crash_recovery_manager_impl_unittest.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/disconnect_tethering_operation.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/disconnect_tethering_operation.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/disconnect_tethering_request_sender_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/disconnect_tethering_request_sender_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/disconnect_tethering_request_sender_impl_unittest.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/error_tolerant_ble_advertisement_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/error_tolerant_ble_advertisement_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/error_tolerant_ble_advertisement_impl_unittest.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/host_scanner_operation.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/host_scanner_operation.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/keep_alive_operation.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/keep_alive_operation.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/synchronous_shutdown_object_container_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/synchronous_shutdown_object_container_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/tether_component_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/tether_component_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/tether_component_impl_unittest.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/tether_host_fetcher_impl.cc
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/tether_host_fetcher_impl.h
[modify] https://crrev.com/0deb5531a31adbddf24918b8159c102bf20bd81d/chromeos/components/tether/tether_host_fetcher_impl_unittest.cc

Status: Fixed (was: Assigned)

Sign in to add a comment