com.independentsoft.exchange

## Class Permission

- java.lang.Object
- - com.independentsoft.exchange.Permission

-     public class Permission
      extends java.lang.Object

  Defines the access that a user has to a folder.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Permission()` Initializes a new instance of the Permission class.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `canCreateItems()` Gets whether a user has permission to create items in a folder.
    `boolean` | `canCreateSubFolders()` Gets whether a user has permission to create subfolders in a folder.
    `PermissionAction` | `getDeleteItems()` Gets whether a user has permission to delete items in a folder.
    `PermissionAction` | `getEditItems()` Gets whether a user has permission to edit items in a folder.
    `PermissionLevel` | `getLevel()` Gets the combination of permissions that a user has on a folder.
    `PermissionReadAccess` | `getReadItems()` Gets whether a user has permission to read items within a folder.
    `UserId` | `getUserId()` Gets a delegate user or a user who has folder access permissions.
    `boolean` | `isFolderContact()` Gets whether a user is a contact for a folder.
    `boolean` | `isFolderOwner()` Gets whether a user is the owner of a folder.
    `boolean` | `isFolderVisible()` Gets whether a user can view a folder.
    `void` | `setCanCreateItems(boolean canCreateItems)` Gets whether a user has permission to create items in a folder.
    `void` | `setCanCreateSubFolders(boolean canCreateSubFolders)` Sets whether a user has permission to create subfolders in a folder.
    `void` | `setDeleteItems(PermissionAction deleteItems)` Sets whether a user has permission to delete items in a folder.
    `void` | `setEditItems(PermissionAction editItems)` Sets whether a user has permission to edit items in a folder.
    `void` | `setFolderContact(boolean isFolderContact)` Sets whether a user is a contact for a folder.
    `void` | `setFolderOwner(boolean isFolderOwner)` Sets whether a user is the owner of a folder.
    `void` | `setFolderVisible(boolean isFolderVisible)` Sets whether a user can view a folder.
    `void` | `setLevel(PermissionLevel level)` Sets the combination of permissions that a user has on a folder.
    `void` | `setReadItems(PermissionReadAccess readItems)` Sets whether a user has permission to read items within a folder.
    `void` | `setUserId(UserId userId)` Sets a delegate user or a user who has folder access permissions.
    `java.lang.String` | `toString()` Converts the value of the current Permission object to its equivalent string representation.

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### Permission

          public Permission()

      Initializes a new instance of the Permission class.

  - ### Method Detail

    - #### toString

          public java.lang.String toString()

      Converts the value of the current Permission object to its equivalent string representation.
      Overrides:
        `toString` in class `java.lang.Object`
      Returns:
        the string

    - #### getUserId

          public UserId getUserId()

      Gets a delegate user or a user who has folder access permissions.
      Returns:
        the user id

    - #### setUserId

          public void setUserId(UserId userId)

      Sets a delegate user or a user who has folder access permissions.
      Parameters:
        `userId` - the new user id

    - #### canCreateItems

          public boolean canCreateItems()

      Gets whether a user has permission to create items in a folder.
      Returns:
        true, if successful

    - #### setCanCreateItems

          public void setCanCreateItems(boolean canCreateItems)

      Gets whether a user has permission to create items in a folder.
      Parameters:
        `canCreateItems` - the new can create items

    - #### canCreateSubFolders

          public boolean canCreateSubFolders()

      Gets whether a user has permission to create subfolders in a folder.
      Returns:
        true, if successful

    - #### setCanCreateSubFolders

          public void setCanCreateSubFolders(boolean canCreateSubFolders)

      Sets whether a user has permission to create subfolders in a folder.
      Parameters:
        `canCreateSubFolders` - the new can create sub folders

    - #### isFolderOwner

          public boolean isFolderOwner()

      Gets whether a user is the owner of a folder.
      Returns:
        true, if is folder owner

    - #### setFolderOwner

          public void setFolderOwner(boolean isFolderOwner)

      Sets whether a user is the owner of a folder.
      Parameters:
        `isFolderOwner` - the new folder owner

    - #### isFolderVisible

          public boolean isFolderVisible()

      Gets whether a user can view a folder.
      Returns:
        true, if is folder visible

    - #### setFolderVisible

          public void setFolderVisible(boolean isFolderVisible)

      Sets whether a user can view a folder.
      Parameters:
        `isFolderVisible` - the new folder visible

    - #### isFolderContact

          public boolean isFolderContact()

      Gets whether a user is a contact for a folder.
      Returns:
        true, if is folder contact

    - #### setFolderContact

          public void setFolderContact(boolean isFolderContact)

      Sets whether a user is a contact for a folder.
      Parameters:
        `isFolderContact` - the new folder contact

    - #### getEditItems

          public PermissionAction getEditItems()

      Gets whether a user has permission to edit items in a folder.
      Returns:
        the edits the items

    - #### setEditItems

          public void setEditItems(PermissionAction editItems)

      Sets whether a user has permission to edit items in a folder.
      Parameters:
        `editItems` - the new edits the items

    - #### getDeleteItems

          public PermissionAction getDeleteItems()

      Gets whether a user has permission to delete items in a folder.
      Returns:
        the delete items

    - #### setDeleteItems

          public void setDeleteItems(PermissionAction deleteItems)

      Sets whether a user has permission to delete items in a folder.
      Parameters:
        `deleteItems` - the new delete items

    - #### getReadItems

          public PermissionReadAccess getReadItems()

      Gets whether a user has permission to read items within a folder.
      Returns:
        the read items

    - #### setReadItems

          public void setReadItems(PermissionReadAccess readItems)

      Sets whether a user has permission to read items within a folder.
      Parameters:
        `readItems` - the new read items

    - #### getLevel

          public PermissionLevel getLevel()

      Gets the combination of permissions that a user has on a folder.
      Returns:
        the level

    - #### setLevel

          public void setLevel(PermissionLevel level)

      Sets the combination of permissions that a user has on a folder.
      Parameters:
        `level` - the new level