Package com.jcabi.github.mock
Class MkCommit
- java.lang.Object
-
- com.jcabi.github.mock.MkCommit
-
- All Implemented Interfaces:
Commit
,JsonReadable
,Comparable<Commit>
@Immutable @Loggable(1) public final class MkCommit extends Object implements Commit
Mock of Github Commit.- Version:
- $Id: 14ae9ed91106cc4995cba01bd759c87891d27f15 $
- Author:
- Ed Hillmann (edhillmann@yahoo.com)
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.jcabi.github.Commit
Commit.Smart
-
-
Constructor Summary
Constructors Constructor Description MkCommit(MkStorage strg, String login, Coordinates crds, String commitsha)
Public constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(Commit commit)
javax.json.JsonObject
json()
Describe it in a JSON object.Repo
repo()
The repo we're in.String
sha()
SHA of it.
-
-
-
Constructor Detail
-
MkCommit
public MkCommit(MkStorage strg, String login, Coordinates crds, String commitsha)
Public constructor.- Parameters:
strg
- The storage.login
- The login namecrds
- Credentialcommitsha
- Commit's sha.- Suppressed Checkstyle violations:
- ParameterNumber (5 lines)
-
-
Method Detail
-
json
public javax.json.JsonObject json() throws IOException
Description copied from interface:JsonReadable
Describe it in a JSON object.- Specified by:
json
in interfaceJsonReadable
- Returns:
- JSON object
- Throws:
IOException
- If there is any I/O problem
-
compareTo
public int compareTo(Commit commit)
- Specified by:
compareTo
in interfaceComparable<Commit>
-
-