Interface Graph.Features.VertexFeatures
- All Superinterfaces:
Graph.Features.ElementFeatures,Graph.Features.FeatureSet
- Enclosing interface:
- Graph.Features
Features that are related to
Vertex operations.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from interface org.apache.tinkerpop.gremlin.structure.Graph.Features.ElementFeatures
FEATURE_ADD_PROPERTY, FEATURE_ANY_IDS, FEATURE_CUSTOM_IDS, FEATURE_NULL_PROPERTY_VALUES, FEATURE_NUMERIC_IDS, FEATURE_REMOVE_PROPERTY, FEATURE_STRING_IDS, FEATURE_USER_SUPPLIED_IDS, FEATURE_UUID_IDS -
Method Summary
Modifier and TypeMethodDescriptiondefault VertexProperty.CardinalitygetCardinality(String key) Gets theVertexProperty.Cardinalityfor a key.default StringGets the default label returned for vertices with no explicit labels when the cardinality requires at least one label (LabelCardinality.ONEorLabelCardinality.ONE_OR_MORE).default LabelCardinalityGets theLabelCardinalityfor vertices in this graph.Gets features related to "properties" on aVertex.default booleanDetermines if aVertexcan be added to theGraph.default booleanDetermines if aVertexcan support non-unique values on the same key.default booleanDetermines if aVertexcan support properties on vertex properties.default booleanDetermines if aVertexcan support multiple properties with the same key.default booleanDetermines if aVertexcan be removed from theGraph.default booleanDetermines if theGraphimplementation uses upsert functionality as opposed to insert functionality forGraph.addVertex(String).Methods inherited from interface org.apache.tinkerpop.gremlin.structure.Graph.Features.ElementFeatures
supportsAddProperty, supportsAnyIds, supportsCustomIds, supportsNullPropertyValues, supportsNumericIds, supportsRemoveProperty, supportsStringIds, supportsUserSuppliedIds, supportsUuidIds, willAllowId
-
Field Details
-
FEATURE_ADD_VERTICES
- See Also:
-
FEATURE_MULTI_PROPERTIES
- See Also:
-
FEATURE_DUPLICATE_MULTI_PROPERTIES
- See Also:
-
FEATURE_META_PROPERTIES
- See Also:
-
FEATURE_REMOVE_VERTICES
- See Also:
-
FEATURE_UPSERT
- See Also:
-
-
Method Details
-
getCardinality
Gets theVertexProperty.Cardinalityfor a key. By default, this method will returnVertexProperty.Cardinality.list. Implementations that employ a schema can consult it to determine theVertexProperty.Cardinality. Those that do no have a schema can return their defaultVertexProperty.Cardinalityfor every key. Note that this method is primarily used by TinkerPop for internal usage and may not be suitable to reliably determine the cardinality of a key. For some implementation it may offer little more than a hint on the actual cardinality. Generally speaking it is likely best to drop down to the API of theGraphimplementation for any schema related queries. -
supportsAddVertices
default boolean supportsAddVertices()Determines if aVertexcan be added to theGraph. -
supportsRemoveVertices
default boolean supportsRemoveVertices()Determines if aVertexcan be removed from theGraph. -
supportsMultiProperties
default boolean supportsMultiProperties()Determines if aVertexcan support multiple properties with the same key. -
supportsDuplicateMultiProperties
default boolean supportsDuplicateMultiProperties()Determines if aVertexcan support non-unique values on the same key. For this value to betrue, thensupportsMetaProperties()must also return true. By default this method, just returns whatsupportsMultiProperties()returns. -
supportsMetaProperties
default boolean supportsMetaProperties()Determines if aVertexcan support properties on vertex properties. It is assumed that a graph will support all the same data types for meta-properties that are supported for regular properties. -
supportsUpsert
default boolean supportsUpsert()Determines if theGraphimplementation uses upsert functionality as opposed to insert functionality forGraph.addVertex(String). This feature gives graph providers some flexibility as to how graph mutations are treated. For graph providers, testing of this feature (as far as TinkerPop is concerned) only covers graphs that can support user supplied identifiers as there is no other way for TinkerPop to know what aspect of a vertex is unique to appropriately apply assertions. Graph providers, especially those who support schema features, may have other methods for uniquely identifying a vertex and should therefore resort to their own body of tests to validate this feature. -
properties
Gets features related to "properties" on aVertex. -
getLabelCardinality
Gets theLabelCardinalityfor vertices in this graph. Defines how many labels a vertex can have and whether labels are mutable.- Returns:
- the label cardinality for vertices, defaulting to
LabelCardinality.ONE - Since:
- 4.0.0
-
getDefaultLabel
Gets the default label returned for vertices with no explicit labels when the cardinality requires at least one label (LabelCardinality.ONEorLabelCardinality.ONE_OR_MORE).- Returns:
- the default vertex label, typically
Vertex.DEFAULT_LABEL - Since:
- 4.0.0
-