Android 12 Developer Preview is here! Try it out, and give us your feedback!

WearableCalendarContract

public class WearableCalendarContract
extends Object

java.lang.Object
   ↳ androidx.wear.provider.WearableCalendarContract


The contract between the wearable calendar provider and applications. This API provides a subset of the data available through CalendarContract, but is automatically synced to wearable devices.

Summary

Nested classes

class WearableCalendarContract.Attendees

 

class WearableCalendarContract.Instances

 

class WearableCalendarContract.Reminders

 

Fields

public static final Uri CONTENT_URI

The content:// style URL for the top-level wearable calendar authority.

Public methods

static void addCalendarAuthorityUri(UriMatcher uriMatcher, String path, int code)

Adds uri to match to the given UriMatcher with calendar authority, String path and the integer code to return when this Uri is matched.

static void addCalendarDataAuthority(IntentFilter intentFilter, String port)

Adds new Intent to the given IntentFilter with calendar data authority and String host to match.

Inherited methods

Fields

CONTENT_URI

public static final Uri CONTENT_URI

The content:// style URL for the top-level wearable calendar authority.

Public methods

addCalendarAuthorityUri

public static void addCalendarAuthorityUri (UriMatcher uriMatcher, 
                String path, 
                int code)

Adds uri to match to the given UriMatcher with calendar authority, String path and the integer code to return when this Uri is matched.

Parameters
uriMatcher UriMatcher: The UriMatcher holding matches.

path String: The path to match in calendar authority. * may be used as a wild card for any text, and # may be used as a wild card for numbers.

code int: The code that is returned when a Uri is matched against the calendar authority and path. Must be positive.

addCalendarDataAuthority

public static void addCalendarDataAuthority (IntentFilter intentFilter, 
                String port)

Adds new Intent to the given IntentFilter with calendar data authority and String host to match.

Parameters
intentFilter IntentFilter: The IntentFilter holding matches.

port String: Optional port part of the authority to match. If null, any port is allowed.