public class YouTrackServer extends Object
| Constructor and Description |
|---|
YouTrackServer(String serverUrl)
Constructs a server.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
addBuildToBundle(User user,
String bundleName,
String buildName)
Adds a build with the name to the bundle with the given name.
|
boolean |
applyCommand(User user,
Issue issue,
String command,
String comment,
User runAs)
Apply a command to an issue.
|
boolean |
comment(User user,
Issue issue,
String comment)
Adds a comment to the issue with currently logged in user.
|
Issue |
getIssue(User user,
String issueId)
Gets an issue by issue id.
|
List<Project> |
getProjects(User user)
Gets all projects that the given user can see.
|
User |
getUserByEmail(User user,
String email)
Get a YouTrack user from the e-mail address.
|
User |
login(String username,
String password)
Logs in a user.
|
public YouTrackServer(String serverUrl)
serverUrl - the url of the server.public List<Project> getProjects(User user)
login(String, String), i.e.
it should contains the cookie strings for the users login session.user - the user to get projects for.public boolean comment(User user, Issue issue, String comment)
user - the currently logged in user.issue - the issue to comment on.comment - the comment text.public boolean applyCommand(User user, Issue issue, String command, String comment, User runAs)
user - the user used to apply the command, shall be one with cookies set.issue - the issue to apply the command to.command - the command to apply.comment - comment with the command, null is allowed.runAs - user to apply the command as, null is allowed.public User getUserByEmail(User user, String email)
user - the user to get.email - the email to get.public User login(String username, String password)
username - the username of the user.password - the password of the user.public boolean addBuildToBundle(User user, String bundleName, String buildName)
user - the logged in user.bundleName - the name of the bundle to add a build to.buildName - the name of the build to add.Copyright © 2004-2013. All Rights Reserved.