Questions tagged [indexer]

367 questions
3
votes
3 answers

Dynamic linq: Is there a way to access object data by index?

I need some in-memory filtering with Dynamic Linq. My objects have only a indexer: public object this[int index] { } The access to my data is like: object[0], object[1],... So my query is like this: // get FilterText from user at runtime // eg.…
Schorsch
  • 137
  • 1
  • 12
3
votes
1 answer

android sectionindexer tutorial?

How do I create a categorical section indexer for a listview with string array? I have seen examples for alphabet indexer, but how is it implemented for categories e.g. Section 1, Section 2, Section 3...?
bunbun
  • 2,595
  • 3
  • 34
  • 52
3
votes
3 answers

Question about indexers and/or generics

how is it possible to know whether an object implements an indexer?, I need to share a logic for a DataRow and a IDataReader, but they don't share any interface. I tried also with generics but don't know what restriction should I put on the where…
Jhonny D. Cano -Leftware-
  • 17,663
  • 14
  • 81
  • 103
3
votes
2 answers

Could not open genesis config file

I am just following the instruction: https://github.com/near/nearcore/blob/master/chain/indexer/README.md to setup testnet indexer. The command cargo run --release --home-dir ~/.near/testnet init --chain-id testnet --download that was suggested to…
3
votes
1 answer

C# Array Indexer

I was wondering: how is the C# array indexer implemented? You can index a C# array with basically every integer value from ulong to sbyte, does the internal implementation simply casts to a common type every time? To be clear will this: ulong i =…
Alakanu
  • 325
  • 2
  • 11
3
votes
0 answers

Eclipse and C++ indexer

I have some problems with Eclipse C++ indexer. Sometimes it just breaks. Everything is OK in my code and some whole files get tainted of red with unresolved names. I have to rebuild the whole index to make my project well-indexed again. However on…
Benjamin Barrois
  • 2,566
  • 13
  • 30
3
votes
1 answer

Accessing "this" pointer/reference using an indexer in C#

I am experimenting with a datastructure for a performance / memory critical part of our codebase. I would like to have a fast access to the bytes defined in the structure. However I am not sure how to access the structure on which I am operating on…
Kraken
  • 295
  • 1
  • 3
  • 13
3
votes
1 answer

Databinding to index property

I have a control bind to an index property of an object which implements INotifyPropertyChanged. The problem is, I don't know how to notify the property changed signal for that particular index string. I was told that I can use OnPropertyChanged("")…
GaryX
  • 737
  • 1
  • 5
  • 20
3
votes
1 answer

What are the benefits of an indexer?

Can somebody explain what is the benefit of having an indexer? public class MyClass { private List list = new List() public string this[int value] { get { return list[value]; } …
user2818430
  • 5,853
  • 21
  • 82
  • 148
3
votes
2 answers

Item property in c#

Is item property in c# is always used like indexer in c#? Let me explain with an example. ArrayList is having many properties like count,capacity, and one of them is Item.Item Property unlike count and capacity which are accessed by putting dot…
Pranita Jain
  • 63
  • 1
  • 7
3
votes
2 answers

How fast is Azure Search Indexer and how I can index faster?

Each index batch is limited from 1 to 1000 documents. When I call it from my local machine or azure VM, I got 800ms to 3000ms per 1000 doc batch. If I submit multiple batches with async, the time spent is roughly the same. That means it would take…
Tony
  • 135
  • 9
3
votes
1 answer

sql full text search not searching exact phrase

I have a database of around 10,000 records. Each record have a text of aprx 40 pages each. I need to implement full-text search in my database coz like query is taking lot of time. I created the index, following these instructions and tried…
3
votes
2 answers

Indexer created to look at array doesn't see changes made to array

I am very new to c#, and I'm creating a serial port class for a board I have designed. In which this class contains methods to open/close a serial port connected to the board. It should also read messages from the board and write messages from the…
3
votes
2 answers

FATAL: no indexes found in config file

I am trying to run the indexer of my sphinx server. This is the command I use (through root access) to start the indexing: indexer --all When I use the command, this is the reponse I get: Sphinx 2.1.9-id64-release (rel21-r4761) Copyright (c)…
Tom Aalbers
  • 4,574
  • 5
  • 29
  • 51
3
votes
1 answer

How to fix "member names cannot be the same as their enclosing type" error when using a class indexer?

I have a class named Item that I use in my project, and wanted to get/set values inside the class by an indexer function. I created the indexer function and got the subject error. After some research, it seems like the problem is that the indexer is…