From a1b36d9ab0186ef1b7a95c88e37ea6f01473a509 Mon Sep 17 00:00:00 2001
From: pkupczyk <pkupczyk>
Date: Mon, 7 Dec 2015 13:20:14 +0000
Subject: [PATCH] SSDM-2783

SVN: 35225
---
 .../dto/{entity => }/attachment/Attachment.js |   2 +-
 .../create}/AttachmentCreation.js             |   2 +-
 .../fetchoptions/AttachmentFetchOptions.js    |  71 ++++++++++
 .../fetchoptions}/AttachmentSortOptions.js    |   4 +-
 .../dto/attachment/id/AttachmentFileName.js   |  48 +++++++
 .../api/v3/dto/attachment/id/IAttachmentId.js |  11 ++
 .../update}/AttachmentListUpdateValue.js      |   4 +-
 .../{ => common}/fetchoptions/CacheMode.js    |   0
 .../fetchoptions/EmptyFetchOptions.js         |   4 +-
 .../fetchoptions}/EntitySortOptions.js        |   4 +-
 .../EntityWithPropertiesSortOptions.js        |   4 +-
 .../{ => common}/fetchoptions/FetchOptions.js |   4 +-
 .../fetchoptions}/SortOptions.js              |   4 +-
 .../sort => common/fetchoptions}/SortOrder.js |   2 +-
 .../sort => common/fetchoptions}/Sorting.js   |   2 +-
 .../api/v3/dto/common/id/CreationId.js        |  47 ++++++
 .../api/v3/dto/common/id/IObjectId.js         |  11 ++
 .../api/v3/dto/common/id/ObjectIdentifier.js  |  49 +++++++
 .../api/v3/dto/common/id/ObjectPermId.js      |  56 ++++++++
 .../v3/dto/{ => common}/id/ObjectTechId.js    |   7 +-
 .../dto/{ => common}/operation/IOperation.js  |   0
 .../operation/IOperationResult.js             |   0
 .../search/AbstractCompositeSearchCriteria.js |   4 +-
 .../search/AbstractDateObjectValue.js         |   4 +-
 .../{ => common}/search/AbstractDateValue.js  |   4 +-
 .../search/AbstractEntitySearchCriteria.js    |  85 +++++++++++
 .../search/AbstractFieldSearchCriteria.js     |   4 +-
 .../search/AbstractNumberValue.js             |   4 +-
 .../search/AbstractObjectSearchCriteria.js    |   4 +-
 .../search/AbstractSearchCriteria.js          |   4 +-
 .../search/AbstractStringValue.js             |   4 +-
 .../search/AbstractTimeZoneValue.js           |   2 +-
 .../dto/{ => common}/search/AbstractValue.js  |   2 +-
 .../search/AnyFieldSearchCriteria.js          |   4 +-
 .../search/AnyPropertySearchCriteria.js       |   4 +-
 .../dto/{ => common}/search/AnyStringValue.js |   4 +-
 .../{ => common}/search/CodeSearchCriteria.js |   4 +-
 .../search/DateEarlierThanOrEqualToValue.js   |   4 +-
 .../{ => common}/search/DateEqualToValue.js   |   4 +-
 .../search/DateFieldSearchCriteria.js         |  34 +++--
 .../search/DateLaterThanOrEqualToValue.js     |   4 +-
 .../DateObjectEarlierThanOrEqualToValue.js    |   4 +-
 .../search/DateObjectEqualToValue.js          |   4 +-
 .../DateObjectLaterThanOrEqualToValue.js      |   4 +-
 .../search/DatePropertySearchCriteria.js      |   4 +-
 .../api/v3/dto/{ => common}/search/IDate.js   |   0
 .../v3/dto/{ => common}/search/IDateFormat.js |   0
 .../{ => common}/search/ISearchCriteria.js    |   0
 .../v3/dto/{ => common}/search/ITimeZone.js   |   0
 .../{ => common}/search/IdSearchCriteria.js   |   4 +-
 .../dto/{ => common}/search/LongDateFormat.js |   4 +-
 .../search/ModificationDateSearchCriteria.js  |   4 +-
 .../{ => common}/search/NormalDateFormat.js   |   4 +-
 .../{ => common}/search/NumberEqualToValue.js |   4 +-
 .../search/NumberFieldSearchCriteria.js       |  19 ++-
 .../search/NumberGreaterThanOrEqualToValue.js |   4 +-
 .../search/NumberGreaterThanValue.js          |   4 +-
 .../search/NumberLessThanOrEqualToValue.js    |   4 +-
 .../search/NumberLessThanValue.js             |   4 +-
 .../search/NumberPropertySearchCriteria.js    |   4 +-
 .../search/PermIdSearchCriteria.js            |   4 +-
 .../search/RegistrationDateSearchCriteria.js  |   4 +-
 .../search/SearchCriteriaToStringBuilder.js   |   4 +-
 .../{ => common}/search/SearchFieldType.js    |   0
 .../dto/{ => common}/search/SearchOperator.js |   0
 .../dto/{ => common}/search/SearchResult.js   |   2 +-
 .../dto/{ => common}/search/ServerTimeZone.js |   4 +-
 .../{ => common}/search/ShortDateFormat.js    |   4 +-
 .../search/StringContainsValue.js             |   4 +-
 .../search/StringEndsWithValue.js             |   4 +-
 .../{ => common}/search/StringEqualToValue.js |   4 +-
 .../search/StringFieldSearchCriteria.js       |  18 ++-
 .../search/StringPropertySearchCriteria.js    |   4 +-
 .../search/StringStartsWithValue.js           |   4 +-
 .../search/TechIdSearchCriteria.js            |   4 +-
 .../v3/dto/{ => common}/search/TimeZone.js    |   4 +-
 .../update}/FieldUpdateValue.js               |   2 +-
 .../update}/IdListUpdateValue.js              |   4 +-
 .../update}/ListUpdateAction.js               |   2 +-
 .../update}/ListUpdateActionAdd.js            |   4 +-
 .../update}/ListUpdateActionRemove.js         |   4 +-
 .../update}/ListUpdateActionSet.js            |   4 +-
 .../update}/ListUpdateValue.js                |   8 +-
 .../{entity => }/dataset/ArchivingStatus.js   |   0
 .../v3/dto/{entity => }/dataset/Complete.js   |   0
 .../v3/dto/{entity => }/dataset/DataSet.js    |  36 ++++-
 .../dto/{entity => }/dataset/DataSetKind.js   |   0
 .../dto/{entity => }/dataset/DataSetType.js   |   2 +-
 .../{entity => }/dataset/FileFormatType.js    |   2 +-
 .../api/v3/dto/dataset/LinkedData.js          |  42 ++++++
 .../dto/{entity => }/dataset/LocatorType.js   |   2 +-
 .../dto/{entity => }/dataset/PhysicalData.js  |   2 +-
 .../dto/{entity => }/dataset/StorageFormat.js |   2 +-
 .../delete}/DataSetDeletionOptions.js         |   4 +-
 .../fetchoptions}/DataSetFetchOptions.js      |  62 +++++---
 .../fetchoptions}/DataSetSortOptions.js       |   4 +-
 .../fetchoptions}/DataSetTypeFetchOptions.js  |   6 +-
 .../fetchoptions}/DataSetTypeSortOptions.js   |   4 +-
 .../FileFormatTypeFetchOptions.js             |   6 +-
 .../FileFormatTypeSortOptions.js              |   4 +-
 .../fetchoptions/LinkedDataFetchOptions.js    |  42 ++++++
 .../fetchoptions/LinkedDataSortOptions.js     |  10 ++
 .../fetchoptions}/LocatorTypeFetchOptions.js  |   6 +-
 .../fetchoptions}/LocatorTypeSortOptions.js   |   4 +-
 .../fetchoptions}/PhysicalDataFetchOptions.js |  14 +-
 .../fetchoptions}/PhysicalDataSortOptions.js  |   4 +-
 .../StorageFormatFetchOptions.js              |   6 +-
 .../fetchoptions}/StorageFormatSortOptions.js |   4 +-
 .../history/DataSetRelationType.js            |   0
 .../api/v3/dto/dataset/id/DataSetPermId.js    |  19 +++
 .../v3/dto/dataset/id/FileFormatTypePermId.js |  19 +++
 .../api/v3/dto/dataset/id/IDataSetId.js       |  11 ++
 .../id}/IFileFormatTypeId.js                  |   2 +-
 .../dataset/search/DataSetSearchCriteria.js   | 133 +++++++++++++++++
 .../search/DataSetSearchRelation.js           |   0
 .../update}/DataSetUpdate.js                  |   4 +-
 .../v3/dto/dataset/update/LinkedDataUpdate.js |  36 +++++
 .../update}/PhysicalDataUpdate.js             |   4 +-
 .../api/v3/dto/datastore/DataStore.js         |  63 ++++++++
 .../fetchoptions/DataStoreFetchOptions.js     |  26 ++++
 .../fetchoptions/DataStoreSortOptions.js      |  10 ++
 .../v3/dto/datastore/id/DataStorePermId.js    |  20 +++
 .../api/v3/dto/datastore/id/IDataStoreId.js   |  11 ++
 .../deletion/AbstractObjectDeletionOptions.js |   2 +-
 .../{entity => }/deletion/DeletedObject.js    |   2 +-
 .../v3/dto/{entity => }/deletion/Deletion.js  |   2 +-
 .../DeletedObjectFetchOptions.js              |   4 +-
 .../fetchoptions}/DeletionFetchOptions.js     |   8 +-
 .../fetchoptions}/DeletionSortOptions.js      |   4 +-
 .../api/v3/dto/deletion/id/DeletionTechId.js  |  13 ++
 .../api/v3/dto/deletion/id/IDeletionId.js     |  11 ++
 .../v3/dto/entitytype/id/EntityTypePermId.js  |  19 +++
 .../api/v3/dto/entitytype/id/IEntityTypeId.js |  11 ++
 .../search/EntityTypeSearchCriteria.js        |  13 +-
 .../dto/{entity => }/experiment/Experiment.js |   2 +-
 .../{entity => }/experiment/ExperimentType.js |   2 +-
 .../create/CreateExperimentsOperation.js      |  17 +++
 .../CreateExperimentsOperationResult.js       |  17 +++
 .../create}/ExperimentCreation.js             |   2 +-
 .../delete}/ExperimentDeletionOptions.js      |   4 +-
 .../fetchoptions}/ExperimentFetchOptions.js   |  34 ++---
 .../fetchoptions}/ExperimentSortOptions.js    |   4 +-
 .../ExperimentTypeFetchOptions.js             |   6 +-
 .../ExperimentTypeSortOptions.js              |   4 +-
 .../history/ExperimentRelationType.js         |   0
 .../dto/experiment/id/ExperimentIdentifier.js |  20 +++
 .../v3/dto/experiment/id/ExperimentPermId.js  |  19 +++
 .../api/v3/dto/experiment/id/IExperimentId.js |  11 ++
 .../list}/ListExperimentsOperation.js         |   4 +-
 .../list}/ListExperimentsOperationResult.js   |   4 +-
 .../search/ExperimentSearchCriteria.js        |   9 +-
 .../search/NoExperimentSearchCriteria.js      |   4 +-
 .../search/SearchExperimentsOperation.js}     |   4 +-
 .../SearchExperimentsOperationResult.js}      |   4 +-
 .../update}/ExperimentUpdate.js               |   4 +-
 .../update}/UpdateExperimentsOperation.js     |   4 +-
 .../UpdateExperimentsOperationResult.js       |   4 +-
 .../api/v3/dto/externaldms/ExternalDms.js     |  54 +++++++
 .../fetchoptions/ExternalDmsFetchOptions.js   |  26 ++++
 .../fetchoptions/ExternalDmsSortOptions.js    |  10 ++
 .../dto/externaldms/id/ExternalDmsPermId.js   |  20 +++
 .../v3/dto/externaldms/id/IExternalDmsId.js   |  12 ++
 .../attachment/AttachmentFetchOptions.js      |  71 ----------
 .../vocabulary/VocabularyFetchOptions.js      |  42 ------
 .../dto/{entity => }/history/HistoryEntry.js  |   2 +-
 .../history/PropertyHistoryEntry.js           |   4 +-
 .../history/RelationHistoryEntry.js           |   4 +-
 .../fetchoptions}/HistoryEntryFetchOptions.js |   9 +-
 .../fetchoptions}/HistoryEntrySortOptions.js  |   4 +-
 .../resources/api/v3/dto/id/CreationId.js     |  46 ------
 .../resources/api/v3/dto/id/IObjectId.js      |  10 --
 .../api/v3/dto/id/ObjectIdentifier.js         |  46 ------
 .../resources/api/v3/dto/id/ObjectPermId.js   |  53 -------
 .../dto/id/attachment/AttachmentFileName.js   |  47 ------
 .../api/v3/dto/id/attachment/IAttachmentId.js |  10 --
 .../api/v3/dto/id/dataset/DataSetPermId.js    |  18 ---
 .../v3/dto/id/dataset/FileFormatTypePermId.js |  18 ---
 .../api/v3/dto/id/dataset/IDataSetId.js       |  10 --
 .../api/v3/dto/id/deletion/DeletionTechId.js  |  13 --
 .../api/v3/dto/id/deletion/IDeletionId.js     |  10 --
 .../v3/dto/id/entitytype/EntityTypePermId.js  |  18 ---
 .../api/v3/dto/id/entitytype/IEntityTypeId.js |  10 --
 .../dto/id/experiment/ExperimentIdentifier.js |  18 ---
 .../v3/dto/id/experiment/ExperimentPermId.js  |  18 ---
 .../api/v3/dto/id/experiment/IExperimentId.js |  10 --
 .../api/v3/dto/id/material/IMaterialId.js     |  10 --
 .../api/v3/dto/id/project/IProjectId.js       |  10 --
 .../v3/dto/id/project/ProjectIdentifier.js    |  18 ---
 .../api/v3/dto/id/project/ProjectPermId.js    |  18 ---
 .../api/v3/dto/id/sample/ISampleId.js         |  10 --
 .../api/v3/dto/id/sample/SampleIdentifier.js  |  18 ---
 .../api/v3/dto/id/sample/SamplePermId.js      |  18 ---
 .../resources/api/v3/dto/id/space/ISpaceId.js |  10 --
 .../api/v3/dto/id/space/SpacePermId.js        |  26 ----
 .../resources/api/v3/dto/id/tag/ITagId.js     |   8 --
 .../resources/api/v3/dto/id/tag/TagCode.js    |  48 -------
 .../resources/api/v3/dto/id/tag/TagPermId.js  |  18 ---
 .../v3/dto/{entity => }/material/Material.js  |   4 +-
 .../dto/{entity => }/material/MaterialType.js |   2 +-
 .../create}/MaterialCreation.js               |   2 +-
 .../delete}/MaterialDeletionOptions.js        |   4 +-
 .../fetchoptions}/MaterialFetchOptions.js     |  18 +--
 .../fetchoptions}/MaterialSortOptions.js      |   4 +-
 .../fetchoptions}/MaterialTypeFetchOptions.js |   6 +-
 .../fetchoptions}/MaterialTypeSortOptions.js  |   4 +-
 .../api/v3/dto/material/id/IMaterialId.js     |  11 ++
 .../id}/MaterialPermId.js                     |   4 +-
 .../search/MaterialSearchCriteria.js          |   4 +-
 .../update}/MaterialUpdate.js                 |   4 +-
 .../experiment/CreateExperimentsOperation.js  |  11 --
 .../CreateExperimentsOperationResult.js       |  11 --
 .../api/v3/dto/{entity => }/person/Person.js  |   2 +-
 .../fetchoptions}/PersonFetchOptions.js       |   8 +-
 .../fetchoptions}/PersonSortOptions.js        |   4 +-
 .../dto/{id/person => person/id}/IPersonId.js |   2 +-
 .../{id/person => person/id}/PersonPermId.js  |   4 +-
 .../v3/dto/{entity => }/project/Project.js    |   2 +-
 .../create}/ProjectCreation.js                |   2 +-
 .../delete}/ProjectDeletionOptions.js         |   4 +-
 .../fetchoptions}/ProjectFetchOptions.js      |  24 ++--
 .../fetchoptions}/ProjectSortOptions.js       |   4 +-
 .../history/ProjectRelationType.js}           |   4 +-
 .../api/v3/dto/project/id/IProjectId.js       |  11 ++
 .../v3/dto/project/id/ProjectIdentifier.js    |  19 +++
 .../api/v3/dto/project/id/ProjectPermId.js    |  19 +++
 .../search/NoProjectSearchCriteria.js         |   4 +-
 .../search/ProjectSearchCriteria.js           |  16 +--
 .../update}/ProjectUpdate.js                  |   4 +-
 .../fetchoptions}/PropertyFetchOptions.js     |   4 +-
 .../api/v3/dto/{entity => }/sample/Sample.js  |   2 +-
 .../v3/dto/{entity => }/sample/SampleType.js  |   2 +-
 .../create}/CreateSamplesOperation.js         |   4 +-
 .../create}/CreateSamplesResult.js            |   4 +-
 .../create}/SampleCreation.js                 |   2 +-
 .../delete}/SampleDeletionOptions.js          |   4 +-
 .../fetchoptions}/SampleFetchOptions.js       |  36 ++---
 .../fetchoptions}/SampleSortOptions.js        |   4 +-
 .../fetchoptions}/SampleTypeFetchOptions.js   |   6 +-
 .../fetchoptions}/SampleTypeSortOptions.js    |   4 +-
 .../history/SampleRelationType.js             |   0
 .../api/v3/dto/sample/id/ISampleId.js         |  11 ++
 .../api/v3/dto/sample/id/SampleIdentifier.js  |  20 +++
 .../api/v3/dto/sample/id/SamplePermId.js      |  19 +++
 .../search/NoSampleContainerSearchCriteria.js |   4 +-
 .../search/NoSampleSearchCriteria.js          |   4 +-
 .../search/SampleSearchCriteria.js            |  28 ++--
 .../search/SampleSearchRelation.js            |   0
 .../sample => sample/update}/SampleUpdate.js  |   4 +-
 .../update}/UpdateSamplesOperation.js         |   4 +-
 .../search/AbstractEntitySearchCriteria.js    |  86 -----------
 .../v3/dto/search/DataSetSearchCriteria.js    | 134 ------------------
 .../search/VocabularyFieldSearchCriteria.js   |  15 --
 .../VocabularyPropertySearchCriteria.js       |  18 ---
 .../api/v3/dto/{entity => }/space/Space.js    |   2 +-
 .../space => space/create}/SpaceCreation.js   |   2 +-
 .../delete}/SpaceDeletionOptions.js           |   4 +-
 .../fetchoptions}/SpaceFetchOptions.js        |  14 +-
 .../fetchoptions}/SpaceSortOptions.js         |   4 +-
 .../resources/api/v3/dto/space/id/ISpaceId.js |  11 ++
 .../api/v3/dto/space/id/SpacePermId.js        |  27 ++++
 .../{ => space}/search/SpaceSearchCriteria.js |  13 +-
 .../space => space/update}/SpaceUpdate.js     |   4 +-
 .../api/v3/dto/{entity => }/tag/Tag.js        |   2 +-
 .../fetchoptions}/TagFetchOptions.js          |   8 +-
 .../fetchoptions}/TagSortOptions.js           |   4 +-
 .../resources/api/v3/dto/tag/id/ITagId.js     |   9 ++
 .../resources/api/v3/dto/tag/id/TagCode.js    |  49 +++++++
 .../resources/api/v3/dto/tag/id/TagPermId.js  |  19 +++
 .../dto/{ => tag}/search/TagSearchCriteria.js |  13 +-
 .../dto/{entity => }/vocabulary/Vocabulary.js |   2 +-
 .../{entity => }/vocabulary/VocabularyTerm.js |   2 +-
 .../fetchoptions/VocabularyFetchOptions.js    |  42 ++++++
 .../fetchoptions}/VocabularySortOptions.js    |   4 +-
 .../VocabularyTermFetchOptions.js             |  12 +-
 .../VocabularyTermSortOptions.js              |   4 +-
 .../api/v3/dto/vocabulary/id/IVocabularyId.js |   9 ++
 .../v3/dto/vocabulary/id/IVocabularyTermId.js |   9 ++
 .../v3/dto/vocabulary/id/VocabularyPermId.js  |  19 +++
 .../dto/vocabulary/id/VocabularyTermCode.js   |  48 +++++++
 279 files changed, 1955 insertions(+), 1435 deletions(-)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/attachment/Attachment.js (98%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/attachment => attachment/create}/AttachmentCreation.js (93%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/fetchoptions/AttachmentFetchOptions.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/attachment => attachment/fetchoptions}/AttachmentSortOptions.js (60%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/AttachmentFileName.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/IAttachmentId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => attachment/update}/AttachmentListUpdateValue.js (72%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/fetchoptions/CacheMode.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/fetchoptions/EmptyFetchOptions.js (60%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sort => common/fetchoptions}/EntitySortOptions.js (84%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sort => common/fetchoptions}/EntityWithPropertiesSortOptions.js (74%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/fetchoptions/FetchOptions.js (83%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sort => common/fetchoptions}/SortOptions.js (75%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sort => common/fetchoptions}/SortOrder.js (87%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sort => common/fetchoptions}/Sorting.js (87%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/CreationId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/IObjectId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectIdentifier.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectPermId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/id/ObjectTechId.js (81%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/operation/IOperation.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/operation/IOperationResult.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractCompositeSearchCriteria.js (84%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractDateObjectValue.js (64%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractDateValue.js (61%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractEntitySearchCriteria.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractFieldSearchCriteria.js (86%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractNumberValue.js (66%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractObjectSearchCriteria.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractSearchCriteria.js (61%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractStringValue.js (63%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractTimeZoneValue.js (77%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AbstractValue.js (90%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AnyFieldSearchCriteria.js (65%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AnyPropertySearchCriteria.js (65%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/AnyStringValue.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/CodeSearchCriteria.js (65%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DateEarlierThanOrEqualToValue.js (72%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DateEqualToValue.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DateFieldSearchCriteria.js (61%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DateLaterThanOrEqualToValue.js (72%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DateObjectEarlierThanOrEqualToValue.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DateObjectEqualToValue.js (69%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DateObjectLaterThanOrEqualToValue.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/DatePropertySearchCriteria.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/IDate.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/IDateFormat.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/ISearchCriteria.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/ITimeZone.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/IdSearchCriteria.js (83%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/LongDateFormat.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/ModificationDateSearchCriteria.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NormalDateFormat.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NumberEqualToValue.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NumberFieldSearchCriteria.js (53%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NumberGreaterThanOrEqualToValue.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NumberGreaterThanValue.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NumberLessThanOrEqualToValue.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NumberLessThanValue.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/NumberPropertySearchCriteria.js (66%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/PermIdSearchCriteria.js (65%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/RegistrationDateSearchCriteria.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/SearchCriteriaToStringBuilder.js (88%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/SearchFieldType.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/SearchOperator.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/SearchResult.js (89%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/ServerTimeZone.js (57%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/ShortDateFormat.js (69%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/StringContainsValue.js (69%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/StringEndsWithValue.js (69%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/StringEqualToValue.js (69%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/StringFieldSearchCriteria.js (53%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/StringPropertySearchCriteria.js (66%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/StringStartsWithValue.js (69%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/TechIdSearchCriteria.js (65%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => common}/search/TimeZone.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => common/update}/FieldUpdateValue.js (92%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => common/update}/IdListUpdateValue.js (73%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => common/update}/ListUpdateAction.js (87%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => common/update}/ListUpdateActionAdd.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => common/update}/ListUpdateActionRemove.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => common/update}/ListUpdateActionSet.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => common/update}/ListUpdateValue.js (79%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/ArchivingStatus.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/Complete.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/DataSet.js (88%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/DataSetKind.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/DataSetType.js (96%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/FileFormatType.js (94%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/LinkedData.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/LocatorType.js (94%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/PhysicalData.js (98%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/dataset/StorageFormat.js (94%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/deletion/dataset => dataset/delete}/DataSetDeletionOptions.js (63%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/DataSetFetchOptions.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/DataSetSortOptions.js (59%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/DataSetTypeFetchOptions.js (68%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/DataSetTypeSortOptions.js (60%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/FileFormatTypeFetchOptions.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/FileFormatTypeSortOptions.js (61%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataFetchOptions.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataSortOptions.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/LocatorTypeFetchOptions.js (68%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/LocatorTypeSortOptions.js (60%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/PhysicalDataFetchOptions.js (72%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/PhysicalDataSortOptions.js (60%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/StorageFormatFetchOptions.js (68%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/dataset => dataset/fetchoptions}/StorageFormatSortOptions.js (61%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => dataset}/history/DataSetRelationType.js (100%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/DataSetPermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/FileFormatTypePermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/IDataSetId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{id/dataset => dataset/id}/IFileFormatTypeId.js (76%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/search/DataSetSearchCriteria.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => dataset}/search/DataSetSearchRelation.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/dataset => dataset/update}/DataSetUpdate.js (93%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/LinkedDataUpdate.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/dataset => dataset/update}/PhysicalDataUpdate.js (78%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/DataStore.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreFetchOptions.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreSortOptions.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/DataStorePermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/IDataStoreId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/deletion/AbstractObjectDeletionOptions.js (85%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/deletion/DeletedObject.js (85%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/deletion/Deletion.js (96%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/deletion => deletion/fetchoptions}/DeletedObjectFetchOptions.js (63%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/deletion => deletion/fetchoptions}/DeletionFetchOptions.js (68%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/deletion => deletion/fetchoptions}/DeletionSortOptions.js (59%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/DeletionTechId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/IDeletionId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/EntityTypePermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/IEntityTypeId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => entitytype}/search/EntityTypeSearchCriteria.js (56%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/experiment/Experiment.js (99%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/experiment/ExperimentType.js (95%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperation.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperationResult.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/experiment => experiment/create}/ExperimentCreation.js (96%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/deletion/experiment => experiment/delete}/ExperimentDeletionOptions.js (62%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/experiment => experiment/fetchoptions}/ExperimentFetchOptions.js (76%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/experiment => experiment/fetchoptions}/ExperimentSortOptions.js (60%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/experiment => experiment/fetchoptions}/ExperimentTypeFetchOptions.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/experiment => experiment/fetchoptions}/ExperimentTypeSortOptions.js (61%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => experiment}/history/ExperimentRelationType.js (100%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentIdentifier.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentPermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/IExperimentId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/experiment => experiment/list}/ListExperimentsOperation.js (58%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/experiment => experiment/list}/ListExperimentsOperationResult.js (58%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => experiment}/search/ExperimentSearchCriteria.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => experiment}/search/NoExperimentSearchCriteria.js (61%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/experiment/SearchForExperimentsOperation.js => experiment/search/SearchExperimentsOperation.js} (59%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/experiment/SearchForExperimentsOperationResult.js => experiment/search/SearchExperimentsOperationResult.js} (59%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/experiment => experiment/update}/ExperimentUpdate.js (85%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/experiment => experiment/update}/UpdateExperimentsOperation.js (58%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/experiment => experiment/update}/UpdateExperimentsOperationResult.js (58%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/ExternalDms.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsFetchOptions.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsSortOptions.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/ExternalDmsPermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/IExternalDmsId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/attachment/AttachmentFetchOptions.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyFetchOptions.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/history/HistoryEntry.js (95%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/history/PropertyHistoryEntry.js (78%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/history/RelationHistoryEntry.js (80%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/history => history/fetchoptions}/HistoryEntryFetchOptions.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/history => history/fetchoptions}/HistoryEntrySortOptions.js (60%)
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/CreationId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/IObjectId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectIdentifier.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectPermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/AttachmentFileName.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/IAttachmentId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/DataSetPermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/FileFormatTypePermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/IDataSetId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/DeletionTechId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/IDeletionId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/EntityTypePermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/IEntityTypeId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentIdentifier.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentPermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/IExperimentId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/material/IMaterialId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/IProjectId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectIdentifier.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectPermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/ISampleId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SampleIdentifier.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SamplePermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/ISpaceId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/SpacePermId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/ITagId.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagCode.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagPermId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/material/Material.js (98%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/material/MaterialType.js (96%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/material => material/create}/MaterialCreation.js (96%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/deletion/material => material/delete}/MaterialDeletionOptions.js (63%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/material => material/fetchoptions}/MaterialFetchOptions.js (78%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/material => material/fetchoptions}/MaterialSortOptions.js (59%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/material => material/fetchoptions}/MaterialTypeFetchOptions.js (67%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/material => material/fetchoptions}/MaterialTypeSortOptions.js (60%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/id/IMaterialId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{id/material => material/id}/MaterialPermId.js (87%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => material}/search/MaterialSearchCriteria.js (78%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/material => material/update}/MaterialUpdate.js (84%)
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperation.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperationResult.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/person/Person.js (98%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/person => person/fetchoptions}/PersonFetchOptions.js (78%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/person => person/fetchoptions}/PersonSortOptions.js (58%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{id/person => person/id}/IPersonId.js (73%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{id/person => person/id}/PersonPermId.js (68%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/project/Project.js (98%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/project => project/create}/ProjectCreation.js (95%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/deletion/project => project/delete}/ProjectDeletionOptions.js (63%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/project => project/fetchoptions}/ProjectFetchOptions.js (76%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/project => project/fetchoptions}/ProjectSortOptions.js (59%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/deletion/DeletionType.js => project/history/ProjectRelationType.js} (63%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/IProjectId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectIdentifier.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectPermId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => project}/search/NoProjectSearchCriteria.js (61%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => project}/search/ProjectSearchCriteria.js (55%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/project => project/update}/ProjectUpdate.js (84%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/property => property/fetchoptions}/PropertyFetchOptions.js (62%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/sample/Sample.js (99%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/sample/SampleType.js (97%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/sample => sample/create}/CreateSamplesOperation.js (74%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/sample => sample/create}/CreateSamplesResult.js (72%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/sample => sample/create}/SampleCreation.js (98%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/deletion/sample => sample/delete}/SampleDeletionOptions.js (63%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sample => sample/fetchoptions}/SampleFetchOptions.js (79%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sample => sample/fetchoptions}/SampleSortOptions.js (58%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sample => sample/fetchoptions}/SampleTypeFetchOptions.js (70%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/sample => sample/fetchoptions}/SampleTypeSortOptions.js (60%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => sample}/history/SampleRelationType.js (100%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/ISampleId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SampleIdentifier.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SamplePermId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => sample}/search/NoSampleContainerSearchCriteria.js (62%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => sample}/search/NoSampleSearchCriteria.js (61%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => sample}/search/SampleSearchCriteria.js (72%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => sample}/search/SampleSearchRelation.js (100%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/sample => sample/update}/SampleUpdate.js (92%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{operation/sample => sample/update}/UpdateSamplesOperation.js (73%)
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractEntitySearchCriteria.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DataSetSearchCriteria.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyFieldSearchCriteria.js
 delete mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyPropertySearchCriteria.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/space/Space.js (98%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/space => space/create}/SpaceCreation.js (91%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/deletion/space => space/delete}/SpaceDeletionOptions.js (63%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/space => space/fetchoptions}/SpaceFetchOptions.js (75%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/space => space/fetchoptions}/SpaceSortOptions.js (58%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/ISpaceId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/SpacePermId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => space}/search/SpaceSearchCriteria.js (56%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity/space => space/update}/SpaceUpdate.js (80%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/tag/Tag.js (97%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/tag => tag/fetchoptions}/TagFetchOptions.js (71%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/tag => tag/fetchoptions}/TagSortOptions.js (57%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/ITagId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagCode.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagPermId.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{ => tag}/search/TagSearchCriteria.js (56%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/vocabulary/Vocabulary.js (96%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{entity => }/vocabulary/VocabularyTerm.js (97%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyFetchOptions.js
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/vocabulary => vocabulary/fetchoptions}/VocabularySortOptions.js (60%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/vocabulary => vocabulary/fetchoptions}/VocabularyTermFetchOptions.js (73%)
 rename openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/{fetchoptions/vocabulary => vocabulary/fetchoptions}/VocabularyTermSortOptions.js (61%)
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyTermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyPermId.js
 create mode 100644 openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyTermCode.js

diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/attachment/Attachment.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/Attachment.js
similarity index 98%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/attachment/Attachment.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/Attachment.js
index 38a5e4a74a9..adf1d9cdb91 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/attachment/Attachment.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/Attachment.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Attachment = function() {
 	};
 	stjs.extend(Attachment, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.attachment.Attachment';
+		prototype['@type'] = 'dto.attachment.Attachment';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.fileName = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/attachment/AttachmentCreation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/create/AttachmentCreation.js
similarity index 93%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/attachment/AttachmentCreation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/create/AttachmentCreation.js
index 753d0eb7a0b..1074f82ccf4 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/attachment/AttachmentCreation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/create/AttachmentCreation.js
@@ -5,7 +5,7 @@ define([ "stjs" ], function(stjs) {
 	var AttachmentCreation = function() {
 	};
 	stjs.extend(AttachmentCreation, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.attachment.AttachmentCreation';
+		prototype['@type'] = 'dto.attachment.create.AttachmentCreation';
 		constructor.serialVersionUID = 1;
 		prototype.fileName = null;
 		prototype.title = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/fetchoptions/AttachmentFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/fetchoptions/AttachmentFetchOptions.js
new file mode 100644
index 00000000000..63d2ee78eac
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/fetchoptions/AttachmentFetchOptions.js
@@ -0,0 +1,71 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/person/fetchoptions/PersonFetchOptions", "dto/common/fetchoptions/EmptyFetchOptions",
+		"dto/attachment/fetchoptions/AttachmentSortOptions" ], function(require, stjs, FetchOptions) {
+	var AttachmentFetchOptions = function() {
+	};
+	stjs.extend(AttachmentFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.attachment.fetchoptions.AttachmentFetchOptions';
+		constructor.serialVersionUID = 1;
+		prototype.registrator = null;
+		prototype.previousVersion = null;
+		prototype.content = null;
+		prototype.sort = null;
+		prototype.withRegistrator = function() {
+			if (this.registrator == null) {
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
+				this.registrator = new PersonFetchOptions();
+			}
+			return this.registrator;
+		};
+		prototype.withRegistratorUsing = function(fetchOptions) {
+			return this.registrator = fetchOptions;
+		};
+		prototype.hasRegistrator = function() {
+			return this.registrator != null;
+		};
+		prototype.withPreviousVersion = function() {
+			if (this.previousVersion == null) {
+				this.previousVersion = new AttachmentFetchOptions();
+			}
+			return this.previousVersion;
+		};
+		prototype.withPreviousVersionUsing = function(fetchOptions) {
+			return this.previousVersion = fetchOptions;
+		};
+		prototype.hasPreviousVersion = function() {
+			return this.previousVersion != null;
+		};
+		prototype.withContent = function() {
+			if (this.content == null) {
+				var EmptyFetchOptions = require("dto/common/fetchoptions/EmptyFetchOptions");
+				this.content = new EmptyFetchOptions();
+			}
+			return this.content;
+		};
+		prototype.withContentUsing = function(fetchOptions) {
+			return this.content = fetchOptions;
+		};
+		prototype.hasContent = function() {
+			return this.content != null;
+		};
+		prototype.sortBy = function() {
+			if (this.sort == null) {
+				var AttachmentSortOptions = require("dto/attachment/fetchoptions/AttachmentSortOptions");
+				this.sort = new AttachmentSortOptions();
+			}
+			return this.sort;
+		};
+		prototype.getSortBy = function() {
+			return this.sort;
+		};
+	}, {
+		registrator : "PersonFetchOptions",
+		previousVersion : "AttachmentFetchOptions",
+		content : "EmptyFetchOptions",
+		sort : "AttachmentSortOptions"
+	});
+	return AttachmentFetchOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/attachment/AttachmentSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/fetchoptions/AttachmentSortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/attachment/AttachmentSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/fetchoptions/AttachmentSortOptions.js
index 959969e81bf..cd09e84f0ef 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/attachment/AttachmentSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/fetchoptions/AttachmentSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var AttachmentSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(AttachmentSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.attachment.AttachmentSortOptions';
+		prototype['@type'] = 'dto.attachment.fetchoptions.AttachmentSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return AttachmentSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/AttachmentFileName.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/AttachmentFileName.js
new file mode 100644
index 00000000000..553a1bdf9a8
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/AttachmentFileName.js
@@ -0,0 +1,48 @@
+/**
+ * Attachment file name.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "util/Exceptions", "dto/attachment/id/IAttachmentId" ], function(stjs, exceptions, IAttachmentId) {
+	/**
+	 * @param fileName
+	 *            Attachment file name, e.g. "my_file.txt".
+	 */
+	var AttachmentFileName = function(fileName) {
+		this.setFileName(fileName);
+	};
+	stjs.extend(AttachmentFileName, null, [ IAttachmentId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.id.attachment.AttachmentFileName';
+		constructor.serialVersionUID = 1;
+		prototype.fileName = null;
+		prototype.getFileName = function() {
+			return this.fileName;
+		};
+		prototype.setFileName = function(fileName) {
+			if (fileName == null) {
+				throw new exceptions.IllegalArgumentException("File name cannot be null");
+			}
+			this.fileName = fileName;
+		};
+		prototype.toString = function() {
+			return this.getFileName();
+		};
+		prototype.hashCode = function() {
+			return ((this.getFileName() == null) ? 0 : this.getFileName().hashCode());
+		};
+		prototype.equals = function(obj) {
+			if (this == obj) {
+				return true;
+			}
+			if (obj == null) {
+				return false;
+			}
+			if (this.getClass() != obj.getClass()) {
+				return false;
+			}
+			var other = obj;
+			return this.getFileName() == null ? this.getFileName() == other.getFileName() : this.getFileName().equals(other.getFileName());
+		};
+	}, {});
+	return AttachmentFileName;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/IAttachmentId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/IAttachmentId.js
new file mode 100644
index 00000000000..f4ba8c1fc68
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/id/IAttachmentId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies an attachment in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IAttachmentId = function() {
+	};
+	stjs.extend(IAttachmentId, null, [ IObjectId ], null, {});
+	return IAttachmentId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/AttachmentListUpdateValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/update/AttachmentListUpdateValue.js
similarity index 72%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/AttachmentListUpdateValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/update/AttachmentListUpdateValue.js
index 6427735fa09..fc064fbde23 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/AttachmentListUpdateValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/attachment/update/AttachmentListUpdateValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/ListUpdateValue" ], function(stjs, ListUpdateValue) {
+define([ "stjs", "dto/common/update/ListUpdateValue" ], function(stjs, ListUpdateValue) {
 	var AttachmentListUpdateValue = function() {
 		ListUpdateValue.call(this);
 	};
 	stjs.extend(AttachmentListUpdateValue, ListUpdateValue, [ ListUpdateValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.AttachmentListUpdateValue';
+		prototype['@type'] = 'dto.attachment.update.AttachmentListUpdateValue';
 		constructor.serialVersionUID = 1;
 	}, {
 		actions : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/CacheMode.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/CacheMode.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/CacheMode.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/CacheMode.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/EmptyFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EmptyFetchOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/EmptyFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EmptyFetchOptions.js
index d6b127497c8..ec20845e714 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/EmptyFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EmptyFetchOptions.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/fetchoptions/FetchOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions" ], function(stjs, FetchOptions) {
 	var EmptyFetchOptions = function() {
 		FetchOptions.call(this);
 	};
 	stjs.extend(EmptyFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.EmptyFetchOptions';
+		prototype['@type'] = 'dto.common.fetchoptions.EmptyFetchOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return EmptyFetchOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/EntitySortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EntitySortOptions.js
similarity index 84%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/EntitySortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EntitySortOptions.js
index 665d45d821c..394606741b5 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/EntitySortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EntitySortOptions.js
@@ -1,4 +1,4 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var EntitySortOptions = function() {
 		SortOptions.call(this);
 	};
@@ -10,7 +10,7 @@ define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(requ
 	};
 
 	stjs.extend(EntitySortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sort.EntitySortOptions';
+		prototype['@type'] = 'dto.common.fetchoptions.EntitySortOptions';
 		constructor.serialVersionUID = 1;
 		prototype.code = function() {
 			return this.getOrCreateSorting(fields.CODE);
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/EntityWithPropertiesSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EntityWithPropertiesSortOptions.js
similarity index 74%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/EntityWithPropertiesSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EntityWithPropertiesSortOptions.js
index 96836842573..047e8fdb440 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/EntityWithPropertiesSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/EntityWithPropertiesSortOptions.js
@@ -1,4 +1,4 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/EntitySortOptions" ], function(require, stjs, EntitySortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/EntitySortOptions" ], function(require, stjs, EntitySortOptions) {
 	var EntityWithPropertiesSortOptions = function() {
 		EntitySortOptions.call(this);
 	};
@@ -8,7 +8,7 @@ define([ "require", "stjs", "dto/fetchoptions/sort/EntitySortOptions" ], functio
 	};
 
 	stjs.extend(EntityWithPropertiesSortOptions, EntitySortOptions, [ EntitySortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sort.EntityWithPropertiesSortOptions';
+		prototype['@type'] = 'dto.common.fetchoptions.EntityWithPropertiesSortOptions';
 		constructor.serialVersionUID = 1;
 
 		prototype.property = function(propertyName) {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/FetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/FetchOptions.js
similarity index 83%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/FetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/FetchOptions.js
index 2e99357c51a..a0f704e6063 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/FetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/FetchOptions.js
@@ -1,11 +1,11 @@
-define([ "stjs", "dto/fetchoptions/CacheMode" ], function(stjs, CacheMode) {
+define([ "stjs", "dto/common/fetchoptions/CacheMode" ], function(stjs, CacheMode) {
 	var FetchOptions = function() {
 		this._count = null;
 		this._from = null;
 		this._cacheMode = CacheMode.NO_CACHE;
 	};
 	stjs.extend(FetchOptions, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.FetchOptions';
+		prototype['@type'] = 'dto.common.fetchoptions.FetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.count = function(count) {
 			this._count = count;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/SortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/SortOptions.js
similarity index 75%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/SortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/SortOptions.js
index dc33bbac04c..94da9d200cf 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/SortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/SortOptions.js
@@ -1,10 +1,10 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOrder", "dto/fetchoptions/sort/Sorting" ], function(require, stjs, SortOrder, Sorting) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOrder", "dto/common/fetchoptions/Sorting" ], function(require, stjs, SortOrder, Sorting) {
 	var SortOptions = function() {
 		this.sortings = [];
 	};
 
 	stjs.extend(SortOptions, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sort.SortOptions';
+		prototype['@type'] = 'dto.common.fetchoptions.SortOptions';
 		constructor.serialVersionUID = 1;
 		prototype.getOrCreateSorting = function(field) {
 			var order = this.getSorting(field);
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/SortOrder.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/SortOrder.js
similarity index 87%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/SortOrder.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/SortOrder.js
index 03ebb024820..c9832de676a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/SortOrder.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/SortOrder.js
@@ -4,7 +4,7 @@ define([ "require", "stjs" ], function(require, stjs) {
 	};
 
 	stjs.extend(SortOrder, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sort.SortOrder';
+		prototype['@type'] = 'dto.common.fetchoptions.SortOrder';
 		constructor.serialVersionUID = 1;
 		prototype.asc = function() {
 			this._asc = true;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/Sorting.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/Sorting.js
similarity index 87%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/Sorting.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/Sorting.js
index a738fe4e863..fef14e8b0a6 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sort/Sorting.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/fetchoptions/Sorting.js
@@ -5,7 +5,7 @@ define([ "require", "stjs" ], function(require, stjs) {
 	};
 
 	stjs.extend(Sorting, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sort.Sorting';
+		prototype['@type'] = 'dto.common.fetchoptions.Sorting';
 		constructor.serialVersionUID = 1;
 		prototype.getField = function() {
 			return this.field;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/CreationId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/CreationId.js
new file mode 100644
index 00000000000..beb4f76c406
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/CreationId.js
@@ -0,0 +1,47 @@
+/**
+ * @author Jakub Straszewski
+ */
+define([ "stjs", "dto/sample/id/ISampleId", "dto/dataset/id/IDataSetId", "dto/experiment/id/IExperimentId", "dto/project/id/IProjectId", "dto/space/id/ISpaceId", "dto/material/id/IMaterialId" ],
+		function(stjs, ISampleId, IDataSetId, IExperimentId, IProjectId, ISpaceId, IMaterialId) {
+			var CreationId = function(creationId) {
+				this.creationId = creationId;
+			};
+			stjs.extend(CreationId, null, [ ISampleId, IDataSetId, IExperimentId, IProjectId, ISpaceId, IMaterialId ], function(constructor, prototype) {
+				prototype['@type'] = 'dto.common.id.CreationId';
+				constructor.serialVersionUID = 1;
+				prototype.creationId = null;
+				prototype.getCreationId = function() {
+					return this.creationId;
+				};
+				prototype.setCreationId = function(creationId) {
+					this.creationId = creationId;
+				};
+				prototype.toString = function() {
+					return this.getCreationId();
+				};
+				prototype.hashCode = function() {
+					return ((this.getCreationId() == null) ? 0 : this.getCreationId().hashCode());
+				};
+				prototype.equals = function(obj) {
+					if (this == obj) {
+						return true;
+					}
+					if (obj == null) {
+						return false;
+					}
+					if (this.getClass() != obj.getClass()) {
+						return false;
+					}
+					var other = obj;
+					if (this.getCreationId() == null) {
+						if (other.getCreationId() != null) {
+							return false;
+						}
+					} else if (!this.getCreationId().equals(other.getCreationId())) {
+						return false;
+					}
+					return true;
+				};
+			}, {});
+			return CreationId;
+		})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/IObjectId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/IObjectId.js
new file mode 100644
index 00000000000..6db51ef2463
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/IObjectId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies an object in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs" ], function(stjs) {
+	var IObjectId = function() {
+	};
+	stjs.extend(IObjectId, null, [], null, {});
+	return IObjectId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectIdentifier.js
new file mode 100644
index 00000000000..386a2596856
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectIdentifier.js
@@ -0,0 +1,49 @@
+/**
+ * Base class for ids that identify objects by identifiers. An identifier is a
+ * mutable user-defined string. An identifier is assigned to an object during
+ * the object creation but can change afterwards. An object's identifier is not
+ * guaranteed to be always the same, e.g. a sample identifier changes when the
+ * sample is moved to a different space.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "util/Exceptions", "dto/common/id/IObjectId" ], function(stjs, exceptions, IObjectId) {
+	var ObjectIdentifier = function(identifier) {
+		this.setIdentifier(identifier);
+	};
+	stjs.extend(ObjectIdentifier, null, [ IObjectId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.common.id.ObjectIdentifier';
+		constructor.serialVersionUID = 1;
+		prototype.identifier = null;
+		prototype.getIdentifier = function() {
+			return this.identifier;
+		};
+		prototype.setIdentifier = function(identifier) {
+			if (identifier == null) {
+				// throw new exceptions.IllegalArgumentException("Identifier id
+				// cannot be null");
+			}
+			this.identifier = identifier;
+		};
+		prototype.toString = function() {
+			return this.getIdentifier();
+		};
+		prototype.hashCode = function() {
+			return ((this.getIdentifier() == null) ? 0 : this.getIdentifier().hashCode());
+		};
+		prototype.equals = function(obj) {
+			if (this == obj) {
+				return true;
+			}
+			if (obj == null) {
+				return false;
+			}
+			if (this.getClass() != obj.getClass()) {
+				return false;
+			}
+			var other = obj;
+			return this.getIdentifier() == null ? this.getIdentifier() == other.getIdentifier() : this.getIdentifier().equals(other.getIdentifier());
+		};
+	}, {});
+	return ObjectIdentifier;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectPermId.js
new file mode 100644
index 00000000000..9034e996653
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectPermId.js
@@ -0,0 +1,56 @@
+/**
+ * Base class for ids that identify objects by a perm id. A perm id is an
+ * immutable system-generated string. A perm id is assigned to an object during
+ * the object creation and cannot be changed afterwards. An object's perm id is
+ * guaranteed to be always the same, e.g. a sample perm id remains the same even
+ * if the sample is moved to a different space.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "util/Exceptions", "dto/common/id/IObjectId" ], function(stjs, exceptions, IObjectId) {
+	var ObjectPermId = function(permId) {
+		this.setPermId(permId);
+	};
+	stjs.extend(ObjectPermId, null, [ IObjectId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.common.id.ObjectPermId';
+		constructor.serialVersionUID = 1;
+		prototype.permId = null;
+		prototype.getPermId = function() {
+			return this.permId;
+		};
+		prototype.setPermId = function(permId) {
+			if (permId == null) {
+				// TODO throw new exceptions.IllegalArgumentException("PermId
+				// cannot be null");
+			}
+			this.permId = permId;
+		};
+		prototype.toString = function() {
+			return this.getPermId();
+		};
+		prototype.hashCode = function() {
+			return ((this.getPermId() == null) ? 0 : this.getPermId().hashCode());
+		};
+		prototype.equals = function(obj) {
+			if (this == obj) {
+				return true;
+			}
+			if (obj == null) {
+				return false;
+			}
+			if (this.getClass() != obj.getClass()) {
+				return false;
+			}
+			var other = obj;
+			if (this.getPermId() == null) {
+				if (other.getPermId() != null) {
+					return false;
+				}
+			} else if (!this.getPermId().equals(other.getPermId())) {
+				return false;
+			}
+			return true;
+		};
+	}, {});
+	return ObjectPermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectTechId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectTechId.js
similarity index 81%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectTechId.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectTechId.js
index e78813baf7d..9979e6590e6 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectTechId.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/id/ObjectTechId.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "util/Exceptions", "dto/id/IObjectId" ], function(stjs, exceptions, IObjectId) {
+define([ "stjs", "util/Exceptions", "dto/common/id/IObjectId" ], function(stjs, exceptions, IObjectId) {
 	var ObjectTechId = function(techId) {
 		this.setTechId(techId);
 	};
 	stjs.extend(ObjectTechId, null, [ IObjectId ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.id.ObjectTechId';
+		prototype['@type'] = 'dto.common.id.ObjectTechId';
 		constructor.serialVersionUID = 1;
 		prototype.techId = null;
 		prototype.getTechId = function() {
@@ -14,7 +14,8 @@ define([ "stjs", "util/Exceptions", "dto/id/IObjectId" ], function(stjs, excepti
 		};
 		prototype.setTechId = function(techId) {
 			if (techId == null) {
-//				throw new exceptions.IllegalArgumentException("TechId cannot be null");
+				// throw new exceptions.IllegalArgumentException("TechId cannot
+				// be null");
 			}
 			this.techId = techId;
 		};
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/IOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/operation/IOperation.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/IOperation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/operation/IOperation.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/IOperationResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/operation/IOperationResult.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/IOperationResult.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/operation/IOperationResult.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractCompositeSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractCompositeSearchCriteria.js
similarity index 84%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractCompositeSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractCompositeSearchCriteria.js
index 2dab5fcad39..4813af98f9a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractCompositeSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractCompositeSearchCriteria.js
@@ -1,13 +1,13 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractSearchCriteria", "dto/search/SearchOperator" ], function(stjs, AbstractSearchCriteria, SearchOperator) {
+define([ "stjs", "dto/common/search/AbstractSearchCriteria", "dto/common/search/SearchOperator" ], function(stjs, AbstractSearchCriteria, SearchOperator) {
 	var AbstractCompositeSearchCriteria = function() {
 		AbstractSearchCriteria.call(this);
 		this.criteria = [];
 	};
 	stjs.extend(AbstractCompositeSearchCriteria, AbstractSearchCriteria, [ AbstractSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractCompositeSearchCriteria';
+		prototype['@type'] = 'dto.common.search.AbstractCompositeSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.operator = SearchOperator.AND;
 		prototype.getCriteria = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractDateObjectValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractDateObjectValue.js
similarity index 64%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractDateObjectValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractDateObjectValue.js
index cb6930ec8f7..e9eefbd4022 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractDateObjectValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractDateObjectValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractValue", "dto/search/IDate" ], function(stjs, AbstractValue, IDate) {
+define([ "stjs", "dto/common/search/AbstractValue", "dto/common/search/IDate" ], function(stjs, AbstractValue, IDate) {
 	var AbstractDateObjectValue = function(value) {
 		AbstractValue.call(this, value);
 	};
 	stjs.extend(AbstractDateObjectValue, AbstractValue, [ AbstractValue, IDate ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractDateObjectValue';
+		prototype['@type'] = 'dto.common.search.AbstractDateObjectValue';
 		constructor.serialVersionUID = 1;
 		prototype.getFormattedValue = function() {
 			return null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractDateValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractDateValue.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractDateValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractDateValue.js
index 49883f5ba00..01e69227b25 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractDateValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractDateValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractValue", "dto/search/IDate" ], function(stjs, AbstractValue, IDate) {
+define([ "stjs", "dto/common/search/AbstractValue", "dto/common/search/IDate" ], function(stjs, AbstractValue, IDate) {
 	var AbstractDateValue = function(value) {
 		AbstractValue.call(this, value);
 	};
 	stjs.extend(AbstractDateValue, AbstractValue, [ AbstractValue, IDate ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractDateValue';
+		prototype['@type'] = 'dto.common.search.AbstractDateValue';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return AbstractDateValue;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractEntitySearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractEntitySearchCriteria.js
new file mode 100644
index 00000000000..ae0114c7287
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractEntitySearchCriteria.js
@@ -0,0 +1,85 @@
+/**
+ * @author pkupczyk
+ */
+define(
+		[ "require", "stjs", "dto/common/search/AbstractObjectSearchCriteria", "dto/common/search/SearchOperator", "dto/common/search/CodeSearchCriteria",
+				"dto/entitytype/search/EntityTypeSearchCriteria", "dto/common/search/PermIdSearchCriteria", "dto/common/search/RegistrationDateSearchCriteria",
+				"dto/common/search/ModificationDateSearchCriteria", "dto/common/search/NumberPropertySearchCriteria", "dto/tag/search/TagSearchCriteria",
+				"dto/common/search/StringPropertySearchCriteria", "dto/common/search/DatePropertySearchCriteria", "dto/common/search/AnyPropertySearchCriteria",
+				"dto/common/search/AnyFieldSearchCriteria", "dto/common/search/AbstractCompositeSearchCriteria" ], function(require, stjs, AbstractObjectSearchCriteria, SearchOperator) {
+			var AbstractEntitySearchCriteria = function() {
+				AbstractObjectSearchCriteria.call(this);
+			};
+			stjs.extend(AbstractEntitySearchCriteria, AbstractObjectSearchCriteria, [ AbstractObjectSearchCriteria ], function(constructor, prototype) {
+				prototype['@type'] = 'dto.search.AbstractEntitySearchCriteria';
+				constructor.serialVersionUID = 1;
+				prototype.operator = SearchOperator.AND;
+				prototype.withOperator = function(anOperator) {
+					this.operator = anOperator;
+					return this;
+				};
+				prototype.getOperator = function() {
+					return this.operator;
+				};
+				prototype.withCode = function() {
+					var CodeSearchCriteria = require("dto/common/search/CodeSearchCriteria");
+					return this.addCriteria(new CodeSearchCriteria());
+				};
+				prototype.withType = function() {
+					var EntityTypeSearchCriteria = require("dto/entitytype/search/EntityTypeSearchCriteria");
+					return this.addCriteria(new EntityTypeSearchCriteria());
+				};
+				prototype.withPermId = function() {
+					var PermIdSearchCriteria = require("dto/common/search/PermIdSearchCriteria");
+					return this.addCriteria(new PermIdSearchCriteria());
+				};
+				prototype.withRegistrationDate = function() {
+					var RegistrationDateSearchCriteria = require("dto/common/search/RegistrationDateSearchCriteria");
+					return this.addCriteria(new RegistrationDateSearchCriteria());
+				};
+				prototype.withModificationDate = function() {
+					var ModificationDateSearchCriteria = require("dto/common/search/ModificationDateSearchCriteria");
+					return this.addCriteria(new ModificationDateSearchCriteria());
+				};
+				prototype.withNumberProperty = function(propertyName) {
+					var NumberPropertySearchCriteria = require("dto/common/search/NumberPropertySearchCriteria");
+					return this.addCriteria(new NumberPropertySearchCriteria(propertyName));
+				};
+				prototype.withTag = function() {
+					var TagSearchCriteria = require("dto/tag/search/TagSearchCriteria");
+					return this.addCriteria(new TagSearchCriteria());
+				};
+				prototype.withProperty = function(propertyName) {
+					var StringPropertySearchCriteria = require("dto/common/search/StringPropertySearchCriteria");
+					return this.addCriteria(new StringPropertySearchCriteria(propertyName));
+				};
+				prototype.withDateProperty = function(propertyName) {
+					var DatePropertySearchCriteria = require("dto/common/search/DatePropertySearchCriteria");
+					return this.addCriteria(new DatePropertySearchCriteria(propertyName));
+				};
+				prototype.withAnyProperty = function() {
+					var AnyPropertySearchCriteria = require("dto/common/search/AnyPropertySearchCriteria");
+					return this.addCriteria(new AnyPropertySearchCriteria());
+				};
+				prototype.withAnyField = function() {
+					var AnyFieldSearchCriteria = require("dto/common/search/AnyFieldSearchCriteria");
+					return this.addCriteria(new AnyFieldSearchCriteria());
+				};
+				prototype.createBuilder = function() {
+					var AbstractCompositeSearchCriteria = require("dto/common/search/AbstractCompositeSearchCriteria");
+					var builder = AbstractCompositeSearchCriteria.prototype.createBuilder.call(this);
+					builder.setOperator(this.operator);
+					return builder;
+				};
+			}, {
+				operator : {
+					name : "Enum",
+					arguments : [ "SearchOperator" ]
+				},
+				criteria : {
+					name : "Collection",
+					arguments : [ "ISearchCriteria" ]
+				}
+			});
+			return AbstractEntitySearchCriteria;
+		})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractFieldSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractFieldSearchCriteria.js
similarity index 86%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractFieldSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractFieldSearchCriteria.js
index f0d0874f5db..653e68c08f3 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractFieldSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractFieldSearchCriteria.js
@@ -1,11 +1,11 @@
-define([ "stjs", "dto/search/AbstractSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, AbstractSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/AbstractSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, AbstractSearchCriteria, SearchFieldType) {
 	var AbstractFieldSearchCriteria = function(fieldName, fieldType) {
 		AbstractSearchCriteria.call(this);
 		this.fieldName = fieldName;
 		this.fieldType = fieldType;
 	};
 	stjs.extend(AbstractFieldSearchCriteria, AbstractSearchCriteria, [ AbstractSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractFieldSearchCriteria';
+		prototype['@type'] = 'dto.common.search.AbstractFieldSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.fieldName = null;
 		prototype.fieldType = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractNumberValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractNumberValue.js
similarity index 66%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractNumberValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractNumberValue.js
index a82f2685c6c..1ce86732096 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractNumberValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractNumberValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractValue" ], function(stjs, AbstractValue) {
+define([ "stjs", "dto/common/search/AbstractValue" ], function(stjs, AbstractValue) {
 	var AbstractNumberValue = function(number) {
 		AbstractValue.call(this, number);
 	};
 	stjs.extend(AbstractNumberValue, AbstractValue, [ AbstractValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractNumberValue';
+		prototype['@type'] = 'dto.common.search.AbstractNumberValue';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return AbstractNumberValue;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractObjectSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractObjectSearchCriteria.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractObjectSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractObjectSearchCriteria.js
index 219dd9f37a7..7e5d1d346ae 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractObjectSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractObjectSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractCompositeSearchCriteria", "dto/search/IdSearchCriteria" ], function(stjs, AbstractCompositeSearchCriteria, IdSearchCriteria) {
+define([ "stjs", "dto/common/search/AbstractCompositeSearchCriteria", "dto/common/search/IdSearchCriteria" ], function(stjs, AbstractCompositeSearchCriteria, IdSearchCriteria) {
 	var AbstractObjectSearchCriteria = function() {
 		AbstractCompositeSearchCriteria.call(this);
 	};
 	stjs.extend(AbstractObjectSearchCriteria, AbstractCompositeSearchCriteria, [ AbstractCompositeSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractObjectSearchCriteria';
+		prototype['@type'] = 'dto.common.search.AbstractObjectSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.withId = function() {
 			return this.addCriteria(new IdSearchCriteria());
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractSearchCriteria.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractSearchCriteria.js
index dcf52863e1b..c0c28f07330 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractSearchCriteria.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
+define([ "stjs", "dto/common/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
 	var AbstractSearchCriteria = function() {
 	};
 	stjs.extend(AbstractSearchCriteria, null, [ ISearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractSearchCriteria';
+		prototype['@type'] = 'dto.common.search.AbstractSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return AbstractSearchCriteria;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractStringValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractStringValue.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractStringValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractStringValue.js
index e24b90d6528..341e9cdf058 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractStringValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractStringValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractValue" ], function(stjs, AbstractValue) {
+define([ "stjs", "dto/common/search/AbstractValue" ], function(stjs, AbstractValue) {
 	var AbstractStringValue = function(value) {
 		AbstractValue.call(this, value);
 	};
 	stjs.extend(AbstractStringValue, AbstractValue, [ AbstractValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractStringValue';
+		prototype['@type'] = 'dto.common.search.AbstractStringValue';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return AbstractStringValue;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractTimeZoneValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractTimeZoneValue.js
similarity index 77%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractTimeZoneValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractTimeZoneValue.js
index 99f93486f01..91dda8663f9 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractTimeZoneValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractTimeZoneValue.js
@@ -5,7 +5,7 @@ define([ "stjs" ], function(stjs) {
 	var AbstractTimeZoneValue = function() {
 	};
 	stjs.extend(AbstractTimeZoneValue, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractTimeZoneValue';
+		prototype['@type'] = 'dto.common.search.AbstractTimeZoneValue';
 	}, {});
 	return AbstractTimeZoneValue;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractValue.js
similarity index 90%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractValue.js
index c640ffbcf12..accac10557c 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AbstractValue.js
@@ -6,7 +6,7 @@ define([ "stjs" ], function(stjs) {
 		this.value = value;
 	};
 	stjs.extend(AbstractValue, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractValue';
+		prototype['@type'] = 'dto.common.search.AbstractValue';
 		constructor.serialVersionUID = 1;
 		prototype.value = null;
 		prototype.getValue = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyFieldSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyFieldSearchCriteria.js
similarity index 65%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyFieldSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyFieldSearchCriteria.js
index ba91362d92b..4bf8583b94e 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyFieldSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyFieldSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/StringFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/StringFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
 	var AnyFieldSearchCriteria = function() {
 		StringFieldSearchCriteria.call(this, "any", SearchFieldType.ANY_FIELD);
 	};
 	stjs.extend(AnyFieldSearchCriteria, StringFieldSearchCriteria, [ StringFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AnyFieldSearchCriteria';
+		prototype['@type'] = 'dto.common.search.AnyFieldSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		fieldType : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyPropertySearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyPropertySearchCriteria.js
similarity index 65%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyPropertySearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyPropertySearchCriteria.js
index 62f84ea06e1..04cb7f6d0e5 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyPropertySearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyPropertySearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/StringFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/StringFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
 	var AnyPropertySearchCriteria = function() {
 		StringFieldSearchCriteria.call(this, "any", SearchFieldType.ANY_PROPERTY);
 	};
 	stjs.extend(AnyPropertySearchCriteria, StringFieldSearchCriteria, [ StringFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AnyPropertySearchCriteria';
+		prototype['@type'] = 'dto.common.search.AnyPropertySearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		fieldType : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyStringValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyStringValue.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyStringValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyStringValue.js
index a107ea670b4..62088e17ce4 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AnyStringValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/AnyStringValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
+define([ "stjs", "dto/common/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
 	var AnyStringValue = function() {
 		AbstractStringValue.call(this, null);
 	};
 	stjs.extend(AnyStringValue, AbstractStringValue, [ AbstractStringValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AnyStringValue';
+		prototype['@type'] = 'dto.common.search.AnyStringValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "any value";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/CodeSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/CodeSearchCriteria.js
similarity index 65%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/CodeSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/CodeSearchCriteria.js
index 6eab70387d7..be906ed4f82 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/CodeSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/CodeSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/StringFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/StringFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
 	var CodeSearchCriteria = function() {
 		StringFieldSearchCriteria.call(this, "code", SearchFieldType.ATTRIBUTE);
 	};
 	stjs.extend(CodeSearchCriteria, StringFieldSearchCriteria, [ StringFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.CodeSearchCriteria';
+		prototype['@type'] = 'dto.common.search.CodeSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		fieldType : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateEarlierThanOrEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateEarlierThanOrEqualToValue.js
similarity index 72%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateEarlierThanOrEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateEarlierThanOrEqualToValue.js
index 090d4c93778..f05573c02da 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateEarlierThanOrEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateEarlierThanOrEqualToValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractDateValue" ], function(stjs, AbstractDateValue) {
+define([ "stjs", "dto/common/search/AbstractDateValue" ], function(stjs, AbstractDateValue) {
 	var DateEarlierThanOrEqualToValue = function(value) {
 		AbstractDateValue.call(this, value);
 	};
 	stjs.extend(DateEarlierThanOrEqualToValue, AbstractDateValue, [ AbstractDateValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DateEarlierThanOrEqualToValue';
+		prototype['@type'] = 'dto.common.search.DateEarlierThanOrEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "earlier than or equal to '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateEqualToValue.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateEqualToValue.js
index bfb119ce220..23132f346e5 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateEqualToValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractDateValue" ], function(stjs, AbstractDateValue) {
+define([ "stjs", "dto/common/search/AbstractDateValue" ], function(stjs, AbstractDateValue) {
 	var DateEqualToValue = function(value) {
 		AbstractDateValue.call(this, value);
 	};
 	stjs.extend(DateEqualToValue, AbstractDateValue, [ AbstractDateValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DateEqualToValue';
+		prototype['@type'] = 'dto.common.search.DateEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "equal to '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateFieldSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateFieldSearchCriteria.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateFieldSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateFieldSearchCriteria.js
index fee547e5767..208975c72a1 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateFieldSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateFieldSearchCriteria.js
@@ -1,10 +1,8 @@
-define([ "require", "stjs", "util/Exceptions", "dto/search/AbstractFieldSearchCriteria", "dto/search/ServerTimeZone",
-         "dto/search/ShortDateFormat", "dto/search/NormalDateFormat", "dto/search/LongDateFormat",
-         "dto/search/DateEqualToValue", "dto/search/DateObjectEqualToValue",
-         "dto/search/DateLaterThanOrEqualToValue", "dto/search/DateObjectLaterThanOrEqualToValue",
-         "dto/search/DateEarlierThanOrEqualToValue", "dto/search/DateObjectEarlierThanOrEqualToValue",
-         "dto/search/TimeZone", "dto/search/AbstractDateValue", "util/DateFormat"], 
-		function(require, stjs, exceptions, AbstractFieldSearchCriteria, ServerTimeZone) {
+define([ "require", "stjs", "util/Exceptions", "dto/common/search/AbstractFieldSearchCriteria", "dto/common/search/ServerTimeZone", "dto/common/search/ShortDateFormat",
+		"dto/common/search/NormalDateFormat", "dto/common/search/LongDateFormat", "dto/common/search/DateEqualToValue", "dto/common/search/DateObjectEqualToValue",
+		"dto/common/search/DateLaterThanOrEqualToValue", "dto/common/search/DateObjectLaterThanOrEqualToValue", "dto/common/search/DateEarlierThanOrEqualToValue",
+		"dto/common/search/DateObjectEarlierThanOrEqualToValue", "dto/common/search/TimeZone", "dto/common/search/AbstractDateValue", "util/DateFormat" ], function(require, stjs, exceptions,
+		AbstractFieldSearchCriteria, ServerTimeZone) {
 	var DateFieldSearchCriteria = function(fieldName, fieldType) {
 		AbstractFieldSearchCriteria.call(this, fieldName, fieldType);
 		this.timeZone = new ServerTimeZone();
@@ -13,9 +11,9 @@ define([ "require", "stjs", "util/Exceptions", "dto/search/AbstractFieldSearchCr
 	stjs.extend(DateFieldSearchCriteria, AbstractFieldSearchCriteria, [ AbstractFieldSearchCriteria ], function(constructor, prototype) {
 		prototype['@type'] = 'dto.search.DateFieldSearchCriteria';
 		constructor.serialVersionUID = 1;
-		var ShortDateFormat = require("dto/search/ShortDateFormat");
-		var NormalDateFormat = require("dto/search/NormalDateFormat");
-		var LongDateFormat = require("dto/search/LongDateFormat");
+		var ShortDateFormat = require("dto/common/search/ShortDateFormat");
+		var NormalDateFormat = require("dto/common/search/NormalDateFormat");
+		var LongDateFormat = require("dto/common/search/LongDateFormat");
 		constructor.DATE_FORMATS = [ new ShortDateFormat(), new NormalDateFormat(), new LongDateFormat() ];
 		var value = function(DateValueClass, DateObjectValueClass, date) {
 			if (date instanceof Date) {
@@ -24,18 +22,18 @@ define([ "require", "stjs", "util/Exceptions", "dto/search/AbstractFieldSearchCr
 			return new DateValueClass(date);
 		}
 		prototype.thatEquals = function(date) {
-			var DateEqualToValue = require("dto/search/DateEqualToValue");
-			var DateObjectEqualToValue = require("dto/search/DateObjectEqualToValue");
+			var DateEqualToValue = require("dto/common/search/DateEqualToValue");
+			var DateObjectEqualToValue = require("dto/common/search/DateObjectEqualToValue");
 			this.setFieldValue(value(DateEqualToValue, DateObjectEqualToValue, date));
 		};
 		prototype.thatIsLaterThanOrEqualTo = function(date) {
-			var DateLaterThanOrEqualToValue = require("dto/search/DateLaterThanOrEqualToValue");
-			var DateObjectLaterThanOrEqualToValue = require("dto/search/DateObjectLaterThanOrEqualToValue");
+			var DateLaterThanOrEqualToValue = require("dto/common/search/DateLaterThanOrEqualToValue");
+			var DateObjectLaterThanOrEqualToValue = require("dto/common/search/DateObjectLaterThanOrEqualToValue");
 			this.setFieldValue(value(DateLaterThanOrEqualToValue, DateObjectLaterThanOrEqualToValue, date));
 		};
 		prototype.thatIsEarlierThanOrEqualTo = function(date) {
-			var DateEarlierThanOrEqualToValue = require("dto/search/DateEarlierThanOrEqualToValue");
-			var DateObjectEarlierThanOrEqualToValue = require("dto/search/DateObjectEarlierThanOrEqualToValue");
+			var DateEarlierThanOrEqualToValue = require("dto/common/search/DateEarlierThanOrEqualToValue");
+			var DateObjectEarlierThanOrEqualToValue = require("dto/common/search/DateObjectEarlierThanOrEqualToValue");
 			this.setFieldValue(value(DateEarlierThanOrEqualToValue, DateObjectEarlierThanOrEqualToValue, date));
 		};
 		prototype.withServerTimeZone = function() {
@@ -43,7 +41,7 @@ define([ "require", "stjs", "util/Exceptions", "dto/search/AbstractFieldSearchCr
 			return this;
 		};
 		prototype.withTimeZone = function(hourOffset) {
-			var TimeZone = require("dto/search/TimeZone");
+			var TimeZone = require("dto/common/search/TimeZone");
 			this.timeZone = new TimeZone(hourOffset);
 			return this;
 		};
@@ -58,7 +56,7 @@ define([ "require", "stjs", "util/Exceptions", "dto/search/AbstractFieldSearchCr
 			AbstractFieldSearchCriteria.prototype.setFieldValue.call(this, value);
 		};
 		constructor.checkValueFormat = function(value) {
-			var AbstractDateValue = require("dto/search/AbstractDateValue");
+			var AbstractDateValue = require("dto/common/search/AbstractDateValue");
 			if (stjs.isInstanceOf(value.constructor, AbstractDateValue)) {
 				var formats = DateFieldSearchCriteria.DATE_FORMATS;
 				for ( var i in formats) {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateLaterThanOrEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateLaterThanOrEqualToValue.js
similarity index 72%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateLaterThanOrEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateLaterThanOrEqualToValue.js
index 375b266f205..eb57c52de91 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateLaterThanOrEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateLaterThanOrEqualToValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractDateValue" ], function(stjs, AbstractDateValue) {
+define([ "stjs", "dto/common/search/AbstractDateValue" ], function(stjs, AbstractDateValue) {
 	var DateLaterThanOrEqualToValue = function(value) {
 		AbstractDateValue.call(this, value);
 	};
 	stjs.extend(DateLaterThanOrEqualToValue, AbstractDateValue, [ AbstractDateValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DateLaterThanOrEqualToValue';
+		prototype['@type'] = 'dto.common.search.DateLaterThanOrEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "later than or equal to '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectEarlierThanOrEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectEarlierThanOrEqualToValue.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectEarlierThanOrEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectEarlierThanOrEqualToValue.js
index 862480f9cdd..ec632c28368 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectEarlierThanOrEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectEarlierThanOrEqualToValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractDateObjectValue" ], function(stjs, AbstractDateObjectValue) {
+define([ "stjs", "dto/common/search/AbstractDateObjectValue" ], function(stjs, AbstractDateObjectValue) {
 	var DateObjectEarlierThanOrEqualToValue = function(value) {
 		AbstractDateObjectValue.call(this, value);
 	};
 	stjs.extend(DateObjectEarlierThanOrEqualToValue, AbstractDateObjectValue, [ AbstractDateObjectValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DateObjectEarlierThanOrEqualToValue';
+		prototype['@type'] = 'dto.common.search.DateObjectEarlierThanOrEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "earlier than or equal to '" + this.getFormattedValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectEqualToValue.js
similarity index 69%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectEqualToValue.js
index 3569787cd86..95789730d6d 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectEqualToValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractDateObjectValue" ], function(stjs, AbstractDateObjectValue) {
+define([ "stjs", "dto/common/search/AbstractDateObjectValue" ], function(stjs, AbstractDateObjectValue) {
 	var DateObjectEqualToValue = function(value) {
 		AbstractDateObjectValue.call(this, value);
 	};
 	stjs.extend(DateObjectEqualToValue, AbstractDateObjectValue, [ AbstractDateObjectValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DateObjectEqualToValue';
+		prototype['@type'] = 'dto.common.search.DateObjectEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "equal to '" + this.getFormattedValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectLaterThanOrEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectLaterThanOrEqualToValue.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectLaterThanOrEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectLaterThanOrEqualToValue.js
index e65a9cb6a2c..cc71285441b 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DateObjectLaterThanOrEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DateObjectLaterThanOrEqualToValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractDateObjectValue" ], function(stjs, AbstractDateObjectValue) {
+define([ "stjs", "dto/common/search/AbstractDateObjectValue" ], function(stjs, AbstractDateObjectValue) {
 	var DateObjectLaterThanOrEqualToValue = function(value) {
 		AbstractDateObjectValue.call(this, value);
 	};
 	stjs.extend(DateObjectLaterThanOrEqualToValue, AbstractDateObjectValue, [ AbstractDateObjectValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DateObjectLaterThanOrEqualToValue';
+		prototype['@type'] = 'dto.common.search.DateObjectLaterThanOrEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "later than or equal to '" + this.getFormattedValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DatePropertySearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DatePropertySearchCriteria.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DatePropertySearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DatePropertySearchCriteria.js
index 5084231f935..33c50bb87bd 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DatePropertySearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/DatePropertySearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/DateFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, DateFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/DateFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, DateFieldSearchCriteria, SearchFieldType) {
 	var DatePropertySearchCriteria = function(fieldName) {
 		DateFieldSearchCriteria.call(this, fieldName, SearchFieldType.PROPERTY);
 	};
 	stjs.extend(DatePropertySearchCriteria, DateFieldSearchCriteria, [ DateFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DatePropertySearchCriteria';
+		prototype['@type'] = 'dto.common.search.DatePropertySearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		DATE_FORMATS : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/IDate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/IDate.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/IDate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/IDate.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/IDateFormat.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/IDateFormat.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/IDateFormat.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/IDateFormat.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ISearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ISearchCriteria.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ISearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ISearchCriteria.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ITimeZone.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ITimeZone.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ITimeZone.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ITimeZone.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/IdSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/IdSearchCriteria.js
similarity index 83%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/IdSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/IdSearchCriteria.js
index 118258bfcec..e428117af57 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/IdSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/IdSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractSearchCriteria" ], function(stjs, AbstractSearchCriteria) {
+define([ "stjs", "dto/common/search/AbstractSearchCriteria" ], function(stjs, AbstractSearchCriteria) {
 	var IdSearchCriteria = function() {
 		AbstractSearchCriteria.call(this);
 	};
 	stjs.extend(IdSearchCriteria, AbstractSearchCriteria, [ AbstractSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.IdSearchCriteria';
+		prototype['@type'] = 'dto.common.search.IdSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.id = null;
 		prototype.thatEquals = function(id) {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/LongDateFormat.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/LongDateFormat.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/LongDateFormat.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/LongDateFormat.js
index 75e67d43ea1..d74d9ba2a79 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/LongDateFormat.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/LongDateFormat.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/IDateFormat" ], function(stjs, IDateFormat) {
+define([ "stjs", "dto/common/search/IDateFormat" ], function(stjs, IDateFormat) {
 	var LongDateFormat = function() {
 	};
 	stjs.extend(LongDateFormat, null, [ IDateFormat ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.LongDateFormat';
+		prototype['@type'] = 'dto.common.search.LongDateFormat';
 		prototype.getFormat = function() {
 			return "YYYY-MM-DD HH:mm:ss";
 		};
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ModificationDateSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ModificationDateSearchCriteria.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ModificationDateSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ModificationDateSearchCriteria.js
index 74d017730a7..8e1102d3922 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ModificationDateSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ModificationDateSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/DateFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, DateFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/DateFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, DateFieldSearchCriteria, SearchFieldType) {
 	var ModificationDateSearchCriteria = function() {
 		DateFieldSearchCriteria.call(this, "modification_date", SearchFieldType.ATTRIBUTE);
 	};
 	stjs.extend(ModificationDateSearchCriteria, DateFieldSearchCriteria, [ DateFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.ModificationDateSearchCriteria';
+		prototype['@type'] = 'dto.common.search.ModificationDateSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		DATE_FORMATS : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NormalDateFormat.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NormalDateFormat.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NormalDateFormat.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NormalDateFormat.js
index 0230a2416c0..6960b18c8be 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NormalDateFormat.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NormalDateFormat.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/IDateFormat" ], function(stjs, IDateFormat) {
+define([ "stjs", "dto/common/search/IDateFormat" ], function(stjs, IDateFormat) {
 	var NormalDateFormat = function() {
 	};
 	stjs.extend(NormalDateFormat, null, [ IDateFormat ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NormalDateFormat';
+		prototype['@type'] = 'dto.common.search.NormalDateFormat';
 		prototype.getFormat = function() {
 			return "YYYY-MM-DD HH:mm";
 		};
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberEqualToValue.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberEqualToValue.js
index a4e9d874be3..21313a58aef 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberEqualToValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
+define([ "stjs", "dto/common/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
 	var NumberEqualToValue = function(number) {
 		AbstractNumberValue.call(this, number);
 	};
 	stjs.extend(NumberEqualToValue, AbstractNumberValue, [ AbstractNumberValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NumberEqualToValue';
+		prototype['@type'] = 'dto.common.search.NumberEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "equal to '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberFieldSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberFieldSearchCriteria.js
similarity index 53%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberFieldSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberFieldSearchCriteria.js
index 30c0c75d621..4a600bdd8b8 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberFieldSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberFieldSearchCriteria.js
@@ -1,31 +1,30 @@
-define([ "require", "stjs", "dto/search/AbstractFieldSearchCriteria",
-         "dto/search/NumberEqualToValue", "dto/search/NumberLessThanValue", "dto/search/NumberLessThanOrEqualToValue",
-         "dto/search/NumberGreaterThanValue", "dto/search/NumberGreaterThanOrEqualToValue"], 
-		function(require, stjs, AbstractFieldSearchCriteria) {
+define([ "require", "stjs", "dto/common/search/AbstractFieldSearchCriteria", "dto/common/search/NumberEqualToValue", "dto/common/search/NumberLessThanValue",
+		"dto/common/search/NumberLessThanOrEqualToValue", "dto/common/search/NumberGreaterThanValue", "dto/common/search/NumberGreaterThanOrEqualToValue" ], function(require, stjs,
+		AbstractFieldSearchCriteria) {
 	var NumberFieldSearchCriteria = function(fieldName, fieldType) {
 		AbstractFieldSearchCriteria.call(this, fieldName, fieldType);
 	};
 	stjs.extend(NumberFieldSearchCriteria, AbstractFieldSearchCriteria, [ AbstractFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NumberFieldSearchCriteria';
+		prototype['@type'] = 'dto.common.search.NumberFieldSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.equalTo = function(number) {
-			var NumberEqualToValue = require("dto/search/NumberEqualToValue");
+			var NumberEqualToValue = require("dto/common/search/NumberEqualToValue");
 			this.setFieldValue(new NumberEqualToValue(number));
 		};
 		prototype.thatIsLessThan = function(number) {
-			var NumberLessThanValue = require("dto/search/NumberLessThanValue");
+			var NumberLessThanValue = require("dto/common/search/NumberLessThanValue");
 			this.setFieldValue(new NumberLessThanValue(number));
 		};
 		prototype.thatIsLessThanOrEqualTo = function(number) {
-			var NumberLessThanOrEqualToValue = require("dto/search/NumberLessThanOrEqualToValue");
+			var NumberLessThanOrEqualToValue = require("dto/common/search/NumberLessThanOrEqualToValue");
 			this.setFieldValue(new NumberLessThanOrEqualToValue(number));
 		};
 		prototype.thatIsGreaterThan = function(number) {
-			var NumberGreaterThanValue = require("dto/search/NumberGreaterThanValue");
+			var NumberGreaterThanValue = require("dto/common/search/NumberGreaterThanValue");
 			this.setFieldValue(new NumberGreaterThanValue(number));
 		};
 		prototype.thatIsGreaterThanOrEqualTo = function(number) {
-			var NumberGreaterThanOrEqualToValue = require("dto/search/NumberGreaterThanOrEqualToValue");
+			var NumberGreaterThanOrEqualToValue = require("dto/common/search/NumberGreaterThanOrEqualToValue");
 			this.setFieldValue(new NumberGreaterThanOrEqualToValue(number));
 		};
 	}, {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberGreaterThanOrEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberGreaterThanOrEqualToValue.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberGreaterThanOrEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberGreaterThanOrEqualToValue.js
index 6e596221bb4..d8f131d2253 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberGreaterThanOrEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberGreaterThanOrEqualToValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
+define([ "stjs", "dto/common/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
 	var NumberGreaterOrEqualThanValue = function(number) {
 		AbstractNumberValue.call(this, number);
 	};
 	stjs.extend(NumberGreaterOrEqualThanValue, AbstractNumberValue, [ AbstractNumberValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NumberGreaterThanOrEqualToValue';
+		prototype['@type'] = 'dto.common.search.NumberGreaterThanOrEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "greater or equal to '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberGreaterThanValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberGreaterThanValue.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberGreaterThanValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberGreaterThanValue.js
index a617cea23e0..69520efa6c1 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberGreaterThanValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberGreaterThanValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
+define([ "stjs", "dto/common/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
 	var NumberGreaterThanValue = function(number) {
 		AbstractNumberValue.call(this, number);
 	};
 	stjs.extend(NumberGreaterThanValue, AbstractNumberValue, [ AbstractNumberValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NumberGreaterThanValue';
+		prototype['@type'] = 'dto.common.search.NumberGreaterThanValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "greater than '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberLessThanOrEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberLessThanOrEqualToValue.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberLessThanOrEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberLessThanOrEqualToValue.js
index 2d53e8de8c8..b8fd04ba49b 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberLessThanOrEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberLessThanOrEqualToValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
+define([ "stjs", "dto/common/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
 	var NumberLessOrEqualThanValue = function(number) {
 		AbstractNumberValue.call(this, number);
 	};
 	stjs.extend(NumberLessOrEqualThanValue, AbstractNumberValue, [ AbstractNumberValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NumberLessThanOrEqualToValue';
+		prototype['@type'] = 'dto.common.search.NumberLessThanOrEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "less or equal to '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberLessThanValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberLessThanValue.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberLessThanValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberLessThanValue.js
index cdebdf6cb56..1731f07f35b 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberLessThanValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberLessThanValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
+define([ "stjs", "dto/common/search/AbstractNumberValue" ], function(stjs, AbstractNumberValue) {
 	var NumberLessThanValue = function(number) {
 		AbstractNumberValue.call(this, number);
 	};
 	stjs.extend(NumberLessThanValue, AbstractNumberValue, [ AbstractNumberValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NumberLessThanValue';
+		prototype['@type'] = 'dto.common.search.NumberLessThanValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "less than '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberPropertySearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberPropertySearchCriteria.js
similarity index 66%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberPropertySearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberPropertySearchCriteria.js
index 12918ad0429..e29cd0cbfcb 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NumberPropertySearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/NumberPropertySearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/NumberFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, NumberFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/NumberFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, NumberFieldSearchCriteria, SearchFieldType) {
 	var NumberPropertySearchCriteria = function(fieldName) {
 		NumberFieldSearchCriteria.call(this, fieldName, SearchFieldType.PROPERTY);
 	};
 	stjs.extend(NumberPropertySearchCriteria, NumberFieldSearchCriteria, [ NumberFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NumberPropertySearchCriteria';
+		prototype['@type'] = 'dto.common.search.NumberPropertySearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		fieldType : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/PermIdSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/PermIdSearchCriteria.js
similarity index 65%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/PermIdSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/PermIdSearchCriteria.js
index 5fe5e68e381..d24ada3d61e 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/PermIdSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/PermIdSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/StringFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/StringFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
 	var PermIdSearchCriteria = function() {
 		StringFieldSearchCriteria.call(this, "perm id", SearchFieldType.ATTRIBUTE);
 	};
 	stjs.extend(PermIdSearchCriteria, StringFieldSearchCriteria, [ StringFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.PermIdSearchCriteria';
+		prototype['@type'] = 'dto.common.search.PermIdSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		fieldType : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/RegistrationDateSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/RegistrationDateSearchCriteria.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/RegistrationDateSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/RegistrationDateSearchCriteria.js
index a472c60430e..81a411e4b95 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/RegistrationDateSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/RegistrationDateSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/DateFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, DateFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/DateFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, DateFieldSearchCriteria, SearchFieldType) {
 	var RegistrationDateSearchCriteria = function() {
 		DateFieldSearchCriteria.call(this, "registration_date", SearchFieldType.ATTRIBUTE);
 	};
 	stjs.extend(RegistrationDateSearchCriteria, DateFieldSearchCriteria, [ DateFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.RegistrationDateSearchCriteria';
+		prototype['@type'] = 'dto.common.search.RegistrationDateSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		DATE_FORMATS : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchCriteriaToStringBuilder.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchCriteriaToStringBuilder.js
similarity index 88%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchCriteriaToStringBuilder.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchCriteriaToStringBuilder.js
index 6e8c8015195..8cc8c425fee 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchCriteriaToStringBuilder.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchCriteriaToStringBuilder.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractCompositeSearchCriteria" ], function(stjs, AbstractCompositeSearchCriteria) {
+define([ "stjs", "dto/common/search/AbstractCompositeSearchCriteria" ], function(stjs, AbstractCompositeSearchCriteria) {
 	var SearchCriteriaToStringBuilder = function() {
 	};
 	stjs.extend(SearchCriteriaToStringBuilder, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.SearchCriteriaToStringBuilder';
+		prototype['@type'] = 'dto.common.search.SearchCriteriaToStringBuilder';
 		prototype.name = null;
 		prototype.operator = null;
 		prototype.criteria = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchFieldType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchFieldType.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchFieldType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchFieldType.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchOperator.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchOperator.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchOperator.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchOperator.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchResult.js
similarity index 89%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchResult.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchResult.js
index 6171830e666..ba2b9ec272e 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SearchResult.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/SearchResult.js
@@ -7,7 +7,7 @@ define([ "stjs" ], function(stjs) {
 		this.totalCount = 0;
 	};
 	stjs.extend(SearchResult, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.SearchResult';
+		prototype['@type'] = 'dto.common.search.SearchResult';
 		constructor.serialVersionUID = 1;
 		prototype.getObjects = function() {
 			return this.objects;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ServerTimeZone.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ServerTimeZone.js
similarity index 57%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ServerTimeZone.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ServerTimeZone.js
index 3f26c2a7dd0..7a9cb44f135 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ServerTimeZone.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ServerTimeZone.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/ITimeZone" ], function(stjs, ITimeZone) {
+define([ "stjs", "dto/common/search/ITimeZone" ], function(stjs, ITimeZone) {
 	var ServerTimeZone = function() {
 	};
 	stjs.extend(ServerTimeZone, null, [ ITimeZone ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.ServerTimeZone';
+		prototype['@type'] = 'dto.common.search.ServerTimeZone';
 	}, {});
 	return ServerTimeZone;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ShortDateFormat.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ShortDateFormat.js
similarity index 69%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ShortDateFormat.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ShortDateFormat.js
index 90c32efd7f8..e031e08692f 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ShortDateFormat.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/ShortDateFormat.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/IDateFormat" ], function(stjs, IDateFormat) {
+define([ "stjs", "dto/common/search/IDateFormat" ], function(stjs, IDateFormat) {
 	var ShortDateFormat = function() {
 	};
 	stjs.extend(ShortDateFormat, null, [ IDateFormat ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.ShortDateFormat';
+		prototype['@type'] = 'dto.common.search.ShortDateFormat';
 		prototype.getFormat = function() {
 			return "YYYY-MM-DD";
 		};
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringContainsValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringContainsValue.js
similarity index 69%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringContainsValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringContainsValue.js
index 1d759751d2b..159c07e5c75 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringContainsValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringContainsValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
+define([ "stjs", "dto/common/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
 	var StringContainsValue = function(value) {
 		AbstractStringValue.call(this, value);
 	};
 	stjs.extend(StringContainsValue, AbstractStringValue, [ AbstractStringValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.StringContainsValue';
+		prototype['@type'] = 'dto.common.search.StringContainsValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "contains '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringEndsWithValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringEndsWithValue.js
similarity index 69%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringEndsWithValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringEndsWithValue.js
index c626fe32edc..b6fc2b42230 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringEndsWithValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringEndsWithValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
+define([ "stjs", "dto/common/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
 	var StringEndsWithValue = function(value) {
 		AbstractStringValue.call(this, value);
 	};
 	stjs.extend(StringEndsWithValue, AbstractStringValue, [ AbstractStringValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.StringEndsWithValue';
+		prototype['@type'] = 'dto.common.search.StringEndsWithValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "ends with '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringEqualToValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringEqualToValue.js
similarity index 69%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringEqualToValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringEqualToValue.js
index 6863c32c93d..b37337ddeba 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringEqualToValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringEqualToValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
+define([ "stjs", "dto/common/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
 	var StringEqualToValue = function(value) {
 		AbstractStringValue.call(this, value);
 	};
 	stjs.extend(StringEqualToValue, AbstractStringValue, [ AbstractStringValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.StringEqualToValue';
+		prototype['@type'] = 'dto.common.search.StringEqualToValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "equal to '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringFieldSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringFieldSearchCriteria.js
similarity index 53%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringFieldSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringFieldSearchCriteria.js
index 041c2796029..7de9b9073cd 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringFieldSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringFieldSearchCriteria.js
@@ -1,29 +1,27 @@
-define([ "require", "stjs", "dto/search/AbstractFieldSearchCriteria",
-         "dto/search/StringEqualToValue", "dto/search/StringStartsWithValue", "dto/search/StringEndsWithValue",
-         "dto/search/StringContainsValue", "dto/search/AnyStringValue"], 
-		function(require, stjs, AbstractFieldSearchCriteria) {
+define([ "require", "stjs", "dto/common/search/AbstractFieldSearchCriteria", "dto/common/search/StringEqualToValue", "dto/common/search/StringStartsWithValue",
+		"dto/common/search/StringEndsWithValue", "dto/common/search/StringContainsValue", "dto/common/search/AnyStringValue" ], function(require, stjs, AbstractFieldSearchCriteria) {
 	var StringFieldSearchCriteria = function(fieldName, fieldType) {
 		AbstractFieldSearchCriteria.call(this, fieldName, fieldType);
-		var AnyStringValue = require("dto/search/AnyStringValue");
+		var AnyStringValue = require("dto/common/search/AnyStringValue");
 		this.setFieldValue(new AnyStringValue());
 	};
 	stjs.extend(StringFieldSearchCriteria, AbstractFieldSearchCriteria, [ AbstractFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.StringFieldSearchCriteria';
+		prototype['@type'] = 'dto.common.search.StringFieldSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.thatEquals = function(string) {
-			var StringEqualToValue = require("dto/search/StringEqualToValue");
+			var StringEqualToValue = require("dto/common/search/StringEqualToValue");
 			this.setFieldValue(new StringEqualToValue(string));
 		};
 		prototype.thatStartsWith = function(prefix) {
-			var StringStartsWithValue = require("dto/search/StringStartsWithValue");
+			var StringStartsWithValue = require("dto/common/search/StringStartsWithValue");
 			this.setFieldValue(new StringStartsWithValue(prefix));
 		};
 		prototype.thatEndsWith = function(suffix) {
-			var StringEndsWithValue = require("dto/search/StringEndsWithValue");
+			var StringEndsWithValue = require("dto/common/search/StringEndsWithValue");
 			this.setFieldValue(new StringEndsWithValue(suffix));
 		};
 		prototype.thatContains = function(string) {
-			var StringContainsValue = require("dto/search/StringContainsValue");
+			var StringContainsValue = require("dto/common/search/StringContainsValue");
 			this.setFieldValue(new StringContainsValue(string));
 		};
 	}, {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringPropertySearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringPropertySearchCriteria.js
similarity index 66%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringPropertySearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringPropertySearchCriteria.js
index 5224de8175b..8f8f73faf8c 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringPropertySearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringPropertySearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/StringFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/StringFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, StringFieldSearchCriteria, SearchFieldType) {
 	var StringPropertySearchCriteria = function(fieldName) {
 		StringFieldSearchCriteria.call(this, fieldName, SearchFieldType.PROPERTY);
 	};
 	stjs.extend(StringPropertySearchCriteria, StringFieldSearchCriteria, [ StringFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.StringPropertySearchCriteria';
+		prototype['@type'] = 'dto.common.search.StringPropertySearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		fieldType : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringStartsWithValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringStartsWithValue.js
similarity index 69%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringStartsWithValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringStartsWithValue.js
index c0672f815bc..7894c91a967 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/StringStartsWithValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/StringStartsWithValue.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
+define([ "stjs", "dto/common/search/AbstractStringValue" ], function(stjs, AbstractStringValue) {
 	var StringStartsWithValue = function(value) {
 		AbstractStringValue.call(this, value);
 	};
 	stjs.extend(StringStartsWithValue, AbstractStringValue, [ AbstractStringValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.StringStartsWithValue';
+		prototype['@type'] = 'dto.common.search.StringStartsWithValue';
 		constructor.serialVersionUID = 1;
 		prototype.toString = function() {
 			return "starts with '" + this.getValue() + "'";
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TechIdSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/TechIdSearchCriteria.js
similarity index 65%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TechIdSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/TechIdSearchCriteria.js
index a8c4cfc9abb..b27dd33f237 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TechIdSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/TechIdSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/NumberFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, NumberFieldSearchCriteria, SearchFieldType) {
+define([ "stjs", "dto/common/search/NumberFieldSearchCriteria", "dto/common/search/SearchFieldType" ], function(stjs, NumberFieldSearchCriteria, SearchFieldType) {
 	var TechIdSearchCriteria = function() {
 		NumberFieldSearchCriteria.call(this, "id", SearchFieldType.ATTRIBUTE);
 	};
 	stjs.extend(TechIdSearchCriteria, NumberFieldSearchCriteria, [ NumberFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.TechIdSearchCriteria';
+		prototype['@type'] = 'dto.common.search.TechIdSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		fieldType : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TimeZone.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/TimeZone.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TimeZone.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/TimeZone.js
index 6952c4a7ae3..ba61fc1a280 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TimeZone.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/search/TimeZone.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/ITimeZone" ], function(stjs, ITimeZone) {
+define([ "stjs", "dto/common/search/ITimeZone" ], function(stjs, ITimeZone) {
 	var TimeZone = function(hourOffset) {
 		this.hourOffset = hourOffset;
 	};
 	stjs.extend(TimeZone, null, [ ITimeZone ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.TimeZone';
+		prototype['@type'] = 'dto.common.search.TimeZone';
 		prototype.hourOffset = 0;
 		prototype.getHourOffset = function() {
 			return this.hourOffset;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/FieldUpdateValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/FieldUpdateValue.js
similarity index 92%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/FieldUpdateValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/FieldUpdateValue.js
index bfef318c4cc..ba8cf1891e9 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/FieldUpdateValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/FieldUpdateValue.js
@@ -7,7 +7,7 @@ define([ "stjs" ], function(stjs) {
 	var FieldUpdateValue = function() {
 	};
 	stjs.extend(FieldUpdateValue, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.FieldUpdateValue';
+		prototype['@type'] = 'dto.common.update.FieldUpdateValue';
 		constructor.serialVersionUID = 1;
 		prototype.isModified = false;
 		prototype.value = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/IdListUpdateValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/IdListUpdateValue.js
similarity index 73%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/IdListUpdateValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/IdListUpdateValue.js
index 5c673ebed1a..52ae3a30f10 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/IdListUpdateValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/IdListUpdateValue.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/ListUpdateValue" ], function(stjs, ListUpdateValue) {
+define([ "stjs", "dto/common/update/ListUpdateValue" ], function(stjs, ListUpdateValue) {
 	var IdListUpdateValue = function() {
 		ListUpdateValue.call(this);
 	};
 	stjs.extend(IdListUpdateValue, ListUpdateValue, [ ListUpdateValue ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.IdListUpdateValue';
+		prototype['@type'] = 'dto.common.update.IdListUpdateValue';
 		constructor.serialVersionUID = 1;
 	}, {
 		actions : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateAction.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateAction.js
similarity index 87%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateAction.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateAction.js
index 4dadef12f85..dedd458e1b1 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateAction.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateAction.js
@@ -2,7 +2,7 @@ define([ "stjs" ], function(stjs) {
 	ListUpdateAction = function() {
 	};
 	stjs.extend(ListUpdateAction, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.ListUpdateAction';
+		prototype['@type'] = 'dto.common.update.ListUpdateAction';
 		constructor.serialVersionUID = 1;
 		prototype.items = null;
 		prototype.getItems = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionAdd.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionAdd.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionAdd.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionAdd.js
index 37d535dd94d..7c7d62403b3 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionAdd.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionAdd.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/entity/ListUpdateAction" ], function(stjs, ListUpdateAction) {
+define([ "stjs", "dto/common/update/ListUpdateAction" ], function(stjs, ListUpdateAction) {
 	ListUpdateActionAdd = function() {
 		ListUpdateAction.call(this);
 	};
 	stjs.extend(ListUpdateActionAdd, ListUpdateAction, [ ListUpdateAction ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.ListUpdateActionAdd';
+		prototype['@type'] = 'dto.common.update.ListUpdateActionAdd';
 		constructor.serialVersionUID = 1;
 	}, {
 		items : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionRemove.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionRemove.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionRemove.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionRemove.js
index 395b8a226ff..8cd81612e07 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionRemove.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionRemove.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/entity/ListUpdateAction" ], function(stjs, ListUpdateAction) {
+define([ "stjs", "dto/common/update/ListUpdateAction" ], function(stjs, ListUpdateAction) {
 	ListUpdateActionRemove = function() {
 		ListUpdateAction.call(this);
 	};
 	stjs.extend(ListUpdateActionRemove, ListUpdateAction, [ ListUpdateAction ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.ListUpdateActionRemove';
+		prototype['@type'] = 'dto.common.update.ListUpdateActionRemove';
 		constructor.serialVersionUID = 1;
 	}, {
 		items : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionSet.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionSet.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionSet.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionSet.js
index 912ece83fc2..6f68e33706e 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateActionSet.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateActionSet.js
@@ -1,9 +1,9 @@
-define([ "stjs", "dto/entity/ListUpdateAction" ], function(stjs, ListUpdateAction) {
+define([ "stjs", "dto/common/update/ListUpdateAction" ], function(stjs, ListUpdateAction) {
 	ListUpdateActionSet = function() {
 		ListUpdateAction.call(this);
 	};
 	stjs.extend(ListUpdateActionSet, ListUpdateAction, [ ListUpdateAction ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.ListUpdateActionSet';
+		prototype['@type'] = 'dto.common.update.ListUpdateActionSet';
 		constructor.serialVersionUID = 1;
 	}, {
 		items : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateValue.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateValue.js
similarity index 79%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateValue.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateValue.js
index 05c35dff7ec..47907c13450 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/ListUpdateValue.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/common/update/ListUpdateValue.js
@@ -1,10 +1,10 @@
-define([ "stjs", "dto/entity/ListUpdateActionRemove", "dto/entity/ListUpdateActionAdd", "dto/entity/ListUpdateActionSet" ], function(stjs, ListUpdateActionRemove, ListUpdateActionAdd,
-		ListUpdateActionSet) {
+define([ "stjs", "dto/common/update/ListUpdateActionRemove", "dto/common/update/ListUpdateActionAdd", "dto/common/update/ListUpdateActionSet" ], function(stjs, ListUpdateActionRemove,
+		ListUpdateActionAdd, ListUpdateActionSet) {
 	var ListUpdateValue = function() {
 		this.actions = [];
 	};
 	stjs.extend(ListUpdateValue, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.ListUpdateValue';
+		prototype['@type'] = 'dto.common.update.ListUpdateValue';
 		constructor.serialVersionUID = 1;
 		prototype.setActions = function(actions) {
 			this.actions = actions;
@@ -22,7 +22,7 @@ define([ "stjs", "dto/entity/ListUpdateActionRemove", "dto/entity/ListUpdateActi
 			if (items === null) {
 				return [];
 			}
-			return [items];
+			return [ items ];
 		}
 		var createAction = function(actions, actionClass, items) {
 			var action = new actionClass();
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/ArchivingStatus.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/ArchivingStatus.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/ArchivingStatus.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/ArchivingStatus.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/Complete.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/Complete.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/Complete.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/Complete.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSet.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSet.js
similarity index 88%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSet.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSet.js
index 05d5cedef61..19a20bc3053 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSet.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSet.js
@@ -6,21 +6,23 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var DataSet = function() {
 	};
 	stjs.extend(DataSet, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.DataSet';
+		prototype['@type'] = 'dto.dataset.DataSet';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
 		prototype.code = null;
 		prototype.accessDate = null;
-		prototype.derived = null;
+		prototype.measured = null;
 		prototype.postRegistered = null;
 		prototype.parents = null;
 		prototype.children = null;
 		prototype.containers = null;
 		prototype.components = null;
 		prototype.physicalData = null;
+		prototype.linkedData = null;
 		prototype.tags = null;
 		prototype.type = null;
+		prototype.dataStore = null;
 		prototype.history = null;
 		prototype.modificationDate = null;
 		prototype.modifier = null;
@@ -54,11 +56,11 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 		prototype.setAccessDate = function(accessDate) {
 			this.accessDate = accessDate;
 		};
-		prototype.isDerived = function() {
-			return this.derived;
+		prototype.isMeasured = function() {
+			return this.measured;
 		};
-		prototype.setDerived = function(derived) {
-			this.derived = derived;
+		prototype.setMeasured = function(measured) {
+			this.measured = measured;
 		};
 		prototype.isPostRegistered = function() {
 			return this.postRegistered;
@@ -116,6 +118,16 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 		prototype.setPhysicalData = function(physicalData) {
 			this.physicalData = physicalData;
 		};
+		prototype.getLinkedData = function() {
+			if (this.getFetchOptions().hasLinkedData()) {
+				return this.linkedData;
+			} else {
+				throw new exceptions.NotFetchedException("Linked data has not been fetched.");
+			}
+		};
+		prototype.setLinkedData = function(linkedData) {
+			this.linkedData = linkedData;
+		};
 		prototype.getTags = function() {
 			if (this.getFetchOptions().hasTags()) {
 				return this.tags;
@@ -136,6 +148,16 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 		prototype.setType = function(type) {
 			this.type = type;
 		};
+		prototype.getDataStore = function() {
+			if (this.getFetchOptions().hasDataStore()) {
+				return this.dataStore;
+			} else {
+				throw new exceptions.NotFetchedException("Data store has not been fetched.");
+			}
+		};
+		prototype.setDataStore = function(dataStore) {
+			this.dataStore = dataStore;
+		};
 		prototype.getHistory = function() {
 			if (this.getFetchOptions().hasHistory()) {
 				return this.history;
@@ -243,11 +265,13 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 			arguments : [ "DataSet" ]
 		},
 		physicalData : "PhysicalData",
+		linkedData : "LinkedData",
 		tags : {
 			name : "Set",
 			arguments : [ "Tag" ]
 		},
 		type : "DataSetType",
+		dataStore : "DataStore",
 		history : {
 			name : "List",
 			arguments : [ "HistoryEntry" ]
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetKind.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSetKind.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetKind.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSetKind.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSetType.js
similarity index 96%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSetType.js
index cd1d65cb6ef..9c643a794f8 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetType.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/DataSetType.js
@@ -6,7 +6,7 @@ define([ "stjs" ], function(stjs) {
 	var DataSetType = function() {
 	};
 	stjs.extend(DataSetType, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.DataSetType';
+		prototype['@type'] = 'dto.dataset.DataSetType';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/FileFormatType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/FileFormatType.js
similarity index 94%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/FileFormatType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/FileFormatType.js
index 7e357031e7e..8370c1263c6 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/FileFormatType.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/FileFormatType.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var FileFormatType = function() {
 	};
 	stjs.extend(FileFormatType, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.FileFormatType';
+		prototype['@type'] = 'dto.dataset.FileFormatType';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.code = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/LinkedData.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/LinkedData.js
new file mode 100644
index 00000000000..0df855f66ff
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/LinkedData.js
@@ -0,0 +1,42 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
+	var LinkedData = function() {
+	};
+	stjs.extend(LinkedData, null, [], function(constructor, prototype) {
+		prototype['@type'] = 'dto.dataset.LinkedData';
+		constructor.serialVersionUID = 1;
+		prototype.fetchOptions = null;
+		prototype.externalCode = null;
+		prototype.externalDms = null;
+
+		prototype.getFetchOptions = function() {
+			return this.fetchOptions;
+		};
+		prototype.setFetchOptions = function(fetchOptions) {
+			this.fetchOptions = fetchOptions;
+		};
+		prototype.getExternalCode = function() {
+			return this.externalCode;
+		};
+		prototype.setExternalCode = function(externalCode) {
+			this.externalCode = externalCode;
+		};
+		prototype.getExternalDms = function() {
+			if (this.getFetchOptions().hasExternalDms()) {
+				return this.externalDms;
+			} else {
+				throw new exceptions.NotFetchedException("External data management system has not been fetched.");
+			}
+		};
+		prototype.setExternalDms = function(externalDms) {
+			this.externalDms = externalDms;
+		};
+	}, {
+		fetchOptions : "LinkedDataFetchOptions",
+		externalDms : "ExternalDms"
+	});
+	return LinkedData;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/LocatorType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/LocatorType.js
similarity index 94%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/LocatorType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/LocatorType.js
index bb2955b1f7c..71668e309ed 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/LocatorType.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/LocatorType.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var LocatorType = function() {
 	};
 	stjs.extend(LocatorType, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.LocatorType';
+		prototype['@type'] = 'dto.dataset.LocatorType';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.code = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/PhysicalData.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/PhysicalData.js
similarity index 98%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/PhysicalData.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/PhysicalData.js
index cc7e2915488..db7fbb3bd51 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/PhysicalData.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/PhysicalData.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var PhysicalData = function() {
 	};
 	stjs.extend(PhysicalData, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.PhysicalData';
+		prototype['@type'] = 'dto.dataset.PhysicalData';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.shareId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/StorageFormat.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/StorageFormat.js
similarity index 94%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/StorageFormat.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/StorageFormat.js
index 91bde88f971..3597c83020a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/StorageFormat.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/StorageFormat.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var StorageFormat = function() {
 	};
 	stjs.extend(StorageFormat, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.StorageFormat';
+		prototype['@type'] = 'dto.dataset.StorageFormat';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.code = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/dataset/DataSetDeletionOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/delete/DataSetDeletionOptions.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/dataset/DataSetDeletionOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/delete/DataSetDeletionOptions.js
index 3c67fc255e8..7e41a793eea 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/dataset/DataSetDeletionOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/delete/DataSetDeletionOptions.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
+define([ "stjs", "dto/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
 	var DataSetDeletionOptions = function() {
 		AbstractObjectDeletionOptions.call(this);
 	};
 	stjs.extend(DataSetDeletionOptions, AbstractObjectDeletionOptions, [ AbstractObjectDeletionOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.dataset.DataSetDeletionOptions';
+		prototype['@type'] = 'dto.dataset.delete.DataSetDeletionOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return DataSetDeletionOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetFetchOptions.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetFetchOptions.js
index 8c93880cbcf..51db58ccd9a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetFetchOptions.js
@@ -2,22 +2,25 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/tag/TagFetchOptions", "dto/fetchoptions/dataset/DataSetTypeFetchOptions", "dto/fetchoptions/person/PersonFetchOptions",
-		"dto/fetchoptions/experiment/ExperimentFetchOptions", "dto/fetchoptions/sample/SampleFetchOptions", "dto/fetchoptions/property/PropertyFetchOptions",
-		"dto/fetchoptions/dataset/PhysicalDataFetchOptions", "dto/fetchoptions/history/HistoryEntryFetchOptions", "dto/fetchoptions/material/MaterialFetchOptions",
-		"dto/fetchoptions/dataset/DataSetSortOptions" ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/tag/fetchoptions/TagFetchOptions", "dto/dataset/fetchoptions/DataSetTypeFetchOptions",
+		"dto/person/fetchoptions/PersonFetchOptions", "dto/experiment/fetchoptions/ExperimentFetchOptions", "dto/sample/fetchoptions/SampleFetchOptions",
+		"dto/property/fetchoptions/PropertyFetchOptions", "dto/dataset/fetchoptions/PhysicalDataFetchOptions", "dto/dataset/fetchoptions/LinkedDataFetchOptions",
+		"dto/history/fetchoptions/HistoryEntryFetchOptions", "dto/material/fetchoptions/MaterialFetchOptions", "dto/datastore/fetchoptions/DataStoreFetchOptions",
+		"dto/dataset/fetchoptions/DataSetSortOptions" ], function(require, stjs, FetchOptions) {
 	var DataSetFetchOptions = function() {
 	};
 	stjs.extend(DataSetFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.DataSetFetchOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.DataSetFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.parents = null;
 		prototype.children = null;
 		prototype.containers = null;
 		prototype.components = null;
 		prototype.physicalData = null;
+		prototype.linkedData = null;
 		prototype.tags = null;
 		prototype.type = null;
+		prototype.dataStore = null;
 		prototype.history = null;
 		prototype.modifier = null;
 		prototype.registrator = null;
@@ -76,7 +79,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withPhysicalData = function() {
 			if (this.physicalData == null) {
-				var PhysicalDataFetchOptions = require("dto/fetchoptions/dataset/PhysicalDataFetchOptions");
+				var PhysicalDataFetchOptions = require("dto/dataset/fetchoptions/PhysicalDataFetchOptions");
 				this.physicalData = new PhysicalDataFetchOptions();
 			}
 			return this.physicalData;
@@ -87,9 +90,22 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		prototype.hasPhysicalData = function() {
 			return this.physicalData != null;
 		};
+		prototype.withLinkedData = function() {
+			if (this.linkedData == null) {
+				var LinkedDataFetchOptions = require("dto/dataset/fetchoptions/LinkedDataFetchOptions");
+				this.linkedData = new LinkedDataFetchOptions();
+			}
+			return this.linkedData;
+		};
+		prototype.withLinkedDataUsing = function(fetchOptions) {
+			return this.linkedData = fetchOptions;
+		};
+		prototype.hasLinkedData = function() {
+			return this.linkedData != null;
+		};
 		prototype.withTags = function() {
 			if (this.tags == null) {
-				var TagFetchOptions = require("dto/fetchoptions/tag/TagFetchOptions");
+				var TagFetchOptions = require("dto/tag/fetchoptions/TagFetchOptions");
 				this.tags = new TagFetchOptions();
 			}
 			return this.tags;
@@ -102,7 +118,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withType = function() {
 			if (this.type == null) {
-				var DataSetTypeFetchOptions = require("dto/fetchoptions/dataset/DataSetTypeFetchOptions");
+				var DataSetTypeFetchOptions = require("dto/dataset/fetchoptions/DataSetTypeFetchOptions");
 				this.type = new DataSetTypeFetchOptions();
 			}
 			return this.type;
@@ -113,9 +129,22 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		prototype.hasType = function() {
 			return this.type != null;
 		};
+		prototype.withDataStore = function() {
+			if (this.dataStore == null) {
+				var DataStoreFetchOptions = require("dto/datastore/fetchoptions/DataStoreFetchOptions");
+				this.dataStore = new DataStoreFetchOptions();
+			}
+			return this.dataStore;
+		};
+		prototype.withDataStoreUsing = function(fetchOptions) {
+			return this.dataStore = fetchOptions;
+		};
+		prototype.hasDataStore = function() {
+			return this.dataStore != null;
+		};
 		prototype.withHistory = function() {
 			if (this.history == null) {
-				var HistoryEntryFetchOptions = require("dto/fetchoptions/history/HistoryEntryFetchOptions");
+				var HistoryEntryFetchOptions = require("dto/history/fetchoptions/HistoryEntryFetchOptions");
 				this.history = new HistoryEntryFetchOptions();
 			}
 			return this.history;
@@ -128,7 +157,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withModifier = function() {
 			if (this.modifier == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.modifier = new PersonFetchOptions();
 			}
 			return this.modifier;
@@ -141,7 +170,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withRegistrator = function() {
 			if (this.registrator == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.registrator = new PersonFetchOptions();
 			}
 			return this.registrator;
@@ -154,7 +183,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withExperiment = function() {
 			if (this.experiment == null) {
-				var ExperimentFetchOptions = require("dto/fetchoptions/experiment/ExperimentFetchOptions");
+				var ExperimentFetchOptions = require("dto/experiment/fetchoptions/ExperimentFetchOptions");
 				this.experiment = new ExperimentFetchOptions();
 			}
 			return this.experiment;
@@ -167,7 +196,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withSample = function() {
 			if (this.sample == null) {
-				var SampleFetchOptions = require("dto/fetchoptions/sample/SampleFetchOptions");
+				var SampleFetchOptions = require("dto/sample/fetchoptions/SampleFetchOptions");
 				this.sample = new SampleFetchOptions();
 			}
 			return this.sample;
@@ -180,7 +209,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withProperties = function() {
 			if (this.properties == null) {
-				var PropertyFetchOptions = require("dto/fetchoptions/property/PropertyFetchOptions");
+				var PropertyFetchOptions = require("dto/property/fetchoptions/PropertyFetchOptions");
 				this.properties = new PropertyFetchOptions();
 			}
 			return this.properties;
@@ -193,7 +222,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.withMaterialProperties = function() {
 			if (this.materialProperties == null) {
-				var MaterialFetchOptions = require("dto/fetchoptions/material/MaterialFetchOptions");
+				var MaterialFetchOptions = require("dto/material/fetchoptions/MaterialFetchOptions");
 				this.materialProperties = new MaterialFetchOptions();
 			}
 			return this.materialProperties;
@@ -206,7 +235,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var DataSetSortOptions = require("dto/fetchoptions/dataset/DataSetSortOptions");
+				var DataSetSortOptions = require("dto/dataset/fetchoptions/DataSetSortOptions");
 				this.sort = new DataSetSortOptions();
 			}
 			return this.sort;
@@ -222,6 +251,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/t
 		physicalData : "PhysicalDataFetchOptions",
 		tags : "TagFetchOptions",
 		type : "DataSetTypeFetchOptions",
+		dataStore : "DataStoreFetchOptions",
 		history : "HistoryEntryFetchOptions",
 		modifier : "PersonFetchOptions",
 		registrator : "PersonFetchOptions",
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetSortOptions.js
similarity index 59%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetSortOptions.js
index 9109ae6c044..2e1a4086423 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
 	var DataSetSortOptions = function() {
 		EntityWithPropertiesSortOptions.call(this);
 	};
 	stjs.extend(DataSetSortOptions, EntityWithPropertiesSortOptions, [ EntityWithPropertiesSortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.DataSetSortOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.DataSetSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return DataSetSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetTypeFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetTypeFetchOptions.js
similarity index 68%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetTypeFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetTypeFetchOptions.js
index c1d07cfd9a9..c5f51669efa 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetTypeFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetTypeFetchOptions.js
@@ -2,16 +2,16 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/dataset/DataSetTypeSortOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions", "dto/dataset/fetchoptions/DataSetTypeSortOptions" ], function(stjs, FetchOptions) {
 	var DataSetTypeFetchOptions = function() {
 	};
 	stjs.extend(DataSetTypeFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.DataSetTypeFetchOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.DataSetTypeFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.sort = null;
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var DataSetTypeSortOptions = require("dto/fetchoptions/dataset/DataSetTypeSortOptions");
+				var DataSetTypeSortOptions = require("dto/dataset/fetchoptions/DataSetTypeSortOptions");
 				this.sort = new DataSetTypeSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetTypeSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetTypeSortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetTypeSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetTypeSortOptions.js
index a9c7b0df229..b76256171d2 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/DataSetTypeSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/DataSetTypeSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var DataSetTypeSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(DataSetTypeSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.DataSetTypeSortOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.DataSetTypeSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return DataSetTypeSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/FileFormatTypeFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/FileFormatTypeFetchOptions.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/FileFormatTypeFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/FileFormatTypeFetchOptions.js
index 938f4ba0647..8bcad167844 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/FileFormatTypeFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/FileFormatTypeFetchOptions.js
@@ -2,16 +2,16 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/dataset/FileFormatTypeSortOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions", "dto/dataset/fetchoptions/FileFormatTypeSortOptions" ], function(stjs, FetchOptions) {
 	var FileFormatTypeFetchOptions = function() {
 	};
 	stjs.extend(FileFormatTypeFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.FileFormatTypeFetchOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.FileFormatTypeFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.sort = null;
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var FileFormatTypeSortOptions = require("dto/fetchoptions/dataset/FileFormatTypeSortOptions");
+				var FileFormatTypeSortOptions = require("dto/dataset/fetchoptions/FileFormatTypeSortOptions");
 				this.sort = new FileFormatTypeSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/FileFormatTypeSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/FileFormatTypeSortOptions.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/FileFormatTypeSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/FileFormatTypeSortOptions.js
index 7383545743a..c2fe698a76a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/FileFormatTypeSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/FileFormatTypeSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var FileFormatTypeSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(FileFormatTypeSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.FileFormatTypeSortOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.FileFormatTypeSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return FileFormatTypeSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataFetchOptions.js
new file mode 100644
index 00000000000..c871953b4e9
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataFetchOptions.js
@@ -0,0 +1,42 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/externaldms/fetchoptions/ExternalDmsFetchOptions", "dto/dataset/fetchoptions/LinkedDataSortOptions" ], function(require, stjs,
+		FetchOptions) {
+	var LinkedDataFetchOptions = function() {
+	};
+	stjs.extend(LinkedDataFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.dataset.fetchoptions.LinkedDataFetchOptions';
+		constructor.serialVersionUID = 1;
+		prototype.externalDms = null;
+		prototype.sort = null;
+		prototype.withExternalDms = function() {
+			if (this.externalDms == null) {
+				var ExternalDmsFetchOptions = require("dto/externaldms/fetchoptions/ExternalDmsFetchOptions");
+				this.externalDms = new ExternalDmsFetchOptions();
+			}
+			return this.externalDms;
+		};
+		prototype.withExternalDmsUsing = function(fetchOptions) {
+			return this.externalDms = fetchOptions;
+		};
+		prototype.hasExternalDms = function() {
+			return this.externalDms != null;
+		};
+		prototype.sortBy = function() {
+			if (this.sort == null) {
+				var LinkedDataSortOptions = require("dto/dataset/fetchoptions/LinkedDataSortOptions");
+				this.sort = new LinkedDataSortOptions();
+			}
+			return this.sort;
+		};
+		prototype.getSortBy = function() {
+			return this.sort;
+		};
+	}, {
+		externalDms : "ExternalDmsFetchOptions",
+		sort : "LinkedDataSortOptions"
+	});
+	return LinkedDataFetchOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataSortOptions.js
new file mode 100644
index 00000000000..5cb4a1fcb7d
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LinkedDataSortOptions.js
@@ -0,0 +1,10 @@
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
+	var LinkedDataSortOptions = function() {
+		SortOptions.call(this);
+	};
+	stjs.extend(LinkedDataSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.dataset.fetchoptions.LinkedDataSortOptions';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return LinkedDataSortOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/LocatorTypeFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LocatorTypeFetchOptions.js
similarity index 68%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/LocatorTypeFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LocatorTypeFetchOptions.js
index ac9c3b722d0..46b4fedff56 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/LocatorTypeFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LocatorTypeFetchOptions.js
@@ -2,16 +2,16 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/dataset/LocatorTypeSortOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions", "dto/dataset/fetchoptions/LocatorTypeSortOptions" ], function(stjs, FetchOptions) {
 	var LocatorTypeFetchOptions = function() {
 	};
 	stjs.extend(LocatorTypeFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.LocatorTypeFetchOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.LocatorTypeFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.sort = null;
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var LocatorTypeSortOptions = require("dto/fetchoptions/dataset/LocatorTypeSortOptions");
+				var LocatorTypeSortOptions = require("dto/dataset/fetchoptions/LocatorTypeSortOptions");
 				this.sort = new LocatorTypeSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/LocatorTypeSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LocatorTypeSortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/LocatorTypeSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LocatorTypeSortOptions.js
index 468346d6375..766889cc85a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/LocatorTypeSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/LocatorTypeSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var LocatorTypeSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(LocatorTypeSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.LocatorTypeSortOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.LocatorTypeSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return LocatorTypeSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/PhysicalDataFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/PhysicalDataFetchOptions.js
similarity index 72%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/PhysicalDataFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/PhysicalDataFetchOptions.js
index 80cb4622ca3..426929eb1d7 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/PhysicalDataFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/PhysicalDataFetchOptions.js
@@ -2,12 +2,12 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/dataset/StorageFormatFetchOptions", "dto/fetchoptions/dataset/FileFormatTypeFetchOptions",
-		"dto/fetchoptions/dataset/LocatorTypeFetchOptions", "dto/fetchoptions/dataset/PhysicalDataSortOptions" ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/dataset/fetchoptions/StorageFormatFetchOptions", "dto/dataset/fetchoptions/FileFormatTypeFetchOptions",
+		"dto/dataset/fetchoptions/LocatorTypeFetchOptions", "dto/dataset/fetchoptions/PhysicalDataSortOptions" ], function(require, stjs, FetchOptions) {
 	var PhysicalDataFetchOptions = function() {
 	};
 	stjs.extend(PhysicalDataFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.PhysicalDataFetchOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.PhysicalDataFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.storageFormat = null;
 		prototype.fileFormatType = null;
@@ -15,7 +15,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/d
 		prototype.sort = null;
 		prototype.withStorageFormat = function() {
 			if (this.storageFormat == null) {
-				var StorageFormatFetchOptions = require("dto/fetchoptions/dataset/StorageFormatFetchOptions");
+				var StorageFormatFetchOptions = require("dto/dataset/fetchoptions/StorageFormatFetchOptions");
 				this.storageFormat = new StorageFormatFetchOptions();
 			}
 			return this.storageFormat;
@@ -28,7 +28,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/d
 		};
 		prototype.withFileFormatType = function() {
 			if (this.fileFormatType == null) {
-				var FileFormatTypeFetchOptions = require("dto/fetchoptions/dataset/FileFormatTypeFetchOptions");
+				var FileFormatTypeFetchOptions = require("dto/dataset/fetchoptions/FileFormatTypeFetchOptions");
 				this.fileFormatType = new FileFormatTypeFetchOptions();
 			}
 			return this.fileFormatType;
@@ -41,7 +41,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/d
 		};
 		prototype.withLocatorType = function() {
 			if (this.locatorType == null) {
-				var LocatorTypeFetchOptions = require("dto/fetchoptions/dataset/LocatorTypeFetchOptions");
+				var LocatorTypeFetchOptions = require("dto/dataset/fetchoptions/LocatorTypeFetchOptions");
 				this.locatorType = new LocatorTypeFetchOptions();
 			}
 			return this.locatorType;
@@ -54,7 +54,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/d
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var PhysicalDataSortOptions = require("dto/fetchoptions/dataset/PhysicalDataSortOptions");
+				var PhysicalDataSortOptions = require("dto/dataset/fetchoptions/PhysicalDataSortOptions");
 				this.sort = new PhysicalDataSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/PhysicalDataSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/PhysicalDataSortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/PhysicalDataSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/PhysicalDataSortOptions.js
index 937456925b3..e28ec81a289 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/PhysicalDataSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/PhysicalDataSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var PhysicalDataSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(PhysicalDataSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.PhysicalDataSortOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.PhysicalDataSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return PhysicalDataSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/StorageFormatFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/StorageFormatFetchOptions.js
similarity index 68%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/StorageFormatFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/StorageFormatFetchOptions.js
index a9c5d87d2c3..59b4154ff3b 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/StorageFormatFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/StorageFormatFetchOptions.js
@@ -2,16 +2,16 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/dataset/StorageFormatSortOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions", "dto/dataset/fetchoptions/StorageFormatSortOptions" ], function(stjs, FetchOptions) {
 	var StorageFormatFetchOptions = function() {
 	};
 	stjs.extend(StorageFormatFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.StorageFormatFetchOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.StorageFormatFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.sort = null;
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var StorageFormatSortOptions = require("dto/fetchoptions/dataset/StorageFormatSortOptions");
+				var StorageFormatSortOptions = require("dto/dataset/fetchoptions/StorageFormatSortOptions");
 				this.sort = new StorageFormatSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/StorageFormatSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/StorageFormatSortOptions.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/StorageFormatSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/StorageFormatSortOptions.js
index 4ea002d4b1b..1416718e245 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/dataset/StorageFormatSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/fetchoptions/StorageFormatSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var StorageFormatSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(StorageFormatSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.dataset.StorageFormatSortOptions';
+		prototype['@type'] = 'dto.dataset.fetchoptions.StorageFormatSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return StorageFormatSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/DataSetRelationType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/history/DataSetRelationType.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/DataSetRelationType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/history/DataSetRelationType.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/DataSetPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/DataSetPermId.js
new file mode 100644
index 00000000000..2f0e25ba449
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/DataSetPermId.js
@@ -0,0 +1,19 @@
+/**
+ * Data set perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/dataset/id/IDataSetId" ], function(stjs, ObjectPermId, IDataSetId) {
+	/**
+	 * @param permId
+	 *            Data set perm id, e.g. "201108050937246-1031".
+	 */
+	var DataSetPermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(DataSetPermId, ObjectPermId, [ ObjectPermId, IDataSetId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.dataset.id.DataSetPermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return DataSetPermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/FileFormatTypePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/FileFormatTypePermId.js
new file mode 100644
index 00000000000..94fdf712602
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/FileFormatTypePermId.js
@@ -0,0 +1,19 @@
+/**
+ * File format type perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/dataset/id/IFileFormatTypeId" ], function(stjs, ObjectPermId, IFileFormatTypeId) {
+	/**
+	 * @param permId
+	 *            File format type perm id, e.g. "PROPRIETARY".
+	 */
+	var FileFormatTypePermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(FileFormatTypePermId, ObjectPermId, [ ObjectPermId, IFileFormatTypeId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.dataset.id.FileFormatTypePermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return FileFormatTypePermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/IDataSetId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/IDataSetId.js
new file mode 100644
index 00000000000..d1f942ff718
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/IDataSetId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies a data set in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IDataSetId = function() {
+	};
+	stjs.extend(IDataSetId, null, [ IObjectId ], null, {});
+	return IDataSetId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/IFileFormatTypeId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/IFileFormatTypeId.js
similarity index 76%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/IFileFormatTypeId.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/IFileFormatTypeId.js
index a02c9d434ca..b492c6edaef 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/IFileFormatTypeId.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/id/IFileFormatTypeId.js
@@ -3,7 +3,7 @@
  * 
  * @author pkupczyk
  */
-define([ "stjs", "dto/id/IObjectId" ], function(stjs, IObjectId) {
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
 	var IFileFormatTypeId = function() {
 	};
 	stjs.extend(IFileFormatTypeId, null, [ IObjectId ], null, {});
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/search/DataSetSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/search/DataSetSearchCriteria.js
new file mode 100644
index 00000000000..425756a7b59
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/search/DataSetSearchCriteria.js
@@ -0,0 +1,133 @@
+/**
+ * @author pkupczyk
+ */
+define([ "require", "stjs", "dto/common/search/AbstractEntitySearchCriteria", "dto/common/search/SearchOperator", "dto/dataset/search/DataSetSearchRelation", ,
+		"dto/experiment/search/ExperimentSearchCriteria", "dto/experiment/search/NoExperimentSearchCriteria", "dto/sample/search/SampleSearchCriteria", "dto/sample/search/NoSampleSearchCriteria" ],
+		function(require, stjs, AbstractEntitySearchCriteria, SearchOperator, DataSetSearchRelation) {
+			var DataSetSearchCriteria = function(relation) {
+				AbstractEntitySearchCriteria.call(this);
+				this.relation = relation ? relation : DataSetSearchRelation.DATASET;
+			};
+			stjs.extend(DataSetSearchCriteria, AbstractEntitySearchCriteria, [ AbstractEntitySearchCriteria ], function(constructor, prototype) {
+				prototype['@type'] = 'dto.dataset.search.DataSetSearchCriteria';
+				constructor.serialVersionUID = 1;
+				prototype.relation = null;
+				prototype.withParents = function() {
+					return this.addCriteria(new DataSetParentsSearchCriteria());
+				};
+				prototype.withChildren = function() {
+					return this.addCriteria(new DataSetChildrenSearchCriteria());
+				};
+				prototype.withContainer = function() {
+					return this.addCriteria(new DataSetContainerSearchCriteria());
+				};
+				prototype.withExperiment = function() {
+					var ExperimentSearchCriteria = require("dto/experiment/search/ExperimentSearchCriteria");
+					return this.addCriteria(new ExperimentSearchCriteria());
+				};
+				prototype.withoutExperiment = function() {
+					var NoExperimentSearchCriteria = require("dto/experiment/search/NoExperimentSearchCriteria");
+					return this.addCriteria(new NoExperimentSearchCriteria());
+				};
+				prototype.withSample = function() {
+					var SampleSearchCriteria = require("dto/sample/search/SampleSearchCriteria");
+					return this.addCriteria(new SampleSearchCriteria());
+				};
+				prototype.withoutSample = function() {
+					var NoSampleSearchCriteria = require("dto/sample/search/NoSampleSearchCriteria");
+					return this.addCriteria(new NoSampleSearchCriteria());
+				};
+				prototype.withOrOperator = function() {
+					return this.withOperator(SearchOperator.OR);
+				};
+				prototype.withAndOperator = function() {
+					return this.withOperator(SearchOperator.AND);
+				};
+				prototype.getRelation = function() {
+					return this.relation;
+				};
+				prototype.createBuilder = function() {
+					var builder = AbstractEntitySearchCriteria.prototype.createBuilder.call(this);
+					builder.setName(this.relation.name());
+					return builder;
+				};
+			}, {
+				relation : {
+					name : "Enum",
+					arguments : [ "DataSetSearchRelation" ]
+				},
+				operator : {
+					name : "Enum",
+					arguments : [ "SearchOperator" ]
+				},
+				criteria : {
+					name : "Collection",
+					arguments : [ "ISearchCriteria" ]
+				}
+			});
+
+			var DataSetParentsSearchCriteria = function() {
+				DataSetSearchCriteria.call(this, DataSetSearchRelation.PARENTS);
+			};
+			stjs.extend(DataSetParentsSearchCriteria, DataSetSearchCriteria, [ DataSetSearchCriteria ], function(constructor, prototype) {
+				prototype['@type'] = 'dto.dataset.search.DataSetParentsSearchCriteria';
+				constructor.serialVersionUID = 1;
+			}, {
+				relation : {
+					name : "Enum",
+					arguments : [ "DataSetSearchRelation" ]
+				},
+				operator : {
+					name : "Enum",
+					arguments : [ "SearchOperator" ]
+				},
+				criteria : {
+					name : "Collection",
+					arguments : [ "ISearchCriteria" ]
+				}
+			});
+
+			var DataSetChildrenSearchCriteria = function() {
+				DataSetSearchCriteria.call(this, DataSetSearchRelation.CHILDREN);
+			};
+			stjs.extend(DataSetChildrenSearchCriteria, DataSetSearchCriteria, [ DataSetSearchCriteria ], function(constructor, prototype) {
+				prototype['@type'] = 'dto.dataset.search.DataSetChildrenSearchCriteria';
+				constructor.serialVersionUID = 1;
+			}, {
+				relation : {
+					name : "Enum",
+					arguments : [ "DataSetSearchRelation" ]
+				},
+				operator : {
+					name : "Enum",
+					arguments : [ "SearchOperator" ]
+				},
+				criteria : {
+					name : "Collection",
+					arguments : [ "ISearchCriteria" ]
+				}
+			});
+
+			var DataSetContainerSearchCriteria = function() {
+				DataSetSearchCriteria.call(this, DataSetSearchRelation.CONTAINER);
+			};
+			stjs.extend(DataSetContainerSearchCriteria, DataSetSearchCriteria, [ DataSetSearchCriteria ], function(constructor, prototype) {
+				prototype['@type'] = 'dto.dataset.search.DataSetContainerSearchCriteria';
+				constructor.serialVersionUID = 1;
+			}, {
+				relation : {
+					name : "Enum",
+					arguments : [ "DataSetSearchRelation" ]
+				},
+				operator : {
+					name : "Enum",
+					arguments : [ "SearchOperator" ]
+				},
+				criteria : {
+					name : "Collection",
+					arguments : [ "ISearchCriteria" ]
+				}
+			});
+
+			return DataSetSearchCriteria;
+		})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DataSetSearchRelation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/search/DataSetSearchRelation.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DataSetSearchRelation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/search/DataSetSearchRelation.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/DataSetUpdate.js
similarity index 93%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetUpdate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/DataSetUpdate.js
index dacdf0e4368..46b68b226ff 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/DataSetUpdate.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/DataSetUpdate.js
@@ -1,7 +1,7 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/FieldUpdateValue", "dto/entity/IdListUpdateValue" ], function(stjs, FieldUpdateValue, IdListUpdateValue) {
+define([ "stjs", "dto/common/update/FieldUpdateValue", "dto/common/update/IdListUpdateValue" ], function(stjs, FieldUpdateValue, IdListUpdateValue) {
 	var DataSetUpdate = function() {
 		this.experimentId = new FieldUpdateValue();
 		this.sampleId = new FieldUpdateValue();
@@ -14,7 +14,7 @@ define([ "stjs", "dto/entity/FieldUpdateValue", "dto/entity/IdListUpdateValue" ]
 		this.childIds = new IdListUpdateValue();
 	};
 	stjs.extend(DataSetUpdate, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.DataSetUpdate';
+		prototype['@type'] = 'dto.dataset.update.DataSetUpdate';
 		constructor.serialVersionUID = 1;
 		prototype.dataSetId = null;
 
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/LinkedDataUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/LinkedDataUpdate.js
new file mode 100644
index 00000000000..a6e21a53da3
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/LinkedDataUpdate.js
@@ -0,0 +1,36 @@
+/**
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/update/FieldUpdateValue" ], function(stjs, FieldUpdateValue) {
+	var LinkedDataUpdate = function() {
+		this.externalCode = new FieldUpdateValue();
+		this.externalDmsId = new FieldUpdateValue();
+	};
+	stjs.extend(LinkedDataUpdate, null, [], function(constructor, prototype) {
+		prototype['@type'] = 'dto.dataset.update.LinkedDataUpdate';
+		constructor.serialVersionUID = 1;
+
+		prototype.getExternalCode = function() {
+			return this.externalCode;
+		};
+		prototype.setExternalCode = function(externalCode) {
+			this.externalCode.setValue(externalCode);
+		};
+		prototype.getExternalDmsId = function() {
+			return this.externalDmsId;
+		};
+		prototype.setExternalDmsId = function(externalDmsId) {
+			this.externalDmsId.setValue(externalDmsId);
+		};
+	}, {
+		externalCode : {
+			name : "FieldUpdateValue",
+			arguments : [ "String" ]
+		},
+		externalDmsId : {
+			name : "FieldUpdateValue",
+			arguments : [ "IExternalDmsId" ]
+		}
+	});
+	return LinkedDataUpdate;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/PhysicalDataUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/PhysicalDataUpdate.js
similarity index 78%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/PhysicalDataUpdate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/PhysicalDataUpdate.js
index dd60d20e8fa..9cc2902038c 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/dataset/PhysicalDataUpdate.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/dataset/update/PhysicalDataUpdate.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/FieldUpdateValue" ], function(stjs, FieldUpdateValue) {
+define([ "stjs", "dto/common/update/FieldUpdateValue" ], function(stjs, FieldUpdateValue) {
 	var PhysicalDataUpdate = function() {
 		this.fileFormatTypeId = new FieldUpdateValue();
 	};
 	stjs.extend(PhysicalDataUpdate, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.dataset.PhysicalDataUpdate';
+		prototype['@type'] = 'dto.dataset.update.PhysicalDataUpdate';
 		constructor.serialVersionUID = 1;
 
 		prototype.getFileFormatTypeId = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/DataStore.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/DataStore.js
new file mode 100644
index 00000000000..5dec028d686
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/DataStore.js
@@ -0,0 +1,63 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
+	var DataStore = function() {
+	};
+	stjs.extend(DataStore, null, [], function(constructor, prototype) {
+		prototype['@type'] = 'dto.datastore.DataStore';
+		constructor.serialVersionUID = 1;
+		prototype.fetchOptions = null;
+		prototype.code = null;
+		prototype.downloadUrl = null;
+		prototype.remoteUrl = null;
+		prototype.registrationDate = null;
+		prototype.modificationDate = null;
+
+		prototype.getFetchOptions = function() {
+			return this.fetchOptions;
+		};
+		prototype.setFetchOptions = function(fetchOptions) {
+			this.fetchOptions = fetchOptions;
+		};
+		prototype.getCode = function() {
+			return this.code;
+		};
+		prototype.setCode = function(code) {
+			this.code = code;
+		};
+		prototype.getDownloadUrl = function() {
+			return this.downloadUrl;
+		};
+		prototype.setDownloadUrl = function(downloadUrl) {
+			this.downloadUrl = downloadUrl;
+		};
+		prototype.getRemoteUrl = function() {
+			return this.remoteUrl;
+		};
+		prototype.setRemoteUrl = function(remoteUrl) {
+			this.remoteUrl = remoteUrl;
+		};
+		prototype.getRegistrationDate = function() {
+			return this.registrationDate;
+		};
+		prototype.setRegistrationDate = function(registrationDate) {
+			this.registrationDate = registrationDate;
+		};
+		prototype.getModificationDate = function() {
+			return this.modificationDate;
+		};
+		prototype.setModificationDate = function(modificationDate) {
+			this.modificationDate = modificationDate;
+		};
+		prototype.toString = function() {
+			return "DataStore " + this.code;
+		};
+	}, {
+		fetchOptions : "DataStoreFetchOptions",
+		registrationDate : "Date",
+		modificationDate : "Date"
+	});
+	return DataStore;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreFetchOptions.js
new file mode 100644
index 00000000000..989032dd98b
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreFetchOptions.js
@@ -0,0 +1,26 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/datastore/fetchoptions/DataStoreSortOptions" ], function(require, stjs, FetchOptions) {
+	var DataStoreFetchOptions = function() {
+	};
+	stjs.extend(DataStoreFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.datastore.fetchoptions.DataStoreFetchOptions';
+		constructor.serialVersionUID = 1;
+		prototype.sort = null;
+		prototype.sortBy = function() {
+			if (this.sort == null) {
+				var DataStoreSortOptions = require("dto/datastore/fetchoptions/DataStoreSortOptions");
+				this.sort = new DataStoreSortOptions();
+			}
+			return this.sort;
+		};
+		prototype.getSortBy = function() {
+			return this.sort;
+		};
+	}, {
+		sort : "DataStoreSortOptions"
+	});
+	return DataStoreFetchOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreSortOptions.js
new file mode 100644
index 00000000000..64e011ea550
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/fetchoptions/DataStoreSortOptions.js
@@ -0,0 +1,10 @@
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
+	var DataStoreSortOptions = function() {
+		SortOptions.call(this);
+	};
+	stjs.extend(DataStoreSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.person.fetchoptions.DataStoreSortOptions';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return DataStoreSortOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/DataStorePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/DataStorePermId.js
new file mode 100644
index 00000000000..53deb58f39b
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/DataStorePermId.js
@@ -0,0 +1,20 @@
+/**
+ * Data store perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/datastore/id/IDataStoreId" ], function(stjs, ObjectPermId, IDataStoreId) {
+
+	/**
+	 * @param permId
+	 *            Data store perm id, e.g. "DSS1".
+	 */
+	var DataStorePermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(DataStorePermId, ObjectPermId, [ ObjectPermId, IDataStoreId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.datastore.id.DataStorePermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return DataStorePermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/IDataStoreId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/IDataStoreId.js
new file mode 100644
index 00000000000..e5c52aa86ed
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/datastore/id/IDataStoreId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies a data store in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IDataStoreId = function() {
+	};
+	stjs.extend(IDataStoreId, null, [ IObjectId ], null, {});
+	return IDataStoreId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/AbstractObjectDeletionOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/AbstractObjectDeletionOptions.js
similarity index 85%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/AbstractObjectDeletionOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/AbstractObjectDeletionOptions.js
index 180b755f83b..f2af5c37707 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/AbstractObjectDeletionOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/AbstractObjectDeletionOptions.js
@@ -5,7 +5,7 @@ define([ "stjs" ], function(stjs) {
 	var AbstractObjectDeletionOptions = function() {
 	};
 	stjs.extend(AbstractObjectDeletionOptions, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.AbstractObjectDeletionOptions';
+		prototype['@type'] = 'dto.deletion.AbstractObjectDeletionOptions';
 		constructor.serialVersionUID = 1;
 		prototype.reason = null;
 		prototype.getReason = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/DeletedObject.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/DeletedObject.js
similarity index 85%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/DeletedObject.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/DeletedObject.js
index 3930287c2e7..10ec84db6bc 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/DeletedObject.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/DeletedObject.js
@@ -5,7 +5,7 @@ define([ "stjs" ], function(stjs) {
 	var DeletedObject = function() {
 	};
 	stjs.extend(DeletedObject, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.DeletedObject';
+		prototype['@type'] = 'dto.deletion.DeletedObject';
 		prototype.id = null;
 		prototype.getId = function() {
 			return this.id;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/Deletion.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/Deletion.js
similarity index 96%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/Deletion.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/Deletion.js
index ea2e7ae0b37..f178f3670f8 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/Deletion.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/Deletion.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 		this.deletedObjects = [];
 	};
 	stjs.extend(Deletion, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.Deletion';
+		prototype['@type'] = 'dto.deletion.Deletion';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.id = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletedObjectFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletedObjectFetchOptions.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletedObjectFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletedObjectFetchOptions.js
index 364b1cb075c..92f1d2a5ec5 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletedObjectFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletedObjectFetchOptions.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/fetchoptions/EmptyFetchOptions" ], function(stjs, EmptyFetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/EmptyFetchOptions" ], function(stjs, EmptyFetchOptions) {
 	var DeletedObjectFetchOptions = function() {
 	};
 	stjs.extend(DeletedObjectFetchOptions, EmptyFetchOptions, [ EmptyFetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.deletion.DeletedObjectFetchOptions';
+		prototype['@type'] = 'dto.deletion.fetchoptions.DeletedObjectFetchOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return DeletedObjectFetchOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletionFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletionFetchOptions.js
similarity index 68%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletionFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletionFetchOptions.js
index e65ccdeba9e..a73b6a1e68b 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletionFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletionFetchOptions.js
@@ -1,18 +1,18 @@
 /**
  * @author pkupczyk
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/deletion/DeletedObjectFetchOptions", "dto/fetchoptions/deletion/DeletionSortOptions" ], function(require, stjs,
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/deletion/fetchoptions/DeletedObjectFetchOptions", "dto/deletion/fetchoptions/DeletionSortOptions" ], function(require, stjs,
 		FetchOptions) {
 	var DeletionFetchOptions = function() {
 	};
 	stjs.extend(DeletionFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.deletion.DeletionFetchOptions';
+		prototype['@type'] = 'dto.deletion.fetchoptions.DeletionFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.deletedObjects = null;
 		prototype.sort = null;
 		prototype.fetchDeletedObjects = function() {
 			if (this.deletedObjects == null) {
-				var DeletedObjectFetchOptions = require("dto/fetchoptions/deletion/DeletedObjectFetchOptions");
+				var DeletedObjectFetchOptions = require("dto/deletion/fetchoptions/DeletedObjectFetchOptions");
 				this.deletedObjects = new DeletedObjectFetchOptions();
 			}
 			return this.deletedObjects;
@@ -22,7 +22,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/d
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var DeletionSortOptions = require("dto/fetchoptions/deletion/DeletionSortOptions");
+				var DeletionSortOptions = require("dto/deletion/fetchoptions/DeletionSortOptions");
 				this.sort = new DeletionSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletionSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletionSortOptions.js
similarity index 59%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletionSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletionSortOptions.js
index b5694be3a55..961322c5980 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/deletion/DeletionSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/fetchoptions/DeletionSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var DeletionSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(DeletionSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.deletion.DeletionSortOptions';
+		prototype['@type'] = 'dto.deletion.fetchoptions.DeletionSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return DeletionSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/DeletionTechId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/DeletionTechId.js
new file mode 100644
index 00000000000..ea2dcbec79d
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/DeletionTechId.js
@@ -0,0 +1,13 @@
+/**
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectTechId", "dto/deletion/id/IDeletionId" ], function(stjs, ObjectTechId, IDeletionId) {
+	var DeletionTechId = function(techId) {
+		ObjectTechId.call(this, techId);
+	};
+	stjs.extend(DeletionTechId, ObjectTechId, [ ObjectTechId, IDeletionId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.deletion.id.DeletionTechId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return DeletionTechId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/IDeletionId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/IDeletionId.js
new file mode 100644
index 00000000000..47b9279154d
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/deletion/id/IDeletionId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies a deletion in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IDeletionId = function() {
+	};
+	stjs.extend(IDeletionId, null, [ IObjectId ], null, {});
+	return IDeletionId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/EntityTypePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/EntityTypePermId.js
new file mode 100644
index 00000000000..4a3eabe134c
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/EntityTypePermId.js
@@ -0,0 +1,19 @@
+/**
+ * Entity type perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/entitytype/id/IEntityTypeId" ], function(stjs, ObjectPermId, IEntityTypeId) {
+	/**
+	 * @param permId
+	 *            Entity type perm id, e.g. "MY_ENTITY_TYPE".
+	 */
+	var EntityTypePermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(EntityTypePermId, ObjectPermId, [ ObjectPermId, IEntityTypeId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.entitytype.id.EntityTypePermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return EntityTypePermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/IEntityTypeId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/IEntityTypeId.js
new file mode 100644
index 00000000000..2122037eeb3
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/id/IEntityTypeId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies an entity type in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IEntityTypeId = function() {
+	};
+	stjs.extend(IEntityTypeId, null, [ IObjectId ], null, {});
+	return IEntityTypeId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/EntityTypeSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/search/EntityTypeSearchCriteria.js
similarity index 56%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/EntityTypeSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/search/EntityTypeSearchCriteria.js
index fd795ffdc6c..4dde393f1e3 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/EntityTypeSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entitytype/search/EntityTypeSearchCriteria.js
@@ -1,25 +1,24 @@
 /**
  * @author pkupczyk
  */
-define([ "require", "stjs", "dto/search/AbstractObjectSearchCriteria",
-         "dto/search/CodeSearchCriteria", "dto/search/PermIdSearchCriteria", "dto/search/AbstractCompositeSearchCriteria"], 
-		function(require, stjs, AbstractObjectSearchCriteria) {
+define([ "require", "stjs", "dto/common/search/AbstractObjectSearchCriteria", "dto/common/search/CodeSearchCriteria", "dto/common/search/PermIdSearchCriteria",
+		"dto/common/search/AbstractCompositeSearchCriteria" ], function(require, stjs, AbstractObjectSearchCriteria) {
 	var EntityTypeSearchCriteria = function() {
 		AbstractObjectSearchCriteria.call(this);
 	};
 	stjs.extend(EntityTypeSearchCriteria, AbstractObjectSearchCriteria, [ AbstractObjectSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.EntityTypeSearchCriteria';
+		prototype['@type'] = 'dto.entitytype.search.EntityTypeSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.withCode = function() {
-			var CodeSearchCriteria = require("dto/search/CodeSearchCriteria");
+			var CodeSearchCriteria = require("dto/common/search/CodeSearchCriteria");
 			return this.addCriteria(new CodeSearchCriteria());
 		};
 		prototype.withPermId = function() {
-			var PermIdSearchCriteria = require("dto/search/PermIdSearchCriteria");
+			var PermIdSearchCriteria = require("dto/common/search/PermIdSearchCriteria");
 			return this.addCriteria(new PermIdSearchCriteria());
 		};
 		prototype.createBuilder = function() {
-			var AbstractCompositeSearchCriteria = require("dto/search/AbstractCompositeSearchCriteria");
+			var AbstractCompositeSearchCriteria = require("dto/common/search/AbstractCompositeSearchCriteria");
 			var builder = AbstractCompositeSearchCriteria.prototype.createBuilder.call(this);
 			builder.setName("TYPE");
 			return builder;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/Experiment.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/Experiment.js
similarity index 99%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/Experiment.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/Experiment.js
index f8cec13ee9e..00274a84a93 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/Experiment.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/Experiment.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Experiment = function() {
 	};
 	stjs.extend(Experiment, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.experiment.Experiment';
+		prototype['@type'] = 'dto.experiment.Experiment';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/ExperimentType.js
similarity index 95%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/ExperimentType.js
index 6e640fefdaf..706f7fb5fb8 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentType.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/ExperimentType.js
@@ -6,7 +6,7 @@ define([ "stjs" ], function(stjs) {
 	var ExperimentType = function() {
 	};
 	stjs.extend(ExperimentType, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.experiment.ExperimentType';
+		prototype['@type'] = 'dto.experiment.ExperimentType';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperation.js
new file mode 100644
index 00000000000..33dbd998bdd
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperation.js
@@ -0,0 +1,17 @@
+/**
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/operation/IOperation" ], function(stjs, IOperation) {
+	var CreateExperimentsOperation = function() {
+	};
+	stjs.extend(CreateExperimentsOperation, null, [ IOperation ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.experiment.create.CreateExperimentsOperation';
+		prototype.newExperiments = null;
+	}, {
+		newExperiments : {
+			name : "List",
+			arguments : [ "ExperimentCreation" ]
+		}
+	});
+	return CreateExperimentsOperation;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperationResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperationResult.js
new file mode 100644
index 00000000000..b6cd1ac2604
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/CreateExperimentsOperationResult.js
@@ -0,0 +1,17 @@
+/**
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/operation/IOperationResult" ], function(stjs, IOperationResult) {
+	var CreateExperimentsOperationResult = function() {
+	};
+	stjs.extend(CreateExperimentsOperationResult, null, [ IOperationResult ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.experiment.create.CreateExperimentsOperationResult';
+		prototype.newExperimentIds = null;
+	}, {
+		newExperimentIds : {
+			name : "List",
+			arguments : [ "ExperimentPermId" ]
+		}
+	});
+	return CreateExperimentsOperationResult;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentCreation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/ExperimentCreation.js
similarity index 96%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentCreation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/ExperimentCreation.js
index 69cb53e4621..e3310f58e76 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentCreation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/create/ExperimentCreation.js
@@ -6,7 +6,7 @@ define([ "stjs" ], function(stjs) {
 		this.properties = {};
 	};
 	stjs.extend(ExperimentCreation, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.experiment.ExperimentCreation';
+		prototype['@type'] = 'dto.experiment.create.ExperimentCreation';
 		constructor.serialVersionUID = 1;
 		prototype.typeId = null;
 		prototype.projectId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/experiment/ExperimentDeletionOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/delete/ExperimentDeletionOptions.js
similarity index 62%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/experiment/ExperimentDeletionOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/delete/ExperimentDeletionOptions.js
index 3fc573cf95c..055521602a1 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/experiment/ExperimentDeletionOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/delete/ExperimentDeletionOptions.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
+define([ "stjs", "dto/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
 	var ExperimentDeletionOptions = function() {
 		AbstractObjectDeletionOptions.call(this);
 	};
 	stjs.extend(ExperimentDeletionOptions, AbstractObjectDeletionOptions, [ AbstractObjectDeletionOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.experiment.ExperimentDeletionOptions';
+		prototype['@type'] = 'dto.experiment.delete.ExperimentDeletionOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return ExperimentDeletionOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentFetchOptions.js
similarity index 76%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentFetchOptions.js
index 51de129a5c3..3872fd101b2 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentFetchOptions.js
@@ -2,14 +2,14 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/experiment/ExperimentTypeFetchOptions', 'dto/fetchoptions/project/ProjectFetchOptions',
-		'dto/fetchoptions/property/PropertyFetchOptions', 'dto/fetchoptions/tag/TagFetchOptions', 'dto/fetchoptions/person/PersonFetchOptions', 'dto/fetchoptions/attachment/AttachmentFetchOptions',
-		'dto/fetchoptions/dataset/DataSetFetchOptions', 'dto/fetchoptions/sample/SampleFetchOptions', 'dto/fetchoptions/history/HistoryEntryFetchOptions',
-		'dto/fetchoptions/material/MaterialFetchOptions', 'dto/fetchoptions/experiment/ExperimentSortOptions' ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", 'dto/experiment/fetchoptions/ExperimentTypeFetchOptions', 'dto/project/fetchoptions/ProjectFetchOptions',
+		'dto/property/fetchoptions/PropertyFetchOptions', 'dto/tag/fetchoptions/TagFetchOptions', 'dto/person/fetchoptions/PersonFetchOptions', 'dto/attachment/fetchoptions/AttachmentFetchOptions',
+		'dto/dataset/fetchoptions/DataSetFetchOptions', 'dto/sample/fetchoptions/SampleFetchOptions', 'dto/history/fetchoptions/HistoryEntryFetchOptions',
+		'dto/material/fetchoptions/MaterialFetchOptions', 'dto/experiment/fetchoptions/ExperimentSortOptions' ], function(require, stjs, FetchOptions) {
 	var ExperimentFetchOptions = function() {
 	};
 	stjs.extend(ExperimentFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.experiment.ExperimentFetchOptions';
+		prototype['@type'] = 'dto.experiment.fetchoptions.ExperimentFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.type = null;
 		prototype.project = null;
@@ -25,7 +25,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		prototype.sort = null;
 		prototype.withType = function() {
 			if (this.type == null) {
-				var ExperimentTypeFetchOptions = require("dto/fetchoptions/experiment/ExperimentTypeFetchOptions");
+				var ExperimentTypeFetchOptions = require("dto/experiment/fetchoptions/ExperimentTypeFetchOptions");
 				this.type = new ExperimentTypeFetchOptions();
 			}
 			return this.type;
@@ -38,7 +38,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withProject = function() {
 			if (this.project == null) {
-				var ProjectFetchOptions = require("dto/fetchoptions/project/ProjectFetchOptions");
+				var ProjectFetchOptions = require("dto/project/fetchoptions/ProjectFetchOptions");
 				this.project = new ProjectFetchOptions();
 			}
 			return this.project;
@@ -51,7 +51,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withDataSets = function() {
 			if (this.dataSets == null) {
-				var DataSetFetchOptions = require("dto/fetchoptions/dataset/DataSetFetchOptions");
+				var DataSetFetchOptions = require("dto/dataset/fetchoptions/DataSetFetchOptions");
 				this.dataSets = new DataSetFetchOptions();
 			}
 			return this.dataSets;
@@ -64,7 +64,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withSamples = function() {
 			if (this.samples == null) {
-				var SampleFetchOptions = require("dto/fetchoptions/sample/SampleFetchOptions");
+				var SampleFetchOptions = require("dto/sample/fetchoptions/SampleFetchOptions");
 				this.samples = new SampleFetchOptions();
 			}
 			return this.samples;
@@ -77,7 +77,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withHistory = function() {
 			if (this.history == null) {
-				var HistoryEntryFetchOptions = require("dto/fetchoptions/history/HistoryEntryFetchOptions");
+				var HistoryEntryFetchOptions = require("dto/history/fetchoptions/HistoryEntryFetchOptions");
 				this.history = new HistoryEntryFetchOptions();
 			}
 			return this.history;
@@ -90,7 +90,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withProperties = function() {
 			if (this.properties == null) {
-				var PropertyFetchOptions = require("dto/fetchoptions/property/PropertyFetchOptions");
+				var PropertyFetchOptions = require("dto/property/fetchoptions/PropertyFetchOptions");
 				this.properties = new PropertyFetchOptions();
 			}
 			return this.properties;
@@ -103,7 +103,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withMaterialProperties = function() {
 			if (this.materialProperties == null) {
-				var MaterialFetchOptions = require("dto/fetchoptions/material/MaterialFetchOptions");
+				var MaterialFetchOptions = require("dto/material/fetchoptions/MaterialFetchOptions");
 				this.materialProperties = new MaterialFetchOptions();
 			}
 			return this.materialProperties;
@@ -116,7 +116,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withTags = function() {
 			if (this.tags == null) {
-				var TagFetchOptions = require("dto/fetchoptions/tag/TagFetchOptions");
+				var TagFetchOptions = require("dto/tag/fetchoptions/TagFetchOptions");
 				this.tags = new TagFetchOptions();
 			}
 			return this.tags;
@@ -129,7 +129,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withRegistrator = function() {
 			if (this.registrator == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.registrator = new PersonFetchOptions();
 			}
 			return this.registrator;
@@ -142,7 +142,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withModifier = function() {
 			if (this.modifier == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.modifier = new PersonFetchOptions();
 			}
 			return this.modifier;
@@ -155,7 +155,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.withAttachments = function() {
 			if (this.attachments == null) {
-				var AttachmentFetchOptions = require("dto/fetchoptions/attachment/AttachmentFetchOptions");
+				var AttachmentFetchOptions = require("dto/attachment/fetchoptions/AttachmentFetchOptions");
 				this.attachments = new AttachmentFetchOptions();
 			}
 			return this.attachments;
@@ -168,7 +168,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/e
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var ExperimentSortOptions = require("dto/fetchoptions/experiment/ExperimentSortOptions");
+				var ExperimentSortOptions = require("dto/experiment/fetchoptions/ExperimentSortOptions");
 				this.sort = new ExperimentSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentSortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentSortOptions.js
index 36006336e54..81c9c8639e3 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
 	var ExperimentSortOptions = function() {
 		EntityWithPropertiesSortOptions.call(this);
 	};
 	stjs.extend(ExperimentSortOptions, EntityWithPropertiesSortOptions, [ EntityWithPropertiesSortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.experiment.ExperimentSortOptions';
+		prototype['@type'] = 'dto.experiment.fetchoptions.ExperimentSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return ExperimentSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentTypeFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentTypeFetchOptions.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentTypeFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentTypeFetchOptions.js
index 25765c86bb1..09b7b78f6fc 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentTypeFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentTypeFetchOptions.js
@@ -2,16 +2,16 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/experiment/ExperimentTypeSortOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions", "dto/experiment/fetchoptions/ExperimentTypeSortOptions" ], function(stjs, FetchOptions) {
 	var ExperimentTypeFetchOptions = function() {
 	};
 	stjs.extend(ExperimentTypeFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.experiment.ExperimentTypeFetchOptions';
+		prototype['@type'] = 'dto.experiment.fetchoptions.ExperimentTypeFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.sort = null;
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var ExperimentTypeSortOptions = require("dto/fetchoptions/experiment/ExperimentTypeSortOptions");
+				var ExperimentTypeSortOptions = require("dto/experiment/fetchoptions/ExperimentTypeSortOptions");
 				this.sort = new ExperimentTypeSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentTypeSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentTypeSortOptions.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentTypeSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentTypeSortOptions.js
index b22d4534b84..af6f3d92150 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/experiment/ExperimentTypeSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/fetchoptions/ExperimentTypeSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var ExperimentTypeSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(ExperimentTypeSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.experiment.ExperimentTypeSortOptions';
+		prototype['@type'] = 'dto.experiment.fetchoptions.ExperimentTypeSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return ExperimentTypeSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/ExperimentRelationType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/history/ExperimentRelationType.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/ExperimentRelationType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/history/ExperimentRelationType.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentIdentifier.js
new file mode 100644
index 00000000000..b19c17ebd17
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentIdentifier.js
@@ -0,0 +1,20 @@
+/**
+ * Experiment identifier.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectIdentifier", "dto/experiment/id/IExperimentId" ], function(stjs, ObjectIdentifier, IExperimentId) {
+	/**
+	 * @param identifier
+	 *            Experiment identifier, e.g.
+	 *            "/MY_SPACE/MY_PROJECT/MY_EXPERIMENT".
+	 */
+	var ExperimentIdentifier = function(identifier) {
+		ObjectIdentifier.call(this, identifier);
+	};
+	stjs.extend(ExperimentIdentifier, ObjectIdentifier, [ ObjectIdentifier, IExperimentId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.experiment.id.ExperimentIdentifier';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return ExperimentIdentifier;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentPermId.js
new file mode 100644
index 00000000000..b6ae9e9e9a4
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/ExperimentPermId.js
@@ -0,0 +1,19 @@
+/**
+ * Experiment perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/experiment/id/IExperimentId" ], function(stjs, ObjectPermId, IExperimentId) {
+	/**
+	 * @param permId
+	 *            Experiment perm id, e.g. "201108050937246-1031".
+	 */
+	var ExperimentPermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(ExperimentPermId, ObjectPermId, [ ObjectPermId, IExperimentId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.experiment.id.ExperimentPermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return ExperimentPermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/IExperimentId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/IExperimentId.js
new file mode 100644
index 00000000000..1f9ae82d830
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/id/IExperimentId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies an experiment in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IExperimentId = function() {
+	};
+	stjs.extend(IExperimentId, null, [ IObjectId ], null, {});
+	return IExperimentId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/ListExperimentsOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/list/ListExperimentsOperation.js
similarity index 58%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/ListExperimentsOperation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/list/ListExperimentsOperation.js
index 202ec902ad6..29ca80c53d1 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/ListExperimentsOperation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/list/ListExperimentsOperation.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperation" ], function(stjs, IOperation) {
+define([ "stjs", "dto/common/operation/IOperation" ], function(stjs, IOperation) {
 	var ListExperimentsOperation = function() {
 	};
 	stjs.extend(ListExperimentsOperation, null, [ IOperation ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.experiment.ListExperimentsOperation';
+		prototype['@type'] = 'dto.experiment.list.ListExperimentsOperation';
 	}, {});
 	return ListExperimentsOperation;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/ListExperimentsOperationResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/list/ListExperimentsOperationResult.js
similarity index 58%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/ListExperimentsOperationResult.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/list/ListExperimentsOperationResult.js
index d88d9152e8b..489783de3af 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/ListExperimentsOperationResult.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/list/ListExperimentsOperationResult.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperationResult" ], function(stjs, IOperationResult) {
+define([ "stjs", "dto/common/operation/IOperationResult" ], function(stjs, IOperationResult) {
 	var ListExperimentsOperationResult = function() {
 	};
 	stjs.extend(ListExperimentsOperationResult, null, [ IOperationResult ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.experiment.ListExperimentsOperationResult';
+		prototype['@type'] = 'dto.experiment.list.ListExperimentsOperationResult';
 	}, {});
 	return ListExperimentsOperationResult;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ExperimentSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/ExperimentSearchCriteria.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ExperimentSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/ExperimentSearchCriteria.js
index 610d760727b..984baa33055 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ExperimentSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/ExperimentSearchCriteria.js
@@ -1,17 +1,16 @@
 /**
  * @author pkupczyk
  */
-define([ "require", "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/search/SearchOperator",
-         "dto/search/ProjectSearchCriteria"], 
-		function(require, stjs, AbstractEntitySearchCriteria, SearchOperator) {
+define([ "require", "stjs", "dto/common/search/AbstractEntitySearchCriteria", "dto/common/search/SearchOperator", "dto/project/search/ProjectSearchCriteria" ], function(require, stjs,
+		AbstractEntitySearchCriteria, SearchOperator) {
 	var ExperimentSearchCriteria = function() {
 		AbstractEntitySearchCriteria.call(this);
 	};
 	stjs.extend(ExperimentSearchCriteria, AbstractEntitySearchCriteria, [ AbstractEntitySearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.ExperimentSearchCriteria';
+		prototype['@type'] = 'dto.experiment.search.ExperimentSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.withProject = function() {
-			var ProjectSearchCriteria = require("dto/search/ProjectSearchCriteria");
+			var ProjectSearchCriteria = require("dto/project/search/ProjectSearchCriteria");
 			return this.addCriteria(new ProjectSearchCriteria());
 		};
 		prototype.withOrOperator = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoExperimentSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/NoExperimentSearchCriteria.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoExperimentSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/NoExperimentSearchCriteria.js
index 441d6c2be67..042279dc116 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoExperimentSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/NoExperimentSearchCriteria.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
+define([ "stjs", "dto/common/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
 	var NoExperimentSearchCriteria = function() {
 	};
 	stjs.extend(NoExperimentSearchCriteria, null, [ ISearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NoExperimentSearchCriteria';
+		prototype['@type'] = 'dto.experiment.search.NoExperimentSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return NoExperimentSearchCriteria;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/SearchForExperimentsOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/SearchExperimentsOperation.js
similarity index 59%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/SearchForExperimentsOperation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/SearchExperimentsOperation.js
index 31d02cd7900..efaf1fb36a6 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/SearchForExperimentsOperation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/SearchExperimentsOperation.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperation" ], function(stjs, IOperation) {
+define([ "stjs", "dto/common/operation/IOperation" ], function(stjs, IOperation) {
 	var SearchForExperimentsOperation = function() {
 	};
 	stjs.extend(SearchForExperimentsOperation, null, [ IOperation ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.experiment.SearchForExperimentsOperation';
+		prototype['@type'] = 'dto.experiment.search.SearchExperimentsOperation';
 	}, {});
 	return SearchForExperimentsOperation;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/SearchForExperimentsOperationResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/SearchExperimentsOperationResult.js
similarity index 59%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/SearchForExperimentsOperationResult.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/SearchExperimentsOperationResult.js
index 436859ca84c..2f0884bb81c 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/SearchForExperimentsOperationResult.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/search/SearchExperimentsOperationResult.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperationResult" ], function(stjs, IOperationResult) {
+define([ "stjs", "dto/common/operation/IOperationResult" ], function(stjs, IOperationResult) {
 	var SearchForExperimentsOperationResult = function() {
 	};
 	stjs.extend(SearchForExperimentsOperationResult, null, [ IOperationResult ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.experiment.SearchForExperimentsOperationResult';
+		prototype['@type'] = 'dto.experiment.search.SearchExperimentsOperationResult';
 	}, {});
 	return SearchForExperimentsOperationResult;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/ExperimentUpdate.js
similarity index 85%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentUpdate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/ExperimentUpdate.js
index 016773d408f..a506301c8ee 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/experiment/ExperimentUpdate.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/ExperimentUpdate.js
@@ -1,7 +1,7 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/FieldUpdateValue", "dto/entity/IdListUpdateValue", "dto/entity/AttachmentListUpdateValue" ], function(stjs, FieldUpdateValue, IdListUpdateValue,
+define([ "stjs", "dto/common/update/FieldUpdateValue", "dto/common/update/IdListUpdateValue", "dto/attachment/update/AttachmentListUpdateValue" ], function(stjs, FieldUpdateValue, IdListUpdateValue,
 		AttachmentListUpdateValue) {
 	var ExperimentUpdate = function() {
 		this.properties = {};
@@ -10,7 +10,7 @@ define([ "stjs", "dto/entity/FieldUpdateValue", "dto/entity/IdListUpdateValue",
 		this.attachments = new AttachmentListUpdateValue();
 	};
 	stjs.extend(ExperimentUpdate, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.experiment.ExperimentUpdate';
+		prototype['@type'] = 'dto.experiment.update.ExperimentUpdate';
 		constructor.serialVersionUID = 1;
 		prototype.experimentId = null;
 		prototype.getExperimentId = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/UpdateExperimentsOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/UpdateExperimentsOperation.js
similarity index 58%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/UpdateExperimentsOperation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/UpdateExperimentsOperation.js
index d61d820a639..eadc2037532 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/UpdateExperimentsOperation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/UpdateExperimentsOperation.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperation" ], function(stjs, IOperation) {
+define([ "stjs", "dto/common/operation/IOperation" ], function(stjs, IOperation) {
 	var UpdateExperimentsOperation = function() {
 	};
 	stjs.extend(UpdateExperimentsOperation, null, [ IOperation ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.experiment.UpdateExperimentsOperation';
+		prototype['@type'] = 'dto.experiment.update.UpdateExperimentsOperation';
 	}, {});
 	return UpdateExperimentsOperation;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/UpdateExperimentsOperationResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/UpdateExperimentsOperationResult.js
similarity index 58%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/UpdateExperimentsOperationResult.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/UpdateExperimentsOperationResult.js
index aa24ef6d878..a59db7f4a15 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/UpdateExperimentsOperationResult.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/experiment/update/UpdateExperimentsOperationResult.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperationResult" ], function(stjs, IOperationResult) {
+define([ "stjs", "dto/common/operation/IOperationResult" ], function(stjs, IOperationResult) {
 	var UpdateExperimentsOperationResult = function() {
 	};
 	stjs.extend(UpdateExperimentsOperationResult, null, [ IOperationResult ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.experiment.UpdateExperimentsOperationResult';
+		prototype['@type'] = 'dto.experiment.update.UpdateExperimentsOperationResult';
 	}, {});
 	return UpdateExperimentsOperationResult;
 })
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/ExternalDms.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/ExternalDms.js
new file mode 100644
index 00000000000..176dd3ac0cc
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/ExternalDms.js
@@ -0,0 +1,54 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
+	var ExternalDms = function() {
+	};
+	stjs.extend(ExternalDms, null, [], function(constructor, prototype) {
+		prototype['@type'] = 'dto.externaldms.ExternalDms';
+		constructor.serialVersionUID = 1;
+		prototype.fetchOptions = null;
+		prototype.code = null;
+		prototype.label = null;
+		prototype.urlTemplate = null;
+		prototype.openbis = null;
+
+		prototype.getFetchOptions = function() {
+			return this.fetchOptions;
+		};
+		prototype.setFetchOptions = function(fetchOptions) {
+			this.fetchOptions = fetchOptions;
+		};
+		prototype.getCode = function() {
+			return this.code;
+		};
+		prototype.setCode = function(code) {
+			this.code = code;
+		};
+		prototype.getLabel = function() {
+			return this.label;
+		};
+		prototype.setLabel = function(label) {
+			this.label = label;
+		};
+		prototype.getUrlTemplate = function() {
+			return this.urlTemplate;
+		};
+		prototype.setUrlTemplate = function(urlTemplate) {
+			this.urlTemplate = urlTemplate;
+		};
+		prototype.isOpenbis = function() {
+			return this.openbis;
+		};
+		prototype.setOpenbis = function(openbis) {
+			this.openbis = openbis;
+		};
+		prototype.toString = function() {
+			return "ExternalDms " + this.code;
+		};
+	}, {
+		fetchOptions : "ExternalDmsFetchOptions"
+	});
+	return ExternalDms;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsFetchOptions.js
new file mode 100644
index 00000000000..0d3803af809
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsFetchOptions.js
@@ -0,0 +1,26 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/externaldms/fetchoptions/ExternalDmsSortOptions" ], function(require, stjs, FetchOptions) {
+	var ExternalDmsFetchOptions = function() {
+	};
+	stjs.extend(ExternalDmsFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.externaldms.fetchoptions.ExternalDmsFetchOptions';
+		constructor.serialVersionUID = 1;
+		prototype.sort = null;
+		prototype.sortBy = function() {
+			if (this.sort == null) {
+				var ExternalDmsSortOptions = require("dto/externaldms/fetchoptions/ExternalDmsSortOptions");
+				this.sort = new ExternalDmsSortOptions();
+			}
+			return this.sort;
+		};
+		prototype.getSortBy = function() {
+			return this.sort;
+		};
+	}, {
+		sort : "ExternalDmsSortOptions"
+	});
+	return ExternalDmsFetchOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsSortOptions.js
new file mode 100644
index 00000000000..e1b6df795fb
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/fetchoptions/ExternalDmsSortOptions.js
@@ -0,0 +1,10 @@
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
+	var ExternalDmsSortOptions = function() {
+		SortOptions.call(this);
+	};
+	stjs.extend(ExternalDmsSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.externaldms.fetchoptions.ExternalDmsSortOptions';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return ExternalDmsSortOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/ExternalDmsPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/ExternalDmsPermId.js
new file mode 100644
index 00000000000..60ff47dacea
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/ExternalDmsPermId.js
@@ -0,0 +1,20 @@
+/**
+ * External data management system perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/externaldms/id/IExternalDmsId" ], function(stjs, ObjectPermId, IExternalDmsId) {
+
+	/**
+	 * @param permId
+	 *            External data management system perm id, e.g. "DMS1".
+	 */
+	var ExternalDmsPermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(ExternalDmsPermId, ObjectPermId, [ ObjectPermId, IExternalDmsId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.externaldms.id.ExternalDmsPermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return ExternalDmsPermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/IExternalDmsId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/IExternalDmsId.js
new file mode 100644
index 00000000000..40b0ae8e9e5
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/externaldms/id/IExternalDmsId.js
@@ -0,0 +1,12 @@
+/**
+ * Holds information that uniquely identifies an external data management system
+ * in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IExternalDmsId = function() {
+	};
+	stjs.extend(IExternalDmsId, null, [ IObjectId ], null, {});
+	return IExternalDmsId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/attachment/AttachmentFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/attachment/AttachmentFetchOptions.js
deleted file mode 100644
index 7c38b413055..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/attachment/AttachmentFetchOptions.js
+++ /dev/null
@@ -1,71 +0,0 @@
-/**
- * Class automatically generated with
- * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
- */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/person/PersonFetchOptions", "dto/fetchoptions/EmptyFetchOptions", "dto/fetchoptions/attachment/AttachmentSortOptions" ],
-		function(require, stjs, FetchOptions) {
-			var AttachmentFetchOptions = function() {
-			};
-			stjs.extend(AttachmentFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-				prototype['@type'] = 'dto.fetchoptions.attachment.AttachmentFetchOptions';
-				constructor.serialVersionUID = 1;
-				prototype.registrator = null;
-				prototype.previousVersion = null;
-				prototype.content = null;
-				prototype.sort = null;
-				prototype.withRegistrator = function() {
-					if (this.registrator == null) {
-						var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
-						this.registrator = new PersonFetchOptions();
-					}
-					return this.registrator;
-				};
-				prototype.withRegistratorUsing = function(fetchOptions) {
-					return this.registrator = fetchOptions;
-				};
-				prototype.hasRegistrator = function() {
-					return this.registrator != null;
-				};
-				prototype.withPreviousVersion = function() {
-					if (this.previousVersion == null) {
-						this.previousVersion = new AttachmentFetchOptions();
-					}
-					return this.previousVersion;
-				};
-				prototype.withPreviousVersionUsing = function(fetchOptions) {
-					return this.previousVersion = fetchOptions;
-				};
-				prototype.hasPreviousVersion = function() {
-					return this.previousVersion != null;
-				};
-				prototype.withContent = function() {
-					if (this.content == null) {
-						var EmptyFetchOptions = require("dto/fetchoptions/EmptyFetchOptions");
-						this.content = new EmptyFetchOptions();
-					}
-					return this.content;
-				};
-				prototype.withContentUsing = function(fetchOptions) {
-					return this.content = fetchOptions;
-				};
-				prototype.hasContent = function() {
-					return this.content != null;
-				};
-				prototype.sortBy = function() {
-					if (this.sort == null) {
-						var AttachmentSortOptions = require("dto/fetchoptions/attachment/AttachmentSortOptions");
-						this.sort = new AttachmentSortOptions();
-					}
-					return this.sort;
-				};
-				prototype.getSortBy = function() {
-					return this.sort;
-				};
-			}, {
-				registrator : "PersonFetchOptions",
-				previousVersion : "AttachmentFetchOptions",
-				content : "EmptyFetchOptions",
-				sort : "AttachmentSortOptions"
-			});
-			return AttachmentFetchOptions;
-		})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyFetchOptions.js
deleted file mode 100644
index 52e3efaeada..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyFetchOptions.js
+++ /dev/null
@@ -1,42 +0,0 @@
-/**
- * Class automatically generated with
- * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
- */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/person/PersonFetchOptions", "dto/fetchoptions/vocabulary/VocabularySortOptions" ],
-		function(require, stjs, FetchOptions) {
-			var VocabularyFetchOptions = function() {
-			};
-			stjs.extend(VocabularyFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-				prototype['@type'] = 'dto.fetchoptions.vocabulary.VocabularyFetchOptions';
-				constructor.serialVersionUID = 1;
-				prototype.registrator = null;
-				prototype.sort = null;
-				prototype.withRegistrator = function() {
-					if (this.registrator == null) {
-						var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
-						this.registrator = new PersonFetchOptions();
-					}
-					return this.registrator;
-				};
-				prototype.withRegistratorUsing = function(fetchOptions) {
-					return this.registrator = fetchOptions;
-				};
-				prototype.hasRegistrator = function() {
-					return this.registrator != null;
-				};
-				prototype.sortBy = function() {
-					if (this.sort == null) {
-						var VocabularySortOptions = require("dto/fetchoptions/vocabulary/VocabularySortOptions");
-						this.sort = new VocabularySortOptions();
-					}
-					return this.sort;
-				};
-				prototype.getSortBy = function() {
-					return this.sort;
-				};
-			}, {
-				registrator : "PersonFetchOptions",
-				sort : "VocabularySortOptions"
-			});
-			return VocabularyFetchOptions;
-		})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/HistoryEntry.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/HistoryEntry.js
similarity index 95%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/HistoryEntry.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/HistoryEntry.js
index 86029f6ee79..ce96eab4b05 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/HistoryEntry.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/HistoryEntry.js
@@ -2,7 +2,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var HistoryEntry = function() {
 	};
 	stjs.extend(HistoryEntry, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.history.HistoryEntry';
+		prototype['@type'] = 'dto.history.HistoryEntry';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.validFrom = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/PropertyHistoryEntry.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/PropertyHistoryEntry.js
similarity index 78%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/PropertyHistoryEntry.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/PropertyHistoryEntry.js
index 5fda346c751..15b6f1384b0 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/PropertyHistoryEntry.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/PropertyHistoryEntry.js
@@ -1,9 +1,9 @@
-define([ "stjs", "util/Exceptions", "dto/entity/history/HistoryEntry" ], function(stjs, exceptions, HistoryEntry) {
+define([ "stjs", "util/Exceptions", "dto/history/HistoryEntry" ], function(stjs, exceptions, HistoryEntry) {
 	var PropertyHistoryEntry = function() {
 		HistoryEntry.call(this);
 	};
 	stjs.extend(PropertyHistoryEntry, HistoryEntry, [ HistoryEntry ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.history.PropertyHistoryEntry';
+		prototype['@type'] = 'dto.history.PropertyHistoryEntry';
 		constructor.serialVersionUID = 1;
 		prototype.propertyName = null;
 		prototype.propertyValue = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/RelationHistoryEntry.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/RelationHistoryEntry.js
similarity index 80%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/RelationHistoryEntry.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/RelationHistoryEntry.js
index 6e1b4c17234..cf9404981ac 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/RelationHistoryEntry.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/RelationHistoryEntry.js
@@ -1,9 +1,9 @@
-define([ "stjs", "util/Exceptions", "dto/entity/history/HistoryEntry" ], function(stjs, exceptions, HistoryEntry) {
+define([ "stjs", "util/Exceptions", "dto/history/HistoryEntry" ], function(stjs, exceptions, HistoryEntry) {
 	var RelationHistoryEntry = function() {
 		HistoryEntry.call(this);
 	};
 	stjs.extend(RelationHistoryEntry, HistoryEntry, [ HistoryEntry ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.history.RelationHistoryEntry';
+		prototype['@type'] = 'dto.history.RelationHistoryEntry';
 		constructor.serialVersionUID = 1;
 		prototype.relationType = null;
 		prototype.relatedObjectId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/history/HistoryEntryFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/fetchoptions/HistoryEntryFetchOptions.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/history/HistoryEntryFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/fetchoptions/HistoryEntryFetchOptions.js
index 53db603b712..ec15958dec6 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/history/HistoryEntryFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/fetchoptions/HistoryEntryFetchOptions.js
@@ -2,17 +2,18 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/person/PersonFetchOptions", "dto/fetchoptions/history/HistoryEntrySortOptions" ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/person/fetchoptions/PersonFetchOptions", "dto/history/fetchoptions/HistoryEntrySortOptions" ], function(require, stjs,
+		FetchOptions) {
 	var HistoryEntryFetchOptions = function() {
 	};
 	stjs.extend(HistoryEntryFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.history.HistoryEntryFetchOptions';
+		prototype['@type'] = 'dto.history.fetchoptions.HistoryEntryFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.author = null;
 		prototype.sort = null;
 		prototype.withAuthor = function() {
 			if (this.author == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.author = new PersonFetchOptions();
 			}
 			return this.author;
@@ -25,7 +26,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/p
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var HistoryEntrySortOptions = require("dto/fetchoptions/history/HistoryEntrySortOptions");
+				var HistoryEntrySortOptions = require("dto/history/fetchoptions/HistoryEntrySortOptions");
 				this.sort = new HistoryEntrySortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/history/HistoryEntrySortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/fetchoptions/HistoryEntrySortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/history/HistoryEntrySortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/fetchoptions/HistoryEntrySortOptions.js
index 232f5561f80..e44b69d18da 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/history/HistoryEntrySortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/history/fetchoptions/HistoryEntrySortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var HistoryEntrySortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(HistoryEntrySortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.history.HistoryEntrySortOptions';
+		prototype['@type'] = 'dto.history.fetchoptions.HistoryEntrySortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return HistoryEntrySortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/CreationId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/CreationId.js
deleted file mode 100644
index 6920a645b41..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/CreationId.js
+++ /dev/null
@@ -1,46 +0,0 @@
-/**
- *  @author Jakub Straszewski
- */
-define(["stjs", "dto/id/sample/ISampleId", "dto/id/dataset/IDataSetId", "dto/id/experiment/IExperimentId", "dto/id/project/IProjectId", "dto/id/space/ISpaceId", "dto/id/material/IMaterialId"], function (stjs, ISampleId, IDataSetId, IExperimentId, IProjectId, ISpaceId, IMaterialId) {
-    var CreationId = function(creationId) {
-        this.creationId = creationId;
-    };
-    stjs.extend(CreationId, null, [ISampleId, IDataSetId, IExperimentId, IProjectId, ISpaceId, IMaterialId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.CreationId';
-        constructor.serialVersionUID = 1;
-        prototype.creationId = null;
-        prototype.getCreationId = function() {
-            return this.creationId;
-        };
-        prototype.setCreationId = function(creationId) {
-            this.creationId = creationId;
-        };
-        prototype.toString = function() {
-            return this.getCreationId();
-        };
-        prototype.hashCode = function() {
-            return ((this.getCreationId() == null) ? 0 : this.getCreationId().hashCode());
-        };
-        prototype.equals = function(obj) {
-            if (this == obj) {
-                return true;
-            }
-            if (obj == null) {
-                return false;
-            }
-            if (this.getClass() != obj.getClass()) {
-                return false;
-            }
-            var other = obj;
-            if (this.getCreationId() == null) {
-                if (other.getCreationId() != null) {
-                    return false;
-                }
-            } else if (!this.getCreationId().equals(other.getCreationId())) {
-                return false;
-            }
-            return true;
-        };
-    }, {});
-    return CreationId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/IObjectId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/IObjectId.js
deleted file mode 100644
index 4f3598210f8..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/IObjectId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies an object in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs"], function (stjs) {
-    var IObjectId = function() {};
-    stjs.extend(IObjectId, null, [], null, {});
-    return IObjectId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectIdentifier.js
deleted file mode 100644
index 2214d257dc6..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectIdentifier.js
+++ /dev/null
@@ -1,46 +0,0 @@
-/**
- *  Base class for ids that identify objects by identifiers. An identifier is a mutable user-defined string. An identifier is assigned to an object
- *  during the object creation but can change afterwards. An object's identifier is not guaranteed to be always the same, e.g. a sample identifier
- *  changes when the sample is moved to a different space.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "util/Exceptions", "dto/id/IObjectId"], function (stjs, exceptions, IObjectId) {
-    var ObjectIdentifier = function(identifier) {
-        this.setIdentifier(identifier);
-    };
-    stjs.extend(ObjectIdentifier, null, [IObjectId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.ObjectIdentifier';
-        constructor.serialVersionUID = 1;
-        prototype.identifier = null;
-        prototype.getIdentifier = function() {
-            return this.identifier;
-        };
-        prototype.setIdentifier = function(identifier) {
-            if (identifier == null) {
-//                 throw new exceptions.IllegalArgumentException("Identifier id cannot be null");
-            }
-            this.identifier = identifier;
-        };
-        prototype.toString = function() {
-            return this.getIdentifier();
-        };
-        prototype.hashCode = function() {
-            return ((this.getIdentifier() == null) ? 0 : this.getIdentifier().hashCode());
-        };
-        prototype.equals = function(obj) {
-            if (this == obj) {
-                return true;
-            }
-            if (obj == null) {
-                return false;
-            }
-            if (this.getClass() != obj.getClass()) {
-                return false;
-            }
-            var other = obj;
-            return this.getIdentifier() == null ? this.getIdentifier() == other.getIdentifier() : this.getIdentifier().equals(other.getIdentifier());
-        };
-    }, {});
-    return ObjectIdentifier;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectPermId.js
deleted file mode 100644
index 990ca79ea0e..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/ObjectPermId.js
+++ /dev/null
@@ -1,53 +0,0 @@
-/**
- *  Base class for ids that identify objects by a perm id. A perm id is an immutable system-generated string. A perm id is assigned to an object during
- *  the object creation and cannot be changed afterwards. An object's perm id is guaranteed to be always the same, e.g. a sample perm id remains the
- *  same even if the sample is moved to a different space.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "util/Exceptions", "dto/id/IObjectId"], function (stjs, exceptions, IObjectId) {
-    var ObjectPermId = function(permId) {
-        this.setPermId(permId);
-    };
-    stjs.extend(ObjectPermId, null, [IObjectId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.ObjectPermId';
-        constructor.serialVersionUID = 1;
-        prototype.permId = null;
-        prototype.getPermId = function() {
-            return this.permId;
-        };
-        prototype.setPermId = function(permId) {
-            if (permId == null) {
-                 //TODO throw new exceptions.IllegalArgumentException("PermId cannot be null");
-            }
-            this.permId = permId;
-        };
-        prototype.toString = function() {
-            return this.getPermId();
-        };
-        prototype.hashCode = function() {
-            return ((this.getPermId() == null) ? 0 : this.getPermId().hashCode());
-        };
-        prototype.equals = function(obj) {
-            if (this == obj) {
-                return true;
-            }
-            if (obj == null) {
-                return false;
-            }
-            if (this.getClass() != obj.getClass()) {
-                return false;
-            }
-            var other = obj;
-            if (this.getPermId() == null) {
-                if (other.getPermId() != null) {
-                    return false;
-                }
-            } else if (!this.getPermId().equals(other.getPermId())) {
-                return false;
-            }
-            return true;
-        };
-    }, {});
-    return ObjectPermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/AttachmentFileName.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/AttachmentFileName.js
deleted file mode 100644
index 14e4f1bf947..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/AttachmentFileName.js
+++ /dev/null
@@ -1,47 +0,0 @@
-/**
- *  Attachment file name.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "util/Exceptions", "dto/id/attachment/IAttachmentId"], function (stjs, exceptions, IAttachmentId) {
-    var AttachmentFileName = /**
-     *  @param fileName Attachment file name, e.g. "my_file.txt".
-     */
-    function(fileName) {
-        this.setFileName(fileName);
-    };
-    stjs.extend(AttachmentFileName, null, [IAttachmentId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.attachment.AttachmentFileName';
-        constructor.serialVersionUID = 1;
-        prototype.fileName = null;
-        prototype.getFileName = function() {
-            return this.fileName;
-        };
-        prototype.setFileName = function(fileName) {
-            if (fileName == null) {
-                 throw new exceptions.IllegalArgumentException("File name cannot be null");
-            }
-            this.fileName = fileName;
-        };
-        prototype.toString = function() {
-            return this.getFileName();
-        };
-        prototype.hashCode = function() {
-            return ((this.getFileName() == null) ? 0 : this.getFileName().hashCode());
-        };
-        prototype.equals = function(obj) {
-            if (this == obj) {
-                return true;
-            }
-            if (obj == null) {
-                return false;
-            }
-            if (this.getClass() != obj.getClass()) {
-                return false;
-            }
-            var other = obj;
-            return this.getFileName() == null ? this.getFileName() == other.getFileName() : this.getFileName().equals(other.getFileName());
-        };
-    }, {});
-    return AttachmentFileName;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/IAttachmentId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/IAttachmentId.js
deleted file mode 100644
index 7bb82417482..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/attachment/IAttachmentId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies an attachment in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var IAttachmentId = function() {};
-    stjs.extend(IAttachmentId, null, [IObjectId], null, {});
-    return IAttachmentId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/DataSetPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/DataSetPermId.js
deleted file mode 100644
index 793d9017f20..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/DataSetPermId.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Data set perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/dataset/IDataSetId"], function (stjs, ObjectPermId, IDataSetId) {
-    var DataSetPermId = /**
-     *  @param permId Data set perm id, e.g. "201108050937246-1031".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(DataSetPermId, ObjectPermId, [ObjectPermId, IDataSetId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.dataset.DataSetPermId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return DataSetPermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/FileFormatTypePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/FileFormatTypePermId.js
deleted file mode 100644
index a99b46e0826..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/FileFormatTypePermId.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  File format type perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/dataset/IFileFormatTypeId"], function (stjs, ObjectPermId, IFileFormatTypeId) {
-    var FileFormatTypePermId = /**
-     *  @param permId File format type perm id, e.g. "PROPRIETARY".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(FileFormatTypePermId, ObjectPermId, [ObjectPermId, IFileFormatTypeId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.dataset.FileFormatTypePermId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return FileFormatTypePermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/IDataSetId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/IDataSetId.js
deleted file mode 100644
index e24e2b64bec..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/dataset/IDataSetId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies a data set in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var IDataSetId = function() {};
-    stjs.extend(IDataSetId, null, [IObjectId], null, {});
-    return IDataSetId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/DeletionTechId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/DeletionTechId.js
deleted file mode 100644
index 5150f52fb38..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/DeletionTechId.js
+++ /dev/null
@@ -1,13 +0,0 @@
-/**
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectTechId", "dto/id/deletion/IDeletionId"], function (stjs, ObjectTechId, IDeletionId) {
-    var DeletionTechId = function(techId) {
-        ObjectTechId.call(this, techId);
-    };
-    stjs.extend(DeletionTechId, ObjectTechId, [ObjectTechId, IDeletionId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.deletion.DeletionTechId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return DeletionTechId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/IDeletionId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/IDeletionId.js
deleted file mode 100644
index de1d8ed684d..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/deletion/IDeletionId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies a deletion in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var IDeletionId = function() {};
-    stjs.extend(IDeletionId, null, [IObjectId], null, {});
-    return IDeletionId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/EntityTypePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/EntityTypePermId.js
deleted file mode 100644
index 9468ed7e944..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/EntityTypePermId.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Entity type perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/entitytype/IEntityTypeId"], function (stjs, ObjectPermId, IEntityTypeId) {
-    var EntityTypePermId = /**
-     *  @param permId Entity type perm id, e.g. "MY_ENTITY_TYPE".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(EntityTypePermId, ObjectPermId, [ObjectPermId, IEntityTypeId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.entitytype.EntityTypePermId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return EntityTypePermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/IEntityTypeId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/IEntityTypeId.js
deleted file mode 100644
index 39689efe649..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/entitytype/IEntityTypeId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies an entity type in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var IEntityTypeId = function() {};
-    stjs.extend(IEntityTypeId, null, [IObjectId], null, {});
-    return IEntityTypeId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentIdentifier.js
deleted file mode 100644
index 3a9547d288a..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentIdentifier.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Experiment identifier.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectIdentifier", "dto/id/experiment/IExperimentId"], function (stjs, ObjectIdentifier, IExperimentId) {
-    var ExperimentIdentifier = /**
-     *  @param identifier Experiment identifier, e.g. "/MY_SPACE/MY_PROJECT/MY_EXPERIMENT".
-     */
-    function(identifier) {
-        ObjectIdentifier.call(this, identifier);
-    };
-    stjs.extend(ExperimentIdentifier, ObjectIdentifier, [ObjectIdentifier, IExperimentId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.experiment.ExperimentIdentifier';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return ExperimentIdentifier;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentPermId.js
deleted file mode 100644
index 6c536c63154..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/ExperimentPermId.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Experiment perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/experiment/IExperimentId"], function (stjs, ObjectPermId, IExperimentId) {
-    var ExperimentPermId = /**
-     *  @param permId Experiment perm id, e.g. "201108050937246-1031".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(ExperimentPermId, ObjectPermId, [ObjectPermId, IExperimentId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.experiment.ExperimentPermId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return ExperimentPermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/IExperimentId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/IExperimentId.js
deleted file mode 100644
index b19ae8fceb8..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/experiment/IExperimentId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies an experiment in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var IExperimentId = function() {};
-    stjs.extend(IExperimentId, null, [IObjectId], null, {});
-    return IExperimentId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/material/IMaterialId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/material/IMaterialId.js
deleted file mode 100644
index 6d7d964fedf..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/material/IMaterialId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies a material in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var IMaterialId = function() {};
-    stjs.extend(IMaterialId, null, [IObjectId], null, {});
-    return IMaterialId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/IProjectId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/IProjectId.js
deleted file mode 100644
index e7e315624c1..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/IProjectId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies a project in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var IProjectId = function() {};
-    stjs.extend(IProjectId, null, [IObjectId], null, {});
-    return IProjectId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectIdentifier.js
deleted file mode 100644
index 13b60c0af71..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectIdentifier.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Project identifier.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectIdentifier", "dto/id/project/IProjectId"], function (stjs, ObjectIdentifier, IProjectId) {
-    var ProjectIdentifier = /**
-     *  @param identifier Project identifier, e.g. "/MY_SPACE/MY_PROJECT".
-     */
-    function(identifier) {
-        ObjectIdentifier.call(this, identifier);
-    };
-    stjs.extend(ProjectIdentifier, ObjectIdentifier, [ObjectIdentifier, IProjectId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.project.ProjectIdentifier';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return ProjectIdentifier;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectPermId.js
deleted file mode 100644
index 365c3fc749f..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/project/ProjectPermId.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Project perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/project/IProjectId"], function (stjs, ObjectPermId, IProjectId) {
-    var ProjectPermId = /**
-     *  @param permId Project perm id, e.g. "201108050937246-1031".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(ProjectPermId, ObjectPermId, [ObjectPermId, IProjectId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.project.ProjectPermId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return ProjectPermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/ISampleId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/ISampleId.js
deleted file mode 100644
index dd2de231ab2..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/ISampleId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies a sample in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var ISampleId = function() {};
-    stjs.extend(ISampleId, null, [IObjectId], null, {});
-    return ISampleId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SampleIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SampleIdentifier.js
deleted file mode 100644
index 8e1a72c8123..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SampleIdentifier.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Sample identifier.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectIdentifier", "dto/id/sample/ISampleId"], function (stjs, ObjectIdentifier, ISampleId) {
-    var SampleIdentifier = /**
-     *  @param identifier Sample identifier, e.g. "/MY_SPACE/MY_SAMPLE" (space sample) or "/MY_SAMPLE" (shared sample)
-     */
-    function(identifier) {
-        ObjectIdentifier.call(this, identifier);
-    };
-    stjs.extend(SampleIdentifier, ObjectIdentifier, [ObjectIdentifier, ISampleId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.sample.SampleIdentifier';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return SampleIdentifier;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SamplePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SamplePermId.js
deleted file mode 100644
index fa253af0c30..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/sample/SamplePermId.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Sample perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/sample/ISampleId"], function (stjs, ObjectPermId, ISampleId) {
-    var SamplePermId = /**
-     *  @param permId Sample perm id, e.g. "201108050937246-1031".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(SamplePermId, ObjectPermId, [ObjectPermId, ISampleId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.sample.SamplePermId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return SamplePermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/ISpaceId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/ISpaceId.js
deleted file mode 100644
index 1f3f2725537..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/ISpaceId.js
+++ /dev/null
@@ -1,10 +0,0 @@
-/**
- *  Holds information that uniquely identifies a space in openBIS.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var ISpaceId = function() {};
-    stjs.extend(ISpaceId, null, [IObjectId], null, {});
-    return ISpaceId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/SpacePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/SpacePermId.js
deleted file mode 100644
index 8d9096f8a40..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/space/SpacePermId.js
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- *  Space perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/space/ISpaceId"], function (stjs, ObjectPermId, ISpaceId) {
-    var SpacePermId = /**
-     *  @param permId Space perm id, e.g. "/MY_SPACE" or "MY_SPACE".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(SpacePermId, ObjectPermId, [ObjectPermId, ISpaceId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.space.SpacePermId';
-        constructor.serialVersionUID = 1;
-        prototype.getPermId = function() {
-            var permId = ObjectPermId.prototype.getPermId.call(this);
-            if (permId.startsWith("/")) {
-                return permId.substring(1);
-            } else {
-                return permId;
-            }
-        };
-    }, {});
-    return SpacePermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/ITagId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/ITagId.js
deleted file mode 100644
index fa6879b4482..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/ITagId.js
+++ /dev/null
@@ -1,8 +0,0 @@
-/**
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/IObjectId"], function (stjs, IObjectId) {
-    var ITagId = function() {};
-    stjs.extend(ITagId, null, [IObjectId], null, {});
-    return ITagId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagCode.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagCode.js
deleted file mode 100644
index 9dcce92ddd1..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagCode.js
+++ /dev/null
@@ -1,48 +0,0 @@
-/**
- *  Tag code.
- *  
- *  @author Franz-Josef Elmer
- *  @author Jakub Straszewski
- */
-define(["stjs", "util/Exceptions", "dto/id/tag/ITagId"], function (stjs, exceptions, ITagId) {
-    var TagCode = /**
-     *  @param code Tag code, e.g. "MY_TAG".
-     */
-    function(code) {
-        this.setCode(code);
-    };
-    stjs.extend(TagCode, null, [ITagId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.tag.TagCode';
-        constructor.serialVersionUID = 1;
-        prototype.code = null;
-        prototype.getCode = function() {
-            return this.code;
-        };
-        prototype.setCode = function(code) {
-            if (code == null) {
-                 throw new exceptions.IllegalArgumentException("Code cannot be null");
-            }
-            this.code = code;
-        };
-        prototype.toString = function() {
-            return this.getCode();
-        };
-        prototype.hashCode = function() {
-            return ((this.getCode() == null) ? 0 : this.getCode().hashCode());
-        };
-        prototype.equals = function(obj) {
-            if (this == obj) {
-                return true;
-            }
-            if (obj == null) {
-                return false;
-            }
-            if (this.getClass() != obj.getClass()) {
-                return false;
-            }
-            var other = obj;
-            return this.getCode() == null ? this.getCode() == other.getCode() : this.getCode().equals(other.getCode());
-        };
-    }, {});
-    return TagCode;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagPermId.js
deleted file mode 100644
index c10b3c39e72..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/tag/TagPermId.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- *  Tag perm id.
- *  
- *  @author pkupczyk
- */
-define(["stjs", "dto/id/ObjectPermId", "dto/id/tag/ITagId"], function (stjs, ObjectPermId, ITagId) {
-    var TagPermId = /**
-     *  @param permId Tag perm id, e.g. "/MY_USER/MY_TAG".
-     */
-    function(permId) {
-        ObjectPermId.call(this, permId);
-    };
-    stjs.extend(TagPermId, ObjectPermId, [ObjectPermId, ITagId], function(constructor, prototype) {
-        prototype['@type'] = 'dto.id.tag.TagPermId';
-        constructor.serialVersionUID = 1;
-    }, {});
-    return TagPermId;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/Material.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/Material.js
similarity index 98%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/Material.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/Material.js
index 63cc5be0d02..29e12c745ae 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/Material.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/Material.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Material = function() {
 	};
 	stjs.extend(Material, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.material.Material';
+		prototype['@type'] = 'dto.material.Material';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
@@ -82,7 +82,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 		prototype.getProperty = function(propertyName) {
 			var properties = this.getProperties();
 			return properties ? properties[propertyName] : null;
-		};		
+		};
 		prototype.getProperties = function() {
 			if (this.getFetchOptions().hasProperties()) {
 				return this.properties;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/MaterialType.js
similarity index 96%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/MaterialType.js
index c107a274c3b..6aba059945b 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialType.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/MaterialType.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var MaterialType = function() {
 	};
 	stjs.extend(MaterialType, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.material.MaterialType';
+		prototype['@type'] = 'dto.material.MaterialType';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialCreation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/create/MaterialCreation.js
similarity index 96%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialCreation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/create/MaterialCreation.js
index 046b0f9fda4..ec10299ccb2 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialCreation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/create/MaterialCreation.js
@@ -6,7 +6,7 @@ define([ "stjs" ], function(stjs) {
 		this.properties = {};
 	};
 	stjs.extend(MaterialCreation, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.material.MaterialCreation';
+		prototype['@type'] = 'dto.material.create.MaterialCreation';
 		constructor.serialVersionUID = 1;
 		prototype.code = null;
 		prototype.typeId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/material/MaterialDeletionOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/delete/MaterialDeletionOptions.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/material/MaterialDeletionOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/delete/MaterialDeletionOptions.js
index 456cfe2b18f..f719b1e4636 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/material/MaterialDeletionOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/delete/MaterialDeletionOptions.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
+define([ "stjs", "dto/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
 	var MaterialDeletionOptions = function() {
 		AbstractObjectDeletionOptions.call(this);
 	};
 	stjs.extend(MaterialDeletionOptions, AbstractObjectDeletionOptions, [ AbstractObjectDeletionOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.material.MaterialDeletionOptions';
+		prototype['@type'] = 'dto.material.delete.MaterialDeletionOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return MaterialDeletionOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialFetchOptions.js
similarity index 78%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialFetchOptions.js
index c7090e0c3ab..cb2c15bfc0a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialFetchOptions.js
@@ -2,13 +2,13 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/material/MaterialTypeFetchOptions", "dto/fetchoptions/history/HistoryEntryFetchOptions",
-		"dto/fetchoptions/person/PersonFetchOptions", "dto/fetchoptions/property/PropertyFetchOptions", "dto/fetchoptions/tag/TagFetchOptions", "dto/fetchoptions/material/MaterialSortOptions" ],
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/material/fetchoptions/MaterialTypeFetchOptions", "dto/history/fetchoptions/HistoryEntryFetchOptions",
+		"dto/person/fetchoptions/PersonFetchOptions", "dto/property/fetchoptions/PropertyFetchOptions", "dto/tag/fetchoptions/TagFetchOptions", "dto/material/fetchoptions/MaterialSortOptions" ],
 		function(require, stjs, FetchOptions) {
 			var MaterialFetchOptions = function() {
 			};
 			stjs.extend(MaterialFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-				prototype['@type'] = 'dto.fetchoptions.material.MaterialFetchOptions';
+				prototype['@type'] = 'dto.material.fetchoptions.MaterialFetchOptions';
 				constructor.serialVersionUID = 1;
 				prototype.type = null;
 				prototype.history = null;
@@ -19,7 +19,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/m
 				prototype.sort = null;
 				prototype.withType = function() {
 					if (this.type == null) {
-						var MaterialTypeFetchOptions = require("dto/fetchoptions/material/MaterialTypeFetchOptions");
+						var MaterialTypeFetchOptions = require("dto/material/fetchoptions/MaterialTypeFetchOptions");
 						this.type = new MaterialTypeFetchOptions();
 					}
 					return this.type;
@@ -32,7 +32,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/m
 				};
 				prototype.withHistory = function() {
 					if (this.history == null) {
-						var HistoryEntryFetchOptions = require("dto/fetchoptions/history/HistoryEntryFetchOptions");
+						var HistoryEntryFetchOptions = require("dto/history/fetchoptions/HistoryEntryFetchOptions");
 						this.history = new HistoryEntryFetchOptions();
 					}
 					return this.history;
@@ -45,7 +45,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/m
 				};
 				prototype.withRegistrator = function() {
 					if (this.registrator == null) {
-						var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+						var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 						this.registrator = new PersonFetchOptions();
 					}
 					return this.registrator;
@@ -58,7 +58,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/m
 				};
 				prototype.withProperties = function() {
 					if (this.properties == null) {
-						var PropertyFetchOptions = require("dto/fetchoptions/property/PropertyFetchOptions");
+						var PropertyFetchOptions = require("dto/property/fetchoptions/PropertyFetchOptions");
 						this.properties = new PropertyFetchOptions();
 					}
 					return this.properties;
@@ -83,7 +83,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/m
 				};
 				prototype.withTags = function() {
 					if (this.tags == null) {
-						var TagFetchOptions = require("dto/fetchoptions/tag/TagFetchOptions");
+						var TagFetchOptions = require("dto/tag/fetchoptions/TagFetchOptions");
 						this.tags = new TagFetchOptions();
 					}
 					return this.tags;
@@ -96,7 +96,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/m
 				};
 				prototype.sortBy = function() {
 					if (this.sort == null) {
-						var MaterialSortOptions = require("dto/fetchoptions/material/MaterialSortOptions");
+						var MaterialSortOptions = require("dto/material/fetchoptions/MaterialSortOptions");
 						this.sort = new MaterialSortOptions();
 					}
 					return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialSortOptions.js
similarity index 59%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialSortOptions.js
index 518d5701d83..5984c408ecb 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
 	var MaterialSortOptions = function() {
 		EntityWithPropertiesSortOptions.call(this);
 	};
 	stjs.extend(MaterialSortOptions, EntityWithPropertiesSortOptions, [ EntityWithPropertiesSortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.material.MaterialSortOptions';
+		prototype['@type'] = 'dto.material.fetchoptions.MaterialSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return MaterialSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialTypeFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialTypeFetchOptions.js
similarity index 67%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialTypeFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialTypeFetchOptions.js
index 793b97288ec..dc195c20fbb 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialTypeFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialTypeFetchOptions.js
@@ -2,16 +2,16 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/material/MaterialTypeSortOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions", "dto/material/fetchoptions/MaterialTypeSortOptions" ], function(stjs, FetchOptions) {
 	var MaterialTypeFetchOptions = function() {
 	};
 	stjs.extend(MaterialTypeFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.material.MaterialTypeFetchOptions';
+		prototype['@type'] = 'dto.material.fetchoptions.MaterialTypeFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.sort = null;
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var MaterialTypeSortOptions = require("dto/fetchoptions/material/MaterialTypeSortOptions");
+				var MaterialTypeSortOptions = require("dto/material/fetchoptions/MaterialTypeSortOptions");
 				this.sort = new MaterialTypeSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialTypeSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialTypeSortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialTypeSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialTypeSortOptions.js
index f5fe27c1f9e..a9e2b5785ac 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/material/MaterialTypeSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/fetchoptions/MaterialTypeSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var MaterialTypeSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(MaterialTypeSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.material.MaterialTypeSortOptions';
+		prototype['@type'] = 'dto.material.fetchoptions.MaterialTypeSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return MaterialTypeSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/id/IMaterialId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/id/IMaterialId.js
new file mode 100644
index 00000000000..80bd55aa7a9
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/id/IMaterialId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies a material in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IMaterialId = function() {
+	};
+	stjs.extend(IMaterialId, null, [ IObjectId ], null, {});
+	return IMaterialId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/material/MaterialPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/id/MaterialPermId.js
similarity index 87%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/material/MaterialPermId.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/id/MaterialPermId.js
index 401cdda1fa5..1777c6cf3a3 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/material/MaterialPermId.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/id/MaterialPermId.js
@@ -3,7 +3,7 @@
  * 
  * @author pkupczyk
  */
-define([ "stjs", "dto/id/material/IMaterialId" ], function(stjs, IMaterialId) {
+define([ "stjs", "dto/material/id/IMaterialId" ], function(stjs, IMaterialId) {
 	/**
 	 * @param permId
 	 *            Material perm id, e.g. "MY_MATERIAL (MY_MATERIAL_TYPE)".
@@ -13,7 +13,7 @@ define([ "stjs", "dto/id/material/IMaterialId" ], function(stjs, IMaterialId) {
 		this.setTypeCode(typeCode);
 	};
 	stjs.extend(MaterialPermId, null, [ IMaterialId ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.id.material.MaterialPermId';
+		prototype['@type'] = 'dto.material.id.MaterialPermId';
 		constructor.serialVersionUID = 1;
 		prototype.code = null;
 		prototype.typeCode = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/MaterialSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/search/MaterialSearchCriteria.js
similarity index 78%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/MaterialSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/search/MaterialSearchCriteria.js
index 9816c2d84e0..634d3a242e1 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/MaterialSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/search/MaterialSearchCriteria.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/search/SearchOperator" ], function(stjs, AbstractEntitySearchCriteria, SearchOperator) {
+define([ "stjs", "dto/common/search/AbstractEntitySearchCriteria", "dto/common/search/SearchOperator" ], function(stjs, AbstractEntitySearchCriteria, SearchOperator) {
 	var MaterialSearchCriteria = function() {
 		AbstractEntitySearchCriteria.call(this);
 	};
 	stjs.extend(MaterialSearchCriteria, AbstractEntitySearchCriteria, [ AbstractEntitySearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.MaterialSearchCriteria';
+		prototype['@type'] = 'dto.material.search.MaterialSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.withOrOperator = function() {
 			return this.withOperator(SearchOperator.OR);
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/update/MaterialUpdate.js
similarity index 84%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialUpdate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/update/MaterialUpdate.js
index 57cbdd8fba9..1d13f38f883 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/material/MaterialUpdate.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/material/update/MaterialUpdate.js
@@ -1,13 +1,13 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/IdListUpdateValue" ], function(stjs, IdListUpdateValue) {
+define([ "stjs", "dto/common/update/IdListUpdateValue" ], function(stjs, IdListUpdateValue) {
 	var MaterialUpdate = function() {
 		this.properties = {};
 		this.tagIds = new IdListUpdateValue();
 	};
 	stjs.extend(MaterialUpdate, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.material.MaterialUpdate';
+		prototype['@type'] = 'dto.material.update.MaterialUpdate';
 		constructor.serialVersionUID = 1;
 		prototype.materialId = null;
 		prototype.getMaterialId = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperation.js
deleted file mode 100644
index 3c7f2489b9e..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperation.js
+++ /dev/null
@@ -1,11 +0,0 @@
-/**
- *  @author pkupczyk
- */
-define(["stjs", "dto/operation/IOperation"], function (stjs, IOperation) {
-    var CreateExperimentsOperation = function() {};
-    stjs.extend(CreateExperimentsOperation, null, [IOperation], function(constructor, prototype) {
-        prototype['@type'] = 'dto.operation.experiment.CreateExperimentsOperation';
-        prototype.newExperiments = null;
-    }, {newExperiments: {name: "List", arguments: ["ExperimentCreation"]}});
-    return CreateExperimentsOperation;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperationResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperationResult.js
deleted file mode 100644
index 4b3de552d89..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/experiment/CreateExperimentsOperationResult.js
+++ /dev/null
@@ -1,11 +0,0 @@
-/**
- *  @author pkupczyk
- */
-define(["stjs", "dto/operation/IOperationResult"], function (stjs, IOperationResult) {
-    var CreateExperimentsOperationResult = function() {};
-    stjs.extend(CreateExperimentsOperationResult, null, [IOperationResult], function(constructor, prototype) {
-        prototype['@type'] = 'dto.operation.experiment.CreateExperimentsOperationResult';
-        prototype.newExperimentIds = null;
-    }, {newExperimentIds: {name: "List", arguments: ["ExperimentPermId"]}});
-    return CreateExperimentsOperationResult;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/person/Person.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/Person.js
similarity index 98%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/person/Person.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/Person.js
index 176c5f26081..2e67ebbf562 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/person/Person.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/Person.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Person = function() {
 	};
 	stjs.extend(Person, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.person.Person';
+		prototype['@type'] = 'dto.person.Person';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/person/PersonFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/fetchoptions/PersonFetchOptions.js
similarity index 78%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/person/PersonFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/fetchoptions/PersonFetchOptions.js
index da3473f5620..eae87c6c939 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/person/PersonFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/fetchoptions/PersonFetchOptions.js
@@ -2,18 +2,18 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/space/SpaceFetchOptions", "dto/fetchoptions/person/PersonSortOptions" ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/space/fetchoptions/SpaceFetchOptions", "dto/person/fetchoptions/PersonSortOptions" ], function(require, stjs, FetchOptions) {
 	var PersonFetchOptions = function() {
 	};
 	stjs.extend(PersonFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.person.PersonFetchOptions';
+		prototype['@type'] = 'dto.person.fetchoptions.PersonFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.space = null;
 		prototype.registrator = null;
 		prototype.sort = null;
 		prototype.withSpace = function() {
 			if (this.space == null) {
-				var SpaceFetchOptions = require("dto/fetchoptions/space/SpaceFetchOptions");
+				var SpaceFetchOptions = require("dto/space/fetchoptions/SpaceFetchOptions");
 				this.space = new SpaceFetchOptions();
 			}
 			return this.space;
@@ -38,7 +38,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/s
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var PersonSortOptions = require("dto/fetchoptions/person/PersonSortOptions");
+				var PersonSortOptions = require("dto/person/fetchoptions/PersonSortOptions");
 				this.sort = new PersonSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/person/PersonSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/fetchoptions/PersonSortOptions.js
similarity index 58%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/person/PersonSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/fetchoptions/PersonSortOptions.js
index bfa5b7f8aee..200929e7e46 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/person/PersonSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/fetchoptions/PersonSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var PersonSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(PersonSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.person.PersonSortOptions';
+		prototype['@type'] = 'dto.person.fetchoptions.PersonSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return PersonSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/person/IPersonId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/id/IPersonId.js
similarity index 73%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/person/IPersonId.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/id/IPersonId.js
index 4903fee3243..2f19729a909 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/person/IPersonId.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/id/IPersonId.js
@@ -3,7 +3,7 @@
  * 
  * @author pkupczyk
  */
-define([ "stjs", "dto/id/IObjectId" ], function(stjs, IObjectId) {
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
 	var IPersonId = function() {
 	};
 	stjs.extend(IPersonId, null, [ IObjectId ], null, {});
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/person/PersonPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/id/PersonPermId.js
similarity index 68%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/person/PersonPermId.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/id/PersonPermId.js
index de042979ccb..b4db44b41ba 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/id/person/PersonPermId.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/person/id/PersonPermId.js
@@ -3,7 +3,7 @@
  * 
  * @author pkupczyk
  */
-define([ "stjs", "dto/id/ObjectPermId", "dto/id/person/IPersonId" ], function(stjs, ObjectPermId, IPersonId) {
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/person/id/IPersonId" ], function(stjs, ObjectPermId, IPersonId) {
 
 	/**
 	 * @param permId
@@ -13,7 +13,7 @@ define([ "stjs", "dto/id/ObjectPermId", "dto/id/person/IPersonId" ], function(st
 		ObjectPermId.call(this, permId);
 	};
 	stjs.extend(PersonPermId, ObjectPermId, [ ObjectPermId, IPersonId ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.id.person.PersonPermId';
+		prototype['@type'] = 'dto.person.id.PersonPermId';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return PersonPermId;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/Project.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/Project.js
similarity index 98%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/Project.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/Project.js
index db42c2357e9..fc1fde32711 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/Project.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/Project.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Project = function() {
 	};
 	stjs.extend(Project, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.project.Project';
+		prototype['@type'] = 'dto.project.Project';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/ProjectCreation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/create/ProjectCreation.js
similarity index 95%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/ProjectCreation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/create/ProjectCreation.js
index 3b59c2b78c5..9dfe5289494 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/ProjectCreation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/create/ProjectCreation.js
@@ -5,7 +5,7 @@ define([ "stjs" ], function(stjs) {
 	var ProjectCreation = function() {
 	};
 	stjs.extend(ProjectCreation, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.project.ProjectCreation';
+		prototype['@type'] = 'dto.project.create.ProjectCreation';
 		constructor.serialVersionUID = 1;
 		prototype.spaceId = null;
 		prototype.code = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/project/ProjectDeletionOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/delete/ProjectDeletionOptions.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/project/ProjectDeletionOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/delete/ProjectDeletionOptions.js
index 28b669051cc..a054c847d52 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/project/ProjectDeletionOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/delete/ProjectDeletionOptions.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
+define([ "stjs", "dto/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
 	var ProjectDeletionOptions = function() {
 		AbstractObjectDeletionOptions.call(this);
 	};
 	stjs.extend(ProjectDeletionOptions, AbstractObjectDeletionOptions, [ AbstractObjectDeletionOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.project.ProjectDeletionOptions';
+		prototype['@type'] = 'dto.project.delete.ProjectDeletionOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return ProjectDeletionOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/project/ProjectFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/fetchoptions/ProjectFetchOptions.js
similarity index 76%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/project/ProjectFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/fetchoptions/ProjectFetchOptions.js
index 79686cc6be9..01b2a3bda5b 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/project/ProjectFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/fetchoptions/ProjectFetchOptions.js
@@ -2,13 +2,13 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/person/PersonFetchOptions', 'dto/fetchoptions/space/SpaceFetchOptions', 'dto/fetchoptions/sample/SampleFetchOptions',
-		'dto/fetchoptions/experiment/ExperimentFetchOptions', 'dto/fetchoptions/attachment/AttachmentFetchOptions', 'dto/fetchoptions/project/ProjectSortOptions' ], function(require, stjs,
-		FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", 'dto/person/fetchoptions/PersonFetchOptions', 'dto/space/fetchoptions/SpaceFetchOptions',
+		'dto/sample/fetchoptions/SampleFetchOptions', 'dto/experiment/fetchoptions/ExperimentFetchOptions', 'dto/attachment/fetchoptions/AttachmentFetchOptions',
+		'dto/project/fetchoptions/ProjectSortOptions' ], function(require, stjs, FetchOptions) {
 	var ProjectFetchOptions = function() {
 	};
 	stjs.extend(ProjectFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.project.ProjectFetchOptions';
+		prototype['@type'] = 'dto.project.fetchoptions.ProjectFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.experiments = null;
 		prototype.samples = null;
@@ -20,7 +20,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		prototype.sort = null;
 		prototype.withExperiments = function() {
 			if (this.experiments == null) {
-				var ExperimentFetchOptions = require("dto/fetchoptions/experiment/ExperimentFetchOptions");
+				var ExperimentFetchOptions = require("dto/experiment/fetchoptions/ExperimentFetchOptions");
 				this.experiments = new ExperimentFetchOptions();
 			}
 			return this.experiments;
@@ -33,7 +33,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		};
 		prototype.withSamples = function() {
 			if (this.samples == null) {
-				var SampleFetchOptions = require("dto/fetchoptions/experiment/SampleFetchOptions");
+				var SampleFetchOptions = require("dto/sample/fetchoptions/SampleFetchOptions");
 				this.samples = new SampleFetchOptions();
 			}
 			return this.samples;
@@ -46,7 +46,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		};
 		prototype.withSpace = function() {
 			if (this.space == null) {
-				var SpaceFetchOptions = require("dto/fetchoptions/space/SpaceFetchOptions");
+				var SpaceFetchOptions = require("dto/space/fetchoptions/SpaceFetchOptions");
 				this.space = new SpaceFetchOptions();
 			}
 			return this.space;
@@ -59,7 +59,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		};
 		prototype.withRegistrator = function() {
 			if (this.registrator == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.registrator = new PersonFetchOptions();
 			}
 			return this.registrator;
@@ -72,7 +72,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		};
 		prototype.withModifier = function() {
 			if (this.modifier == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.modifier = new PersonFetchOptions();
 			}
 			return this.modifier;
@@ -85,7 +85,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		};
 		prototype.withLeader = function() {
 			if (this.leader == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.leader = new PersonFetchOptions();
 			}
 			return this.leader;
@@ -98,7 +98,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		};
 		prototype.withAttachments = function() {
 			if (this.attachments == null) {
-				var AttachmentFetchOptions = require("dto/fetchoptions/attachment/AttachmentFetchOptions");
+				var AttachmentFetchOptions = require("dto/attachment/fetchoptions/AttachmentFetchOptions");
 				this.attachments = new AttachmentFetchOptions();
 			}
 			return this.attachments;
@@ -111,7 +111,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/p
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var ProjectSortOptions = require("dto/fetchoptions/project/ProjectSortOptions");
+				var ProjectSortOptions = require("dto/project/fetchoptions/ProjectSortOptions");
 				this.sort = new ProjectSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/project/ProjectSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/fetchoptions/ProjectSortOptions.js
similarity index 59%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/project/ProjectSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/fetchoptions/ProjectSortOptions.js
index d10fa414aaf..b52d3fb9c62 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/project/ProjectSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/fetchoptions/ProjectSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/EntitySortOptions" ], function(require, stjs, EntitySortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/EntitySortOptions" ], function(require, stjs, EntitySortOptions) {
 	var ProjectSortOptions = function() {
 		EntitySortOptions.call(this);
 	};
 	stjs.extend(ProjectSortOptions, EntitySortOptions, [ EntitySortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.project.ProjectSortOptions';
+		prototype['@type'] = 'dto.project.fetchoptions.ProjectSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return ProjectSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/DeletionType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/history/ProjectRelationType.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/DeletionType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/history/ProjectRelationType.js
index 5af45a744fb..7064b881b2a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/DeletionType.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/history/ProjectRelationType.js
@@ -3,7 +3,7 @@
  */
 define([ "stjs" ], function(stjs) {
 	return {
-		PERMANENT : "PERMANENT",
-		TRASH : "TRASH"
+		SPACE : "SPACE",
+		EXPERIMENT : "EXPERIMENT"
 	};
 })
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/IProjectId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/IProjectId.js
new file mode 100644
index 00000000000..e8ea14ccc39
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/IProjectId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies a project in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IProjectId = function() {
+	};
+	stjs.extend(IProjectId, null, [ IObjectId ], null, {});
+	return IProjectId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectIdentifier.js
new file mode 100644
index 00000000000..6c3f0088f91
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectIdentifier.js
@@ -0,0 +1,19 @@
+/**
+ * Project identifier.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectIdentifier", "dto/project/id/IProjectId" ], function(stjs, ObjectIdentifier, IProjectId) {
+	/**
+	 * @param identifier
+	 *            Project identifier, e.g. "/MY_SPACE/MY_PROJECT".
+	 */
+	var ProjectIdentifier = function(identifier) {
+		ObjectIdentifier.call(this, identifier);
+	};
+	stjs.extend(ProjectIdentifier, ObjectIdentifier, [ ObjectIdentifier, IProjectId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.project.id.ProjectIdentifier';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return ProjectIdentifier;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectPermId.js
new file mode 100644
index 00000000000..094ee1c5f79
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/id/ProjectPermId.js
@@ -0,0 +1,19 @@
+/**
+ * Project perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/project/id/IProjectId" ], function(stjs, ObjectPermId, IProjectId) {
+	/**
+	 * @param permId
+	 *            Project perm id, e.g. "201108050937246-1031".
+	 */
+	var ProjectPermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(ProjectPermId, ObjectPermId, [ ObjectPermId, IProjectId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.project.id.ProjectPermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return ProjectPermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoProjectSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/search/NoProjectSearchCriteria.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoProjectSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/search/NoProjectSearchCriteria.js
index 01973f9bf52..6cc716cc0c6 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoProjectSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/search/NoProjectSearchCriteria.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
+define([ "stjs", "dto/common/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
 	var NoProjectSearchCriteria = function() {
 	};
 	stjs.extend(NoProjectSearchCriteria, null, [ ISearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NoProjectSearchCriteria';
+		prototype['@type'] = 'dto.project.search.NoProjectSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return NoProjectSearchCriteria;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ProjectSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/search/ProjectSearchCriteria.js
similarity index 55%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ProjectSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/search/ProjectSearchCriteria.js
index b04a4ba3e9a..5491d9d28da 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/ProjectSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/search/ProjectSearchCriteria.js
@@ -1,30 +1,28 @@
 /**
  * @author pkupczyk
  */
-define([ "require", "stjs", "dto/search/AbstractObjectSearchCriteria",
-         "dto/search/CodeSearchCriteria", "dto/search/PermIdSearchCriteria", "dto/search/SpaceSearchCriteria",
-         "dto/search/AbstractCompositeSearchCriteria"], 
-		function(require, stjs, AbstractObjectSearchCriteria) {
+define([ "require", "stjs", "dto/common/search/AbstractObjectSearchCriteria", "dto/common/search/AbstractCompositeSearchCriteria", "dto/common/search/CodeSearchCriteria",
+		"dto/common/search/PermIdSearchCriteria", "dto/space/search/SpaceSearchCriteria" ], function(require, stjs, AbstractObjectSearchCriteria) {
 	var ProjectSearchCriteria = function() {
 		AbstractObjectSearchCriteria.call(this);
 	};
 	stjs.extend(ProjectSearchCriteria, AbstractObjectSearchCriteria, [ AbstractObjectSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.ProjectSearchCriteria';
+		prototype['@type'] = 'dto.project.search.ProjectSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.withCode = function() {
-			var CodeSearchCriteria = require("dto/search/CodeSearchCriteria");
+			var CodeSearchCriteria = require("dto/common/search/CodeSearchCriteria");
 			return this.addCriteria(new CodeSearchCriteria());
 		};
 		prototype.withPermId = function() {
-			var PermIdSearchCriteria = require("dto/search/PermIdSearchCriteria");
+			var PermIdSearchCriteria = require("dto/common/search/PermIdSearchCriteria");
 			return this.addCriteria(new PermIdSearchCriteria());
 		};
 		prototype.withSpace = function() {
-			var SpaceSearchCriteria = require("dto/search/SpaceSearchCriteria");
+			var SpaceSearchCriteria = require("dto/space/search/SpaceSearchCriteria");
 			return this.addCriteria(new SpaceSearchCriteria());
 		};
 		prototype.createBuilder = function() {
-			var AbstractCompositeSearchCriteria = require("dto/search/AbstractCompositeSearchCriteria");
+			var AbstractCompositeSearchCriteria = require("dto/common/search/AbstractCompositeSearchCriteria");
 			var builder = AbstractCompositeSearchCriteria.prototype.createBuilder.call(this);
 			builder.setName("PROJECT");
 			return builder;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/ProjectUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/update/ProjectUpdate.js
similarity index 84%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/ProjectUpdate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/update/ProjectUpdate.js
index 3f8d6d8bf7e..e7d875b9da2 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/project/ProjectUpdate.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/project/update/ProjectUpdate.js
@@ -1,14 +1,14 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/FieldUpdateValue", "dto/entity/AttachmentListUpdateValue" ], function(stjs, FieldUpdateValue, AttachmentListUpdateValue) {
+define([ "stjs", "dto/common/update/FieldUpdateValue", "dto/attachment/update/AttachmentListUpdateValue" ], function(stjs, FieldUpdateValue, AttachmentListUpdateValue) {
 	var ProjectUpdate = function() {
 		this.spaceId = new FieldUpdateValue();
 		this.description = new FieldUpdateValue();
 		this.attachments = new AttachmentListUpdateValue();
 	};
 	stjs.extend(ProjectUpdate, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.project.ProjectUpdate';
+		prototype['@type'] = 'dto.project.update.ProjectUpdate';
 		constructor.serialVersionUID = 1;
 		prototype.projectId = null;
 		prototype.getProjectId = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/property/PropertyFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/property/fetchoptions/PropertyFetchOptions.js
similarity index 62%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/property/PropertyFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/property/fetchoptions/PropertyFetchOptions.js
index 2775d269302..1d6f6191ee8 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/property/PropertyFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/property/fetchoptions/PropertyFetchOptions.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/fetchoptions/EmptyFetchOptions" ], function(stjs, EmptyFetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/EmptyFetchOptions" ], function(stjs, EmptyFetchOptions) {
 	var PropertyFetchOptions = function() {
 	};
 	stjs.extend(PropertyFetchOptions, EmptyFetchOptions, [ EmptyFetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.property.PropertyFetchOptions';
+		prototype['@type'] = 'dto.property.fetchoptions.PropertyFetchOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return PropertyFetchOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/Sample.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/Sample.js
similarity index 99%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/Sample.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/Sample.js
index 0eccf4ba78d..88dfa14ab17 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/Sample.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/Sample.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Sample = function() {
 	};
 	stjs.extend(Sample, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.sample.Sample';
+		prototype['@type'] = 'dto.sample.Sample';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/SampleType.js
similarity index 97%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/SampleType.js
index d20264b8c61..c75dc66af98 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleType.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/SampleType.js
@@ -6,7 +6,7 @@ define([ "stjs" ], function(stjs) {
 	var SampleType = function() {
 	};
 	stjs.extend(SampleType, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.sample.SampleType';
+		prototype['@type'] = 'dto.sample.SampleType';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/CreateSamplesOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/CreateSamplesOperation.js
similarity index 74%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/CreateSamplesOperation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/CreateSamplesOperation.js
index 130ca9ce506..b999447487f 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/CreateSamplesOperation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/CreateSamplesOperation.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperation" ], function(stjs, IOperation) {
+define([ "stjs", "dto/common/operation/IOperation" ], function(stjs, IOperation) {
 	var CreateSamplesOperation = function(creations) {
 		this.creations = creations;
 	};
 	stjs.extend(CreateSamplesOperation, null, [ IOperation ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.sample.CreateSamplesOperation';
+		prototype['@type'] = 'dto.sample.create.CreateSamplesOperation';
 		prototype.creations = null;
 		prototype.getCreations = function() {
 			return this.creations;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/CreateSamplesResult.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/CreateSamplesResult.js
similarity index 72%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/CreateSamplesResult.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/CreateSamplesResult.js
index a5b768dbf65..b4d74ae119e 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/CreateSamplesResult.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/CreateSamplesResult.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperationResult" ], function(stjs, IOperationResult) {
+define([ "stjs", "dto/common/operation/IOperationResult" ], function(stjs, IOperationResult) {
 	var CreateSamplesResult = function(permIds) {
 		this.permIds = permIds;
 	};
 	stjs.extend(CreateSamplesResult, null, [ IOperationResult ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.sample.CreateSamplesResult';
+		prototype['@type'] = 'dto.sample.create.CreateSamplesResult';
 		prototype.permIds = null;
 		prototype.getPermIds = function() {
 			return this.permIds;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleCreation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/SampleCreation.js
similarity index 98%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleCreation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/SampleCreation.js
index 9b77554081b..196b67dfce9 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleCreation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/create/SampleCreation.js
@@ -6,7 +6,7 @@ define([ "stjs" ], function(stjs) {
 		this.properties = {};
 	};
 	stjs.extend(SampleCreation, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.sample.SampleCreation';
+		prototype['@type'] = 'dto.sample.create.SampleCreation';
 		constructor.serialVersionUID = 1;
 		prototype.typeId = null;
 		prototype.experimentId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/sample/SampleDeletionOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/delete/SampleDeletionOptions.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/sample/SampleDeletionOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/delete/SampleDeletionOptions.js
index 5d6e67d42a7..1f50085aa72 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/sample/SampleDeletionOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/delete/SampleDeletionOptions.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
+define([ "stjs", "dto/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
 	var SampleDeletionOptions = function() {
 		AbstractObjectDeletionOptions.call(this);
 	};
 	stjs.extend(SampleDeletionOptions, AbstractObjectDeletionOptions, [ AbstractObjectDeletionOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.sample.SampleDeletionOptions';
+		prototype['@type'] = 'dto.sample.delete.SampleDeletionOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return SampleDeletionOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleFetchOptions.js
similarity index 79%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleFetchOptions.js
index 7ebb4decc04..eadaf1edb54 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleFetchOptions.js
@@ -2,14 +2,14 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/sample/SampleTypeFetchOptions', 'dto/fetchoptions/space/SpaceFetchOptions', 'dto/fetchoptions/project/ProjectFetchOptions',
-		'dto/fetchoptions/experiment/ExperimentFetchOptions', 'dto/fetchoptions/property/PropertyFetchOptions', 'dto/fetchoptions/tag/TagFetchOptions', 'dto/fetchoptions/person/PersonFetchOptions',
-		'dto/fetchoptions/attachment/AttachmentFetchOptions', 'dto/fetchoptions/material/MaterialFetchOptions', 'dto/fetchoptions/dataset/DataSetFetchOptions',
-		'dto/fetchoptions/history/HistoryEntryFetchOptions', 'dto/fetchoptions/sample/SampleSortOptions' ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", 'dto/sample/fetchoptions/SampleTypeFetchOptions', 'dto/space/fetchoptions/SpaceFetchOptions',
+		'dto/project/fetchoptions/ProjectFetchOptions', 'dto/experiment/fetchoptions/ExperimentFetchOptions', 'dto/property/fetchoptions/PropertyFetchOptions', 'dto/tag/fetchoptions/TagFetchOptions',
+		'dto/person/fetchoptions/PersonFetchOptions', 'dto/attachment/fetchoptions/AttachmentFetchOptions', 'dto/material/fetchoptions/MaterialFetchOptions',
+		'dto/dataset/fetchoptions/DataSetFetchOptions', 'dto/history/fetchoptions/HistoryEntryFetchOptions', 'dto/sample/fetchoptions/SampleSortOptions' ], function(require, stjs, FetchOptions) {
 	var SampleFetchOptions = function() {
 	};
 	stjs.extend(SampleFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sample.SampleFetchOptions';
+		prototype['@type'] = 'dto.sample.fetchoptions.SampleFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.type = null;
 		prototype.project = null;
@@ -30,7 +30,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		prototype.sort = null;
 		prototype.withType = function() {
 			if (this.type == null) {
-				var SampleTypeFetchOptions = require("dto/fetchoptions/sample/SampleTypeFetchOptions");
+				var SampleTypeFetchOptions = require("dto/sample/fetchoptions/SampleTypeFetchOptions");
 				this.type = new SampleTypeFetchOptions();
 			}
 			return this.type;
@@ -43,7 +43,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withProject = function() {
 			if (this.project == null) {
-				var ProjectFetchOptions = require("dto/fetchoptions/space/ProjectFetchOptions");
+				var ProjectFetchOptions = require("dto/project/fetchoptions/ProjectFetchOptions");
 				this.project = new ProjectFetchOptions();
 			}
 			return this.project;
@@ -56,7 +56,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withSpace = function() {
 			if (this.space == null) {
-				var SpaceFetchOptions = require("dto/fetchoptions/space/SpaceFetchOptions");
+				var SpaceFetchOptions = require("dto/space/fetchoptions/SpaceFetchOptions");
 				this.space = new SpaceFetchOptions();
 			}
 			return this.space;
@@ -69,7 +69,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withExperiment = function() {
 			if (this.experiment == null) {
-				var ExperimentFetchOptions = require("dto/fetchoptions/experiment/ExperimentFetchOptions");
+				var ExperimentFetchOptions = require("dto/experiment/fetchoptions/ExperimentFetchOptions");
 				this.experiment = new ExperimentFetchOptions();
 			}
 			return this.experiment;
@@ -82,7 +82,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withProperties = function() {
 			if (this.properties == null) {
-				var PropertyFetchOptions = require("dto/fetchoptions/property/PropertyFetchOptions");
+				var PropertyFetchOptions = require("dto/property/fetchoptions/PropertyFetchOptions");
 				this.properties = new PropertyFetchOptions();
 			}
 			return this.properties;
@@ -95,7 +95,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withMaterialProperties = function() {
 			if (this.materialProperties == null) {
-				var MaterialFetchOptions = require("dto/fetchoptions/material/MaterialFetchOptions");
+				var MaterialFetchOptions = require("dto/material/fetchoptions/MaterialFetchOptions");
 				this.materialProperties = new MaterialFetchOptions();
 			}
 			return this.materialProperties;
@@ -156,7 +156,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withDataSets = function() {
 			if (this.dataSets == null) {
-				var DataSetFetchOptions = require("dto/fetchoptions/dataset/DataSetFetchOptions");
+				var DataSetFetchOptions = require("dto/dataset/fetchoptions/DataSetFetchOptions");
 				this.dataSets = new DataSetFetchOptions();
 			}
 			return this.dataSets;
@@ -169,7 +169,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withHistory = function() {
 			if (this.history == null) {
-				var HistoryEntryFetchOptions = require("dto/fetchoptions/history/HistoryEntryFetchOptions");
+				var HistoryEntryFetchOptions = require("dto/history/fetchoptions/HistoryEntryFetchOptions");
 				this.history = new HistoryEntryFetchOptions();
 			}
 			return this.history;
@@ -182,7 +182,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withTags = function() {
 			if (this.tags == null) {
-				var TagFetchOptions = require("dto/fetchoptions/tag/TagFetchOptions");
+				var TagFetchOptions = require("dto/tag/fetchoptions/TagFetchOptions");
 				this.tags = new TagFetchOptions();
 			}
 			return this.tags;
@@ -195,7 +195,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withRegistrator = function() {
 			if (this.registrator == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.registrator = new PersonFetchOptions();
 			}
 			return this.registrator;
@@ -208,7 +208,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withModifier = function() {
 			if (this.modifier == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.modifier = new PersonFetchOptions();
 			}
 			return this.modifier;
@@ -221,7 +221,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.withAttachments = function() {
 			if (this.attachments == null) {
-				var AttachmentFetchOptions = require("dto/fetchoptions/attachment/AttachmentFetchOptions");
+				var AttachmentFetchOptions = require("dto/attachment/fetchoptions/AttachmentFetchOptions");
 				this.attachments = new AttachmentFetchOptions();
 			}
 			return this.attachments;
@@ -234,7 +234,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", 'dto/fetchoptions/s
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var SampleSortOptions = require("dto/fetchoptions/sample/SampleSortOptions");
+				var SampleSortOptions = require("dto/sample/fetchoptions/SampleSortOptions");
 				this.sort = new SampleSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleSortOptions.js
similarity index 58%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleSortOptions.js
index 0fe19869860..d10ba524212 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/EntityWithPropertiesSortOptions" ], function(require, stjs, EntityWithPropertiesSortOptions) {
 	var SampleSortOptions = function() {
 		EntityWithPropertiesSortOptions.call(this);
 	};
 	stjs.extend(SampleSortOptions, EntityWithPropertiesSortOptions, [ EntityWithPropertiesSortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sample.SampleSortOptions';
+		prototype['@type'] = 'dto.sample.fetchoptions.SampleSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return SampleSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleTypeFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleTypeFetchOptions.js
similarity index 70%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleTypeFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleTypeFetchOptions.js
index ced7ee3e442..dbc9c8dec99 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleTypeFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleTypeFetchOptions.js
@@ -2,16 +2,16 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/sample/SampleTypeSortOptions" ], function(stjs, FetchOptions) {
+define([ "stjs", "dto/common/fetchoptions/FetchOptions", "dto/sample/fetchoptions/SampleTypeSortOptions" ], function(stjs, FetchOptions) {
 	var SampleTypeFetchOptions = function() {
 	};
 	stjs.extend(SampleTypeFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sample.SampleTypeFetchOptions';
+		prototype['@type'] = 'dto.sample.fetchoptions.SampleTypeFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.sort = null;
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var SampleTypeSortOptions = require("dto/fetchoptions/sample/SampleTypeSortOptions");
+				var SampleTypeSortOptions = require("dto/sample/fetchoptions/SampleTypeSortOptions");
 				this.sort = new SampleTypeSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleTypeSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleTypeSortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleTypeSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleTypeSortOptions.js
index b76e2037234..78bc6600e89 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/sample/SampleTypeSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/fetchoptions/SampleTypeSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var SampleTypeSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(SampleTypeSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.sample.SampleTypeSortOptions';
+		prototype['@type'] = 'dto.sample.fetchoptions.SampleTypeSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return SampleTypeSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/SampleRelationType.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/history/SampleRelationType.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/history/SampleRelationType.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/history/SampleRelationType.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/ISampleId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/ISampleId.js
new file mode 100644
index 00000000000..fecd90259f8
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/ISampleId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies a sample in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var ISampleId = function() {
+	};
+	stjs.extend(ISampleId, null, [ IObjectId ], null, {});
+	return ISampleId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SampleIdentifier.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SampleIdentifier.js
new file mode 100644
index 00000000000..b0dbbcc5b33
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SampleIdentifier.js
@@ -0,0 +1,20 @@
+/**
+ * Sample identifier.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectIdentifier", "dto/sample/id/ISampleId" ], function(stjs, ObjectIdentifier, ISampleId) {
+	/**
+	 * @param identifier
+	 *            Sample identifier, e.g. "/MY_SPACE/MY_SAMPLE" (space sample)
+	 *            or "/MY_SAMPLE" (shared sample)
+	 */
+	var SampleIdentifier = function(identifier) {
+		ObjectIdentifier.call(this, identifier);
+	};
+	stjs.extend(SampleIdentifier, ObjectIdentifier, [ ObjectIdentifier, ISampleId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.sample.id.SampleIdentifier';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return SampleIdentifier;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SamplePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SamplePermId.js
new file mode 100644
index 00000000000..6bb32b1cdd5
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/id/SamplePermId.js
@@ -0,0 +1,19 @@
+/**
+ * Sample perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/sample/id/ISampleId" ], function(stjs, ObjectPermId, ISampleId) {
+	/**
+	 * @param permId
+	 *            Sample perm id, e.g. "201108050937246-1031".
+	 */
+	var SamplePermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(SamplePermId, ObjectPermId, [ ObjectPermId, ISampleId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.sample.id.SamplePermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return SamplePermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoSampleContainerSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/NoSampleContainerSearchCriteria.js
similarity index 62%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoSampleContainerSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/NoSampleContainerSearchCriteria.js
index 9d1d31736e8..b005ec75eb9 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoSampleContainerSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/NoSampleContainerSearchCriteria.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/NoSampleSearchCriteria" ], function(stjs, NoSampleSearchCriteria) {
+define([ "stjs", "dto/sample/search/NoSampleSearchCriteria" ], function(stjs, NoSampleSearchCriteria) {
 	var NoSampleContainerSearchCriteria = function() {
 	};
 	stjs.extend(NoSampleContainerSearchCriteria, NoSampleSearchCriteria, [ NoSampleSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NoSampleContainerSearchCriteria';
+		prototype['@type'] = 'dto.sample.search.NoSampleContainerSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return NoSampleContainerSearchCriteria;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoSampleSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/NoSampleSearchCriteria.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoSampleSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/NoSampleSearchCriteria.js
index 97056d1243d..73270bfb05e 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/NoSampleSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/NoSampleSearchCriteria.js
@@ -1,11 +1,11 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
+define([ "stjs", "dto/common/search/ISearchCriteria" ], function(stjs, ISearchCriteria) {
 	var NoSampleSearchCriteria = function() {
 	};
 	stjs.extend(NoSampleSearchCriteria, null, [ ISearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.NoSampleSearchCriteria';
+		prototype['@type'] = 'dto.sample.search.NoSampleSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return NoSampleSearchCriteria;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SampleSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/SampleSearchCriteria.js
similarity index 72%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SampleSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/SampleSearchCriteria.js
index 2fb43ae4677..566f4f20fea 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SampleSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/SampleSearchCriteria.js
@@ -1,38 +1,36 @@
 /**
  * @author pkupczyk
  */
-define([ "require", "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/search/SampleSearchRelation", "dto/search/SearchOperator",
-         "dto/search/SpaceSearchCriteria", "dto/search/ProjectSearchCriteria", "dto/search/NoProjectSearchCriteria",
-         "dto/search/ExperimentSearchCriteria", "dto/search/NoExperimentSearchCriteria",
-         "dto/search/NoSampleContainerSearchCriteria"], 
-		function(require, stjs, AbstractEntitySearchCriteria, SampleSearchRelation, SearchOperator) {
+define([ "require", "stjs", "dto/common/search/AbstractEntitySearchCriteria", "dto/common/search/SearchOperator", "dto/sample/search/SampleSearchRelation", "dto/space/search/SpaceSearchCriteria",
+		"dto/project/search/ProjectSearchCriteria", "dto/project/search/NoProjectSearchCriteria", "dto/experiment/search/ExperimentSearchCriteria", "dto/experiment/search/NoExperimentSearchCriteria",
+		"dto/sample/search/NoSampleContainerSearchCriteria" ], function(require, stjs, AbstractEntitySearchCriteria, SearchOperator, SampleSearchRelation) {
 
 	var SampleSearchCriteria = function(relation) {
 		AbstractEntitySearchCriteria.call(this);
 		this.relation = relation ? relation : SampleSearchRelation.SAMPLE;
 	};
 	stjs.extend(SampleSearchCriteria, AbstractEntitySearchCriteria, [ AbstractEntitySearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.SampleSearchCriteria';
+		prototype['@type'] = 'dto.sample.search.SampleSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.relation = null;
 		prototype.withSpace = function() {
-			var SpaceSearchCriteria = require("dto/search/SpaceSearchCriteria");
+			var SpaceSearchCriteria = require("dto/space/search/SpaceSearchCriteria");
 			return this.addCriteria(new SpaceSearchCriteria());
 		};
 		prototype.withProject = function() {
-			var ProjectSearchCriteria = require("dto/search/ProjectSearchCriteria");
+			var ProjectSearchCriteria = require("dto/project/search/ProjectSearchCriteria");
 			return this.addCriteria(new ProjectSearchCriteria());
 		};
 		prototype.withoutProject = function() {
-			var NoProjectSearchCriteria = require("dto/search/NoProjectSearchCriteria");
+			var NoProjectSearchCriteria = require("dto/project/search/NoProjectSearchCriteria");
 			return this.addCriteria(new NoProjectSearchCriteria());
 		};
 		prototype.withExperiment = function() {
-			var ExperimentSearchCriteria = require("dto/search/ExperimentSearchCriteria");
+			var ExperimentSearchCriteria = require("dto/experiment/search/ExperimentSearchCriteria");
 			return this.addCriteria(new ExperimentSearchCriteria());
 		};
 		prototype.withoutExperiment = function() {
-			var NoExperimentSearchCriteria = require("dto/search/NoExperimentSearchCriteria");
+			var NoExperimentSearchCriteria = require("dto/experiment/search/NoExperimentSearchCriteria");
 			return this.addCriteria(new NoExperimentSearchCriteria());
 		};
 		prototype.withParents = function() {
@@ -45,7 +43,7 @@ define([ "require", "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/sear
 			return this.addCriteria(new SampleContainerSearchCriteria());
 		};
 		prototype.withoutContainer = function() {
-			var NoSampleContainerSearchCriteria = require("dto/search/NoSampleContainerSearchCriteria");
+			var NoSampleContainerSearchCriteria = require("dto/sample/search/NoSampleContainerSearchCriteria");
 			return this.addCriteria(new NoSampleContainerSearchCriteria());
 		};
 		prototype.withOrOperator = function() {
@@ -81,7 +79,7 @@ define([ "require", "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/sear
 		SampleSearchCriteria.call(this, SampleSearchRelation.PARENTS);
 	};
 	stjs.extend(SampleParentsSearchCriteria, SampleSearchCriteria, [ SampleSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.SampleParentsSearchCriteria';
+		prototype['@type'] = 'dto.sample.search.SampleParentsSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		relation : {
@@ -102,7 +100,7 @@ define([ "require", "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/sear
 		SampleSearchCriteria.call(this, SampleSearchRelation.CHILDREN);
 	};
 	stjs.extend(SampleChildrenSearchCriteria, SampleSearchCriteria, [ SampleSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.SampleChildrenSearchCriteria';
+		prototype['@type'] = 'dto.sample.search.SampleChildrenSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		relation : {
@@ -123,7 +121,7 @@ define([ "require", "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/sear
 		SampleSearchCriteria.call(this, SampleSearchRelation.CONTAINER);
 	};
 	stjs.extend(SampleContainerSearchCriteria, SampleSearchCriteria, [ SampleSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.SampleContainerSearchCriteria';
+		prototype['@type'] = 'dto.sample.search.SampleContainerSearchCriteria';
 		constructor.serialVersionUID = 1;
 	}, {
 		relation : {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SampleSearchRelation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/SampleSearchRelation.js
similarity index 100%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SampleSearchRelation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/search/SampleSearchRelation.js
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/update/SampleUpdate.js
similarity index 92%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleUpdate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/update/SampleUpdate.js
index c24134d9597..fbaa005dfac 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/sample/SampleUpdate.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/update/SampleUpdate.js
@@ -1,7 +1,7 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/FieldUpdateValue", "dto/entity/IdListUpdateValue", "dto/entity/AttachmentListUpdateValue" ], function(stjs, FieldUpdateValue, IdListUpdateValue,
+define([ "stjs", "dto/common/update/FieldUpdateValue", "dto/common/update/IdListUpdateValue", "dto/attachment/update/AttachmentListUpdateValue" ], function(stjs, FieldUpdateValue, IdListUpdateValue,
 		AttachmentListUpdateValue) {
 	var SampleUpdate = function() {
 		this.properties = {};
@@ -16,7 +16,7 @@ define([ "stjs", "dto/entity/FieldUpdateValue", "dto/entity/IdListUpdateValue",
 		this.attachments = new AttachmentListUpdateValue();
 	};
 	stjs.extend(SampleUpdate, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.sample.SampleUpdate';
+		prototype['@type'] = 'dto.sample.update.SampleUpdate';
 		constructor.serialVersionUID = 1;
 		prototype.sampleId = null;
 
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/UpdateSamplesOperation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/update/UpdateSamplesOperation.js
similarity index 73%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/UpdateSamplesOperation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/update/UpdateSamplesOperation.js
index 1c4ae45bac2..77f4050513c 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/operation/sample/UpdateSamplesOperation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/sample/update/UpdateSamplesOperation.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/operation/IOperation" ], function(stjs, IOperation) {
+define([ "stjs", "dto/common/operation/IOperation" ], function(stjs, IOperation) {
 	var UpdateSamplesOperation = function(updates) {
 		this.updates = updates;
 	};
 	stjs.extend(UpdateSamplesOperation, null, [ IOperation ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.operation.sample.UpdateSamplesOperation';
+		prototype['@type'] = 'dto.sample.update.UpdateSamplesOperation';
 		prototype.updates = null;
 		prototype.getUpdates = function() {
 			return this.updates;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractEntitySearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractEntitySearchCriteria.js
deleted file mode 100644
index da3cc1ac69b..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/AbstractEntitySearchCriteria.js
+++ /dev/null
@@ -1,86 +0,0 @@
-/**
- * @author pkupczyk
- */
-define([ "require", "stjs", "dto/search/AbstractObjectSearchCriteria", "dto/search/SearchOperator",
-         "dto/search/CodeSearchCriteria", "dto/search/EntityTypeSearchCriteria", "dto/search/PermIdSearchCriteria",
-         "dto/search/RegistrationDateSearchCriteria", "dto/search/ModificationDateSearchCriteria",
-         "dto/search/NumberPropertySearchCriteria", "dto/search/TagSearchCriteria", "dto/search/StringPropertySearchCriteria",
-         "dto/search/DatePropertySearchCriteria", "dto/search/AnyPropertySearchCriteria", "dto/search/AnyFieldSearchCriteria",
-         "dto/search/AbstractCompositeSearchCriteria"],
-		function(require, stjs, AbstractObjectSearchCriteria, SearchOperator) {
-	var AbstractEntitySearchCriteria = function() {
-		AbstractObjectSearchCriteria.call(this);
-	};
-	stjs.extend(AbstractEntitySearchCriteria, AbstractObjectSearchCriteria, [ AbstractObjectSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.AbstractEntitySearchCriteria';
-		constructor.serialVersionUID = 1;
-		prototype.operator = SearchOperator.AND;
-		prototype.withOperator = function(anOperator) {
-			this.operator = anOperator;
-			return this;
-		};
-		prototype.getOperator = function() {
-			return this.operator;
-		};
-		prototype.withCode = function() {
-			var CodeSearchCriteria = require("dto/search/CodeSearchCriteria");
-			return this.addCriteria(new CodeSearchCriteria());
-		};
-		prototype.withType = function() {
-			var EntityTypeSearchCriteria = require("dto/search/EntityTypeSearchCriteria");
-			return this.addCriteria(new EntityTypeSearchCriteria());
-		};
-		prototype.withPermId = function() {
-			var PermIdSearchCriteria = require("dto/search/PermIdSearchCriteria");
-			return this.addCriteria(new PermIdSearchCriteria());
-		};
-		prototype.withRegistrationDate = function() {
-			var RegistrationDateSearchCriteria = require("dto/search/RegistrationDateSearchCriteria");
-			return this.addCriteria(new RegistrationDateSearchCriteria());
-		};
-		prototype.withModificationDate = function() {
-			var ModificationDateSearchCriteria = require("dto/search/ModificationDateSearchCriteria");
-			return this.addCriteria(new ModificationDateSearchCriteria());
-		};
-		prototype.withNumberProperty = function(propertyName) {
-			var NumberPropertySearchCriteria = require("dto/search/NumberPropertySearchCriteria");
-			return this.addCriteria(new NumberPropertySearchCriteria(propertyName));
-		};
-		prototype.withTag = function() {
-			var TagSearchCriteria = require("dto/search/TagSearchCriteria");
-			return this.addCriteria(new TagSearchCriteria());
-		};
-		prototype.withProperty = function(propertyName) {
-			var StringPropertySearchCriteria = require("dto/search/StringPropertySearchCriteria");
-			return this.addCriteria(new StringPropertySearchCriteria(propertyName));
-		};
-		prototype.withDateProperty = function(propertyName) {
-			var DatePropertySearchCriteria = require("dto/search/DatePropertySearchCriteria");
-			return this.addCriteria(new DatePropertySearchCriteria(propertyName));
-		};
-		prototype.withAnyProperty = function() {
-			var AnyPropertySearchCriteria = require("dto/search/AnyPropertySearchCriteria");
-			return this.addCriteria(new AnyPropertySearchCriteria());
-		};
-		prototype.withAnyField = function() {
-			var AnyFieldSearchCriteria = require("dto/search/AnyFieldSearchCriteria");
-			return this.addCriteria(new AnyFieldSearchCriteria());
-		};
-		prototype.createBuilder = function() {
-			var AbstractCompositeSearchCriteria = require("dto/search/AbstractCompositeSearchCriteria");
-			var builder = AbstractCompositeSearchCriteria.prototype.createBuilder.call(this);
-			builder.setOperator(this.operator);
-			return builder;
-		};
-	}, {
-		operator : {
-			name : "Enum",
-			arguments : [ "SearchOperator" ]
-		},
-		criteria : {
-			name : "Collection",
-			arguments : [ "ISearchCriteria" ]
-		}
-	});
-	return AbstractEntitySearchCriteria;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DataSetSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DataSetSearchCriteria.js
deleted file mode 100644
index d749ceb7a40..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/DataSetSearchCriteria.js
+++ /dev/null
@@ -1,134 +0,0 @@
-/**
- * @author pkupczyk
- */
-define([ "require", "stjs", "dto/search/AbstractEntitySearchCriteria", "dto/search/DataSetSearchRelation", "dto/search/SearchOperator",
-         "dto/search/ExperimentSearchCriteria", "dto/search/NoExperimentSearchCriteria", 
-         "dto/search/SampleSearchCriteria", "dto/search/NoSampleSearchCriteria"], 
-		function(require, stjs, AbstractEntitySearchCriteria, DataSetSearchRelation, SearchOperator) {
-	var DataSetSearchCriteria = function(relation) {
-		AbstractEntitySearchCriteria.call(this);
-		this.relation = relation ? relation : DataSetSearchRelation.DATASET;
-	};
-	stjs.extend(DataSetSearchCriteria, AbstractEntitySearchCriteria, [ AbstractEntitySearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DataSetSearchCriteria';
-		constructor.serialVersionUID = 1;
-		prototype.relation = null;
-		prototype.withParents = function() {
-			return this.addCriteria(new DataSetParentsSearchCriteria());
-		};
-		prototype.withChildren = function() {
-			return this.addCriteria(new DataSetChildrenSearchCriteria());
-		};
-		prototype.withContainer = function() {
-			return this.addCriteria(new DataSetContainerSearchCriteria());
-		};
-		prototype.withExperiment = function() {
-			var ExperimentSearchCriteria = require("dto/search/ExperimentSearchCriteria");
-			return this.addCriteria(new ExperimentSearchCriteria());
-		};
-		prototype.withoutExperiment = function() {
-			var NoExperimentSearchCriteria = require("dto/search/NoExperimentSearchCriteria");
-			return this.addCriteria(new NoExperimentSearchCriteria());
-		};
-		prototype.withSample = function() {
-			var SampleSearchCriteria = require("dto/search/SampleSearchCriteria");
-			return this.addCriteria(new SampleSearchCriteria());
-		};
-		prototype.withoutSample = function() {
-			var NoSampleSearchCriteria = require("dto/search/NoSampleSearchCriteria");
-			return this.addCriteria(new NoSampleSearchCriteria());
-		};
-		prototype.withOrOperator = function() {
-			return this.withOperator(SearchOperator.OR);
-		};
-		prototype.withAndOperator = function() {
-			return this.withOperator(SearchOperator.AND);
-		};
-		prototype.getRelation = function() {
-			return this.relation;
-		};
-		prototype.createBuilder = function() {
-			var builder = AbstractEntitySearchCriteria.prototype.createBuilder.call(this);
-			builder.setName(this.relation.name());
-			return builder;
-		};
-	}, {
-		relation : {
-			name : "Enum",
-			arguments : [ "DataSetSearchRelation" ]
-		},
-		operator : {
-			name : "Enum",
-			arguments : [ "SearchOperator" ]
-		},
-		criteria : {
-			name : "Collection",
-			arguments : [ "ISearchCriteria" ]
-		}
-	});
-
-	var DataSetParentsSearchCriteria = function() {
-		DataSetSearchCriteria.call(this, DataSetSearchRelation.PARENTS);
-	};
-	stjs.extend(DataSetParentsSearchCriteria, DataSetSearchCriteria, [ DataSetSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DataSetParentsSearchCriteria';
-		constructor.serialVersionUID = 1;
-	}, {
-		relation : {
-			name : "Enum",
-			arguments : [ "DataSetSearchRelation" ]
-		},
-		operator : {
-			name : "Enum",
-			arguments : [ "SearchOperator" ]
-		},
-		criteria : {
-			name : "Collection",
-			arguments : [ "ISearchCriteria" ]
-		}
-	});
-
-	var DataSetChildrenSearchCriteria = function() {
-		DataSetSearchCriteria.call(this, DataSetSearchRelation.CHILDREN);
-	};
-	stjs.extend(DataSetChildrenSearchCriteria, DataSetSearchCriteria, [ DataSetSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DataSetChildrenSearchCriteria';
-		constructor.serialVersionUID = 1;
-	}, {
-		relation : {
-			name : "Enum",
-			arguments : [ "DataSetSearchRelation" ]
-		},
-		operator : {
-			name : "Enum",
-			arguments : [ "SearchOperator" ]
-		},
-		criteria : {
-			name : "Collection",
-			arguments : [ "ISearchCriteria" ]
-		}
-	});
-
-	var DataSetContainerSearchCriteria = function() {
-		DataSetSearchCriteria.call(this, DataSetSearchRelation.CONTAINER);
-	};
-	stjs.extend(DataSetContainerSearchCriteria, DataSetSearchCriteria, [ DataSetSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.DataSetContainerSearchCriteria';
-		constructor.serialVersionUID = 1;
-	}, {
-		relation : {
-			name : "Enum",
-			arguments : [ "DataSetSearchRelation" ]
-		},
-		operator : {
-			name : "Enum",
-			arguments : [ "SearchOperator" ]
-		},
-		criteria : {
-			name : "Collection",
-			arguments : [ "ISearchCriteria" ]
-		}
-	});
-
-	return DataSetSearchCriteria;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyFieldSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyFieldSearchCriteria.js
deleted file mode 100644
index 530365ce3c6..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyFieldSearchCriteria.js
+++ /dev/null
@@ -1,15 +0,0 @@
-define([ "stjs", "dto/search/AbstractFieldSearchCriteria" ], function(stjs, AbstractFieldSearchCriteria) {
-	var VocabularyFieldSearchCriteria = function(fieldName, fieldType) {
-		AbstractFieldSearchCriteria.call(this, fieldName, fieldType);
-	};
-	stjs.extend(VocabularyFieldSearchCriteria, AbstractFieldSearchCriteria, [ AbstractFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.VocabularyFieldSearchCriteria';
-		constructor.serialVersionUID = 1;
-	}, {
-		fieldType : {
-			name : "Enum",
-			arguments : [ "SearchFieldType" ]
-		}
-	});
-	return VocabularyFieldSearchCriteria;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyPropertySearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyPropertySearchCriteria.js
deleted file mode 100644
index ec901ec311b..00000000000
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/VocabularyPropertySearchCriteria.js
+++ /dev/null
@@ -1,18 +0,0 @@
-/**
- * @author pkupczyk
- */
-define([ "stjs", "dto/search/VocabularyFieldSearchCriteria", "dto/search/SearchFieldType" ], function(stjs, VocabularyFieldSearchCriteria) {
-	var VocabularyPropertySearchCriteria = function(fieldName) {
-		VocabularyFieldSearchCriteria.call(this, fieldName, SearchFieldType.PROPERTY);
-	};
-	stjs.extend(VocabularyPropertySearchCriteria, VocabularyFieldSearchCriteria, [ VocabularyFieldSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.VocabularyPropertySearchCriteria';
-		constructor.serialVersionUID = 1;
-	}, {
-		fieldType : {
-			name : "Enum",
-			arguments : [ "SearchFieldType" ]
-		}
-	});
-	return VocabularyPropertySearchCriteria;
-})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/Space.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/Space.js
similarity index 98%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/Space.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/Space.js
index 98d8f73cd74..56c46ff5e87 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/Space.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/Space.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Space = function() {
 	};
 	stjs.extend(Space, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.space.Space';
+		prototype['@type'] = 'dto.space.Space';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/SpaceCreation.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/create/SpaceCreation.js
similarity index 91%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/SpaceCreation.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/create/SpaceCreation.js
index 17b46cdf30c..3a0e13b4d5f 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/SpaceCreation.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/create/SpaceCreation.js
@@ -5,7 +5,7 @@ define([ "stjs" ], function(stjs) {
 	var SpaceCreation = function() {
 	};
 	stjs.extend(SpaceCreation, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.space.SpaceCreation';
+		prototype['@type'] = 'dto.space.create.SpaceCreation';
 		constructor.serialVersionUID = 1;
 		prototype.code = null;
 		prototype.description = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/space/SpaceDeletionOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/delete/SpaceDeletionOptions.js
similarity index 63%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/space/SpaceDeletionOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/delete/SpaceDeletionOptions.js
index c261e7ff7c0..939da75fd9d 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/deletion/space/SpaceDeletionOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/delete/SpaceDeletionOptions.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
+define([ "stjs", "dto/deletion/AbstractObjectDeletionOptions" ], function(stjs, AbstractObjectDeletionOptions) {
 	var SpaceDeletionOptions = function() {
 		AbstractObjectDeletionOptions.call(this);
 	};
 	stjs.extend(SpaceDeletionOptions, AbstractObjectDeletionOptions, [ AbstractObjectDeletionOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.deletion.space.SpaceDeletionOptions';
+		prototype['@type'] = 'dto.space.delete.SpaceDeletionOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return SpaceDeletionOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/space/SpaceFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/fetchoptions/SpaceFetchOptions.js
similarity index 75%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/space/SpaceFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/fetchoptions/SpaceFetchOptions.js
index 0a2a812bebf..8d873c186eb 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/space/SpaceFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/fetchoptions/SpaceFetchOptions.js
@@ -2,12 +2,12 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/person/PersonFetchOptions", "dto/fetchoptions/sample/SampleFetchOptions",
-		"dto/fetchoptions/project/ProjectFetchOptions", "dto/fetchoptions/space/SpaceSortOptions" ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/person/fetchoptions/PersonFetchOptions", "dto/sample/fetchoptions/SampleFetchOptions",
+		"dto/project/fetchoptions/ProjectFetchOptions", "dto/space/fetchoptions/SpaceSortOptions" ], function(require, stjs, FetchOptions) {
 	var SpaceFetchOptions = function() {
 	};
 	stjs.extend(SpaceFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.space.SpaceFetchOptions';
+		prototype['@type'] = 'dto.space.fetchoptions.SpaceFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.registrator = null;
 		prototype.samples = null;
@@ -15,7 +15,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/p
 		prototype.sort = null;
 		prototype.withRegistrator = function() {
 			if (this.registrator == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.registrator = new PersonFetchOptions();
 			}
 			return this.registrator;
@@ -28,7 +28,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/p
 		};
 		prototype.withSamples = function() {
 			if (this.samples == null) {
-				var SampleFetchOptions = require("dto/fetchoptions/sample/SampleFetchOptions");
+				var SampleFetchOptions = require("dto/sample/fetchoptions/SampleFetchOptions");
 				this.samples = new SampleFetchOptions();
 			}
 			return this.samples;
@@ -41,7 +41,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/p
 		};
 		prototype.withProjects = function() {
 			if (this.projects == null) {
-				var ProjectFetchOptions = require("dto/fetchoptions/project/ProjectFetchOptions");
+				var ProjectFetchOptions = require("dto/project/fetchoptions/ProjectFetchOptions");
 				this.projects = new ProjectFetchOptions();
 			}
 			return this.projects;
@@ -54,7 +54,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/p
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var SpaceSortOptions = require("dto/fetchoptions/space/SpaceSortOptions");
+				var SpaceSortOptions = require("dto/space/fetchoptions/SpaceSortOptions");
 				this.sort = new SpaceSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/space/SpaceSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/fetchoptions/SpaceSortOptions.js
similarity index 58%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/space/SpaceSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/fetchoptions/SpaceSortOptions.js
index be295fb8cb0..e01900238a5 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/space/SpaceSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/fetchoptions/SpaceSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/EntitySortOptions" ], function(require, stjs, EntitySortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/EntitySortOptions" ], function(require, stjs, EntitySortOptions) {
 	var SpaceSortOptions = function() {
 		EntitySortOptions.call(this);
 	};
 	stjs.extend(SpaceSortOptions, EntitySortOptions, [ EntitySortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.space.SpaceSortOptions';
+		prototype['@type'] = 'dto.space.fetchoptions.SpaceSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return SpaceSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/ISpaceId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/ISpaceId.js
new file mode 100644
index 00000000000..22e2feafc81
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/ISpaceId.js
@@ -0,0 +1,11 @@
+/**
+ * Holds information that uniquely identifies a space in openBIS.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var ISpaceId = function() {
+	};
+	stjs.extend(ISpaceId, null, [ IObjectId ], null, {});
+	return ISpaceId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/SpacePermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/SpacePermId.js
new file mode 100644
index 00000000000..ae3d5f6de92
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/id/SpacePermId.js
@@ -0,0 +1,27 @@
+/**
+ * Space perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/space/id/ISpaceId" ], function(stjs, ObjectPermId, ISpaceId) {
+	/**
+	 * @param permId
+	 *            Space perm id, e.g. "/MY_SPACE" or "MY_SPACE".
+	 */
+	var SpacePermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(SpacePermId, ObjectPermId, [ ObjectPermId, ISpaceId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.space.id.SpacePermId';
+		constructor.serialVersionUID = 1;
+		prototype.getPermId = function() {
+			var permId = ObjectPermId.prototype.getPermId.call(this);
+			if (permId.startsWith("/")) {
+				return permId.substring(1);
+			} else {
+				return permId;
+			}
+		};
+	}, {});
+	return SpacePermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SpaceSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/search/SpaceSearchCriteria.js
similarity index 56%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SpaceSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/search/SpaceSearchCriteria.js
index fa14f250990..fe01d11d3be 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/SpaceSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/search/SpaceSearchCriteria.js
@@ -1,25 +1,24 @@
 /**
  * @author pkupczyk
  */
-define([ "require", "stjs", "dto/search/AbstractObjectSearchCriteria",
-         "dto/search/CodeSearchCriteria", "dto/search/PermIdSearchCriteria", "dto/search/AbstractCompositeSearchCriteria"], 
-		function(require, stjs, AbstractObjectSearchCriteria) {
+define([ "require", "stjs", "dto/common/search/AbstractObjectSearchCriteria", "dto/common/search/CodeSearchCriteria", "dto/common/search/PermIdSearchCriteria",
+		"dto/common/search/AbstractCompositeSearchCriteria" ], function(require, stjs, AbstractObjectSearchCriteria) {
 	var SpaceSearchCriteria = function() {
 		AbstractObjectSearchCriteria.call(this);
 	};
 	stjs.extend(SpaceSearchCriteria, AbstractObjectSearchCriteria, [ AbstractObjectSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.SpaceSearchCriteria';
+		prototype['@type'] = 'dto.space.search.SpaceSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.withCode = function() {
-			var CodeSearchCriteria = require("dto/search/CodeSearchCriteria");
+			var CodeSearchCriteria = require("dto/common/search/CodeSearchCriteria");
 			return this.addCriteria(new CodeSearchCriteria());
 		};
 		prototype.withPermId = function() {
-			var PermIdSearchCriteria = require("dto/search/PermIdSearchCriteria");
+			var PermIdSearchCriteria = require("dto/common/search/PermIdSearchCriteria");
 			return this.addCriteria(new PermIdSearchCriteria());
 		};
 		prototype.createBuilder = function() {
-			var AbstractCompositeSearchCriteria = require("dto/search/AbstractCompositeSearchCriteria");
+			var AbstractCompositeSearchCriteria = require("dto/common/search/AbstractCompositeSearchCriteria");
 			var builder = AbstractCompositeSearchCriteria.prototype.createBuilder.call(this);
 			builder.setName("SPACE");
 			return builder;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/SpaceUpdate.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/update/SpaceUpdate.js
similarity index 80%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/SpaceUpdate.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/update/SpaceUpdate.js
index 23aee800b7e..23dd379bca0 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/space/SpaceUpdate.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/space/update/SpaceUpdate.js
@@ -1,12 +1,12 @@
 /**
  * @author pkupczyk
  */
-define([ "stjs", "dto/entity/FieldUpdateValue" ], function(stjs, FieldUpdateValue) {
+define([ "stjs", "dto/common/update/FieldUpdateValue" ], function(stjs, FieldUpdateValue) {
 	var SpaceUpdate = function() {
 		this.description = new FieldUpdateValue();
 	};
 	stjs.extend(SpaceUpdate, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.space.SpaceUpdate';
+		prototype['@type'] = 'dto.space.update.SpaceUpdate';
 		constructor.serialVersionUID = 1;
 		prototype.spaceId = null;
 		prototype.getSpaceId = function() {
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/tag/Tag.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/Tag.js
similarity index 97%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/tag/Tag.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/Tag.js
index 461a0da6861..467658c1150 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/tag/Tag.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/Tag.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Tag = function() {
 	};
 	stjs.extend(Tag, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.tag.Tag';
+		prototype['@type'] = 'dto.tag.Tag';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.permId = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/tag/TagFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/fetchoptions/TagFetchOptions.js
similarity index 71%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/tag/TagFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/fetchoptions/TagFetchOptions.js
index b2c95a96060..5c638260e7a 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/tag/TagFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/fetchoptions/TagFetchOptions.js
@@ -2,17 +2,17 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/person/PersonFetchOptions", "dto/fetchoptions/tag/TagSortOptions" ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/person/fetchoptions/PersonFetchOptions", "dto/tag/fetchoptions/TagSortOptions" ], function(require, stjs, FetchOptions) {
 	var TagFetchOptions = function() {
 	};
 	stjs.extend(TagFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.tag.TagFetchOptions';
+		prototype['@type'] = 'dto.tag.fetchoptions.TagFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.owner = null;
 		prototype.sort = null;
 		prototype.withOwner = function() {
 			if (this.owner == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.owner = new PersonFetchOptions();
 			}
 			return this.owner;
@@ -25,7 +25,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/p
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var TagSortOptions = require("dto/fetchoptions/tag/TagSortOptions");
+				var TagSortOptions = require("dto/tag/fetchoptions/TagSortOptions");
 				this.sort = new TagSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/tag/TagSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/fetchoptions/TagSortOptions.js
similarity index 57%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/tag/TagSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/fetchoptions/TagSortOptions.js
index ddc67860325..eff26932446 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/tag/TagSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/fetchoptions/TagSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var TagSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(TagSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.tag.TagSortOptions';
+		prototype['@type'] = 'dto.tag.fetchoptions.TagSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return TagSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/ITagId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/ITagId.js
new file mode 100644
index 00000000000..0e329cad625
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/ITagId.js
@@ -0,0 +1,9 @@
+/**
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var ITagId = function() {
+	};
+	stjs.extend(ITagId, null, [ IObjectId ], null, {});
+	return ITagId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagCode.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagCode.js
new file mode 100644
index 00000000000..64e38227bd1
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagCode.js
@@ -0,0 +1,49 @@
+/**
+ * Tag code.
+ * 
+ * @author Franz-Josef Elmer
+ * @author Jakub Straszewski
+ */
+define([ "stjs", "util/Exceptions", "dto/tag/id/ITagId" ], function(stjs, exceptions, ITagId) {
+	/**
+	 * @param code
+	 *            Tag code, e.g. "MY_TAG".
+	 */
+	var TagCode = function(code) {
+		this.setCode(code);
+	};
+	stjs.extend(TagCode, null, [ ITagId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.tag.id.TagCode';
+		constructor.serialVersionUID = 1;
+		prototype.code = null;
+		prototype.getCode = function() {
+			return this.code;
+		};
+		prototype.setCode = function(code) {
+			if (code == null) {
+				throw new exceptions.IllegalArgumentException("Code cannot be null");
+			}
+			this.code = code;
+		};
+		prototype.toString = function() {
+			return this.getCode();
+		};
+		prototype.hashCode = function() {
+			return ((this.getCode() == null) ? 0 : this.getCode().hashCode());
+		};
+		prototype.equals = function(obj) {
+			if (this == obj) {
+				return true;
+			}
+			if (obj == null) {
+				return false;
+			}
+			if (this.getClass() != obj.getClass()) {
+				return false;
+			}
+			var other = obj;
+			return this.getCode() == null ? this.getCode() == other.getCode() : this.getCode().equals(other.getCode());
+		};
+	}, {});
+	return TagCode;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagPermId.js
new file mode 100644
index 00000000000..e0baaab4513
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/id/TagPermId.js
@@ -0,0 +1,19 @@
+/**
+ * Tag perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/tag/id/ITagId" ], function(stjs, ObjectPermId, ITagId) {
+	/**
+	 * @param permId
+	 *            Tag perm id, e.g. "/MY_USER/MY_TAG".
+	 */
+	var TagPermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(TagPermId, ObjectPermId, [ ObjectPermId, ITagId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.tag.id.TagPermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return TagPermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TagSearchCriteria.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/search/TagSearchCriteria.js
similarity index 56%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TagSearchCriteria.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/search/TagSearchCriteria.js
index 5fe0fd491db..4af846dc4b7 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/search/TagSearchCriteria.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/tag/search/TagSearchCriteria.js
@@ -1,25 +1,24 @@
 /**
  * @author pkupczyk
  */
-define([ "require", "stjs", "dto/search/AbstractObjectSearchCriteria", 
-         "dto/search/CodeSearchCriteria", "dto/search/PermIdSearchCriteria", "dto/search/AbstractCompositeSearchCriteria"], 
-		function(require, stjs, AbstractObjectSearchCriteria) {
+define([ "require", "stjs", "dto/common/search/AbstractObjectSearchCriteria", "dto/common/search/CodeSearchCriteria", "dto/common/search/PermIdSearchCriteria",
+		"dto/common/search/AbstractCompositeSearchCriteria" ], function(require, stjs, AbstractObjectSearchCriteria) {
 	var TagSearchCriteria = function() {
 		AbstractObjectSearchCriteria.call(this);
 	};
 	stjs.extend(TagSearchCriteria, AbstractObjectSearchCriteria, [ AbstractObjectSearchCriteria ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.search.TagSearchCriteria';
+		prototype['@type'] = 'dto.tag.search.TagSearchCriteria';
 		constructor.serialVersionUID = 1;
 		prototype.withCode = function() {
-			var CodeSearchCriteria = require("dto/search/CodeSearchCriteria");
+			var CodeSearchCriteria = require("dto/common/search/CodeSearchCriteria");
 			return this.addCriteria(new CodeSearchCriteria());
 		};
 		prototype.withPermId = function() {
-			var PermIdSearchCriteria = require("dto/search/PermIdSearchCriteria");
+			var PermIdSearchCriteria = require("dto/common/search/PermIdSearchCriteria");
 			return this.addCriteria(new PermIdSearchCriteria());
 		};
 		prototype.createBuilder = function() {
-			var AbstractCompositeSearchCriteria = require("dto/search/AbstractCompositeSearchCriteria");
+			var AbstractCompositeSearchCriteria = require("dto/common/search/AbstractCompositeSearchCriteria");
 			var builder = AbstractCompositeSearchCriteria.prototype.createBuilder.call(this);
 			builder.setName("TAG");
 			return builder;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/vocabulary/Vocabulary.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/Vocabulary.js
similarity index 96%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/vocabulary/Vocabulary.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/Vocabulary.js
index 69fc6a1f039..f6c556dc8a6 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/vocabulary/Vocabulary.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/Vocabulary.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var Vocabulary = function() {
 	};
 	stjs.extend(Vocabulary, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.vocabulary.Vocabulary';
+		prototype['@type'] = 'dto.vocabulary.Vocabulary';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.code = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/vocabulary/VocabularyTerm.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/VocabularyTerm.js
similarity index 97%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/vocabulary/VocabularyTerm.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/VocabularyTerm.js
index 4fa4b1a27ca..95bad10bdc9 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/entity/vocabulary/VocabularyTerm.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/VocabularyTerm.js
@@ -6,7 +6,7 @@ define([ "stjs", "util/Exceptions" ], function(stjs, exceptions) {
 	var VocabularyTerm = function() {
 	};
 	stjs.extend(VocabularyTerm, null, [], function(constructor, prototype) {
-		prototype['@type'] = 'dto.entity.vocabulary.VocabularyTerm';
+		prototype['@type'] = 'dto.vocabulary.VocabularyTerm';
 		constructor.serialVersionUID = 1;
 		prototype.fetchOptions = null;
 		prototype.code = null;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyFetchOptions.js
new file mode 100644
index 00000000000..dfaeaffdb81
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyFetchOptions.js
@@ -0,0 +1,42 @@
+/**
+ * Class automatically generated with
+ * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
+ */
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/person/fetchoptions/PersonFetchOptions", "dto/vocabulary/fetchoptions/VocabularySortOptions" ], function(require, stjs,
+		FetchOptions) {
+	var VocabularyFetchOptions = function() {
+	};
+	stjs.extend(VocabularyFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.vocabulary.fetchoptions.VocabularyFetchOptions';
+		constructor.serialVersionUID = 1;
+		prototype.registrator = null;
+		prototype.sort = null;
+		prototype.withRegistrator = function() {
+			if (this.registrator == null) {
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
+				this.registrator = new PersonFetchOptions();
+			}
+			return this.registrator;
+		};
+		prototype.withRegistratorUsing = function(fetchOptions) {
+			return this.registrator = fetchOptions;
+		};
+		prototype.hasRegistrator = function() {
+			return this.registrator != null;
+		};
+		prototype.sortBy = function() {
+			if (this.sort == null) {
+				var VocabularySortOptions = require("dto/vocabulary/fetchoptions/VocabularySortOptions");
+				this.sort = new VocabularySortOptions();
+			}
+			return this.sort;
+		};
+		prototype.getSortBy = function() {
+			return this.sort;
+		};
+	}, {
+		registrator : "PersonFetchOptions",
+		sort : "VocabularySortOptions"
+	});
+	return VocabularyFetchOptions;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularySortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularySortOptions.js
similarity index 60%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularySortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularySortOptions.js
index 059312d05f1..a70033caedf 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularySortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularySortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var VocabularySortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(VocabularySortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.vocabulary.VocabularySortOptions';
+		prototype['@type'] = 'dto.vocabulary.fetchoptions.VocabularySortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return VocabularySortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyTermFetchOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyTermFetchOptions.js
similarity index 73%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyTermFetchOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyTermFetchOptions.js
index da31f143fe9..cc22507334c 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyTermFetchOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyTermFetchOptions.js
@@ -2,19 +2,19 @@
  * Class automatically generated with
  * {@link ch.ethz.sis.openbis.generic.shared.api.v3.dto.generators.DtoGenerator}
  */
-define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/vocabulary/VocabularyFetchOptions", "dto/fetchoptions/person/PersonFetchOptions",
-		"dto/fetchoptions/vocabulary/VocabularyTermSortOptions" ], function(require, stjs, FetchOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/FetchOptions", "dto/vocabulary/fetchoptions/VocabularyFetchOptions", "dto/person/fetchoptions/PersonFetchOptions",
+		"dto/vocabulary/fetchoptions/VocabularyTermSortOptions" ], function(require, stjs, FetchOptions) {
 	var VocabularyTermFetchOptions = function() {
 	};
 	stjs.extend(VocabularyTermFetchOptions, FetchOptions, [ FetchOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.vocabulary.VocabularyTermFetchOptions';
+		prototype['@type'] = 'dto.vocabulary.fetchoptions.VocabularyTermFetchOptions';
 		constructor.serialVersionUID = 1;
 		prototype.vocabulary = null;
 		prototype.registrator = null;
 		prototype.sort = null;
 		prototype.withVocabulary = function() {
 			if (this.vocabulary == null) {
-				var VocabularyFetchOptions = require("dto/fetchoptions/vocabulary/VocabularyFetchOptions");
+				var VocabularyFetchOptions = require("dto/vocabulary/fetchoptions/VocabularyFetchOptions");
 				this.vocabulary = new VocabularyFetchOptions();
 			}
 			return this.vocabulary;
@@ -27,7 +27,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/v
 		};
 		prototype.withRegistrator = function() {
 			if (this.registrator == null) {
-				var PersonFetchOptions = require("dto/fetchoptions/person/PersonFetchOptions");
+				var PersonFetchOptions = require("dto/person/fetchoptions/PersonFetchOptions");
 				this.registrator = new PersonFetchOptions();
 			}
 			return this.registrator;
@@ -40,7 +40,7 @@ define([ "require", "stjs", "dto/fetchoptions/FetchOptions", "dto/fetchoptions/v
 		};
 		prototype.sortBy = function() {
 			if (this.sort == null) {
-				var VocabularyTermSortOptions = require("dto/fetchoptions/vocabulary/VocabularyTermSortOptions");
+				var VocabularyTermSortOptions = require("dto/vocabulary/fetchoptions/VocabularyTermSortOptions");
 				this.sort = new VocabularyTermSortOptions();
 			}
 			return this.sort;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyTermSortOptions.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyTermSortOptions.js
similarity index 61%
rename from openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyTermSortOptions.js
rename to openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyTermSortOptions.js
index ce90b998583..1e308de506d 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/fetchoptions/vocabulary/VocabularyTermSortOptions.js
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/fetchoptions/VocabularyTermSortOptions.js
@@ -1,9 +1,9 @@
-define([ "require", "stjs", "dto/fetchoptions/sort/SortOptions" ], function(require, stjs, SortOptions) {
+define([ "require", "stjs", "dto/common/fetchoptions/SortOptions" ], function(require, stjs, SortOptions) {
 	var VocabularyTermSortOptions = function() {
 		SortOptions.call(this);
 	};
 	stjs.extend(VocabularyTermSortOptions, SortOptions, [ SortOptions ], function(constructor, prototype) {
-		prototype['@type'] = 'dto.fetchoptions.vocabulary.VocabularyTermSortOptions';
+		prototype['@type'] = 'dto.vocabulary.fetchoptions.VocabularyTermSortOptions';
 		constructor.serialVersionUID = 1;
 	}, {});
 	return VocabularyTermSortOptions;
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyId.js
new file mode 100644
index 00000000000..6f19069dc3d
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyId.js
@@ -0,0 +1,9 @@
+/**
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IVocabularyId = function() {
+	};
+	stjs.extend(IVocabularyId, null, [ IObjectId ], null, {});
+	return IVocabularyId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyTermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyTermId.js
new file mode 100644
index 00000000000..cf20c0356c4
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/IVocabularyTermId.js
@@ -0,0 +1,9 @@
+/**
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/IObjectId" ], function(stjs, IObjectId) {
+	var IVocabularyTermId = function() {
+	};
+	stjs.extend(IVocabularyTermId, null, [ IObjectId ], null, {});
+	return IVocabularyTermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyPermId.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyPermId.js
new file mode 100644
index 00000000000..9f985af7505
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyPermId.js
@@ -0,0 +1,19 @@
+/**
+ * Vocabulary perm id.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "dto/common/id/ObjectPermId", "dto/vocabulary/id/IVocabularyId" ], function(stjs, ObjectPermId, IVocabularyId) {
+	/**
+	 * @param permId
+	 *            Vocabulary perm id, e.g. "MY_VOCABULARY".
+	 */
+	var VocabularyPermId = function(permId) {
+		ObjectPermId.call(this, permId);
+	};
+	stjs.extend(VocabularyPermId, ObjectPermId, [ ObjectPermId, IVocabularyId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.vocabulary.id.VocabularyPermId';
+		constructor.serialVersionUID = 1;
+	}, {});
+	return VocabularyPermId;
+})
\ No newline at end of file
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyTermCode.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyTermCode.js
new file mode 100644
index 00000000000..a57af182608
--- /dev/null
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/resources/api/v3/dto/vocabulary/id/VocabularyTermCode.js
@@ -0,0 +1,48 @@
+/**
+ * Vocabulary term code.
+ * 
+ * @author pkupczyk
+ */
+define([ "stjs", "util/Exceptions", "dto/vocabulary/id/IVocabularyTermId" ], function(stjs, exceptions, IVocabularyTermId) {
+	/**
+	 * @param code
+	 *            Vocabulary term code, e.g. "MY_TERM".
+	 */
+	var VocabularyTermCode = function(code) {
+		this.setCode(code);
+	};
+	stjs.extend(VocabularyTermCode, null, [ IVocabularyTermId ], function(constructor, prototype) {
+		prototype['@type'] = 'dto.vocabulary.id.VocabularyTermCode';
+		constructor.serialVersionUID = 1;
+		prototype.code = null;
+		prototype.getCode = function() {
+			return this.code;
+		};
+		prototype.setCode = function(code) {
+			if (code == null) {
+				throw new exceptions.IllegalArgumentException("Code cannot be null");
+			}
+			this.code = code;
+		};
+		prototype.toString = function() {
+			return this.getCode();
+		};
+		prototype.hashCode = function() {
+			return ((this.getCode() == null) ? 0 : this.getCode().hashCode());
+		};
+		prototype.equals = function(obj) {
+			if (this == obj) {
+				return true;
+			}
+			if (obj == null) {
+				return false;
+			}
+			if (this.getClass() != obj.getClass()) {
+				return false;
+			}
+			var other = obj;
+			return this.getCode() == null ? this.getCode() == other.getCode() : this.getCode().equals(other.getCode());
+		};
+	}, {});
+	return VocabularyTermCode;
+})
\ No newline at end of file
-- 
GitLab