Skip to content

Commit

Permalink
Revert "Merge branch 'master' of https://cpubwin.visualstudio.com/win…
Browse files Browse the repository at this point in the history
…dows-uwp/_git/winrt-api"

This reverts commit 77705d0, reversing
changes made to 3ca07de.
  • Loading branch information
muhsinking committed May 3, 2017
1 parent 7dc0ccf commit d120d6a
Show file tree
Hide file tree
Showing 4,947 changed files with 3,495 additions and 8,145 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,13 @@ public Windows.Foundation.IAsyncOperation<Windows.Foundation.Collections.IVector
# Windows.ApplicationModel.AppExtensions.AppExtensionCatalog.FindAllAsync

## -description
Provides the list of extensions in the catalog.
Provides a list of extensions available within an extension package.
<!--What's the scope - need to understand open() better-->

## -returns
The list of extensions in the catalog. Note that this method returns a list of [AppExtensions](appextension.md), not [Packages](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.package). You can get the **Package** for each **AppExtension** with [AppExtension.Package](appextension_package.md).
The list of extensions.

## -remarks
Extensions are scoped by the `<uap3:AppExtension Name=...>` defined in the extension's Package.appxmanifest file. This method returns the list of extensions installed on the machine that match the `<uap3:AppExtension Name=...>` defined in the host's Package.appxmanifest file.

