public class EntityContext extends Object implements Iterable<AttachedEntity>
Constructor and Description |
---|
EntityContext() |
Modifier and Type | Method and Description |
---|---|
void |
addFurtherDeletes(URI uri) |
void |
attach(EntityInvocationHandler entity)
Attaches an existing entity with status ATTACHED.
|
void |
attach(EntityInvocationHandler entity,
AttachedEntityStatus status)
Attaches an entity with specified status.
|
void |
attach(EntityInvocationHandler entity,
AttachedEntityStatus status,
boolean force)
Attaches an entity with specified status.
|
void |
attachNew(EntityInvocationHandler entity)
Attaches an entity with status NEW.
|
void |
detach(EntityInvocationHandler entity)
Detaches entity.
|
void |
detachAll()
Detaches all attached entities.
|
EntityInvocationHandler |
getEntity(EntityUUID uuid)
Searches an entity with the specified key.
|
List<URI> |
getFurtherDeletes() |
AttachedEntityStatus |
getStatus(EntityInvocationHandler entity)
Gets entity status.
|
boolean |
isAttached(EntityInvocationHandler entity)
Checks if an entity is already attached.
|
Iterator<AttachedEntity> |
iterator()
Iterator.
|
void |
setStatus(EntityInvocationHandler entity,
AttachedEntityStatus status)
Changes attached entity status.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
public void attachNew(EntityInvocationHandler entity)
entity
- entity to be attached.AttachedEntityStatus
public void attach(EntityInvocationHandler entity)
entity
- entity to be attached.AttachedEntityStatus
public void attach(EntityInvocationHandler entity, AttachedEntityStatus status)
entity
- entity to be attached.status
- status.AttachedEntityStatus
public void attach(EntityInvocationHandler entity, AttachedEntityStatus status, boolean force)
entity
- entity to be attached.status
- status.force
- force attach.public void detach(EntityInvocationHandler entity)
entity
- entity to be detached.public void detachAll()
public EntityInvocationHandler getEntity(EntityUUID uuid)
uuid
- entity key.public AttachedEntityStatus getStatus(EntityInvocationHandler entity)
entity
- entity to be retrieved.public void setStatus(EntityInvocationHandler entity, AttachedEntityStatus status)
entity
- attached entity to be modified.status
- new status.public boolean isAttached(EntityInvocationHandler entity)
entity
- entity.public Iterator<AttachedEntity> iterator()
iterator
in interface Iterable<AttachedEntity>
public void addFurtherDeletes(URI uri)
Copyright © 2013–2018 The Apache Software Foundation. All rights reserved.