Skip to content

Commit e466421

Browse files
authored
[DE-220] removed deprecated ArangoSearch client API (#443)
* removed deprecated ArangoSearch client API * removed deprecated entities methods * removed deprecated ArangoCursor methods * removed deprecated DocumentField annotations * removed deprecated methods handling db names as strings * removed deprecated serialization customization methods
1 parent 9c6ff4d commit e466421

32 files changed

+25
-2397
lines changed

src/main/java/com/arangodb/ArangoDB.java

Lines changed: 5 additions & 359 deletions
Large diffs are not rendered by default.

src/main/java/com/arangodb/ArangoDatabase.java

Lines changed: 0 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
package com.arangodb;
2222

2323
import com.arangodb.entity.*;
24-
import com.arangodb.entity.arangosearch.AnalyzerEntity;
2524
import com.arangodb.entity.arangosearch.analyzer.SearchAnalyzer;
2625
import com.arangodb.model.*;
2726
import com.arangodb.model.arangosearch.AnalyzerDeleteOptions;
@@ -48,17 +47,6 @@ public interface ArangoDatabase extends ArangoSerializationAccessor {
4847
*/
4948
ArangoDB arango();
5049

51-
/**
52-
* Returns the name of the database
53-
*
54-
* @return database name
55-
* @deprecated Use {@link #dbName()} instead
56-
*/
57-
@Deprecated
58-
default String name() {
59-
return dbName().get();
60-
}
61-
6250
/**
6351
* Returns the name of the database
6452
*
@@ -719,19 +707,6 @@ GraphEntity createGraph(String name, Collection<EdgeDefinition> edgeDefinitions,
719707
*/
720708
ViewEntity createArangoSearch(String name, ArangoSearchCreateOptions options) throws ArangoDBException;
721709

722-
/**
723-
* Creates an Analyzer
724-
*
725-
* @param options AnalyzerEntity
726-
* @return the created Analyzer
727-
* @throws ArangoDBException
728-
* @see <a href="https://www.arangodb.com/docs/stable/http/analyzers.html">API Documentation</a>
729-
* @since ArangoDB 3.5.0
730-
* @deprecated use {@link this#createSearchAnalyzer(SearchAnalyzer)}}
731-
*/
732-
@Deprecated
733-
AnalyzerEntity createAnalyzer(AnalyzerEntity options) throws ArangoDBException;
734-
735710
/**
736711
* Creates an Analyzer
737712
*
@@ -743,19 +718,6 @@ GraphEntity createGraph(String name, Collection<EdgeDefinition> edgeDefinitions,
743718
*/
744719
SearchAnalyzer createSearchAnalyzer(SearchAnalyzer analyzer) throws ArangoDBException;
745720

746-
/**
747-
* Gets information about an Analyzer
748-
*
749-
* @param name of the Analyzer without database prefix
750-
* @return information about an Analyzer
751-
* @throws ArangoDBException
752-
* @see <a href="https://www.arangodb.com/docs/stable/http/analyzers.html">API Documentation</a>
753-
* @since ArangoDB 3.5.0
754-
* @deprecated use {@link this#getSearchAnalyzer(String)}}
755-
*/
756-
@Deprecated
757-
AnalyzerEntity getAnalyzer(String name) throws ArangoDBException;
758-
759721
/**
760722
* Gets information about an Analyzer
761723
*
@@ -767,18 +729,6 @@ GraphEntity createGraph(String name, Collection<EdgeDefinition> edgeDefinitions,
767729
*/
768730
SearchAnalyzer getSearchAnalyzer(String name) throws ArangoDBException;
769731

770-
/**
771-
* Retrieves all analyzers definitions.
772-
*
773-
* @return collection of all analyzers definitions
774-
* @throws ArangoDBException
775-
* @see <a href="https://www.arangodb.com/docs/stable/http/analyzers.html">API Documentation</a>
776-
* @since ArangoDB 3.5.0
777-
* @deprecated use {@link this#getSearchAnalyzers()}
778-
*/
779-
@Deprecated
780-
Collection<AnalyzerEntity> getAnalyzers() throws ArangoDBException;
781-
782732
/**
783733
* Retrieves all analyzers definitions.
784734
*
@@ -789,31 +739,6 @@ GraphEntity createGraph(String name, Collection<EdgeDefinition> edgeDefinitions,
789739
*/
790740
Collection<SearchAnalyzer> getSearchAnalyzers() throws ArangoDBException;
791741

792-
/**
793-
* Deletes an Analyzer
794-
*
795-
* @param name of the Analyzer without database prefix
796-
* @throws ArangoDBException
797-
* @see <a href="https://www.arangodb.com/docs/stable/http/analyzers.html">API Documentation</a>
798-
* @since ArangoDB 3.5.0
799-
* @deprecated use {@link this#deleteSearchAnalyzer(String)}}}
800-
*/
801-
@Deprecated
802-
void deleteAnalyzer(String name) throws ArangoDBException;
803-
804-
/**
805-
* Deletes an Analyzer
806-
*
807-
* @param name of the Analyzer without database prefix
808-
* @param options AnalyzerDeleteOptions
809-
* @throws ArangoDBException
810-
* @see <a href="https://www.arangodb.com/docs/stable/http/analyzers.html">API Documentation</a>
811-
* @since ArangoDB 3.5.0
812-
* @deprecated use {@link this#deleteSearchAnalyzer(String, AnalyzerDeleteOptions)}}}
813-
*/
814-
@Deprecated
815-
void deleteAnalyzer(String name, AnalyzerDeleteOptions options) throws ArangoDBException;
816-
817742
/**
818743
* Deletes an Analyzer
819744
*

src/main/java/com/arangodb/ArangoIterable.java

Lines changed: 0 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020

2121
package com.arangodb;
2222

23-
import java.util.Collection;
2423
import java.util.stream.Stream;
2524

2625
/**
@@ -33,101 +32,4 @@ public interface ArangoIterable<T> extends Iterable<T> {
3332

3433
Stream<T> stream();
3534

36-
/**
37-
* Performs the given action for each element of the {@code ArangoIterable}
38-
*
39-
* @param action
40-
* a action to perform on the elements
41-
* @deprecated Use {@link #forEach(java.util.function.Consumer)} instead.
42-
*/
43-
@Deprecated
44-
void foreach(Consumer<? super T> action);
45-
46-
/**
47-
* Returns a {@code ArangoIterable} consisting of the results of applying the given function to the elements of this
48-
* {@code ArangoIterable}.
49-
*
50-
* @param mapper
51-
* a function to apply to each element
52-
* @return the new {@code ArangoIterable}
53-
*
54-
* @deprecated Use {@link #stream()} and {@link Stream#map(java.util.function.Function)} instead.
55-
*/
56-
@Deprecated
57-
<R> ArangoIterable<R> map(Function<? super T, ? extends R> mapper);
58-
59-
/**
60-
* Returns a {@code ArangoIterable} consisting of the elements of this {@code ArangoIterable} that match the given
61-
* predicate.
62-
*
63-
* @param predicate
64-
* a predicate to apply to each element to determine if it should be included
65-
* @return the new {@code ArangoIterable}
66-
*
67-
* @deprecated Use {@link #stream()} and {@link Stream#filter(java.util.function.Predicate)} instead.
68-
*/
69-
@Deprecated
70-
ArangoIterable<T> filter(Predicate<? super T> predicate);
71-
72-
/**
73-
* Returns the first element or {@code null} if no element exists.
74-
*
75-
* @return first element or {@code null}
76-
* @deprecated Use {@link #stream()} and {@link Stream#findFirst()} instead.
77-
*/
78-
@Deprecated
79-
T first();
80-
81-
/**
82-
* Returns the count of elements of this {@code ArangoIterable}.
83-
*
84-
* @return the count of elements
85-
* @deprecated Use {@link #stream()} and {@link Stream#count()} instead.
86-
*/
87-
@Deprecated
88-
long count();
89-
90-
/**
91-
* Returns whether any elements of this {@code ArangoIterable} match the provided predicate.
92-
*
93-
* @param predicate a predicate to apply to elements of this {@code ArangoIterable}
94-
* @return {@code true} if any elements of the {@code ArangoIterable} match the provided predicate, otherwise
95-
* {@code false}
96-
* @deprecated Use {@link #stream()} and {@link Stream#anyMatch(java.util.function.Predicate)} instead.
97-
*/
98-
@Deprecated
99-
boolean anyMatch(Predicate<? super T> predicate);
100-
101-
/**
102-
* Returns whether all elements of this {@code ArangoIterable} match the provided predicate.
103-
*
104-
* @param predicate a predicate to apply to elements of this {@code ArangoIterable}
105-
* @return {@code true} if all elements of the {@code ArangoIterable} match the provided predicate, otherwise
106-
* {@code false}
107-
* @deprecated Use {@link #stream()} and {@link Stream#allMatch(java.util.function.Predicate)} instead.
108-
*/
109-
@Deprecated
110-
boolean allMatch(Predicate<? super T> predicate);
111-
112-
/**
113-
* Returns whether no elements of this {@code ArangoIterable} match the provided predicate.
114-
*
115-
* @param predicate a predicate to apply to elements of this {@code ArangoIterable}
116-
* @return {@code true} if no elements of the {@code ArangoIterable} match the provided predicate, otherwise
117-
* {@code false}
118-
* @deprecated Use {@link #stream()} and {@link Stream#noneMatch(java.util.function.Predicate)} instead.
119-
*/
120-
@Deprecated
121-
boolean noneMatch(Predicate<? super T> predicate);
122-
123-
/**
124-
* Iterates over all elements of this {@code ArangoIterable} and adds each to the given target.
125-
*
126-
* @param target the collection to insert into
127-
* @return the filled target
128-
* @deprecated Use {@link #stream()} and {@link Stream#collect} instead.
129-
*/
130-
@Deprecated
131-
<R extends Collection<? super T>> R collectInto(R target);
132-
13335
}

src/main/java/com/arangodb/Consumer.java

Lines changed: 0 additions & 38 deletions
This file was deleted.

src/main/java/com/arangodb/Predicate.java

Lines changed: 0 additions & 39 deletions
This file was deleted.

0 commit comments

Comments
 (0)