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
2f2d2b45
Commit
2f2d2b45
authored
Mar 19, 2019
by
Greg Messner
Browse files
Implemented toString() (#320).
parent
88ec32b9
Changes
25
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/gitlab4j/api/webhook/NoteEvent.java
View file @
2f2d2b45
...
...
@@ -7,6 +7,7 @@ import javax.xml.bind.annotation.XmlAccessorType;
import
org.gitlab4j.api.models.Diff
;
import
org.gitlab4j.api.models.User
;
import
org.gitlab4j.api.utils.JacksonJson
;
import
org.gitlab4j.api.utils.JacksonJsonEnumHelper
;
import
com.fasterxml.jackson.annotation.JsonCreator
;
...
...
@@ -260,4 +261,9 @@ public class NoteEvent extends AbstractEvent {
this
.
url
=
url
;
}
}
@Override
public
String
toString
()
{
return
(
JacksonJson
.
toJsonString
(
this
));
}
}
src/main/java/org/gitlab4j/api/webhook/PipelineEvent.java
View file @
2f2d2b45
...
...
@@ -8,6 +8,7 @@ import javax.xml.bind.annotation.XmlAccessorType;
import
org.gitlab4j.api.models.ArtifactsFile
;
import
org.gitlab4j.api.models.User
;
import
org.gitlab4j.api.utils.JacksonJson
;
@XmlAccessorType
(
XmlAccessType
.
FIELD
)
public
class
PipelineEvent
extends
AbstractEvent
{
...
...
@@ -268,4 +269,9 @@ public class PipelineEvent extends AbstractEvent {
this
.
duration
=
duration
;
}
}
@Override
public
String
toString
()
{
return
(
JacksonJson
.
toJsonString
(
this
));
}
}
src/main/java/org/gitlab4j/api/webhook/PushEvent.java
View file @
2f2d2b45
...
...
@@ -4,6 +4,8 @@ package org.gitlab4j.api.webhook;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
org.gitlab4j.api.utils.JacksonJson
;
@XmlAccessorType
(
XmlAccessType
.
FIELD
)
public
class
PushEvent
extends
AbstractPushEvent
implements
Event
{
...
...
@@ -20,4 +22,9 @@ public class PushEvent extends AbstractPushEvent implements Event {
throw
new
RuntimeException
(
"Invalid object_kind ("
+
objectKind
+
"), must be '"
+
OBJECT_KIND
+
"'"
);
}
}
@Override
public
String
toString
()
{
return
(
JacksonJson
.
toJsonString
(
this
));
}
}
src/main/java/org/gitlab4j/api/webhook/TagPushEvent.java
View file @
2f2d2b45
...
...
@@ -4,6 +4,8 @@ package org.gitlab4j.api.webhook;
import
javax.xml.bind.annotation.XmlAccessType
;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
org.gitlab4j.api.utils.JacksonJson
;
@XmlAccessorType
(
XmlAccessType
.
FIELD
)
public
class
TagPushEvent
extends
AbstractPushEvent
implements
Event
{
...
...
@@ -19,4 +21,9 @@ public class TagPushEvent extends AbstractPushEvent implements Event {
if
(!
OBJECT_KIND
.
equals
(
objectKind
))
throw
new
RuntimeException
(
"Invalid object_kind ("
+
objectKind
+
"), must be '"
+
OBJECT_KIND
+
"'"
);
}
@Override
public
String
toString
()
{
return
(
JacksonJson
.
toJsonString
(
this
));
}
}
src/main/java/org/gitlab4j/api/webhook/WikiPageEvent.java
View file @
2f2d2b45
...
...
@@ -4,6 +4,7 @@ import javax.xml.bind.annotation.XmlAccessType;
import
javax.xml.bind.annotation.XmlAccessorType
;
import
org.gitlab4j.api.models.User
;
import
org.gitlab4j.api.utils.JacksonJson
;
@XmlAccessorType
(
XmlAccessType
.
FIELD
)
public
class
WikiPageEvent
extends
AbstractEvent
{
...
...
@@ -174,4 +175,9 @@ public class WikiPageEvent extends AbstractEvent {
this
.
url
=
url
;
}
}
@Override
public
String
toString
()
{
return
(
JacksonJson
.
toJsonString
(
this
));
}
}
Prev
1
2
Next
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