• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# CommandFlags类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中CommandFlags的典型用法代码示例。如果您正苦于以下问题:C# CommandFlags类的具体用法?C# CommandFlags怎么用?C# CommandFlags使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



CommandFlags类属于命名空间,在下文中一共展示了CommandFlags类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: CreateLongCommand

 internal static Command CreateLongCommand(string name, Func<FSharpOption<int>, Register, LongCommandResult> func, CommandFlags flags = CommandFlags.None)
 {
     var fsharpFunc = FSharpFuncUtil.Create(func);
     var list = name.Select(InputUtil.CharToKeyInput).ToFSharpList();
     var commandName = CommandName.NewManyKeyInputs(list);
     return Command.NewLongCommand(commandName, flags, fsharpFunc);
 }
开发者ID:ChrisMarinos,项目名称:VsVim,代码行数:7,代码来源:VimUtil.cs


示例2: Command

 /// <summary>
 /// Initializes a new instance of the <see cref="Command"/> class.
 /// </summary>
 /// <param name="flags">Command flags.</param>
 /// <param name="name">The command's name.</param>
 /// <param name="description">The command's description.</param>
 /// <param name="usage">The command's usage string.</param>
 /// <param name="helpMessage">The command's help message.</param>
 protected Command(CommandFlags flags, string name, string description, string usage, string helpMessage)
 {
     Name = name;
     Description = description;
     Usage = usage;
     HelpMessage = helpMessage;
     Flags = flags;
 }
开发者ID:medsouz,项目名称:HaloOnlineTagTool,代码行数:16,代码来源:Command.cs


示例3: Exists

 /// <summary>
 /// EXISTS http://redis.io/commands/exists
 /// </summary>
 public Task<bool> Exists(CommandFlags commandFlags = CommandFlags.None)
 {
     return TraceHelper.RecordReceive(Settings, Key, CallType, async () =>
     {
         var r = await Command.KeyExistsAsync(Key, commandFlags).ForAwait();
         return Tracing.CreateReceived(r, sizeof(bool));
     });
 }
开发者ID:cloud9-plus,项目名称:CloudStructures,代码行数:11,代码来源:RedisStructure.cs


示例4: Dispose

 public void Dispose()
 {
     if (Disposing != null)
         Disposing(this);
     Flags = CommandFlags.None;
     ValidateHnd = null;
     PrepareHnd = null;
     ExecuteHnd = null;
     FinishHnd = null;
 }
开发者ID:Basilid,项目名称:Spheres,代码行数:10,代码来源:GameObjectQueryDesc.cs


示例5: Common

 // private Properties.WidgetPropsManager _prop_man;
 // Constructor is 'protected'
 protected Common()
 {
     _cur_element = null;
     _cur_window = null;
     _obj_props_panel = null;
     _cur_action = CommandFlags.TB_NONE;
     _obj_tree_il = null;
     _py_editor = new mkdb.Python.PyFileEditor();
     // _prop_man = new mkdb.Properties.WidgetPropsManager();
 }
开发者ID:miquik,项目名称:mkdb,代码行数:12,代码来源:Common.cs


示例6: CommandDefinition

        /// <summary>
        /// Initialize the command definition
        /// </summary>
        public CommandDefinition(string commandText, object parameters = null, IDbTransaction transaction = null, int? commandTimeout = null,
                                 CommandType? commandType = null, CommandFlags flags = CommandFlags.Buffered
#if ASYNC
                                 , CancellationToken cancellationToken = default(CancellationToken)
#endif
            )
        {
            CommandText = commandText;
            Parameters = parameters;
            Transaction = transaction;
            CommandTimeout = commandTimeout;
            CommandType = commandType;
            Flags = flags;
#if ASYNC
            CancellationToken = cancellationToken;
#endif
        }
开发者ID:ServiceStack,项目名称:ServiceStack.OrmLite,代码行数:20,代码来源:CommandDefinition.cs


示例7: Combine

 public RedisValue[] Combine(SetOperation operation, RedisKey first, RedisKey second, CommandFlags flags = CommandFlags.None)
 {
     return RedisSync.SetCombine(operation, first, second, flags);
 }
开发者ID:HyperSharp,项目名称:Hyperspace.Redis,代码行数:4,代码来源:RedisSet.cs


示例8: CombineAsync

 public Task<RedisValue[]> CombineAsync(SetOperation operation, RedisKey first, RedisKey second, CommandFlags flags = CommandFlags.None)
 {
     return RedisAsync.SetCombineAsync(operation, first, second, flags);
 }
开发者ID:HyperSharp,项目名称:Hyperspace.Redis,代码行数:4,代码来源:RedisSet.cs


示例9: EvaluateAsync

        /// <summary>
        /// Evaluates this LoadedLuaScript against the given database, extracting parameters for the passed in object if any.
        /// 
        /// This method sends the SHA1 hash of the ExecutableScript instead of the script itself.  If the script has not
        /// been loaded into the passed Redis instance it will fail.
        /// </summary>
        public Task<RedisResult> EvaluateAsync(IDatabaseAsync db, object ps = null, RedisKey? withKeyPrefix = null, CommandFlags flags = CommandFlags.None)
        {
            RedisKey[] keys;
            RedisValue[] args;
            Original.ExtractParameters(ps, withKeyPrefix, out keys, out args);

            return db.ScriptEvaluateAsync(Hash, keys, args, flags);
        }
开发者ID:etrpreddy,项目名称:StackExchange.Redis,代码行数:14,代码来源:LuaScript.cs


