Package com.arangodb.model
Class DocumentImportOptions
java.lang.Object
com.arangodb.model.DocumentImportOptions
- Author:
- Mark Vollmary
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfromPrefix
(String fromPrefix) onDuplicate
(DocumentImportOptions.OnDuplicate onDuplicate) waitForSync
(Boolean waitForSync)
-
Constructor Details
-
DocumentImportOptions
public DocumentImportOptions()
-
-
Method Details
-
getFromPrefix
-
fromPrefix
- Parameters:
fromPrefix
- An optional prefix for the values in _from attributes. If specified, the value is automatically prepended to each _from input value. This allows specifying just the keys for _from.- Returns:
- options
-
getToPrefix
-
toPrefix
- Parameters:
toPrefix
- An optional prefix for the values in _to attributes. If specified, the value is automatically prepended to each _to input value. This allows specifying just the keys for _to.- Returns:
- options
-
getOverwrite
-
overwrite
- Parameters:
overwrite
- If this parameter has a value of true, then all data in the collection will be removed prior to the import. Note that any existing index definitions will be preserved.- Returns:
- options
-
getWaitForSync
-
waitForSync
- Parameters:
waitForSync
- Wait until documents have been synced to disk before returning.- Returns:
- options
-
getOnDuplicate
-
onDuplicate
- Parameters:
onDuplicate
- Controls what action is carried out in case of a unique key constraint violation. Possible values are:- error: this will not import the current document because of the unique key constraint violation. This is the default setting.
- update: this will update an existing document in the database with the data specified in the request. Attributes of the existing document that are not present in the request will be preserved.
- replace: this will replace an existing document in the database with the data specified in the request.
- ignore: this will not update an existing document and simply ignore the error caused by the unique key constraint violation. Note that update, replace and ignore will only work when the import document in the request contains the _key attribute. update and replace may also fail because of secondary unique key constraint violations.
- Returns:
- options
-
getComplete
-
complete
- Parameters:
complete
- If set to true, it will make the whole import fail if any error occurs. Otherwise the import will continue even if some documents cannot be imported.- Returns:
- options
-
getDetails
-
details
- Parameters:
details
- If set to true, the result will include an attribute details with details about documents that could not be imported.- Returns:
- options
-