Amr Yousef
Amr Yousef

Reputation: 594

is "content://" in the Uri of Content Provider in Android replaceable ?

In our platform, we use a certain format from paths. In the Android App, it receives those paths to load some data or do something.

I want to do all the data handling using content provider, I want to give the path and get data. A simple transaction.

When I read into content providers, the documentation and all the tutorials out there always use "content://" at the beginning. However, I want to use our own start of the path which is usually "is-://". Can something like this work?

Upvotes: 0

Views: 277

Answers (2)

iYoung
iYoung

Reputation: 3622

After referring to Developer.google site

A content URI is a URI that identifies data in a provider. Content URIs include the symbolic name of the entire provider (its authority) and a name that points to a table (a path). When you call a client method to access a table in a provider, the content URI for the table is one of the arguments.

From this I believe you can't set it on your own as it includes the symbol name.

Also why do you want to change it?

Upvotes: 0

yotam hadas
yotam hadas

Reputation: 853

no, this is how the system categorize the uri as content provider. its like relacing file:// with something else.

Upvotes: 1

Related Questions