E - the element typeID - the ID type of the element typepublic abstract class PgxCollection<E extends PgxEntity<ID>,ID> extends PgxManagedObject implements java.lang.Iterable<E>
| Modifier and Type | Method and Description |
|---|---|
void |
add(E entity)
Adds one element to this collection.
|
void |
addAll(java.util.Collection<E> source)
Blocking version of
addAllAsync(Collection). |
void |
addAll(E[] elements)
Blocking version of
addAllAsync(PgxEntity[]). |
abstract void |
addAll(ID... ids) |
PgxFuture<java.lang.Void> |
addAllAsync(java.util.Collection<E> source)
Add vertices/edges to an existing vertex/edge collection
|
PgxFuture<java.lang.Void> |
addAllAsync(E[] elements)
Add vertices/edges to an existing vertex/edge collection
|
void |
clear()
Blocking version of
clearAsync(). |
PgxFuture<java.lang.Void> |
clearAsync()
Clear an existing vertex/edge collection
|
PgxCollection<E,ID> |
clone() |
PgxCollection<E,ID> |
clone(java.lang.String newName) |
PgxFuture<PgxCollection<E,ID>> |
cloneAsync()
Convenience method around
cloneAsync(String) passing name as nullClone an existing vertex/edge collection. |
PgxFuture<PgxCollection<E,ID>> |
cloneAsync(java.lang.String newName)
Clone an existing vertex/edge collection.
|
CollectionType |
getCollectionType()
Gets the collection type.
|
EntityType |
getElementType()
Gets the element type.
|
PgxGraph |
getGraph()
Gets the graph.
|
abstract IdType |
getIdType()
Gets the ID type of the element type.
|
java.lang.String |
getName() |
java.util.Iterator<E> |
iterator()
Blocking version of
iteratorAsync(). |
PgxFuture<java.util.Iterator<E>> |
iteratorAsync()
Gets an Iterator over the collection.
|
void |
removeAll(java.util.Collection<E> source)
Blocking version of
removeAllAsync(Collection). |
abstract void |
removeAll(ID... ids) |
PgxFuture<java.lang.Void> |
removeAllAsync(java.util.Collection<E> source)
Remove vertices/edges from an existing vertex/edge collection
|
int |
size()
Blocking version of
sizeAsync(). |
PgxFuture<java.lang.Integer> |
sizeAsync()
Gets the number of elements in this collection
|
java.lang.String |
toString() |
equals, hashCodeclose, destroy, destroyAsyncpublic void add(E entity) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
entity - the entityjava.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.@Generated(value="src/python/synchronize.py") public void addAll(java.util.Collection<E> source) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
addAllAsync(Collection). Calls addAllAsync(Collection) and waits for the returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.@Generated(value="src/python/synchronize.py") public void addAll(E[] elements) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
addAllAsync(PgxEntity[]). Calls addAllAsync(PgxEntity[]) and waits for the returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public abstract void addAll(ID... ids) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
java.util.concurrent.ExecutionExceptionjava.lang.InterruptedExceptionpublic PgxFuture<java.lang.Void> addAllAsync(java.util.Collection<E> source)
source - vertices/edges to addpublic PgxFuture<java.lang.Void> addAllAsync(E[] elements)
elements - vertices/edges to add
@Generated(value="src/python/synchronize.py")
public void clear()
throws java.util.concurrent.ExecutionException,
java.lang.InterruptedException
clearAsync(). Calls clearAsync() and waits for the returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<java.lang.Void> clearAsync()
public PgxCollection<E,ID> clone()
clone in class java.lang.Objectpublic PgxCollection<E,ID> clone(java.lang.String newName) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
java.lang.InterruptedExceptionjava.util.concurrent.ExecutionExceptionpublic PgxFuture<PgxCollection<E,ID>> cloneAsync()
cloneAsync(String) passing name as nullpublic PgxFuture<PgxCollection<E,ID>> cloneAsync(java.lang.String newName)
newName - name of the new collectionpublic CollectionType getCollectionType()
public EntityType getElementType()
public PgxGraph getGraph()
public abstract IdType getIdType()
public java.lang.String getName()
getName in class PgxManagedObject@Generated(value="src/python/synchronize.py") public java.util.Iterator<E> iterator()
iteratorAsync(). Calls iteratorAsync() and waits for the returned PgxFuture to complete.iterator in interface java.lang.Iterable<E extends PgxEntity<ID>>java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<java.util.Iterator<E>> iteratorAsync()
@Generated(value="src/python/synchronize.py") public void removeAll(java.util.Collection<E> source) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
removeAllAsync(Collection). Calls removeAllAsync(Collection) and waits for the returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public abstract void removeAll(ID... ids) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
java.util.concurrent.ExecutionExceptionjava.lang.InterruptedExceptionpublic PgxFuture<java.lang.Void> removeAllAsync(java.util.Collection<E> source)
source - vertices/edges to remove
@Generated(value="src/python/synchronize.py")
public int size()
throws java.util.concurrent.ExecutionException,
java.lang.InterruptedException
sizeAsync(). Calls sizeAsync() and waits for the returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<java.lang.Integer> sizeAsync()
public java.lang.String toString()
toString in class PgxManagedObjectCopyright © 2016, 2017 Oracle Corp. All Rights Reserved.