Package org.eclipse.jgit.util
Class GitDateFormatter
- java.lang.Object
-
- org.eclipse.jgit.util.GitDateFormatter
-
public class GitDateFormatter extends Object
A utility for formatting dates according to the Git log.date formats plus extensions.The enum
GitDateFormatter.Format
defines the available types.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GitDateFormatter.Format
Git and JGit formats
-
Constructor Summary
Constructors Constructor Description GitDateFormatter(GitDateFormatter.Format format)
Create a new Git oriented date formatter
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
formatDate(PersonIdent ident)
Format committer, author or tagger ident according to this formatter's specification.
-
-
-
Constructor Detail
-
GitDateFormatter
public GitDateFormatter(GitDateFormatter.Format format)
Create a new Git oriented date formatter- Parameters:
format
- aGitDateFormatter.Format
object.
-
-
Method Detail
-
formatDate
public String formatDate(PersonIdent ident)
Format committer, author or tagger ident according to this formatter's specification.- Parameters:
ident
- aPersonIdent
object.- Returns:
- formatted version of date, time and time zone
-
-