Package com.orchestranetworks.instance

# Class HomeCreationSpec

java.lang.Object
com.orchestranetworks.instance.HomeCreationSpec

public class HomeCreationSpec extends Object
Specifies the features of a dataspace or snapshot to be created.

See Also:
  - `Repository.createHome(HomeCreationSpec, Session)`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `HomeCreationSpec()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `UserMessage`
  `getDescription()`
  `AdaptationHome`
  `getHomeToCopyPermissionsFrom()`
  `HomeKey`
  `getKey()`
  `UserMessage`
  `getLabel()`
  `Profile`
  `getOwner()`
  `AdaptationHome`
  `getParent()`
  `boolean`
  `isCopyParentValidationReports()`
  Indicates if the validation reports of the datasets contained in the parent dataspace are copied during the creation of the new dataspace.
  `boolean`
  `isRelationalModeDataSpace()`
  Deprecated.
  since 6.0.
  `void`
  `setCopyParentValidationReports(boolean copyValidationReports)`
  Specifies whether the validation reports of the datasets contained in the parent dataspace must by copied in the child to be created.
  `void`
  `setDescription(UserMessage description)`
  Specifies a description for the dataspace or snapshot to be created.
  `void`
  `setHomeToCopyPermissionsFrom(AdaptationHome aDataSpace)`
  Specifies that the permissions of the dataspace to be created will be a copy of those of the specified dataspace.
  `void`
  `setKey(HomeKey aDataSpaceOrSnapshotKey)`
  Specifies the unique identifier of the dataspace or snapshot to be created.
  `void`
  `setLabel(UserMessage label)`
  Specifies the label of the dataspace or snapshot to create.
  `void`
  `setOwner(Profile anOwner)`
  Specifies the owner of the dataspace or snapshot to be created.
  `void`
  `setParent(AdaptationHome aDataSpace)`
  Specifies the parent dataspace of the new dataspace or snapshot to be created.
  `void`
  `setRelationalModeDataSpace(boolean isRelationalModeDataSpace)`
  Deprecated.
  since 6.0.
  `String`
  `toString()`

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

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

- ## Constructor Details

  - ### HomeCreationSpec

    public HomeCreationSpec()

- ## Method Details

  - ### getKey

    public HomeKey getKey()
    See Also:
      - `setKey(HomeKey)`

  - ### setKey

    public void setKey(HomeKey aDataSpaceOrSnapshotKey)
    Specifies the unique identifier of the dataspace or snapshot to be created.

    This parameter is mandatory.

    Throws:
      `IllegalArgumentException` - if the specified identifier is `null`, if its name's length exceeds `HomeKey.MAX_KEY_LENGTH`, or if its name does not match `HomeKey.KEY_PATTERN_COMPILED`

  - ### getParent

    public AdaptationHome getParent()
    See Also:
      - `setParent(AdaptationHome)`

  - ### setParent

    public void setParent(AdaptationHome aDataSpace)
    Specifies the parent dataspace of the new dataspace or snapshot to be created.

    This parameter is mandatory.

    Throws:
      `IllegalArgumentException` - If the dataspace specified is a snapshot (currently, dataspaces and snapshots must be created from a parent dataspace).

  - ### getOwner

    public Profile getOwner()
    See Also:
      - `setOwner(Profile)`

  - ### setOwner

    public void setOwner(Profile anOwner)
    Specifies the owner of the dataspace or snapshot to be created.

    This parameter is mandatory.

    Throws:
      `IllegalArgumentException` - If owner specified is `null`.

  - ### getLabel

    public UserMessage getLabel()
    See Also:
      - `setLabel(UserMessage)`

  - ### setLabel

    public void setLabel(UserMessage label)
    Specifies the label of the dataspace or snapshot to create.

    If no label is specified, the `dataspace or snapshot key` is displayed to the end-user.

    See Also:
      - `AdaptationHome.getLabel()`

  - ### getDescription

    public UserMessage getDescription()
    See Also:
      - `setDescription(UserMessage)`

  - ### setDescription

    public void setDescription(UserMessage description)
    Specifies a description for the dataspace or snapshot to be created.

    This possibly internationalized text is displayed in EBX® user interface when the user accesses the dataspace or snapshot.

    See Also:
      - `AdaptationHome.getDescription()`

  - ### getHomeToCopyPermissionsFrom

    public AdaptationHome getHomeToCopyPermissionsFrom()
    See Also:
      - `setHomeToCopyPermissionsFrom(AdaptationHome)`

  - ### setHomeToCopyPermissionsFrom

    public void setHomeToCopyPermissionsFrom(AdaptationHome aDataSpace)
    Specifies that the permissions of the dataspace to be created will be a copy of those of the specified dataspace.

    If this method is not called, the permissions of the new dataspace will be determined from the Permissions of child dataspace when created defined in the permissions of the parent dataspace. If the current user of the session has one or several roles restricted by the restriction policy node, the most restrictive permissions will be applied. If no restrictions are defined for the current user, the least restrictive permissions will be applied.

    This method is ignored for snapshots, as they do not have compatible permissions.

    Throws:
      `IllegalArgumentException` - If specified source is a snapshot (only dataspaces can be used as a source for permissions, as snapshots do not have compatible permissions.

  - ### isRelationalModeDataSpace

    @Deprecated public boolean isRelationalModeDataSpace()
    Deprecated.
    since 6.0. Relational mode is obsolete.
    Returns false.
    See Also:
      - `setRelationalModeDataSpace(boolean)`

  - ### setRelationalModeDataSpace

    @Deprecated public void setRelationalModeDataSpace(boolean isRelationalModeDataSpace)
    Deprecated.
    since 6.0. Relational mode is obsolete.
    Indicates that this dataspace is relational. That is, all datasets contained in this home are in relational mode.
    See Also:
      - `isRelationalModeDataSpace()`

  - ### setCopyParentValidationReports

    public void setCopyParentValidationReports(boolean copyValidationReports)
    Specifies whether the validation reports of the datasets contained in the parent dataspace must by copied in the child to be created.

    By default, the validation reports from the parent dataspace are copied.

    Performance note: Avoiding the copy of the validation reports allows to prevent any delay on dataspace creation due to a concurrent validation process. As a counterpart, the created dataspace will start with an empty validation report.

    Parameters:
      `copyValidationReports` - if `false`, the validation reports of datasets contained in the parent dataspace won't be copied when creating the child dataspace. As a consequence, the datasets contained in the child dataspace will be fully validated the first time a validation report will be requested. if `true`, the validation reports of datasets contained in the parent dataspace will be copied when creating the child dataspace. The validation reports of the datasets contained in the child dataspace will be up-to-date.
    Since:
      5.8.1
    See Also:
      - `Adaptation.getValidationReport()`

  - ### isCopyParentValidationReports

    public boolean isCopyParentValidationReports()
    Indicates if the validation reports of the datasets contained in the parent dataspace are copied during the creation of the new dataspace.
    Since:
      5.8.1
    See Also:
      - `setCopyParentValidationReports(boolean)`

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`