Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
佳 邓
Gitlab4j Api
Commits
5fbd9049
Commit
5fbd9049
authored
Dec 30, 2017
by
Greg Messner
Browse files
Added methods to get authToken, authType, and secretToken (#119).
parent
b0e1aac8
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/gitlab4j/api/GitLabApi.java
View file @
5fbd9049
...
@@ -515,7 +515,34 @@ public class GitLabApi {
...
@@ -515,7 +515,34 @@ public class GitLabApi {
* @return the current sudo as ID, will return null if not in sudo mode
* @return the current sudo as ID, will return null if not in sudo mode
*/
*/
public
Integer
getSudoAsId
()
{
public
Integer
getSudoAsId
()
{
return
(
this
.
apiClient
.
getSudoAsId
());
return
(
apiClient
.
getSudoAsId
());
}
/**
* Get the auth token being used by this client.
*
* @return the auth token being used by this client
*/
public
String
getAuthToken
()
{
return
(
apiClient
.
getAuthToken
());
}
/**
* Get the secret token.
*
* @return the secret token
*/
public
String
getSecretToken
()
{
return
(
apiClient
.
getSecretToken
());
}
/**
* Get the TokenType this client is using.
*
* @return the TokenType this client is using
*/
public
TokenType
getTokenType
()
{
return
(
apiClient
.
getTokenType
());
}
}
/**
/**
...
...
src/main/java/org/gitlab4j/api/GitLabApiClient.java
View file @
5fbd9049
...
@@ -219,6 +219,33 @@ public class GitLabApiClient {
...
@@ -219,6 +219,33 @@ public class GitLabApiClient {
clientConfig
.
register
(
JacksonJson
.
class
);
clientConfig
.
register
(
JacksonJson
.
class
);
}
}
/**
* Get the auth token being used by this client.
*
* @return the auth token being used by this client
*/
String
getAuthToken
()
{
return
(
authToken
);
}
/**
* Get the secret token.
*
* @return the secret token
*/
String
getSecretToken
()
{
return
(
secretToken
);
}
/**
* Get the TokenType this client is using.
*
* @return the TokenType this client is using
*/
TokenType
getTokenType
()
{
return
(
tokenType
);
}
/**
/**
* Set the ID of the user to sudo as.
* Set the ID of the user to sudo as.
*
*
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment