OperationContext

We found 10 examples in language CSharp for this search. You will see 55 fragments of code.

        public override Task AbortCopyAsync(string copyId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return base.AbortCopyAsync(copyId, accessCondition, options, operationContext);
        }

        public override Task AbortCopyAsync(string copyId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
            //return base.AbortCopyAsync(copyId, accessCondition, options, operationContext, cancellationToken);
        }

        public override Task<string> AcquireLeaseAsync(TimeSpan? leaseTime, string proposedLeaseId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return base.AcquireLeaseAsync(leaseTime, proposedLeaseId, accessCondition, options, operationContext);
        }

        public override Task<string> AcquireLeaseAsync(TimeSpan? leaseTime, string proposedLeaseId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
            // return base.AcquireLeaseAsync(leaseTime, proposedLeaseId, accessCondition, options, operationContext, cancellationToken);
        }        

        public override Task<long> AppendBlockAsync(Stream blockData, string contentMD5, AccessCondition accesscondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return base.AppendBlockAsync(blockData, contentMD5, accesscondition, options, operationContext);
        }

        public override Task<long> AppendBlockAsync(Stream blockData, string contentMD5, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
            // return base.AppendBlockAsync(blockData, contentMD5, accessCondition, options, operationContext, cancellationToken);
        }


        public override Task AbortCopyAsync(string copyId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return base.AbortCopyAsync(copyId, accessCondition, options, operationContext);
        }

        public override Task AbortCopyAsync(string copyId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
            // return base.AbortCopyAsync(copyId, accessCondition, options, operationContext, cancellationToken);
        }

        public override Task<string> AcquireLeaseAsync(TimeSpan? leaseTime, string proposedLeaseId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return base.AcquireLeaseAsync(leaseTime, proposedLeaseId, accessCondition, options, operationContext);
        }

        public override Task<string> AcquireLeaseAsync(TimeSpan? leaseTime, string proposedLeaseId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
            // return base.AcquireLeaseAsync(leaseTime, proposedLeaseId, accessCondition, options, operationContext, cancellationToken);
        }

        public override Task<TimeSpan> BreakLeaseAsync(TimeSpan? breakPeriod, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return base.BreakLeaseAsync(breakPeriod, accessCondition, options, operationContext);
        }

        public override Task<TimeSpan> BreakLeaseAsync(TimeSpan? breakPeriod, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
            //return base.BreakLeaseAsync(breakPeriod, accessCondition, options, operationContext, cancellationToken);
        }


        public override Task AddMessageAsync(CloudQueueMessage message, TimeSpan? timeToLive, TimeSpan? initialVisibilityDelay, QueueRequestOptions options, OperationContext operationContext)
        {
            //throw new NotImplementedException();
            return base.AddMessageAsync(message, timeToLive, initialVisibilityDelay, options, operationContext);
        }

        public override Task AddMessageAsync(CloudQueueMessage message, TimeSpan? timeToLive, TimeSpan? initialVisibilityDelay, QueueRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            if (message == null)
            {
                throw new ArgumentNullException("message");
            }

            _store.AddMessage(this.Name, message);
            return Task.FromResult(0);
        }

        public override Task ClearAsync(QueueRequestOptions options, OperationContext operationContext)
        {
            throw new NotImplementedException();
            // return base.ClearAsync(options, operationContext);
        }

        public override Task ClearAsync(QueueRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
            // return base.ClearAsync(options, operationContext, cancellationToken);
        }

        public override Task CreateAsync(QueueRequestOptions options, OperationContext operationContext)
        {
            //throw new NotImplementedException();
            return base.CreateAsync(options, operationContext);
        }

        public override Task CreateAsync(QueueRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            _store.CreateIfNotExists(this.Name);
            return Task.FromResult(0);

            // throw new NotImplementedException();
            // return base.CreateAsync(options, operationContext, cancellationToken);
        }


        public override Task AbortCopyAsync(string copyId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            throw new NotImplementedException();
        }

        public override Task AbortCopyAsync(string copyId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
        }

        public override Task<string> AcquireLeaseAsync(TimeSpan? leaseTime, string proposedLeaseId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return AcquireLeaseCore(leaseTime, proposedLeaseId);
        }

        public override Task<string> AcquireLeaseAsync(TimeSpan? leaseTime, string proposedLeaseId, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return AcquireLeaseCore(leaseTime, proposedLeaseId);
        }

        public override Task<TimeSpan> BreakLeaseAsync(TimeSpan? breakPeriod, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            throw new NotImplementedException();
        }

        public override Task<TimeSpan> BreakLeaseAsync(TimeSpan? breakPeriod, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
        }

        public override Task CreateAsync(TableRequestOptions requestOptions, OperationContext operationContext)
        {
            return base.CreateAsync(requestOptions, operationContext);
        }
        public override Task CreateAsync(TableRequestOptions requestOptions, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return this.CreateIfNotExistsAsync();
        }
        public override Task<bool> CreateIfNotExistsAsync(TableRequestOptions requestOptions, OperationContext operationContext)
        {
            return base.CreateIfNotExistsAsync(requestOptions, operationContext);
        }
        public override Task<bool> CreateIfNotExistsAsync(TableRequestOptions requestOptions, OperationContext operationContext, CancellationToken cancellationToken)
        {
            _store.CreateIfNotExists(_tableName);
            return Task.FromResult(false); // $$$
        }
        public override Task DeleteAsync(TableRequestOptions requestOptions, OperationContext operationContext)
        {
            return base.DeleteAsync(requestOptions, operationContext);
        }
        public override Task DeleteAsync(TableRequestOptions requestOptions, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return base.DeleteAsync(requestOptions, operationContext, cancellationToken);
        }


		public void AddCurrentOperationContextInfo()
		{
			if (OperationContext.Current != null) {
				string_res += "OperationContext , ";
				if (OperationContext.Current.InstanceContext != null) {
					string_res += ("InstanceContext = " + OperationContext.Current.InstanceContext.State + " , ");
					//if (OperationContext.Current.InstanceContext != null)
					//    string_res += ("Instance = " + OperationContext.Current.InstanceContext.GetServiceInstance () + " , ");
				}
			}
		}


        public override Task CreateAsync(BlobContainerPublicAccessType accessType, BlobRequestOptions options, OperationContext operationContext)
        {
            throw new NotImplementedException();
        }

        public override Task CreateAsync(BlobContainerPublicAccessType accessType, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            throw new NotImplementedException();
        }

        public override Task<bool> CreateIfNotExistsAsync(BlobRequestOptions options, OperationContext operationContext)
        {
            return base.CreateIfNotExistsAsync(options, operationContext);
        }

        public override Task<bool> CreateIfNotExistsAsync(BlobContainerPublicAccessType accessType, BlobRequestOptions options, OperationContext operationContext)
        {
            return base.CreateIfNotExistsAsync(accessType, options, operationContext);
        }

        public override Task<bool> CreateIfNotExistsAsync(BlobContainerPublicAccessType accessType, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            _store.CreateIfNotExists(this.Name);
            return Task.FromResult(true); // $$$ what is this
        }

        public override Task DeleteAsync(AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            throw new NotImplementedException();
        }



        [DoesServiceRequest]
        public virtual Task<CloudBlockBlob> CreateSnapshotAsync(IDictionary<string, string> metadata, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.CreateSnapshotAsync(metadata, accessCondition, options, operationContext, cancellationToken));
        }

        [DoesServiceRequest]
        public virtual Task<CloudBlockBlob> CreateSnapshotAsync(IDictionary<string, string> metadata, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.CreateSnapshotAsync(metadata, accessCondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task<IEnumerable<ListBlockItem>> DownloadBlockListAsync(BlockListingFilter blockListingFilter, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadBlockListAsync(blockListingFilter, accessCondition, options, operationContext, cancellationToken));
        }

        [DoesServiceRequest]
        public virtual Task<IEnumerable<ListBlockItem>> DownloadBlockListAsync(BlockListingFilter blockListingFilter, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadBlockListAsync(blockListingFilter, accessCondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task<string> DownloadTextAsync(Encoding encoding, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadTextAsync(encoding, accessCondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task<string> DownloadTextAsync(Encoding encoding, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, IProgress<StorageProgress> progressHandler, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadTextAsync(encoding, accessCondition, options, operationContext, progressHandler, cancellationToken));
        }



        [DoesServiceRequest]
        public virtual Task<CloudBlockBlob> CreateSnapshotAsync(IDictionary<string, string> metadata, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.CreateSnapshotAsync(metadata, accessCondition, options, operationContext, cancellationToken));
        }

        [DoesServiceRequest]
        public virtual Task<CloudBlockBlob> CreateSnapshotAsync(IDictionary<string, string> metadata, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.CreateSnapshotAsync(metadata, accessCondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task<IEnumerable<ListBlockItem>> DownloadBlockListAsync(BlockListingFilter blockListingFilter, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadBlockListAsync(blockListingFilter, accessCondition, options, operationContext, cancellationToken));
        }

        [DoesServiceRequest]
        public virtual Task<IEnumerable<ListBlockItem>> DownloadBlockListAsync(BlockListingFilter blockListingFilter, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadBlockListAsync(blockListingFilter, accessCondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task<string> DownloadTextAsync(Encoding encoding, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadTextAsync(encoding, accessCondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task<string> DownloadTextAsync(Encoding encoding, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, IProgress<StorageProgress> progressHandler, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.DownloadTextAsync(encoding, accessCondition, options, operationContext, progressHandler, cancellationToken));
        }



        [DoesServiceRequest]
        public virtual Task<long> AppendBlockAsync(Stream blockData, string contentMD5, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, IProgress<StorageProgress> progressHandler, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.AppendBlockAsync(blockData, contentMD5, accessCondition, options, operationContext, progressHandler, cancellationToken));
        }

        [DoesServiceRequest]
        public virtual Task<long> AppendBlockAsync(Stream blockData, string contentMD5, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.AppendBlockAsync(blockData, contentMD5, accessCondition, options, operationContext, cancellationToken));
        }

        public virtual Task<long> AppendBlockAsync(Stream blockData, string contentMD5, AccessCondition accesscondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.AppendBlockAsync(blockData, contentMD5, accesscondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task AppendFromByteArrayAsync(byte[] buffer, int index, int count, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.AppendFromByteArrayAsync(buffer, index, count, accessCondition, options, operationContext, cancellationToken));
        }

        [DoesServiceRequest]
        public virtual Task AppendFromByteArrayAsync(byte[] buffer, int index, int count, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.AppendFromByteArrayAsync(buffer, index, count, accessCondition, options, operationContext));
        }

        [DoesServiceRequest]
        public virtual Task AppendFromFileAsync(string path, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, IProgress<StorageProgress> progressHandler, CancellationToken cancellationToken)
        {
            return this.failoverExecutor.ExecuteAsync(x => x.AppendFromFileAsync(path, accessCondition, options, operationContext, progressHandler, cancellationToken));
        }

Microsoft.Azure.Storage.OperationContext : Object

Constructors :

public OperationContext()

Methods :

public IDictionary<StringString> get_UserHeaders()
public Void set_UserHeaders(IDictionary<StringString> value = )
public String get_ClientRequestID()
public Void set_ClientRequestID(String value = )
public String get_CustomUserAgent()
public Void set_CustomUserAgent(String value = )
public static LogLevel get_DefaultLogLevel()
public static Void set_DefaultLogLevel(LogLevel value = )
public LogLevel get_LogLevel()
public Void set_LogLevel(LogLevel value = )
public static Void add_GlobalSendingRequest(EventHandler<RequestEventArgs> value = )
public static Void remove_GlobalSendingRequest(EventHandler<RequestEventArgs> value = )
public static Void add_GlobalResponseReceived(EventHandler<RequestEventArgs> value = )
public static Void remove_GlobalResponseReceived(EventHandler<RequestEventArgs> value = )
public static Void add_GlobalRequestCompleted(EventHandler<RequestEventArgs> value = )
public static Void remove_GlobalRequestCompleted(EventHandler<RequestEventArgs> value = )
public static Void add_GlobalRetrying(EventHandler<RequestEventArgs> value = )
public static Void remove_GlobalRetrying(EventHandler<RequestEventArgs> value = )
public Void add_SendingRequest(EventHandler<RequestEventArgs> value = )
public Void remove_SendingRequest(EventHandler<RequestEventArgs> value = )
public Void add_ResponseReceived(EventHandler<RequestEventArgs> value = )
public Void remove_ResponseReceived(EventHandler<RequestEventArgs> value = )
public Void add_RequestCompleted(EventHandler<RequestEventArgs> value = )
public Void remove_RequestCompleted(EventHandler<RequestEventArgs> value = )
public Void add_Retrying(EventHandler<RequestEventArgs> value = )
public Void remove_Retrying(EventHandler<RequestEventArgs> value = )
public DateTimeOffset get_StartTime()
public Void set_StartTime(DateTimeOffset value = )
public DateTimeOffset get_EndTime()
public Void set_EndTime(DateTimeOffset value = )
public IList<RequestResult> get_RequestResults()
public RequestResult get_LastResult()
public Type GetType()
public String ToString()
public Boolean Equals(Object obj = )
public Int32 GetHashCode()