Expose StorageVolume.isStub() as @SystemApi API

StorageVolume.isStub() indicates whether the volume is a StubVolume,
i.e. whether it is a volume managed from outside Android (e.g. from
Chrome OS).
It needs to be exposed as a @SystemApi API because the MediaProvider
module will use it to decide whether default folders like Music, Movies,
Pictures, etc. should be automatically created inside a volume; when the
volume is a StubVolume, such automatic creation should be avoided.

Bug: 206019156
Test: m
Test: atest MtpTests
Test: atest StorageManagerTest#testGetPrimaryVolume

Change-Id: I9a9bd170408c5d92c94eac33cdab9aea394b324e
7 files changed