示例10: CombineAndStoreAsync

 public Task<long> CombineAndStoreAsync(SetOperation operation, RedisKey destination, RedisKey first, RedisKey second, CommandFlags flags = CommandFlags.None)
 {
     return RedisAsync.SetCombineAndStoreAsync(operation, destination, first, second, flags);
 }
开发者ID:HyperSharp,项目名称:Hyperspace.Redis,代码行数:4,代码来源:RedisSet.cs


示例11: Select

        private ServerEndPoint Select(int slot, RedisCommand command, CommandFlags flags)
        {
            flags = Message.GetMasterSlaveFlags(flags); // only intersted in master/slave preferences

            ServerEndPoint[] arr;
            if (slot == NoSlot || (arr = map) == null) return Any(command, flags);

            ServerEndPoint endpoint = arr[slot], testing;
            // but: ^^^ is the MASTER slots; if we want a slave, we need to do some thinking
            
            if (endpoint != null)
            {
                switch (flags)
                {
                    case CommandFlags.DemandSlave:
                        return FindSlave(endpoint, command) ?? Any(command, flags);
                    case CommandFlags.PreferSlave:
                        testing = FindSlave(endpoint, command);
                        if (testing != null) return testing;
                        break;
                    case CommandFlags.DemandMaster:
                        return FindMaster(endpoint, command) ?? Any(command, flags);
                    case CommandFlags.PreferMaster:
                        testing = FindMaster(endpoint, command);
                        if (testing != null) return testing;
                        break;
                }
                if (endpoint.IsSelectable(command)) return endpoint;
            }
            return Any(command, flags);
        }
开发者ID:carfaxad,项目名称:StackExchange.Redis,代码行数:31,代码来源:ServerSelectionStrategy.cs


示例12: Evaluate

        /// <summary>
        /// Evaluates this LuaScript against the given database, extracting parameters from the passed in object if any.
        /// </summary>
        public RedisResult Evaluate(IDatabase db, object ps = null, RedisKey? withKeyPrefix = null, CommandFlags flags = CommandFlags.None)
        {
            RedisKey[] keys;
            RedisValue[] args;
            ExtractParameters(ps, withKeyPrefix, out keys, out args);

            return db.ScriptEvaluate(ExecutableScript, keys, args, flags);
        }
开发者ID:etrpreddy,项目名称:StackExchange.Redis,代码行数:11,代码来源:LuaScript.cs


示例13: GetMenuMask

        public static CommandFlags GetMenuMask()
        {
            var pathToCheck = GetSelectedPath();

            if (pathToCheck == _lastCheckedPath)
                return _lastMenuMask;

            _lastCheckedPath = pathToCheck;
            _lastMenuMask = GetMenuMask(_lastCheckedPath);
            return _lastMenuMask;
        }
开发者ID:kthompson,项目名称:gitmenu,代码行数:11,代码来源:GitCommand.cs


示例14: GitCommand

 protected GitCommand(GitMenuPackage provider, int id, CommandFlags selection, string text)
     : base(new CommandID(GuidList.GuidGitMenuCmdSet, id), text)
 {
     this.Selection = selection;
     Package = provider;
 }
开发者ID:kthompson,项目名称:gitmenu,代码行数:6,代码来源:GitCommand.cs


示例15: Eval

 protected object Eval(string script, bool async = false, CommandFlags flags = CommandFlags.FireAndForget)
 {
     object result = null;
         var redisDatabase = GetRedisDatabase();
         if (async)
             redisDatabase.ScriptEvaluateAsync(script);
         else
             result = redisDatabase.ScriptEvaluate(script, null, null, flags);
         return result;
 }
开发者ID:njfife,项目名称:playground,代码行数:10,代码来源:RedisUnlockedStateStore.cs


示例16: Command

 /// <summary>
 /// 命令标志
 /// </summary>
 /// <param name="commandName"></param>
 protected Command(CommandFlags commandName)
 {
     _commandName = commandName;
 }
开发者ID:ssjylsg,项目名称:tcp-net,代码行数:8,代码来源:Command.cs


示例17: ExecuteAsync

 Task<string> IRedisAsync.ClientGetNameAsync(CommandFlags flags)
 {
     var msg = Message.Create(-1, flags, RedisCommand.CLIENT, RedisLiterals.GETNAME);
     return ExecuteAsync(msg, ResultProcessor.String);
 }
开发者ID:MichaCo,项目名称:StackExchange.Redis,代码行数:5,代码来源:DebuggingAids.cs


示例18: ExecuteSync

 void IServer.Hang(TimeSpan duration, CommandFlags flags)
 {
     var msg = Message.Create(-1, flags, RedisCommand.CLIENT, RedisLiterals.PAUSE, (long)duration.TotalMilliseconds);
     ExecuteSync(msg, ResultProcessor.DemandOK);
 }
开发者ID:MichaCo,项目名称:StackExchange.Redis,代码行数:5,代码来源:DebuggingAids.cs


示例19: CombineAndStore

 public long CombineAndStore(SetOperation operation, RedisKey destination, RedisKey[] keys, CommandFlags flags = CommandFlags.None)
 {
     return RedisSync.SetCombineAndStore(operation, destination, keys, flags);
 }
开发者ID:HyperSharp,项目名称:Hyperspace.Redis,代码行数:4,代码来源:RedisSet.cs


示例20: Any

 private ServerEndPoint Any(RedisCommand command, CommandFlags flags)
 {
     return multiplexer.AnyConnected(serverType, (uint)Interlocked.Increment(ref anyStartOffset), command, flags);
 }
开发者ID:carfaxad,项目名称:StackExchange.Redis,代码行数:4,代码来源:ServerSelectionStrategy.cs



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# CommandFunction类代码示例发布时间:2022-05-24
下一篇:
C# CommandEventHandler类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap