Beispiel #1
0
        // Token: 0x06000CC7 RID: 3271 RVA: 0x0002F660 File Offset: 0x0002D860
        private ConversationResponseShape GetNotificationPayloadShape(string requestedConversationShapeName)
        {
            if (string.IsNullOrEmpty(requestedConversationShapeName))
            {
                requestedConversationShapeName = RowBrokerHandler.DefaultConversationViewShapeName;
            }
            ConversationResponseShape clientResponseShape = new ConversationResponseShape(ShapeEnum.IdOnly, Array <PropertyPath> .Empty);

            return(Global.ResponseShapeResolver.GetResponseShape <ConversationResponseShape>(requestedConversationShapeName, clientResponseShape, this.GetFeaturesManager()));
        }
        // Token: 0x06000D63 RID: 3427 RVA: 0x00032668 File Offset: 0x00030868
        private static PropertyDefinition[] GetSpecialConversationProperties(ConversationResponseShape itemShape)
        {
            HashSet <PropertyDefinition> hashSet = new HashSet <PropertyDefinition>();

            foreach (PropertyPath propertyPath in itemShape.AdditionalProperties)
            {
                PropertyUri propertyUri = propertyPath as PropertyUri;
                if (propertyUri != null && propertyUri.Uri == PropertyUriEnum.ConversationPreview)
                {
                    hashSet.Add(ConversationItemSchema.ConversationPreview);
                    break;
                }
            }
            return(hashSet.ToArray <PropertyDefinition>());
        }
        // Token: 0x06000D62 RID: 3426 RVA: 0x000325E4 File Offset: 0x000307E4
        private static PropertyDefinition[] GetSubscriptionProperties(string requestedConversationShapeName, IFeaturesManager featuresManager)
        {
            if (string.IsNullOrEmpty(requestedConversationShapeName))
            {
                requestedConversationShapeName = WellKnownShapeName.ConversationUberListView.ToString();
            }
            ConversationResponseShape clientResponseShape = new ConversationResponseShape(ShapeEnum.IdOnly, new PropertyPath[0]);
            ConversationResponseShape responseShape       = Global.ResponseShapeResolver.GetResponseShape <ConversationResponseShape>(requestedConversationShapeName, clientResponseShape, featuresManager);

            if (responseShape == null)
            {
                ExTraceGlobals.NotificationsCallTracer.TraceError <string>((long)requestedConversationShapeName.GetHashCode(), "[ConversationRowNotificationHandler.GetSubscriptionProperties] Unable to resolve requestedConversationShapeName: {0}", requestedConversationShapeName);
                return(ConversationRowNotificationHandler.defaultConversationViewQuerySubscriptionProperties);
            }
            Shape[] shapes = new Shape[]
            {
                ConversationShape.CreateShape()
            };
            PropertyDefinition[] specialConversationProperties = ConversationRowNotificationHandler.GetSpecialConversationProperties(responseShape);
            return(RowNotificationHandler.GetPropertyDefinitionsForResponseShape(shapes, responseShape, specialConversationProperties));
        }