public abstract class ElementBuilder<T extends Element> extends Object implements ElementMutation<T>
DEFAULT_KEY| Constructor and Description |
|---|
ElementBuilder() |
| Modifier and Type | Method and Description |
|---|---|
ElementBuilder<T> |
addPropertyValue(String key,
String name,
Object value,
Metadata metadata,
Visibility visibility)
Adds or updates a property.
|
ElementBuilder<T> |
addPropertyValue(String key,
String name,
Object value,
Visibility visibility)
Adds or updates a property.
|
IndexHint |
getIndexHint() |
Iterable<Property> |
getProperties()
Gets the properties currently in this mutation.
|
Iterable<PropertyRemoveMutation> |
getPropertyRemoves()
Gets the properties currently being removed in this mutation.
|
ElementBuilder<T> |
removeProperty(Property property)
Removes a property.
|
ElementBuilder<T> |
removeProperty(String key,
String name,
Visibility visibility)
Removes a property.
|
ElementBuilder<T> |
removeProperty(String name,
Visibility visibility)
Removes the default property with that name.
|
abstract T |
save(Authorizations authorizations)
saves the element to the graph.
|
ElementMutation<T> |
setIndexHint(IndexHint indexHint)
Sets the index hint of this element.
|
ElementBuilder<T> |
setProperty(String name,
Object value,
Metadata metadata,
Visibility visibility)
Sets or updates a property value.
|
ElementBuilder<T> |
setProperty(String name,
Object value,
Visibility visibility)
Sets or updates a property value.
|
public ElementBuilder<T> setProperty(String name, Object value, Visibility visibility)
setProperty in interface ElementMutation<T extends Element>name - The name of the property.value - The value of the property.visibility - The visibility to give this property.public ElementBuilder<T> setProperty(String name, Object value, Metadata metadata, Visibility visibility)
setProperty in interface ElementMutation<T extends Element>name - The name of the property.value - The value of the property.metadata - The metadata to assign to this property.visibility - The visibility to give this property.public ElementBuilder<T> addPropertyValue(String key, String name, Object value, Visibility visibility)
addPropertyValue in interface ElementMutation<T extends Element>key - The unique key given to the property allowing for multi-valued properties.name - The name of the property.value - The value of the property.visibility - The visibility to give this property.public ElementBuilder<T> addPropertyValue(String key, String name, Object value, Metadata metadata, Visibility visibility)
addPropertyValue in interface ElementMutation<T extends Element>key - The unique key given to the property allowing for multi-valued properties.name - The name of the property.value - The value of the property.metadata - The metadata to assign to this property.visibility - The visibility to give this property.public ElementBuilder<T> removeProperty(Property property)
ElementMutationremoveProperty in interface ElementMutation<T extends Element>property - the property to remove.public ElementBuilder<T> removeProperty(String name, Visibility visibility)
ElementMutationremoveProperty in interface ElementMutation<T extends Element>name - the property name to remove.visibility - the visibility of the property to remove.public ElementBuilder<T> removeProperty(String key, String name, Visibility visibility)
ElementMutationremoveProperty in interface ElementMutation<T extends Element>key - the key of the property to remove.name - the name of the property to remove.visibility - the visibility of the property to remove.public abstract T save(Authorizations authorizations)
save in interface ElementMutation<T extends Element>public Iterable<Property> getProperties()
ElementMutationgetProperties in interface ElementMutation<T extends Element>public Iterable<PropertyRemoveMutation> getPropertyRemoves()
ElementMutationgetPropertyRemoves in interface ElementMutation<T extends Element>public IndexHint getIndexHint()
public ElementMutation<T> setIndexHint(IndexHint indexHint)
ElementMutationsetIndexHint in interface ElementMutation<T extends Element>Copyright © 2014–2015. All rights reserved.