to top
Android APIs
public final class

Timestamp

extends Object
implements Serializable
java.lang.Object
   ↳ java.security.Timestamp

Class Overview

Timestamp represents a signed time stamp. Timestamp is immutable.

Summary

Public Constructors
Timestamp(Date timestamp, CertPath signerCertPath)
Constructs a new instance of Timestamp with the specified timestamp and the given certificate path.
Public Methods
boolean equals(Object obj)
Compares the specified object with this Timestamp for equality and returns true if the specified object is equal, false otherwise.
CertPath getSignerCertPath()
Returns the certificate path of this Timestamp.
Date getTimestamp()
Returns the date and time of this Timestamp.
int hashCode()
Returns the hash code value for this Timestamp.
String toString()
Returns a string containing a concise, human-readable description of this Timestamp.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public Timestamp (Date timestamp, CertPath signerCertPath)

Added in API level 1

Constructs a new instance of Timestamp with the specified timestamp and the given certificate path.

Parameters
timestamp date and time.
signerCertPath the certificate path.
Throws
NullPointerException if timestamp is null or if signerCertPath is null.

Public Methods

public boolean equals (Object obj)

Added in API level 1

Compares the specified object with this Timestamp for equality and returns true if the specified object is equal, false otherwise. The given object is equal to this Timestamp, if it is an instance of Timestamp, the two timestamps have an equal date and time and their certificate paths are equal.

Parameters
obj object to be compared for equality with this Timestamp.
Returns
  • true if the specified object is equal to this Timestamp, otherwise false.
See Also

public CertPath getSignerCertPath ()

Added in API level 1

Returns the certificate path of this Timestamp.

Returns
  • the certificate path of this Timestamp.

public Date getTimestamp ()

Added in API level 1

Returns the date and time of this Timestamp.

Returns
  • the date and time of this Timestamp.

public int hashCode ()

Added in API level 1

Returns the hash code value for this Timestamp. Returns the same hash code for Timestamps that are equal to each other as required by the general contract of hashCode().

Returns
  • the hash code value for this Timestamp.

public String toString ()

Added in API level 1

Returns a string containing a concise, human-readable description of this Timestamp.

Returns
  • a printable representation for this Timestamp.