Apologies to reply in this old thread, but am facing the same issue while trying to modify the 'referer' for and HLS Stream using exoplayer.
The same error comes as listed below, while trying to access "http As JavaObject = r.GetField("baseDataSourceFactory")".
java.lang.NoSuchFieldException: No field baseDataSourceFactory in class Lcom/google/android/exoplayer2/source/hls/DefaultHlsDataSourceFactory; (declaration of 'com.google.android.exoplayer2.source.hls.DefaultHlsDataSourceFactory' appears in base.apk!classes2.dex)
at java.lang.Class.getDeclaredField(Native Method)
at anywheresoftware.b4a.agraham.reflection.Reflection.GetField(Reflection.java:316)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:348)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:157)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:205)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:201)
at anywheresoftware.b4a.objects.ViewWrapper$1.onClick(ViewWrapper.java:80)
at android.view.View.performClick(View.java:6597)
at android.view.View.performClickInternal(View.java:6574)
at android.view.View.access$3100(View.java:778)
at android.view.View$PerformClick.run(View.java:25885)
at android.os.Handler.handleCallback(Handler.java:873)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:6669)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
** Activity (main) Pause, UserClosed = true **
** Service (starter) Destroy (ignored)**
Code used is listed below, in the Log it has the value of Log(GetType(r.Target)) as "com.google.android.exoplayer2.source.hls.DefaultHlsDataSourceFactory"
Dim jo As JavaObject = player1.CreateHlsSource(uri)
Dim r As Reflector
r.Target = jo
r.Target = r.GetField("dataSourceFactory")
Log(GetType(r.Target))
Dim http As JavaObject = r.GetField("baseDataSourceFactory")
How to deal with this, is there any way to sort this.