public class LegalHoldPolicy
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
LegalHoldPolicy.Builder
Builder for
LegalHoldPolicy . |
Modifier and Type | Field and Description |
---|---|
protected java.util.Date |
activationTime |
protected java.lang.String |
description |
protected java.util.Date |
endDate |
protected java.lang.String |
id |
protected MembersInfo |
members |
protected java.lang.String |
name |
protected java.util.Date |
startDate |
protected LegalHoldStatus |
status |
Constructor and Description |
---|
LegalHoldPolicy(java.lang.String id,
java.lang.String name,
MembersInfo members,
LegalHoldStatus status,
java.util.Date startDate)
None
|
LegalHoldPolicy(java.lang.String id,
java.lang.String name,
MembersInfo members,
LegalHoldStatus status,
java.util.Date startDate,
java.lang.String description,
java.util.Date activationTime,
java.util.Date endDate)
Use
newBuilder to create instances of this class without
specifying values for all optional fields. |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.util.Date |
getActivationTime()
The time at which the legal hold was activated.
|
java.lang.String |
getDescription()
A description of the legal hold policy.
|
java.util.Date |
getEndDate()
End date of the legal hold policy.
|
java.lang.String |
getId()
The legal hold id.
|
MembersInfo |
getMembers()
Team members IDs and number of permanetly deleted members under hold.
|
java.lang.String |
getName()
Policy name.
|
java.util.Date |
getStartDate()
Start date of the legal hold policy.
|
LegalHoldStatus |
getStatus()
The current state of the hold.
|
int |
hashCode() |
static LegalHoldPolicy.Builder |
newBuilder(java.lang.String id,
java.lang.String name,
MembersInfo members,
LegalHoldStatus status,
java.util.Date startDate)
Returns a new builder for creating an instance of this class.
|
java.lang.String |
toString() |
java.lang.String |
toStringMultiline()
Returns a String representation of this object formatted for easier
readability.
|
protected final java.lang.String id
protected final java.lang.String name
protected final java.lang.String description
protected final java.util.Date activationTime
protected final MembersInfo members
protected final LegalHoldStatus status
protected final java.util.Date startDate
protected final java.util.Date endDate
public LegalHoldPolicy(java.lang.String id, java.lang.String name, MembersInfo members, LegalHoldStatus status, java.util.Date startDate, java.lang.String description, java.util.Date activationTime, java.util.Date endDate)
newBuilder
to create instances of this class without
specifying values for all optional fields.id
- The legal hold id. Must match pattern "^pid_dbhid:.+
"
and not be null
.name
- Policy name. Must have length of at most 140 and not be
null
.members
- Team members IDs and number of permanetly deleted members
under hold. Must not be null
.status
- The current state of the hold. Must not be null
.startDate
- Start date of the legal hold policy. Must not be null
.description
- A description of the legal hold policy. Must have
length of at most 501.activationTime
- The time at which the legal hold was activated.endDate
- End date of the legal hold policy.java.lang.IllegalArgumentException
- If any argument does not meet its
preconditions.public LegalHoldPolicy(java.lang.String id, java.lang.String name, MembersInfo members, LegalHoldStatus status, java.util.Date startDate)
The default values for unset fields will be used.
id
- The legal hold id. Must match pattern "^pid_dbhid:.+
"
and not be null
.name
- Policy name. Must have length of at most 140 and not be
null
.members
- Team members IDs and number of permanetly deleted members
under hold. Must not be null
.status
- The current state of the hold. Must not be null
.startDate
- Start date of the legal hold policy. Must not be null
.java.lang.IllegalArgumentException
- If any argument does not meet its
preconditions.public java.lang.String getId()
null
.public java.lang.String getName()
null
.public MembersInfo getMembers()
null
.public LegalHoldStatus getStatus()
null
.public java.util.Date getStartDate()
null
.public java.lang.String getDescription()
null
if not present.public java.util.Date getActivationTime()
null
if not present.public java.util.Date getEndDate()
null
if not present.public static LegalHoldPolicy.Builder newBuilder(java.lang.String id, java.lang.String name, MembersInfo members, LegalHoldStatus status, java.util.Date startDate)
id
- The legal hold id. Must match pattern "^pid_dbhid:.+
"
and not be null
.name
- Policy name. Must have length of at most 140 and not be
null
.members
- Team members IDs and number of permanetly deleted members
under hold. Must not be null
.status
- The current state of the hold. Must not be null
.startDate
- Start date of the legal hold policy. Must not be null
.java.lang.IllegalArgumentException
- If any argument does not meet its
preconditions.public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String toStringMultiline()
The returned String may contain newlines.