Note: The study material is "first line code Android"--Guo Lin
Today, I learned about content Provider and encountered a lot of problems:
Like what
java.lang.IndexOutOfBoundsException error; The final discovery is because in the process of writing URIs is missing a "/", the process of solving the problem is from the source of content provider to find errors, and finally accurate to determine the method, because it is a cross-program sharing data, one program calls another program's API, there is no use of breakpoints, Instead of directly using the Andriod LOG.D () method to print the implemented URI in the source method, the URI is found to be content://com.example.mydatabasehelper.providerbook/24 and should be CONTENT://COM.EXAMPLE.MYDATABASEHELPER.PROVIDER/BOOK/24, there is a "/" missing between provider and book.
Android App Development Learning Documentary (7)