Class NamespaceMetadata

java.lang.Object
com.dropbox.core.v2.team.NamespaceMetadata

public class NamespaceMetadata extends Object
Properties of a namespace.
  • Field Details

    • name

      @Nonnull protected final String name
    • namespaceId

      @Nonnull protected final String namespaceId
    • namespaceType

      @Nonnull protected final NamespaceType namespaceType
    • teamMemberId

      @Nullable protected final String teamMemberId
    • quotaLimit

      protected final long quotaLimit
  • Constructor Details

    • NamespaceMetadata

      public NamespaceMetadata(@Nonnull String name, @Nonnull String namespaceId, @Nonnull NamespaceType namespaceType, @Nullable String teamMemberId, long quotaLimit)
      Properties of a namespace.

      Use newBuilder(java.lang.String,java.lang.String,com.dropbox.core.v2.team.NamespaceType) to create instances of this class without specifying values for all optional fields.

      Parameters:
      name - The name of this namespace. Must not be null.
      namespaceId - The ID of this namespace. Must match pattern " [-_0-9a-zA-Z:]+" and not be null.
      namespaceType - The type of this namespace. Must not be null.
      teamMemberId - If this is a team member or app folder, the ID of the owning team member. Otherwise, this field is not present.
      quotaLimit - The quota limit in bytes for this namespace tree. Only applicable to team folders.
      Throws:
      IllegalArgumentException - If any argument does not meet its preconditions.
    • NamespaceMetadata

      public NamespaceMetadata(@Nonnull String name, @Nonnull String namespaceId, @Nonnull NamespaceType namespaceType)
      Properties of a namespace.

      The default values for unset fields will be used.

      Parameters:
      name - The name of this namespace. Must not be null.
      namespaceId - The ID of this namespace. Must match pattern " [-_0-9a-zA-Z:]+" and not be null.
      namespaceType - The type of this namespace. Must not be null.
      Throws:
      IllegalArgumentException - If any argument does not meet its preconditions.
  • Method Details

    • getName

      @Nonnull public String getName()
      The name of this namespace.
      Returns:
      value for this field, never null.
    • getNamespaceId

      @Nonnull public String getNamespaceId()
      The ID of this namespace.
      Returns:
      value for this field, never null.
    • getNamespaceType

      @Nonnull public NamespaceType getNamespaceType()
      The type of this namespace.
      Returns:
      value for this field, never null.
    • getTeamMemberId

      @Nullable public String getTeamMemberId()
      If this is a team member or app folder, the ID of the owning team member. Otherwise, this field is not present.
      Returns:
      value for this field, or null if not present.
    • getQuotaLimit

      public long getQuotaLimit()
      The quota limit in bytes for this namespace tree. Only applicable to team folders.
      Returns:
      value for this field, or null if not present. Defaults to 0L.
    • newBuilder

      public static NamespaceMetadata.Builder newBuilder(String name, String namespaceId, NamespaceType namespaceType)
      Returns a new builder for creating an instance of this class.
      Parameters:
      name - The name of this namespace. Must not be null.
      namespaceId - The ID of this namespace. Must match pattern " [-_0-9a-zA-Z:]+" and not be null.
      namespaceType - The type of this namespace. Must not be null.
      Returns:
      builder for this class.
      Throws:
      IllegalArgumentException - If any argument does not meet its preconditions.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toStringMultiline

      public String toStringMultiline()
      Returns a String representation of this object formatted for easier readability.

      The returned String may contain newlines.

      Returns:
      Formatted, multiline String representation of this object