Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4362: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4364: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4365: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4366: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
anddev.org • View topic - URI_MATCHER doesn't work correctly

URI_MATCHER doesn't work correctly

Put your problem here if it does not fit any of the other categories.

URI_MATCHER doesn't work correctly

Postby rocke » Wed Aug 20, 2008 11:44 pm

Hi Guys,

I've written my own ContentProvider, which works, except for the URI_MATCHER.
URI_MATCHER returns -1, when it should give me 1:

First, I add my URI, so that the matcher is able to recognize it:
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1. URI_MATCHER.addURI(Crowd.CROWD_AUTHORITY, "/Crowd", CUSTOMER);
Parsed in 0.012 seconds, using GeSHi 1.0.8.4


At this point:
is Crowd.CROWD_AUTHORITY = "lan.tiptop.android.CrowdProvider"
and CUSTOMER = 1


At some points in the code it's necessary to check the uri:
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1. if (URI_MATCHER.match(uri) != CUSTOMER) {
  2.             throw new IllegalArgumentException("Unknown URI: " + uri);
  3. }
  4.  
Parsed in 0.010 seconds, using GeSHi 1.0.8.4


The if-statement throws that exception:

"Unkown URI: content://lan.tiptop.android.CrowdProvider/Crowd"


I think the URI ist correct and URI_MATCHER should give me 1. :?:

Does anybody know, how to solve this?

P.S.: I use version 0.9 of the SDK.
rocke
Freshman
Freshman
 
Posts: 6
Joined: Mon Jul 21, 2008 12:24 am

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: Exabot [Bot], Google [Bot], MSNbot Media and 9 guests