-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add SplitKey type for subindexing in token query service #719
Conversation
/// A split key is used to specify a subindex on indices with a struct key. | ||
/// | ||
/// For example, a primr | ||
/// Warning: No type checking! It's up to the user to ensure that T + Rest | ||
/// is equivalent to the primary key) | ||
template <typename Rest, typename T> | ||
struct SplitKey | ||
{ | ||
T value; | ||
}; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The reason I suggested SplitKey
is that it's non-intrusive. If we're adding this to the main Table.hpp
header, a better solution would be to add an overload of subindex
that takes an explicit type.
subindex<Rest>(key)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I decided to make this non-intrusive rather than try to figure out how to implement your subindex idea
SplitKey
type for subindexingSplitKey
type for subindexing in token query service
SplitKey
type for subindexing in token query service
SplitKey
type to the token query service to allow subindexing on indices with a struct key