|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.jgit.transport.CredentialsProvider org.eclipse.jgit.transport.UsernamePasswordCredentialsProvider
public class UsernamePasswordCredentialsProvider
Simple CredentialsProvider
that always uses the same information.
Constructor Summary | |
---|---|
UsernamePasswordCredentialsProvider(String username,
char[] password)
Initialize the provider with a single username and password. |
|
UsernamePasswordCredentialsProvider(String username,
String password)
Initialize the provider with a single username and password. |
Method Summary | |
---|---|
void |
clear()
Destroy the saved username and password.. |
boolean |
get(URIish uri,
CredentialItem... items)
Ask for the credential items to be populated. |
boolean |
isInteractive()
Check if the provider is interactive with the end-user. |
boolean |
supports(CredentialItem... items)
Check if the provider can supply the necessary CredentialItem s. |
Methods inherited from class org.eclipse.jgit.transport.CredentialsProvider |
---|
get, getDefault, reset, setDefault |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public UsernamePasswordCredentialsProvider(String username, String password)
username
- password
- public UsernamePasswordCredentialsProvider(String username, char[] password)
username
- password
- Method Detail |
---|
public boolean isInteractive()
CredentialsProvider
isInteractive
in class CredentialsProvider
true
if the provider is interactive with the end-user.public boolean supports(CredentialItem... items)
CredentialsProvider
CredentialItem
s.
supports
in class CredentialsProvider
items
- the items the application requires to complete authentication.
true
if this CredentialsProvider
supports all of
the items supplied.public boolean get(URIish uri, CredentialItem... items) throws UnsupportedCredentialItem
CredentialsProvider
get
in class CredentialsProvider
uri
- the URI of the remote resource that needs authentication.items
- the items the application requires to complete authentication.
true
if the request was successful and values were
supplied; false
if the user canceled the request and did
not supply all requested values.
UnsupportedCredentialItem
- if one of the items supplied is not supported.public void clear()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |