Removed unused API functions in AudioProcessing and AudioProcessingModule

BUG=

Review URL: https://codereview.webrtc.org/1379123002

Cr-Commit-Position: refs/heads/master@{#10138}
diff --git a/talk/media/webrtc/fakewebrtcvoiceengine.h b/talk/media/webrtc/fakewebrtcvoiceengine.h
index 6144f2d..abe6e6d 100644
--- a/talk/media/webrtc/fakewebrtcvoiceengine.h
+++ b/talk/media/webrtc/fakewebrtcvoiceengine.h
@@ -118,16 +118,12 @@
     experimental_ns_enabled_ = config.Get<webrtc::ExperimentalNs>().enabled;
   }
 
-  WEBRTC_STUB(set_sample_rate_hz, (int rate));
-  WEBRTC_STUB_CONST(input_sample_rate_hz, ());
-  WEBRTC_STUB_CONST(sample_rate_hz, ());
   WEBRTC_STUB_CONST(proc_sample_rate_hz, ());
   WEBRTC_STUB_CONST(proc_split_sample_rate_hz, ());
   WEBRTC_STUB_CONST(num_input_channels, ());
   WEBRTC_STUB_CONST(num_output_channels, ());
   WEBRTC_STUB_CONST(num_reverse_channels, ());
   WEBRTC_VOID_STUB(set_output_will_be_muted, (bool muted));
-  WEBRTC_BOOL_STUB_CONST(output_will_be_muted, ());
   WEBRTC_STUB(ProcessStream, (webrtc::AudioFrame* frame));
   WEBRTC_STUB(ProcessStream, (
       const float* const* src,
@@ -158,7 +154,6 @@
   WEBRTC_STUB_CONST(stream_delay_ms, ());
   WEBRTC_BOOL_STUB_CONST(was_stream_delay_set, ());
   WEBRTC_VOID_STUB(set_stream_key_pressed, (bool key_pressed));
-  WEBRTC_BOOL_STUB_CONST(stream_key_pressed, ());
   WEBRTC_VOID_STUB(set_delay_offset_ms, (int offset));
   WEBRTC_STUB_CONST(delay_offset_ms, ());
   WEBRTC_STUB(StartDebugRecording, (const char filename[kMaxFilenameSize]));
diff --git a/webrtc/modules/audio_processing/audio_processing_impl.cc b/webrtc/modules/audio_processing/audio_processing_impl.cc
index 4ef4e6d..0de6bf0 100644
--- a/webrtc/modules/audio_processing/audio_processing_impl.cc
+++ b/webrtc/modules/audio_processing/audio_processing_impl.cc
@@ -281,15 +281,6 @@
   return InitializeLocked();
 }
 
-int AudioProcessingImpl::set_sample_rate_hz(int rate) {
-  CriticalSectionScoped crit_scoped(crit_);
-
-  ProcessingConfig processing_config = api_format_;
-  processing_config.input_stream().set_sample_rate_hz(rate);
-  processing_config.output_stream().set_sample_rate_hz(rate);
-  return InitializeLocked(processing_config);
-}
-
 int AudioProcessingImpl::Initialize(int input_sample_rate_hz,
                                     int output_sample_rate_hz,
                                     int reverse_sample_rate_hz,
@@ -475,15 +466,6 @@
   }
 }
 
-int AudioProcessingImpl::input_sample_rate_hz() const {
-  CriticalSectionScoped crit_scoped(crit_);
-  return api_format_.input_stream().sample_rate_hz();
-}
-
-int AudioProcessingImpl::sample_rate_hz() const {
-  CriticalSectionScoped crit_scoped(crit_);
-  return api_format_.input_stream().sample_rate_hz();
-}
 
 int AudioProcessingImpl::proc_sample_rate_hz() const {
   return fwd_proc_format_.sample_rate_hz();
@@ -513,10 +495,6 @@
   }
 }
 
-bool AudioProcessingImpl::output_will_be_muted() const {
-  CriticalSectionScoped lock(crit_);
-  return output_will_be_muted_;
-}
 
 int AudioProcessingImpl::ProcessStream(const float* const* src,
                                        size_t samples_per_channel,
@@ -911,10 +889,6 @@
   key_pressed_ = key_pressed;
 }
 
