forked from Redth/PushSharp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
182 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
54 changes: 54 additions & 0 deletions
54
PushSharp.WindowsPhone/WindowsPhonePushBrokerExtensions.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using PushSharp.WindowsPhone; | ||
using PushSharp.Core; | ||
|
||
namespace PushSharp | ||
{ | ||
public static class ApplePushBrokerExtensions | ||
{ | ||
public static void RegisterWindowsPhoneService(this PushBroker broker, WindowsPhonePushChannelSettings channelSettings, PushServiceSettings serviceSettings = null) | ||
{ | ||
var service = new WindowsPhonePushService(new WindowsPhonePushChannelFactory(), channelSettings, serviceSettings); | ||
|
||
broker.RegisterService<WindowsPhoneCycleTileNotification>(service); | ||
broker.RegisterService<WindowsPhoneFlipTileNotification>(service); | ||
broker.RegisterService<WindowsPhoneIconicTileNotification>(service); | ||
broker.RegisterService<WindowsPhoneTileNotification>(service); | ||
broker.RegisterService<WindowsPhoneToastNotification>(service); | ||
broker.RegisterService<WindowsPhoneRawNotification>(service); | ||
} | ||
|
||
public static WindowsPhoneCycleTileNotification WindowsPhoneCycleTileNotification(this PushBroker broker) | ||
{ | ||
return new WindowsPhoneCycleTileNotification(); | ||
} | ||
|
||
public static WindowsPhoneFlipTileNotification WindowsPhoneFlipTileNotification(this PushBroker broker) | ||
{ | ||
return new WindowsPhoneFlipTileNotification(); | ||
} | ||
|
||
public static WindowsPhoneIconicTileNotification WindowsPhoneIconicTileNotification(this PushBroker broker) | ||
{ | ||
return new WindowsPhoneIconicTileNotification(); | ||
} | ||
|
||
public static WindowsPhoneTileNotification WindowsPhoneTileNotification(this PushBroker broker) | ||
{ | ||
return new WindowsPhoneTileNotification(); | ||
} | ||
|
||
public static WindowsPhoneToastNotification WindowsPhoneToastNotification(this PushBroker broker) | ||
{ | ||
return new WindowsPhoneToastNotification(); | ||
} | ||
|
||
public static WindowsPhoneRawNotification WindowsPhoneRawNotification(this PushBroker broker) | ||
{ | ||
return new WindowsPhoneRawNotification(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.