You typically call this method when your app launches or resumes from suspension. Then use the events on this class to listen for updates to the extensions in the catalog.

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,17 @@ public Windows.ApplicationModel.AppExtensions.AppExtensionCatalog Open(System.St
# Windows.ApplicationModel.AppExtensions.AppExtensionCatalog.Open

## -description
Opens a catalog of extensions.
Opens an app package that contains one or more extensions.

## -parameters
### -param appExtensionName
The extension namespace name.
The name of the extension.
<!--how do you specify this name?-->

## -returns
A catalog containing the extensions declared with the specified extension namespace name.
Information about the various extensions within an extension group.

## -remarks
Extensions are scoped by the `<uap3:AppExtension Name=...>` defined in the extension's Package.appxmanifest file. Only extensions that match the `<uap3:AppExtension Name=...>` defined in the host's Package.appxmanifest file appear in the catalog.

If you have multiple `<uap3:AppExtensionHost>` declarations in your host app, you need to open a separate catalog for each one.

An instance of the **PackageCatalog** is required to handle the events so keep a reference to it as long as you need to manage your app extensions.

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,7 @@ public event Windows.Foundation.TypedEventHandler PackageInstalled<Windows.Appli
Event that is fired when an extension package is installed.

## -remarks
The event argument, [AppExtensionPackageInstalledEventArgs.Extensions](appextensionpackageinstalledeventargs.md), contains a list of extensions within the extension package.

Extensions are scoped by the `<uap3:AppExtension Name=...>` defined in the extension's Package.appxmanifest file. Only extensions that match the `<uap3:AppExtension Name=...>` defined in the host's Package.appxmanifest file, are in the list of extensions.

An event handler for this event is a good place to examine each app extension for correctness and to provide the user the option to use it.

The unit of deployment for an [AppExtension](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.appextensions.appextension) is the [Package](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.package). That's why this is a **Package** install event and not an **AppExtension** install event.

Typically there will only be one extension in a package. However, be prepared to handle the case where there are multiple extensions in the package.

Use [AppExtension.Id](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.appextensions.appextension) to distinguish between extensions in the same package. To uniquely identify an extension in your app, consider concatenating [AppInfo.AppUserModelId](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.appinfo) and [AppExtension.Id](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.appinfo):

```cs
_uniqueId = yourAppExtention.AppInfo.AppUserModelId + "!" + yourAppExtention.Id;
```

This guarantees that each **AppExtension** has a unique name that you can use to track it with in your app. We recommend using this as a key for your **AppExtensions** so that you can efficiently and correctly identify if a given **AppExtension** is one that you already know about.
A host app can listen to this event to be notified when a new extension package is installed.

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,9 @@ public event Windows.Foundation.TypedEventHandler PackageStatusChanged<Windows.A
# Windows.ApplicationModel.AppExtensions.AppExtensionCatalog.PackageStatusChanged

## -description
Event that is fired when an extension package in the catalog removed, updated, or installed.
Event that is fired when an extension package is installed, removed, or updated.

## -remarks
This event helps you identify when a package is no longer available, valid, or has been modified. Handle this event to determine when an extension may no longer be valid and should be disabled. A common use for this event is to detect whether the app package providing the extension is installed on removable media. If the user removes the media containing the package, this event is raised for that package.

The [PackageStatus](../windows.applicationmodel/package_status.md) class provides the possible package status states.
Use [PackageStatus.VerifyIsOk](../windows.applicationmodel/package_status.md) to determine if the package is in good condition. If it returns **false**, you can check [PackageStatus.LicenseIssue](../windows.applicationmodel/package_status.md) or [PackageStatus.PackageOffline](../windows.applicationmodel/package_status.md) and provide special handling for those situations. Typically, if the package state is not Ok, you should disable it. It is good practice to call **PackageStatus.VerifyIsOk** anytime you are about to load an extension.

Consider handling the this event to provide an indicator in your extension manager UI that the extension is disabled or not usable because there is something wrong with the package.

Continue to handle this event, even if you've determined that there is an issue with a package, because the user may update the package and it may then be Ok to load.

Like [PackageUpdating](appextensioncatalog_packageupdating.md) and [PackageUninstalling](appextensioncatalog_packageuninstalling.md), this event only passes the [Package](../windows.applicationmodel/package.md) that's status changed. It is up to you to match the **Package** against the [AppExtensions](appextension.md) you have loaded to determine which extensions are affected by the status change.

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@ public event Windows.Foundation.TypedEventHandler PackageUninstalling<Windows.Ap
Event that is fired when an extension package is being uninstalled.

## -remarks
Update the list of extensions that you are tracking when you handle this event to reflect the ones that have been unloaded. If the user re-installs the package, then a [PackageInstalled](appextensioncatalog_packageinstalled.md) event will be raised and you can re-add the extensions while handling that event just as you would the addition of any extension.

Like [PackageUpdating](appextensioncatalog_packageupdating.md), this event only passes the package that is being uninstalled and not a list of [AppExtensions](appextension.md).

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,9 @@ public event Windows.Foundation.TypedEventHandler PackageUpdated<Windows.Applica
# Windows.ApplicationModel.AppExtensions.AppExtensionCatalog.PackageUpdated

## -description
Event that is fired when an extension package in the catalog is updated.
Event that is fired when an extension package is updated.

## -remarks
The event arguments contain a list of extensions within the extension package. Extensions are scoped by the `<uap3:AppExtension Name=...>` defined in the extension's Package.appxmanifest file. Only extensions that match the `<uap3:AppExtension Name=...>` defined in the host's Package.appxmanifest file are in the list.

The updated package may include new [AppExtensions](appextension.md), and may no longer contain **AppExtensions** that were there previously. If you are maintaining a list of loaded extensions, the handler for this event is a good place to compare the list of **AppExtensions** in the new package against your list and then update your list accordingly.

**AppExtension** properties may have changed during the update. If you cached any of them, this is a good time to check for updates.

Generally the best way to handle this event is to treat it as you do the [PackageInstalled](appextensioncatalog_packageinstalled.md) event, but update your tracking list of **AppExtensions** instead of creating a new tracking list.

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,6 @@ public event Windows.Foundation.TypedEventHandler PackageUpdating<Windows.Applic
Event that is fired when an extension package is being updated.

## -remarks
This event marks when a package update has started. It precedes the [PackageUpdated](appextensioncatalog_packageupdated.md) event. In most cases, treat this as you do [PackageUninstalling](appextensioncatalog_packageuninstalling.md).

A good way to handle this event is to treat the associated extensions within the package as unavailable when you handle **PackageUpdating**, and then reload them when you handle the **PackageUpdated** event. The time between these two events is typically less than a second.

The event argument, [AppExtensionPackageUpdatingEventArgs.Extensions](appextensionpackageupdatingeventargs.md), only includes the Package and the extension namespace name specified in the extension's Package.appxmanifest file as `<uap3:AppExtension Name=...>`. It doesn't contain the list of extensions.

When you handle the **PackageUpdating** event, match the package that is being updated against any extensions that you have loaded from that package so that you can keep track of which extensions are now available. This is why you should keep track of the [AppExtensions](appextension.md) that you have loaded, the packages to which they belong, and a unique identifier for them that you can use as a key as described in the remarks for **AppExtensionCatalog.Open**.

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,24 +10,18 @@ public Windows.Foundation.IAsyncOperation<bool> RequestRemovePackageAsync(System
# Windows.ApplicationModel.AppExtensions.AppExtensionCatalog.RequestRemovePackageAsync

## -description
Attempts to remove the specified extension package from the machine.
Removes the specified extension package.

## -parameters
### -param packageFullName
The name of the package to remove, which you can get from [AppExtension.Package.Id.FullName](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.packageid).
The name of the package to remove.
<!--how do you know the 'full' name?-->

## -returns
Returns **true** if the request to the user to remove the package was made; otherwise, **false**.
This function will return **false** if you try to use a **Package** name that is not associated with an extension in the **AppExtensionCatalog** instance. The return value doesn't reflect whether the package was actually removed or not. If the user accepts the prompt to remove the package, you will get a [PackageUninstalling](appextensioncatalog_packageuninstalling.md) event.
Returns **true** if the package was successfully removed; otherwise, **false**.

## -remarks
The user is prompted to allow or deny the package removal. You can only remove packages that contain extensions found in the **AppExtensionCatalog** instance you make the call from.

The unit of deployment for [AppExtensions](appextension.md) is the [Package](https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.package). You cannot remove **AppExtensions**; you can only remove **Packages**. **Packages** may contain multiple **AppExtensions**.

The user may not understand the relationship between **AppExtensions** and **Packages**, or between an **AppExtension** and an app on the machine (because an app may be designed to also serve as an extension). The user may accept the request to remove a package thinking that they are only removing an extension but then find that one of their favorite apps is now gone. Only use this method if you are certain that the **AppExtension** is the only thing in the package.

Avoid using this method if you do not control the ecosystem of extensions involved. This method is intended for convenience in a closed ecosystem of extensions, such as in an enterprise environment.
The user is prompted to allow or deny the removal of the package.

[Desktop Bridge](https://developer.microsoft.com/en-us/windows/bridges/desktop) app extension hosts cannot use this method directly. Desktop Bridge app extension hosts should use their Universal Windows Platform component to manage app extensions.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,10 @@ public Windows.Foundation.Collections.IVectorView<Windows.ApplicationModel.AppEx
# Windows.ApplicationModel.AppExtensions.AppExtensionPackageInstalledEventArgs.Extensions

## -description
Provides a list of extensions in the extension package that was just installed.
Provides a list of extensions that are in the extension package that was installed.

## -property-value
The list of extensions within the extension package.

Extensions are scoped by the `<uap3:AppExtension Name=...>` defined in the extension's Package.appxmanifest file. Only extensions that match the `<uap3:AppExtension Name=...>` defined in the host's Package.appxmanifest file are returned.

A list of extensions within the extension package.

## -remarks

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ Provides a list of extensions that are in the extension package that was updated
A list of extensions within the updated extension package.

## -remarks
Extensions are scoped by the `<uap3:AppExtension Name=...>` in the extension's Package.appxmanifest file. Only extensions that match the `<uap3:AppExtension Name=...>` defined in the host's Package.appxmanifest file are returned.

## -examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public string AppointmentCalendarLocalId { get; }
# Windows.ApplicationModel.Appointments.DataProvider.AppointmentCalendarCancelMeetingRequest.AppointmentCalendarLocalId

## -description

Gets a string that uniquely identifies the calendar associated with the appointment on the local device.

## -property-value
A string that uniquely identifies the calendar on the local device.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ An unknown error occurred.
The device to which a connection was attempted is not available.

### -field RemoteSystemNotSupportedByApp:6
The app on the remote device does not support remote connections. It needs to specify SupportsRemoteSystems="true" on the appService extension in its AppXManifest to accept remote connections.
The app does not support remote connections to the device you attempted to connect with.

### -field NotAuthorized:7
The user for your app is not authorized to connect to the service.
Expand All @@ -45,4 +45,4 @@ The user for your app is not authorized to connect to the service.
## -examples

## -see-also
[AppServiceConnection.OpenAsync](appserviceconnection_openasync.md)
[AppServiceConnection.OpenAsync](appserviceconnection_openasync.md)
5 changes: 1 addition & 4 deletions windows.applicationmodel.background/applicationtrigger.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,7 @@ This allows you to programmatically trigger a background tasks from within your

## -remarks

> [!IMPORTANT]
> An app can only register one **ApplicationTrigger** with the [BackgroundTaskBuilder](https://docs.microsoft.com/en-us/uwp/api/Windows.ApplicationModel.Background.BackgroundTaskBuilder) at any given time.
## -examples

## -see-also
[IBackgroundTrigger](ibackgroundtrigger.md)
[IBackgroundTrigger](ibackgroundtrigger.md)
4 changes: 2 additions & 2 deletions windows.applicationmodel.background/backgroundtaskbuilder.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ Represents a background task to be registered with the system.
## -remarks
> [!NOTE]
> This class is not agile, which means that you need to consider its threading model and marshaling behavior. For more info, see [Threading and Marshaling (C++/CX)](http://go.microsoft.com/fwlink/p/?linkid=258275) and [Using Windows Runtime objects in a multithreaded environment (.NET)](http://go.microsoft.com/fwlink/p/?linkid=258277).
> : This class is not agile, which means that you need to consider its threading model and marshaling behavior. For more info, see [Threading and Marshaling (C++/CX)](http://go.microsoft.com/fwlink/p/?linkid=258275) and [Using Windows Runtime objects in a multithreaded environment (.NET)](http://go.microsoft.com/fwlink/p/?linkid=258277).
## -examples

## -see-also
## -see-also
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ An instance of a [BackgroundTaskRegistration](backgroundtaskregistration.md) obj
## -remarks
The task must have an event trigger and a task entry point for the [Register](backgroundtaskbuilder_register.md) method to succeed. The system schedules the background task when its trigger event occurs and all of its conditions have been met.

### Background task parameter validation
### Background task parameter validatio
n


> **Windows 8**
> Windows 8 does not validate the parameters set on the [BackgroundTaskBuilder](backgroundtaskbuilder.md) object until the system tries to run the background task. If the parameters aren't valid, the background task can't start and an event log entry is created.
Expand All @@ -27,6 +29,5 @@ The task must have an event trigger and a task entry point for the [Register](ba
> Starting in Windows 8.1, the parameters used to register the background task are validated at the time of registration. An error is returned if the background task registration fails, allowing the app to determine whether or not the background task is valid. For C# and Visual Basic, task registration errors typically result in specific .NET exceptions being thrown. These exceptions are thrown as first-chance exceptions and should be corrected while you're still developing your code.Existing Windows 8 apps running on Windows 8.1 are subject to this new system behavior, which can cause the app to crash if it can't handle a failed background task registration. (An event log entry will still be generated for the failed background task registration.) As a result, Windows 8 apps that register invalid background tasks should be rewritten to register background tasks correctly and to handle failed background task registration as a caught exception.
## -examples
[BackgroundTask sample](https://github.com/Microsoft/Windows-universal-samples/tree/master/Samples/BackgroundTask/cs/BackgroundTask )

## -see-also
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public Windows.Foundation.Collections.IMapView<System.Guid, Windows.ApplicationM
# Windows.ApplicationModel.Background.BackgroundTaskRegistration.AllTasks

## -description
Enumerates an application's registered background tasks, except for the background tasks registered in a group with [Windows.ApplicationModel.Background.BackgroundTaskBuilder.TaskGroup](backgroundtaskbuilder_taskgroup.md).
Enumerates an application's registered background tasks.

## -property-value
A view into a map of registered background tasks consisting of the task ID and an [IBackgroundTaskRegistration](ibackgroundtaskregistration.md) interface.
Expand Down Expand Up @@ -39,4 +39,3 @@ foreach (var cur in BackgroundTaskRegistration.AllTasks)
```

## -see-also
[Windows.ApplicationModel.Background.BackgroundTaskBuilder.TaskGroup](backgroundtaskbuilder_taskgroup.md)
Loading

0 comments on commit d120d6a

Please sign in to comment.