Hey there.
You probably noticed that all the methods our crowd methods and also the get type method used that you
are right.
Parameter.
Let's talk about this in more detail.
What exactly is your right.
Your right.
Is the unified Resource Identifier abbreviation.
Let me write it here for you.
Unified resource
identifier
like this it is written as follows
for content we write content call on double slash next
column not Android that Europe all collab Olympus
for example.
It may be like these.
No I will explain you next.
We specify the name of the table members.
This is a enter form a form of writing probably familiar to you.
You've probably seen this form ETP call on double slash.
For example Google dot com.
This is the so-called u r l let me right here you are.
I
and here
you are.
L
and this is unified
resource.
Also but not identifier.
I hear the mistake
and here lucky to that is position of the resource identifier.
You're right in Defiance both as the name and the location of a resource the subset of you are right.
Is a Euro that defines the location of what page we will use.
There you are right.
See this class your eyes specified here to determine the content that is in our database to work with
this content that is your eyes are used to additive identified data from content providers.
Your I can point to either a single roll in a table or an entire table or even several tables in a database.
We can indicate this using the you are right.
And since I already told you.
Content providers are used not only for working with databases.
This year I can also point to some files texts photos videos and any media files.
Content providers are widely used in the Android system and we can access to the database of our full
using content providers for example contacts using the following.
All right
content
call and double slash chrome dot Android dot contacts and slash contacts or the calendar specify content
call double slash
com Android calendar
events or to use a dictionary.
For example a dictionary to which words you enter one type and some text on your form are added using
the following.
You are right you can access tweet content use a dictionary
slash words as you see all these your eyes have the same structure similar they consist of three parts.
Let's see what these parts are.
And so all content.
You are right.
Begin with content.
This part is called the scheme
the next spot.
The Swan which goes between the double slash and the slash called authority
and next the last part is information about the tape type of data.
We want to get
and so the first part.
Canton calling and double flush is a scheme.
It's like a prefix that is generally accepted in the Android system for accessing your right content.
Right.
Just like we use the ATP call in double such prefix to access the web page just like this to access
the content on Android.
We use these prefix called scheme and the next part is the most important because it indicates which
provider we need.
This part is unique for each content provider.
The package name is usually used for authority.
What we did in our manifest we specify it in the name of the package authority that is to get access
to our provider which we indicated we must indicate this part here
and in and manifest.
This authority is associated with our class.
The name that is indicated in the name that is when we specify this value in content to authority.
Content your right we specify that we should use this class Olympus content provider for work on the
last part.
This is simple name of the table from which we want to extract information that is in our case the name
of the table is members.
I made a mistake so we must specify in the are I these last part and we will have access to this particular
table.
That is if we had one more table we would specify another.
Public static final class in our contract create a table for example user data which could contain age
maybe and address a number of classes and so we could create another class describing this table and
we could access members data then we would call this table and could be accessed this table using site
or your right.
So in these methods in all.
Firstly when the methods name indicate what needs to be done when specifying your right we indicate
indicate with what data we want to do this.
What to do if we want to delete not the whole table not all records but for example one or all from
this table with this form of writing we we have access to the entire members table and we can do this
through a slash specify the I.D. of these are all this line with which we want to work delete or edit
or update here we can specify some kind of I.D. for example 30 for the one we want to work with with
that is if we want to work for example with only one or one line then we write size you arrive with
an I.D. but if we want to work with all rows with the whole table then we indicate the entire table
without specifying an idea.
So let's summarize.
This is the part content column double slash here and here is as Kim.
This is a standup prefix.
Next comes the authority here and here too they are the same.
It shows which content provider will be used to access the data.
In this case that this authority is specified the content provider specified in the manifest will be
used associated authority here.
Olympus content provide our content provider.
The next part is here consisting of the name of the table and idea and here consisting of only one table
name.
This is the type of data we want to work with.
Further we will implement them and everything will be clear.