You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add an optional scope parameter to the method getter on DID Document implementations to allow iterating over particular verification relationship fields.
E.g.
/// Returns an iterator over all [`<DID>VerificationMethods`] in the DID Document.pubfnmethods(&self,scope:Option<MethodScope>) -> implIterator<Item = &<DID>VerificationMethod>{
...}
Edit: alternatively we could just delegate the individual authentication(), assertionMethod(), etc. functions.
Motivation
Currently, there is no way to list or iterate over the methods with a particular verification relationship (authentication, assertionMethod, keyAgreement, etc.) in IotaDocument and StardustDocument other than accessing the inner CoreDocument which has dedicated methods for each (authentication(), assertionMethod(), keyAgreement(), etc,).
It would be convenient to expose this functionality without bloating the API with methods for each field, similar to how resolve_method works now.
To-do list
Add optional scope parameter to methods().
Change checklist
Add an x to the boxes that are relevant to your changes, and delete any items that are not.
The feature or fix is implemented in Rust and across all bindings whereas possible.
The feature or fix has sufficient testing coverage
All tests and examples build and run locally as expected
Every piece of code has been document according to the documentation guidelines.
If conceptual documentation (mdbook) and examples highlighting the feature exist, they are properly updated.
If the feature is not currently documented, a documentation task Issue has been opened to address this.
The text was updated successfully, but these errors were encountered:
Description
Add an optional
scope
parameter to themethod
getter on DID Document implementations to allow iterating over particular verification relationship fields.E.g.
Edit: alternatively we could just delegate the individual
authentication()
,assertionMethod()
, etc. functions.Motivation
Currently, there is no way to list or iterate over the methods with a particular verification relationship (
authentication
,assertionMethod
,keyAgreement
, etc.) inIotaDocument
andStardustDocument
other than accessing the innerCoreDocument
which has dedicated methods for each (authentication()
,assertionMethod()
,keyAgreement()
, etc,).It would be convenient to expose this functionality without bloating the API with methods for each field, similar to how
resolve_method
works now.To-do list
scope
parameter tomethods()
.Change checklist
Add an
x
to the boxes that are relevant to your changes, and delete any items that are not.The text was updated successfully, but these errors were encountered: