当前位置: 首页>>代码示例>>C#>>正文


C# NSDictionary.ToString方法代码示例

本文整理汇总了C#中NSDictionary.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# NSDictionary.ToString方法的具体用法?C# NSDictionary.ToString怎么用?C# NSDictionary.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在NSDictionary的用法示例。


在下文中一共展示了NSDictionary.ToString方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: ReceivedRemoteNotification

		public override void ReceivedRemoteNotification(UIApplication application, NSDictionary userInfo)
		{
			Console.WriteLine(userInfo.ToString());
			NSObject inAppMessage;

			bool success = userInfo.TryGetValue(new NSString("inAppMessage"), out inAppMessage);

			if (success)
			{
				var alert = new UIAlertView("Got push notification", inAppMessage.ToString(), null, "OK", null);
				alert.Show();
			}
		}
开发者ID:conceptdev,项目名称:xamarin-samples,代码行数:13,代码来源:AppDelegate.cs

示例2: ReceivedRemoteNotification

        public override void ReceivedRemoteNotification(UIApplication application, NSDictionary userInfo)
        {
            // NOTE: Don't call the base implementation on a Model class
            // see http://docs.xamarin.com/guides/ios/application_fundamentals/delegates,_protocols,_and_events 

            Debug.WriteLine(userInfo.ToString());
            NSObject inAppMessage;

            bool success = userInfo.TryGetValue(new NSString("inAppMessage"), out inAppMessage);

            if (success)
            {
                var alert = new UIAlertView("Got push notification", inAppMessage.ToString(), null, "OK", null);
                alert.Show();
            }
        }
开发者ID:ARMoir,项目名称:mobile-samples,代码行数:16,代码来源:AppDelegate.cs

示例3: ReceivedRemoteNotification

        public void ReceivedRemoteNotification(NSDictionary userInfo)
        {
            string message = null;
            NSObject aps = userInfo.ObjectForKey(new NSString("aps"));
            if (aps != null && aps.IsKindOfClass(new Class(typeof(NSDictionary))))
            {
                var dict = (NSDictionary)aps;
                NSObject alert = dict.ObjectForKey(new NSString("alert"));
                if (alert != null && alert.IsKindOfClass(new Class(typeof(NSString))))
                    message = alert.ToString();
            }

            if (message != null)
                BusinessProcessContext.Current.GlobalEventsController.OnPushMessage(message);
            else
                _applicaitonContext.HandleException(new NonFatalException(D.PUSH_NOTIFICATION_ERROR, userInfo.ToString()));
        }
开发者ID:Fedorm,项目名称:core-master,代码行数:17,代码来源:PushNotificationManager.cs

示例4: ReceiveEvent

            public override NSObject ReceiveEvent(CoronaView view, NSDictionary pEvent)
            {
                if(OnReceive!=null){
                    OnReceive (view,pEvent);
                }

                //Console.WriteLine ("CoronaViewDelegate.ReceiveEvent:{0}",pEvent);
                return new NSString( pEvent.ToString());
            }
开发者ID:WildenChen,项目名称:CoronaCards-Xamarin-iOS,代码行数:9,代码来源:CoronaCardsViewExtensions.cs


注:本文中的NSDictionary.ToString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。