Skip to content

Commit 379c5fb

Browse files
committed
Fill out JavaDoc for credentialRepositoryV2 and usernameRepository setters
1 parent e0668ee commit 379c5fb

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

webauthn-server-core/src/main/java/com/yubico/webauthn/RelyingParty.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -606,7 +606,12 @@ public RelyingPartyBuilder credentialRepository(CredentialRepository credentialR
606606

607607
/**
608608
* {@link RelyingPartyBuilder#credentialRepository(CredentialRepository)
609-
* credentialRepository} is a required parameter.
609+
* credentialRepository} is a required parameter. This setter differs from {@link
610+
* #credentialRepository(CredentialRepository)} in that it takes an instance of {@link
611+
* CredentialRepositoryV2} and converts the builder's return type to {@link RelyingPartyV2}.
612+
* {@link CredentialRepositoryV2} does not require the application to support usernames,
613+
* unless {@link RelyingPartyV2.RelyingPartyV2Builder#usernameRepository(UsernameRepository)
614+
* usernameRepository} is also set in a subsequent builder step.
610615
*
611616
* @see #credentialRepository(CredentialRepository)
612617
* @deprecated EXPERIMENTAL: This is an experimental feature. It is likely to change or be

webauthn-server-core/src/main/java/com/yubico/webauthn/RelyingPartyV2.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,13 @@ public class RelyingPartyV2<C extends CredentialRecord> {
140140
@NonNull private final CredentialRepositoryV2<C> credentialRepository;
141141

142142
/**
143-
* TODO
143+
* Enable support for identifying users by username.
144+
*
145+
* <p>If set, then {@link #startAssertion(StartAssertionOptions)} allows setting the {@link
146+
* StartAssertionOptions.StartAssertionOptionsBuilder#username(String) username} parameter when
147+
* starting an assertion.
148+
*
149+
* <p>By default, this is not set.
144150
*
145151
* @deprecated EXPERIMENTAL: This is an experimental feature. It is likely to change or be deleted
146152
* before reaching a mature release.

0 commit comments

Comments
 (0)