-bool AudioProcessingImpl::stream_key_pressed() const {
-  return key_pressed_;
-}
-
 void AudioProcessingImpl::set_delay_offset_ms(int offset) {
   CriticalSectionScoped crit_scoped(crit_);
   delay_offset_ms_ = offset;
diff --git a/webrtc/modules/audio_processing/audio_processing_impl.h b/webrtc/modules/audio_processing/audio_processing_impl.h
index 15c6f75..eeab34f 100644
--- a/webrtc/modules/audio_processing/audio_processing_impl.h
+++ b/webrtc/modules/audio_processing/audio_processing_impl.h
@@ -68,16 +68,12 @@
                  ChannelLayout reverse_layout) override;
   int Initialize(const ProcessingConfig& processing_config) override;
   void SetExtraOptions(const Config& config) override;
-  int set_sample_rate_hz(int rate) override;
-  int input_sample_rate_hz() const override;
-  int sample_rate_hz() const override;
   int proc_sample_rate_hz() const override;
   int proc_split_sample_rate_hz() const override;
   int num_input_channels() const override;
   int num_output_channels() const override;
   int num_reverse_channels() const override;
   void set_output_will_be_muted(bool muted) override;
-  bool output_will_be_muted() const override;
   int ProcessStream(AudioFrame* frame) override;
   int ProcessStream(const float* const* src,
                     size_t samples_per_channel,
@@ -106,7 +102,6 @@
   void set_delay_offset_ms(int offset) override;
   int delay_offset_ms() const override;
   void set_stream_key_pressed(bool key_pressed) override;
-  bool stream_key_pressed() const override;
   int StartDebugRecording(const char filename[kMaxFilenameSize]) override;
   int StartDebugRecording(FILE* handle) override;
   int StartDebugRecordingForPlatformFile(rtc::PlatformFile handle) override;
diff --git a/webrtc/modules/audio_processing/include/audio_processing.h b/webrtc/modules/audio_processing/include/audio_processing.h
index 5eb3b62..318b2f8 100644
--- a/webrtc/modules/audio_processing/include/audio_processing.h
+++ b/webrtc/modules/audio_processing/include/audio_processing.h
@@ -264,15 +264,6 @@
   // ensures the options are applied immediately.
   virtual void SetExtraOptions(const Config& config) = 0;
 
-  // DEPRECATED.
-  // TODO(ajm): Remove after Chromium has upgraded to using Initialize().
-  virtual int set_sample_rate_hz(int rate) = 0;
-  // TODO(ajm): Remove after voice engine no longer requires it to resample
-  // the reverse stream to the forward rate.
-  virtual int input_sample_rate_hz() const = 0;
-  // TODO(ajm): Remove after Chromium no longer depends on it.
-  virtual int sample_rate_hz() const = 0;
-
   // TODO(ajm): Only intended for internal use. Make private and friend the
   // necessary classes?
   virtual int proc_sample_rate_hz() const = 0;
@@ -286,7 +277,6 @@
   // but some components may change behavior based on this information.
   // Default false.
   virtual void set_output_will_be_muted(bool muted) = 0;
-  virtual bool output_will_be_muted() const = 0;
 
   // Processes a 10 ms |frame| of the primary audio stream. On the client-side,
   // this is the near-end (or captured) audio.
@@ -387,7 +377,6 @@
   // Call to signal that a key press occurred (true) or did not occur (false)
   // with this chunk of audio.
   virtual void set_stream_key_pressed(bool key_pressed) = 0;
-  virtual bool stream_key_pressed() const = 0;
 
   // Sets a delay |offset| in ms to add to the values passed in through
   // set_stream_delay_ms(). May be positive or negative.
diff --git a/webrtc/modules/audio_processing/test/audio_processing_unittest.cc b/webrtc/modules/audio_processing/test/audio_processing_unittest.cc
index d82ea31..3ebea13 100644
--- a/webrtc/modules/audio_processing/test/audio_processing_unittest.cc
+++ b/webrtc/modules/audio_processing/test/audio_processing_unittest.cc
@@ -902,7 +902,6 @@
   for (size_t i = 0; i < sizeof(fs) / sizeof(*fs); i++) {
     SetContainerFormat(fs[i], 2, frame_, &float_cb_);
     EXPECT_NOERR(ProcessStreamChooser(kIntFormat));
-    EXPECT_EQ(fs[i], apm_->input_sample_rate_hz());
   }
 }