title: When to call dispose and clear on CompositeDisposable
body: <p>My question can be a duplicate of <a href="https://stackoverflow.com/questions/39203791/how-to-use-compositedisposable-of-rxjava-2">How to use CompositeDisposable of RxJava 2?</a> But asking to clear one more doubt. 
  According to the accepted answer</p>
  
  <pre><code>// Using clear will clear all, but can accept new disposable
  disposables.clear(); 
  // Using dispose will clear all and set isDisposed = true, so it will not accept any new disposable
  disposables.dispose(); 
  </code></pre>
  
  <p>In my case, I'm using fragments as my views (View layer in MVP) and in some scenarios, I add active fragment to backstack, which actually does not kill the Fragment but only its view. Which means only <code>onDestroyView</code> is called and not the <code>onDestroy</code> . And later I can come back to the same fragment which is in the backstack, so only its view is being re-created.
  I have a <code>CompositeDisposable</code> as the member of my <code>BaseFragment</code> which holds subscriptions.</p>
  
  <p>My question is, should I call <code>clear</code> on <code>CompositeDisposable</code> each time on <code>onDestroyView</code>? So that it can again take subscriptions once the view is resumed?  And call <code>dispose</code> on the <code>onDestroy</code>, so that when the fragment itself is destroyed no need to take disposables anymore?</p>
  
  <p>If it is wrong what is the proper way to handle. When <code>clear</code> and <code>dispose</code> have to be called.?</p>