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
44b47f3a
Commit
44b47f3a
authored
Apr 16, 2019
by
Greg Messner
Browse files
Initial commit (#332).
parent
043521ac
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/gitlab4j/api/systemhooks/MergeRequestSystemHookEvent.java
0 → 100644
View file @
44b47f3a
package
org.gitlab4j.api.systemhooks
;
import
org.gitlab4j.api.webhook.MergeRequestEvent
;
import
com.fasterxml.jackson.annotation.JsonIgnore
;
import
com.fasterxml.jackson.annotation.JsonSubTypes
;
import
com.fasterxml.jackson.annotation.JsonTypeInfo
;
@JsonTypeInfo
(
use
=
JsonTypeInfo
.
Id
.
NAME
,
property
=
"object_kind"
)
@JsonSubTypes
({
@JsonSubTypes
.
Type
(
value
=
MergeRequestSystemHookEvent
.
class
,
name
=
MergeRequestSystemHookEvent
.
OBJECT_KIND
),
})
public
class
MergeRequestSystemHookEvent
extends
MergeRequestEvent
implements
SystemHookEvent
{
public
static
final
String
X_GITLAB_EVENT
=
"System Hook"
;
@JsonIgnore
@Override
public
String
getEventName
()
{
return
(
OBJECT_KIND
);
}
}
src/test/resources/org/gitlab4j/api/merge-request-system-hook-event.json
0 → 100644
View file @
44b47f3a
{
"object_kind"
:
"merge_request"
,
"user"
:
{
"name"
:
"Administrator"
,
"username"
:
"root"
,
"avatar_url"
:
"http://www.gravatar.com/avatar/e64c7d89f26bd1972efa854d13d7dd61?s=80&d=identicon"
},
"project"
:
{
"name"
:
"Example"
,
"description"
:
""
,
"web_url"
:
"http://example.com/jsmith/example"
,
"git_ssh_url"
:
"git@example.com:jsmith/example.git"
,
"git_http_url"
:
"http://example.com/jsmith/example.git"
,
"namespace"
:
"Jsmith"
,
"visibility_level"
:
0
,
"path_with_namespace"
:
"jsmith/example"
,
"default_branch"
:
"master"
,
"ci_config_path"
:
""
,
"homepage"
:
"http://example.com/jsmith/example"
,
"url"
:
"git@example.com:jsmith/example.git"
,
"ssh_url"
:
"git@example.com:jsmith/example.git"
,
"http_url"
:
"http://example.com/jsmith/example.git"
},
"object_attributes"
:
{
"id"
:
90
,
"target_branch"
:
"master"
,
"source_branch"
:
"ms-viewport"
,
"source_project_id"
:
14
,
"author_id"
:
51
,
"assignee_id"
:
6
,
"title"
:
"MS-Viewport"
,
"created_at"
:
"2017-09-20T08:31:45.944Z"
,
"updated_at"
:
"2017-09-28T12:23:42.365Z"
,
"state"
:
"opened"
,
"merge_status"
:
"unchecked"
,
"target_project_id"
:
14
,
"iid"
:
1
,
"description"
:
""
,
"updated_by_id"
:
1
,
"merge_params"
:
{
"force_remove_source_branch"
:
"0"
},
"merge_when_pipeline_succeeds"
:
false
,
"lock_version"
:
5
,
"time_estimate"
:
0
,
"last_edited_at"
:
"2017-09-27T12:43:37.558Z"
,
"last_edited_by_id"
:
1
,
"head_pipeline_id"
:
61
,
"ref_fetched"
:
true
,
"source"
:
{
"name"
:
"Awesome Project"
,
"description"
:
""
,
"web_url"
:
"http://example.com/awesome_space/awesome_project"
,
"git_ssh_url"
:
"git@example.com:awesome_space/awesome_project.git"
,
"git_http_url"
:
"http://example.com/awesome_space/awesome_project.git"
,
"namespace"
:
"root"
,
"visibility_level"
:
0
,
"path_with_namespace"
:
"awesome_space/awesome_project"
,
"default_branch"
:
"master"
,
"ci_config_path"
:
""
,
"homepage"
:
"http://example.com/awesome_space/awesome_project"
,
"url"
:
"http://example.com/awesome_space/awesome_project.git"
,
"ssh_url"
:
"git@example.com:awesome_space/awesome_project.git"
,
"http_url"
:
"http://example.com/awesome_space/awesome_project.git"
},
"target"
:
{
"name"
:
"Awesome Project"
,
"description"
:
"Aut reprehenderit ut est."
,
"web_url"
:
"http://example.com/awesome_space/awesome_project"
,
"git_ssh_url"
:
"git@example.com:awesome_space/awesome_project.git"
,
"git_http_url"
:
"http://example.com/awesome_space/awesome_project.git"
,
"namespace"
:
"Awesome Space"
,
"visibility_level"
:
0
,
"path_with_namespace"
:
"awesome_space/awesome_project"
,
"default_branch"
:
"master"
,
"ci_config_path"
:
""
,
"homepage"
:
"http://example.com/awesome_space/awesome_project"
,
"url"
:
"http://example.com/awesome_space/awesome_project.git"
,
"ssh_url"
:
"git@example.com:awesome_space/awesome_project.git"
,
"http_url"
:
"http://example.com/awesome_space/awesome_project.git"
},
"last_commit"
:
{
"id"
:
"ba3e0d8ff79c80d5b0bbb4f3e2e343e0aaa662b7"
,
"message"
:
"fixed readme"
,
"timestamp"
:
"2017-09-26T16:12:57Z"
,
"url"
:
"http://example.com/awesome_space/awesome_project/commits/da1560886d4f094c3e6c9ef40349f7d38b5d27d7"
,
"author"
:
{
"name"
:
"GitLab dev user"
,
"email"
:
"gitlabdev@dv6700.(none)"
}
},
"work_in_progress"
:
false
,
"total_time_spent"
:
0
},
"labels"
:
[],
"repository"
:
{
"name"
:
"git-gpg-test"
,
"url"
:
"git@example.com:awesome_space/awesome_project.git"
,
"description"
:
""
,
"homepage"
:
"http://example.com/awesome_space/awesome_project"
}
}
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