Skip to content
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

[Feat][C++] Replace the polymorphism implement of EdgesCollection #237

Closed
acezen opened this issue Sep 26, 2023 · 1 comment
Closed

[Feat][C++] Replace the polymorphism implement of EdgesCollection #237

acezen opened this issue Sep 26, 2023 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@acezen
Copy link
Contributor

acezen commented Sep 26, 2023

Is your feature request related to a problem? Please describe.
Currently GraphAr use variant to implement the EdgesCollection polymorphism, it's clear for API access but it's hard to convert to the actual EdgesCollection like:

auto& edges = GraphAr::ConstructEdgesCollection(AdjListType::ordered_by_source).value()
if (adj_list_type==AdjListType::ordered_by_source) {
    auto real_edges = std::get<>(edges)
    ... // process code
} else {
   auto real_edges = std::get<>(edges)
   ... // same process code
}

Describe the solution you'd like
Use inherit and virtual member function to implement the polymorphism

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

@acezen acezen added the enhancement New feature or request label Sep 26, 2023
@acezen acezen self-assigned this Sep 26, 2023
@acezen
Copy link
Contributor Author

acezen commented Oct 16, 2023

The PR #238 has been merged, close

@acezen acezen closed this as completed Oct 16, 2023
@acezen acezen added this to the Release v0.10.0[WIP] milestone Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant