ArangoDBClient class
- Available extensions
- Annotations
-
- @Deprecated('Use DbClient instead of this class. Unlike this class, DbClient throws errors for unsucessful operations instead of returning a result property.')
Constructors
- ArangoDBClient.new({String scheme = 'http', String host = 'localhost', int port = 8529, String db = '_system', required String user, required String pass, String realm = '', SecurityContext? securityContext})
- ArangoDBClient.fromConnectionString(String connectionString, {SecurityContext? securityContext})
-
factory
Properties
- credentials ↔ HttpClientBasicCredentials
-
getter/setter pair
- db → String
-
final
- dbUrl ↔ Uri
-
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- host → String
-
final
- httpClient ↔ HttpClient
-
getter/setter pair
- pass → String
-
final
- port → int
-
final
- realm → String
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scheme → String
-
final
- securityContext → SecurityContext?
-
final
- user → String
-
final
Methods
-
abortTransaction(
Transaction transaction) → Future< TransactionResponse> - Aborts a transaction https://www.arangodb.com/docs/stable/http/transaction-stream-transaction.html#abort-transaction
-
allCollections(
) → Future< ResultResponse< List< >CollectionInfo> > - Reads all collections https://www.arangodb.com/docs/3.4/http/collection-getting.html#reads-all-collections
-
beginTransaction(
TransactionOptions options) → Future< TransactionResponse> - Begins a transaction https://www.arangodb.com/docs/stable/http/transaction-stream-transaction.html#begin-a-transaction
-
collectionChecksum(
String collectionName) → Future< CollectionResponse> - Returns checksum for the collection https://www.arangodb.com/docs/3.4/http/collection-getting.html#return-checksum-for-the-collection
-
collectionInfo(
String name) → Future< CollectionResponse> - Gets id, name, status of collection https://www.arangodb.com/docs/3.4/http/collection-getting.html#return-information-about-a-collection
-
collectionProperties(
String name) → Future< CollectionPropertiesResponse> - Get collection properties See https://www.arangodb.com/docs/3.4/http/collection-getting.html#read-properties-of-a-collection for details
-
collectionRevisionId(
String collectionName) → Future< CollectionPropertiesResponse> - Returns collection revision id https://www.arangodb.com/docs/3.4/http/collection-getting.html#return-collection-revision-id
-
collectionStatistics(
String collectionName) → Future< CollectionPropertiesResponse> - Returns statistics for a collection https://www.arangodb.com/docs/3.4/http/collection-getting.html#return-statistics-for-a-collection
-
commitTransaction(
Transaction transaction) → Future< TransactionResponse> - Commits a transaction https://www.arangodb.com/docs/stable/http/transaction-stream-transaction.html#commit-transaction
-
createCollection(
CollectionCriteria criteria) → Future< CollectionPropertiesResponse> - Creates a collection See https://www.arangodb.com/docs/3.4/http/collection-creating.html for details.
-
createDatabase(
CreateDatabaseInfo databaseInfo) → Future< ResultResponse< bool> > - Creates a database. The data with these properties is required:
-
createDocument(
String collectionName, Map< String, dynamic> data, {Transaction? transaction}) → Future<OperationResult> - Creates document https://www.arangodb.com/docs/3.4/http/document-working-with-documents.html#create-document
-
createDocuments(
String collectionName, List< Map< data, {Transaction? transaction}) → Future<String, dynamic> >List< OperationResult> > -
createPersistentIndex(
IndexCriteria criteria) → Future< IndexResponse> - Creates an index See https://www.arangodb.com/docs/devel/http/indexes-working-with.html for details.
-
currentDatabase(
) → Future< ResultResponse< DbInfoResult> > - Retrieves information about the current database https://www.arangodb.com/docs/devel/http/database-database-management.html#information-of-the-database
-
documentsCount(
String collectionName, {Transaction? transaction}) → Future< CollectionPropertiesResponse> - Returns number of documents in a collection https://www.arangodb.com/docs/3.4/http/collection-getting.html#return-number-of-documents-in-a-collection
-
dropCollection(
String name, {bool isSystem = false}) → Future< IdResponse> - Drops a collection https://www.arangodb.com/docs/stable/http/collection-creating.html#drops-a-collection
-
dropDatabase(
String name) → Future< ResultResponse< bool> > - Drops the database along with all data stored in it. https://www.arangodb.com/docs/devel/http/database-database-management.html#drop-database
-
existingDatabases(
) → Future< ResultResponse< List< >String> > - Retrieves the list of all existing databases (availabe or not) https://www.arangodb.com/docs/devel/http/database-database-management.html#list-of-databases
-
getDocumentByKey(
String collection, String documentKey, {String? ifNoneMatchRevision, String? ifMatchRevision, Transaction? transaction}) → Future< DocumentResponse> - Reads a single document https://www.arangodb.com/docs/3.4/http/document-working-with-documents.html#read-document
-
getTransaction(
String id) → Future< TransactionResponse> - Gets a transaction status https://www.arangodb.com/docs/stable/http/transaction-stream-transaction.html#get-transaction-status
-
newQuery(
) → QueryWithClient -
Available on ArangoDBClient, provided by the ArangoClientQuery extension
Creates new QueryWithClient (with saved link to client) object for continue to constructing it later. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
queryToList(
Map< String, Object> data, {Transaction? transaction}) → Future<List< Map< >String, dynamic> > - Makes query to ArangoDB batabase, collect results in memory and return as List. If result has error - throws error.
-
queryToStream(
Map< String, Object> data, {Transaction? transaction}) → Stream<Map< String, dynamic> > -
removeDocument(
String collectionName, String documentKey, {String? ifMatchRevision, Map< String, dynamic> queryParams = const {}, Transaction? transaction}) → Future<OperationResult> - Removes a document https://www.arangodb.com/docs/3.4/http/document-working-with-documents.html#removes-a-document
-
removeDocuments(
String collectionName, List< Map< data, {Map<String, dynamic> >String, dynamic> queryParams = const {}, Transaction? transaction}) → Future<List< OperationResult> > - td: Removes multiple documents https://www.arangodb.com/docs/3.4/http/document-working-with-documents.html#removes-multiple-documents
-
replaceDocument(
String collectionName, String documentKey, Map< String, dynamic> data, {String? ifMatchRevision, Map<String, dynamic> queryParams = const {}, Transaction? transaction}) → Future<OperationResult> - Replaces document https://www.arangodb.com/docs/3.4/http/document-working-with-documents.html#replace-document
-
replaceDocuments(
String collectionName, List< Map< data, {Map<String, dynamic> >String, dynamic> queryParams = const {}, Transaction? transaction}) → Future<List< OperationResult> > - Replaces multiple documents https://www.arangodb.com/docs/3.4/http/document-working-with-documents.html#replace-documents
-
toString(
) → String -
A string representation of this object.
inherited
-
transactions(
) → Future< List< Transaction> > - Gets currently running transactions https://www.arangodb.com/docs/stable/http/transaction-stream-transaction.html#list-currently-ongoing-transactions
-
truncateCollection(
String name, {Transaction? transaction}) → Future< CollectionResponse> - Truncates a collection
-
updateDocument(
String collectionName, String documentKey, Map< String, dynamic> data, {String? ifMatchRevision, Map<String, dynamic> queryParams = const {}, Transaction? transaction}) → Future<OperationResult> - Updates a document https://www.arangodb.com/docs/3.4/http/document-working-with-documents.html#update-document
-
userDatabases(
) → Future< ResultResponse< List< >String> > - List of accessible databases for current user https://www.arangodb.com/docs/devel/http/database-database-management.html#list-of-accessible-databases
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited