Exemplo n.º 1
0
        /// <summary>
        /// Sends an ObjectAccessRevoked message to a customer.
        /// </summary>
        /// <param name="requestUuid">The request UUID.</param>
        /// <param name="uri">The URI.</param>
        /// <param name="changeTime">The change time.</param>
        /// <param name="extension">The message header extension.</param>
        /// <returns>The sent message on success; <c>null</c> otherwise.</returns>
        public virtual EtpMessage <ObjectAccessRevoked> ObjectAccessRevoked(Guid requestUuid, string uri, DateTime changeTime, IMessageHeaderExtension extension = null)
        {
            var body = new ObjectAccessRevoked
            {
                RequestUuid = requestUuid,
                ChangeTime  = changeTime,
            };

            return(SendNotification(body, extension: extension));
        }
Exemplo n.º 2
0
        /// <summary>
        /// Sends a ObjectAccessRevoked message to a customer.
        /// </summary>
        /// <param name="request">The request.</param>
        /// <param name="uri">The URI.</param>
        /// <param name="changeTime">The change time.</param>
        /// <returns>The message identifier.</returns>
        public long ObjectAccessRevoked(IMessageHeader request, string uri, long changeTime)
        {
            var header = CreateMessageHeader(Protocols.StoreNotification, MessageTypes.StoreNotification.ObjectAccessRevoked, request.MessageId);

            var notification = new ObjectAccessRevoked
            {
                Uri        = uri,
                ChangeTime = changeTime
            };

            return(Session.SendMessage(header, notification));
        }
Exemplo n.º 3
0
 /// <summary>
 /// Handles the ObjectAccessRevoked message from a store.
 /// </summary>
 /// <param name="header">The message header.</param>
 /// <param name="notification">The ObjectAccessRevoked message.</param>
 protected virtual void HandleObjectAccessRevoked(IMessageHeader header, ObjectAccessRevoked notification)
 {
     Notify(OnObjectAccessRevoked, header, notification);
 }