Package com.dropbox.core.v2.sharing
Class GroupMembershipInfo
- java.lang.Object
-
- com.dropbox.core.v2.sharing.MembershipInfo
-
- com.dropbox.core.v2.sharing.GroupMembershipInfo
-
public class GroupMembershipInfo extends MembershipInfo
The information about a group member of the shared content.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GroupMembershipInfo.Builder
Builder forGroupMembershipInfo
.
-
Field Summary
Fields Modifier and Type Field Description protected GroupInfo
group
-
Fields inherited from class com.dropbox.core.v2.sharing.MembershipInfo
accessType, initials, isInherited, permissions
-
-
Constructor Summary
Constructors Constructor Description GroupMembershipInfo(AccessLevel accessType, GroupInfo group)
The information about a group member of the shared content.GroupMembershipInfo(AccessLevel accessType, GroupInfo group, java.util.List<MemberPermission> permissions, java.lang.String initials, boolean isInherited)
The information about a group member of the shared content.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
AccessLevel
getAccessType()
The access type for this member.GroupInfo
getGroup()
The information about the membership group.java.lang.String
getInitials()
Never set.boolean
getIsInherited()
True if the member has access from a parent folder.java.util.List<MemberPermission>
getPermissions()
The permissions that requesting user has on this member.int
hashCode()
static GroupMembershipInfo.Builder
newBuilder(AccessLevel accessType, GroupInfo group)
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.-
Methods inherited from class com.dropbox.core.v2.sharing.MembershipInfo
newBuilder
-
-
-
-
Field Detail
-
group
@Nonnull protected final GroupInfo group
-
-
Constructor Detail
-
GroupMembershipInfo
public GroupMembershipInfo(@Nonnull AccessLevel accessType, @Nonnull GroupInfo group, @Nullable java.util.List<MemberPermission> permissions, @Nullable java.lang.String initials, boolean isInherited)
The information about a group member of the shared content.Use
newBuilder(com.dropbox.core.v2.sharing.AccessLevel,com.dropbox.core.v2.sharing.GroupInfo)
to create instances of this class without specifying values for all optional fields.- Parameters:
accessType
- The access type for this member. It contains inherited access type from parent folder, and acquired access type from this folder. Must not benull
.group
- The information about the membership group. Must not benull
.permissions
- The permissions that requesting user has on this member. The set of permissions corresponds to the MemberActions in the request. Must not contain anull
item.initials
- Never set.isInherited
- True if the member has access from a parent folder.- Throws:
java.lang.IllegalArgumentException
- If any argument does not meet its preconditions.
-
GroupMembershipInfo
public GroupMembershipInfo(@Nonnull AccessLevel accessType, @Nonnull GroupInfo group)
The information about a group member of the shared content.The default values for unset fields will be used.
- Parameters:
accessType
- The access type for this member. It contains inherited access type from parent folder, and acquired access type from this folder. Must not benull
.group
- The information about the membership group. Must not benull
.- Throws:
java.lang.IllegalArgumentException
- If any argument does not meet its preconditions.
-
-
Method Detail
-
getAccessType
@Nonnull public AccessLevel getAccessType()
The access type for this member. It contains inherited access type from parent folder, and acquired access type from this folder.- Overrides:
getAccessType
in classMembershipInfo
- Returns:
- value for this field, never
null
.
-
getGroup
@Nonnull public GroupInfo getGroup()
The information about the membership group.- Returns:
- value for this field, never
null
.
-
getPermissions
@Nullable public java.util.List<MemberPermission> getPermissions()
The permissions that requesting user has on this member. The set of permissions corresponds to the MemberActions in the request.- Overrides:
getPermissions
in classMembershipInfo
- Returns:
- value for this field, or
null
if not present.
-
getInitials
@Nullable public java.lang.String getInitials()
Never set.- Overrides:
getInitials
in classMembershipInfo
- Returns:
- value for this field, or
null
if not present.
-
getIsInherited
public boolean getIsInherited()
True if the member has access from a parent folder.- Overrides:
getIsInherited
in classMembershipInfo
- Returns:
- value for this field, or
null
if not present. Defaults to false.
-
newBuilder
public static GroupMembershipInfo.Builder newBuilder(AccessLevel accessType, GroupInfo group)
Returns a new builder for creating an instance of this class.- Parameters:
accessType
- The access type for this member. It contains inherited access type from parent folder, and acquired access type from this folder. Must not benull
.group
- The information about the membership group. Must not benull
.- Returns:
- builder for this class.
- Throws:
java.lang.IllegalArgumentException
- If any argument does not meet its preconditions.
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classMembershipInfo
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classMembershipInfo
-
toString
public java.lang.String toString()
- Overrides:
toString
in classMembershipInfo
-
toStringMultiline
public java.lang.String toStringMultiline()
Returns a String representation of this object formatted for easier readability.The returned String may contain newlines.
- Overrides:
toStringMultiline
in classMembershipInfo
- Returns:
- Formatted, multiline String representation of this object
-
-