Package cz.o2.proxima.core.transaction
Class KeyAttributes
- java.lang.Object
-
- cz.o2.proxima.core.transaction.KeyAttributes
-
@Experimental public class KeyAttributes extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static KeyAttributeofAttributeDescriptor(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor, long sequentialId)CreateKeyAttributefor given entity, key and attribute descriptor.static KeyAttributeofAttributeDescriptor(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor, long sequentialId, java.lang.String attributeSuffix)CreateKeyAttributefor given entity, key and attribute descriptor.static KeyAttributeofMissingAttribute(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor)CreateKeyAttributefor given entity, key and attribute descriptor.static KeyAttributeofMissingAttribute(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor, java.lang.String attributeSuffix)CreateKeyAttributefor given entity, key and attribute descriptor.static KeyAttributeofStreamElement(StreamElement element)Create aKeyAttributefor givenStreamElement.static <E extends StreamElement>
java.util.List<KeyAttribute>ofWildcardQueryElements(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> wildcardAttribute, java.lang.Iterable<E> elements)Create a list ofKeyAttributesthat represent a query for wildcard attribute and the returned
-
-
-
Method Detail
-
ofWildcardQueryElements
public static <E extends StreamElement> java.util.List<KeyAttribute> ofWildcardQueryElements(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> wildcardAttribute, java.lang.Iterable<E> elements)
Create a list ofKeyAttributesthat represent a query for wildcard attribute and the returned- Type Parameters:
E- type parameter- Parameters:
entity- the entity descriptorkey- the key of the entitywildcardAttribute- the descriptor of wildcard attributeelements- the elements returned by query- Returns:
-
ofAttributeDescriptor
public static KeyAttribute ofAttributeDescriptor(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor, long sequentialId)
CreateKeyAttributefor given entity, key and attribute descriptor. This describes either all wildcard attributes of that key or a single regular attribute.- Parameters:
entity- the entity descriptorkey- the entity keyattributeDescriptor- descriptor of wildcard or regular attributesequentialId- sequence ID of the read attribute
-
ofAttributeDescriptor
public static KeyAttribute ofAttributeDescriptor(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor, long sequentialId, @Nullable java.lang.String attributeSuffix)
CreateKeyAttributefor given entity, key and attribute descriptor. This describes either all wildcard attributes of that key or a single regular attribute.- Parameters:
entity- the entity descriptorkey- the entity keyattributeDescriptor- descriptor of wildcard or regular attributesequentialId- sequence ID of the read attributeattributeSuffix- a specific attribute suffix whenattributeDescriptoris wildcard attribute
-
ofMissingAttribute
public static KeyAttribute ofMissingAttribute(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor)
CreateKeyAttributefor given entity, key and attribute descriptor. This represents a missing value, that is a value that was either not-yet written or already deleted.- Parameters:
entity- the entity descriptorkey- the entity keyattributeDescriptor- descriptor of wildcard or regular attribute
-
ofMissingAttribute
public static KeyAttribute ofMissingAttribute(EntityDescriptor entity, java.lang.String key, AttributeDescriptor<?> attributeDescriptor, java.lang.String attributeSuffix)
CreateKeyAttributefor given entity, key and attribute descriptor. This represents a missing value, that is a value that was either not-yet written or already deleted.- Parameters:
entity- the entity descriptorkey- the entity keyattributeDescriptor- descriptor of wildcard or regular attributeattributeSuffix- a specific attribute suffix whenattributeDescriptoris wildcard attribute
-
ofStreamElement
public static KeyAttribute ofStreamElement(StreamElement element)
Create aKeyAttributefor givenStreamElement.- Parameters:
element- theStreamElementthat should be part of the transaction
-
-