コード例 #1
0
        public virtual int _GetUniqueIdentifier()
        {
            var hashCode = 399326290;

            hashCode = hashCode * -1521134295 + (Id?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (FreeSpace?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Time?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (Distance?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (CurrentLoad?.GetHashCode() ?? 0);
            return(hashCode);
        }
コード例 #2
0
        private async Task StartRequest(string peerName, object request)
        {
            CurrentLoad?.StartRequest();

            _msg.InfoFormat("Starting verification request from {0}", peerName);

            if (_msg.IsVerboseDebugEnabled)
            {
                _msg.VerboseDebugFormat("Request details: {0}", request);
            }

            bool licensed = await EnsureLicenseAsync();

            if (!licensed)
            {
                _msg.Warn("Could not check out the specified license");
            }
        }
コード例 #3
0
 private void EndRequest()
 {
     CurrentLoad?.EndRequest();
 }