public LazyQueryOperation(QueryOperation queryOperation, Action <QueryResult> afterQueryExecuted, NameValueCollection headers) { this.queryOperation = queryOperation; this.afterQueryExecuted = afterQueryExecuted; this.headers = headers; }
public QueryDemoVersionEvent(QueryOperation operation, byte immediate, ushort argument) { Operation = operation; Immediate = immediate; Argument = argument; }
public QueryChosenVerbEvent(QueryOperation operation, byte immediate, TriggerType triggerType) { Operation = operation; Immediate = immediate; TriggerType = triggerType; }
public QueryHasItemEvent(QueryOperation operation, byte immediate, ItemId itemId) { Operation = operation; Immediate = immediate; ItemId = itemId; }
public static string Convert(QueryOperation select, Expression where, QueryOrder order, int?skip, int?take, Graph graph, ModelDetail modelDetail) { return(instance.ConvertInternal(select, where, order, skip, take, graph, modelDetail)); }
public QueryYieldStream(AsyncDocumentSession parent, IAsyncEnumerator <RavenJObject> enumerator, QueryOperation queryOperation) : base(parent, enumerator) { this.queryOperation = queryOperation; }
public QueryConsciousEvent(QueryOperation operation, byte immediate, PartyMemberId partyMemberId) { Operation = operation; Immediate = immediate; PartyMemberId = partyMemberId; }
public LazyQueryOperation(InMemoryDocumentSessionOperations session, QueryOperation queryOperation, Action <QueryResult> afterQueryExecuted) { _session = session; _queryOperation = queryOperation; _afterQueryExecuted = afterQueryExecuted; }
public static IEnumerable <IFeature> QueryFeatures(string layer, string prop, QueryOperation operation, object param) { return(MapControl.Current.AllMaps.SelectMany(x => x.Layers[layer].Features).Where(x => FeatureSelector(x, prop, operation, param)).ToList()); }
/// <inheritdoc /> public IEnumerator <T> GetEnumerator() { InitSync(); return(QueryOperation.Complete <T>().GetEnumerator()); }
/// <summary> /// Prompts the user to chose an operation and routes it to the appropriate dialog /// </summary> /// <param name="context">IDialogContext</param> /// <returns>Task</returns> private async Task routeOperation(IDialogContext context) { //initialize a new operation on the context context.NewOperation(); //check the entity type to determine the valid operations var entity = context.ConversationData.GetDialogEntity(); List <QueryOperation> operations = QueryOperation.GetEntityResourceTypes(entity.entityType); //prepare the prompt string prompt = "What would like to lookup for you?"; if (entity.entityType != EntityType.Me) { prompt = String.Format("What would like to lookup for {0}?", entity.text); } //add start over operations.Add(new Models.QueryOperation() { Text = "(Start over)", Type = Models.OperationType.StartOver }); //let the user select an operation PromptDialog.Choice(context, async(IDialogContext opContext, IAwaitable <QueryOperation> opResult) => { //check the operation selected and route appropriately var operation = await opResult; switch (operation.Type) { case OperationType.StartOver: await this.MessageReceivedAsync(opContext, null); break; case OperationType.Manager: await opContext.Forward(new ResourceTypes.ManagerDialog(), OperationComplete, true, CancellationToken.None); break; case OperationType.DirectReports: await opContext.Forward(new ResourceTypes.DirectReportsDialog(), OperationComplete, true, CancellationToken.None); break; case OperationType.Files: await opContext.Forward(new ResourceTypes.FilesDialog(), OperationComplete, true, CancellationToken.None); break; case OperationType.Members: await opContext.Forward(new ResourceTypes.MembersDialog(), OperationComplete, true, CancellationToken.None); break; case OperationType.Contacts: case OperationType.Conversations: case OperationType.Events: case OperationType.Groups: case OperationType.Mail: case OperationType.Notebooks: case OperationType.People: case OperationType.Photo: case OperationType.Plans: await opContext.Forward(new PlanLookupDialog(), OnPlanLookupDialogResumeAsync, new Plan(), CancellationToken.None); break; case OperationType.Tasks: await opContext.Forward(new TasksDialog(), OperationComplete, true, CancellationToken.None); break; case OperationType.TrendingAround: case OperationType.WorkingWith: await opContext.PostAsync("Operation not yet implemented"); opContext.Wait(MessageReceivedAsync); break; } }, operations, prompt); }
public MemoryDbObjectQuery(MemoryTable table) { this.table = table; query = new QueryOperation(); }
public QueryNpcActiveOnMapEvent(QueryOperation operation, byte npcNumber, MapId mapId) { Operation = operation; NpcNumber = npcNumber; MapId = mapId; }
public QueryMapEvent(QueryOperation operation, byte immediate, MapId mapId) { Operation = operation; Immediate = immediate; MapId = mapId; }
public QueryEventUsedEvent(QueryOperation operation, byte immediate, ushort argument) { Operation = operation; Immediate = immediate; Argument = argument; }
private static Task <Tuple <QueryResult, List <T> > > ProcessEnumerator(QueryOperation currentQueryOperation) { var list = currentQueryOperation.Complete <T>(); return(Task.FromResult(Tuple.Create(currentQueryOperation.CurrentQueryResults, list))); }
public QuerySwitchEvent(QueryOperation operation, byte immediate, SwitchId switchId) { Operation = operation; Immediate = immediate; SwitchId = switchId; }
public LazyQueryOperation(QueryOperation queryOperation, Action <QueryResult> afterQueryExecuted, HashSet <string> includes) { this.queryOperation = queryOperation; this.afterQueryExecuted = afterQueryExecuted; this.includes = includes; }
public QueryDemoVersionEvent(ushort argument, QueryOperation operation, byte immediate) { Argument = argument; Operation = operation; Immediate = immediate; }
public QueryTriggerTypeEvent(QueryOperation operation, byte immediate, ushort argument) { Operation = operation; Immediate = immediate; Argument = argument; }
public QueryTickerEvent(TickerId tickerId, QueryOperation operation, byte immediate) { TickerId = tickerId; Operation = operation; Immediate = immediate; }
public LazyQueryOperation(DocumentConventions conventions, QueryOperation queryOperation, Action <QueryResult> afterQueryExecuted) { _conventions = conventions; _queryOperation = queryOperation; _afterQueryExecuted = afterQueryExecuted; }
public OperationAttribute(string name, QueryOperation op) {
public LazyQueryOperation(QueryOperation queryOperation, Action <QueryResult> afterQueryExecuted) { this.queryOperation = queryOperation; this.afterQueryExecuted = afterQueryExecuted; }
protected override void GenerateEnding(QueryOperation select, Graph graph, ModelDetail modelDetail, ref CharWriteBuffer sb) { }
public QueryChainActiveEvent(QueryOperation operation, byte immediate, ushort argument) { Operation = operation; Immediate = immediate; Argument = argument; }
private DynamicQueryParam CreateParam(QueryOperation opt, string field, object value) { return(new DynamicQueryParam { Operator = opt, Field = field, Value = value }); }
public QueryYieldStream(AsyncDocumentSession parent, IAsyncEnumerator <RavenJObject> enumerator, QueryOperation queryOperation, CancellationToken token = default(CancellationToken)) : base(parent, enumerator, token) { this.queryOperation = queryOperation; }
private void listCapabilities_SelectedIndexChanged(object sender, EventArgs e) { if (this.listCapabilities.SelectedIndex == -1) { return; } DeviceCapability cap = (DeviceCapability)this.listCapabilities.SelectedItem; this.listValues.Items.Clear(); this.lblCapType.Text = _device.Controller.GetCapabilityTwainType(cap).ToString(); QueryOperation operations = _device.GetQueryOperations(cap); FillOperationList(operations); if ((operations & QueryOperation.TWQC_GET) == QueryOperation.TWQC_GET) { TwainCapability capability = new TwainCapability(cap, TwainContainer.TWON_DONTCARE16, IntPtr.Zero); if (_device.Controller.SendCommand(TwainTriplet.CapabilityGet, _device.Identity, capability) == TwainReturnCode.TWRC_SUCCESS) { this.lblGetContainer.Text = capability.ContainerType.ToString(); // Always use a TwainMemory object when working with memory returned from a driver. TwainMemory memory = _device.Controller.CreateTwainMemory(capability.Data); try { object vals = _device.Controller.ReadTwainContainerData(capability.ContainerType, memory); FillValueList(vals, cap); } catch (Exception ex) { MessageBox.Show("ReadTwainContainerData failed for " + cap.ToString() + "\r\n\r\n" + ex.Message + "\r\n" + ex.StackTrace); } finally { memory.Dispose(); } } else { this.lblGetContainer.Text = "Unknown"; } } else { this.lblGetContainer.Text = "Not Supported"; } if ((operations & QueryOperation.TWQC_GETCURRENT) == QueryOperation.TWQC_GETCURRENT) { TwainCapability capability = new TwainCapability(cap, TwainContainer.TWON_DONTCARE16, IntPtr.Zero); if (_device.Controller.SendCommand(TwainTriplet.CapabilityGet, _device.Identity, capability) == TwainReturnCode.TWRC_SUCCESS) { this.lblGetCurrentContainer.Text = capability.ContainerType.ToString(); // Don't forget to free the memory allocated by the driver. _device.Controller.FreeTwainMemory(capability.Data); } else { this.lblGetContainer.Text = "Unknown"; } } else { this.lblGetCurrentContainer.Text = "Not Supported"; } }
public QueryScriptDebugModeEvent(ushort argument, QueryOperation operation, byte immediate) { Argument = argument; Operation = operation; Immediate = immediate; }