T
- which graph configuration object this builder will producepublic abstract class AbstractGraphConfigBuilder<T extends AbstractGraphConfigBuilder<T,GC>,GC extends GraphConfig>
extends java.lang.Object
implements oracle.pgx.config.internal.ConvertibleToGraphConfigBuilder
Constructor and Description |
---|
AbstractGraphConfigBuilder()
default constructor
|
Modifier and Type | Method and Description |
---|---|
T |
addAttribute(java.lang.String key,
java.lang.String value)
Adds a specific additional attribute to this config
|
T |
addEdgeProperty(java.lang.String name,
PropertyType type)
Convenience method for
addEdgeProperty(String, PropertyType, Object) . |
T |
addEdgeProperty(java.lang.String name,
PropertyType type,
java.lang.Object defaultVal)
Adds an edge property to this builder
|
T |
addEdgeProperty(java.lang.String name,
PropertyType type,
java.lang.Object defaultVal,
java.lang.Object column)
Adds an edge property to this builder
|
T |
addEdgeStringProperty(java.lang.String name,
int dimension,
java.lang.Object defaultVal,
java.lang.Object column,
StringPoolingStrategy stringPoolingStrategy,
java.lang.Integer maxDistinctStringPerPool)
Add a string edge property to the builder
|
T |
addEdgeStringProperty(java.lang.String name,
java.lang.Object defaultVal,
StringPoolingStrategy stringPoolingStrategy,
java.lang.Integer maxDistinctStringPerPool)
Convenience method for
addEdgeStringProperty(String, int, Object, Object, StringPoolingStrategy, Integer) . |
T |
addEdgeVectorProperty(java.lang.String name,
PropertyType type,
int dimension)
Convenience method for
addEdgeProperty(String, PropertyType, Object) . |
T |
addEdgeVectorProperty(java.lang.String name,
PropertyType type,
int dimension,
java.lang.Object defaultVal)
Adds an edge property to this builder
|
T |
addEdgeVectorProperty(java.lang.String name,
PropertyType type,
int dimension,
java.lang.Object defaultVal,
java.lang.Object column)
Adds an edge property to this builder
|
T |
addNodeProperty(java.lang.String name,
PropertyType type)
Alias for
addVertexProperty(String, PropertyType) . |
T |
addNodeProperty(java.lang.String name,
PropertyType type,
java.lang.Object defaultVal)
|
T |
addVertexProperty(java.lang.String name,
PropertyType type)
Convenience method for
addVertexProperty(String, PropertyType, Object) . |
T |
addVertexProperty(java.lang.String name,
PropertyType type,
java.lang.Object defaultVal)
Adds a vertex property to this builder
|
T |
addVertexProperty(java.lang.String name,
PropertyType type,
java.lang.Object defaultVal,
java.lang.Object column)
Adds a vertex property to this builder
|
T |
addVertexStringProperty(java.lang.String name,
int dimension,
java.lang.Object defaultVal,
java.lang.Object column,
StringPoolingStrategy stringPoolingStrategy,
java.lang.Integer maxDistinctStringPerPool)
Add a string vertex property to the builder
|
T |
addVertexStringProperty(java.lang.String name,
java.lang.Object defaultVal,
StringPoolingStrategy stringPoolingStrategy,
java.lang.Integer maxDistinctStringPerPool)
Convenience method for
addVertexStringProperty(String, int, Object, Object, StringPoolingStrategy, Integer) . |
T |
addVertexVectorProperty(java.lang.String name,
PropertyType type,
int dimension)
Convenience method for
addVertexProperty(String, PropertyType, Object) . |
T |
addVertexVectorProperty(java.lang.String name,
PropertyType type,
int dimension,
java.lang.Object defaultVal)
Add a vertex property to this builder
|
T |
addVertexVectorProperty(java.lang.String name,
PropertyType type,
int dimension,
java.lang.Object defaultVal,
java.lang.Object column)
Add a vertex property to this builder
|
GC |
build()
Build the graph configuration object
|
T |
clearEdgeProperties()
Removes all edge properties from this builder
|
T |
clearVertexProperties()
Removes all vertex properties from this builder
|
T |
copyBaseFrom(GraphConfig graphConfig)
Sets this builder with the values of the given graph config, this only includes base settings (format,
temporal formats, vertex properties, edge properties, loading configuration and error handling configuration).
|
T |
copyFrom(GC graphConfig)
Sets this builder with all the values of the given graph config.
|
T |
enableEdgeIdDuplicateCheck(boolean checkEdgeIdDuplicates)
Sets whether or not edge ID duplicates should be checked.
|
T |
enableVertexIdDuplicateCheck(boolean checkVertexIdDuplicates)
Sets whether or not vertex ID duplicates should be checked.
|
T |
redactPassword() |
T |
removeEdgeProperty(java.lang.String name)
Removes an edge property from this builder
|
T |
removeVertexProperty(java.lang.String name)
Removes a vertex property from this builder
|
T |
setArrayCompactionThreshold(java.lang.Double arrayCompactionThreshold)
For graphs optimized for updates, set the array compaction threshold.
|
T |
setAutoRefresh(boolean autoRefresh) |
T |
setCreateEdgeIdIndex(boolean create)
Sets the create edge id index flag.
|
T |
setCreateEdgeIdMapping(boolean create)
Sets the create edge id mapping.
|
T |
setCreateLabelHistogram(boolean flag)
Sets the flag to create a label histogram when loading the graph
|
T |
setCreateVertexIdIndex(boolean create)
Sets the create vertex ID index flag.
|
T |
setCreateVertexIdMapping(boolean create)
Sets the create vertex id mapping flag.
|
T |
setEdgeIdStrategy(IdStrategy idStrategy)
Sets the ID strategy used for the edges of this graph
|
T |
setEdgeIdType(IdType edgeIdType)
Sets the type of edge IDs
|
T |
setErrorHandlingOnDuplicateEntityId(OnMismatch action)
Sets the error handling on duplicated entity ID.
|
T |
setErrorHandlingOnMissedPropKey(OnMismatch action)
Sets the error handling on missed prop key.
|
T |
setErrorHandlingOnMissingVertex(OnMissingVertex action)
Sets the error handling on a missing vertex.
|
T |
setErrorHandlingOnParsingIssue(OnMismatch action)
Sets the error handling on a parsing issue.
|
T |
setErrorHandlingOnPropConversion(OnMismatch action)
Sets the error handling on prop conversion.
|
T |
setErrorHandlingOnTypeMismatch(OnMismatch action)
Sets the error handling on type mismatch.
|
T |
setErrorHandlingOnVectorLengthMismatch(OnMismatch action)
Sets the error handling on vector length mismatch.
|
T |
setFetchIntervalSec(int seconds)
Sets the refresh interval in seconds.
|
T |
setKeystoreAlias(java.lang.String keystoreAlias)
Sets the keystore alias.
|
T |
setLabelValueDelimiter(java.lang.String delimiter)
if
null read the whole String value as label. |
T |
setLoadEdgeLabel(boolean flag)
Sets the edge label loading.
|
T |
setLoadingProgressReportingFrequency(long frequency) |
T |
setLoadVertexLabels(boolean flag)
Sets the vertex label loading.
|
T |
setLocalDateFormat(java.util.List<java.lang.String> localDateFormatList)
Sets the list of local_date formats used for loading and storing the graph.
|
T |
setOptimizedFor(GraphOptimizedFor strategy)
Indicates if the graph should use data-structures optimized for updates.
|
T |
setPartitionDiscardDefaultValues(boolean discardDefaultValues)
Sets the flag to discard properties filled only with default values when partitioning a graph while loading
|
T |
setPartitionWhileLoading(PartitionWhileLoading partitionWhileLoading)
Indicates if the graph should be transformed into a heterogeneous graph while loading the graph data.
|
T |
setPassword(java.lang.String password)
Sets the password.
|
T |
setPropertyValueDelimiter(java.lang.String delimiter)
(only relevant for
use_vertex_property_value_as_label ) if null read the whole
property value as label. |
T |
setSkipEdgeLoading(boolean flag)
Sets the skip edges flag.
|
T |
setSkipVertexLoading(boolean flag)
Sets the skip vertices flag.
|
T |
setSnapshotsSource(SnapshotsSource source)
Sets the snapshots source field.
|
T |
setStrictMode(boolean strictMode)
Sets the strict mode.
|
T |
setTimeFormat(java.util.List<java.lang.String> timeFormatList)
Sets the list of time formats used for loading and storing the graph.
|
T |
setTimestampFormat(java.util.List<java.lang.String> timestampFormatList)
Sets the list timestamp formats used for loading and storing the graph.
|
T |
setTimestampWithTimezoneFormat(java.util.List<java.lang.String> timestampWithTimezoneFormatList)
Sets the list of timestamp with timezone formats used for loading and storing the graph.
|
T |
setTimeWithTimezoneFormat(java.util.List<java.lang.String> timeWithTimezoneFormatList)
Sets the list of time with timezone formats used for loading and storing the graph.
|
T |
setUpdateIntervalSec(int seconds) |
T |
setUpdatePropertiesInPlace(boolean updatePropertiesInPlace)
enables in-pplace non-structural updates.
|
T |
setUpdateThreshold(int threshold) |
T |
setUseVertexPropertyValueAsLabel(java.lang.String labelPropertyName)
Load the given property as vertex label.
|
T |
setVertexIdStrategy(IdStrategy idStrategy)
Sets the ID strategy used for the vertices of this graph
|
T |
setVertexIdType(IdType vertexIdType)
Sets the type of vertex IDs
|
T |
toGraphConfigBuilder() |
public AbstractGraphConfigBuilder()
public T addAttribute(java.lang.String key, java.lang.String value)
key
- the attribute's keyvalue
- the attribute's valuepublic T addEdgeProperty(java.lang.String name, PropertyType type)
addEdgeProperty(String, PropertyType, Object)
.name
- the name of the edge propertytype
- the type of the edge propertypublic T addEdgeProperty(java.lang.String name, PropertyType type, java.lang.Object defaultVal)
name
- the name of the edge propertytype
- the type of the edge propertydefaultVal
- the default value of the edge property (can be null
)public T addEdgeProperty(java.lang.String name, PropertyType type, java.lang.Object defaultVal, java.lang.Object column)
name
- the name of the edge propertytype
- the type of the edge propertydefaultVal
- the default value of the edge property (can be null
)column
- the column of the edge propertypublic T addEdgeStringProperty(java.lang.String name, int dimension, java.lang.Object defaultVal, java.lang.Object column, StringPoolingStrategy stringPoolingStrategy, java.lang.Integer maxDistinctStringPerPool)
name
- the name of the vertex propertydimension
- the dimension of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)column
- the column of the vertex propertystringPoolingStrategy
- which string pooling strategy to usemaxDistinctStringPerPool
- the amount of distinct strings per property after which to stop poolingpublic T addEdgeStringProperty(java.lang.String name, java.lang.Object defaultVal, StringPoolingStrategy stringPoolingStrategy, java.lang.Integer maxDistinctStringPerPool)
addEdgeStringProperty(String, int, Object, Object, StringPoolingStrategy, Integer)
.name
- the name of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)stringPoolingStrategy
- which string pooling strategy to usemaxDistinctStringPerPool
- the amount of distinct strings per property after which to stop poolingpublic T addEdgeVectorProperty(java.lang.String name, PropertyType type, int dimension)
addEdgeProperty(String, PropertyType, Object)
.name
- the name of the edge propertytype
- the type of the edge propertydimension
- the vector dimension of the propertypublic T addEdgeVectorProperty(java.lang.String name, PropertyType type, int dimension, java.lang.Object defaultVal)
name
- the name of the edge propertytype
- the type of the edge propertydimension
- the vector dimension of the propertydefaultVal
- the default value of the edge property (can be null
)public T addEdgeVectorProperty(java.lang.String name, PropertyType type, int dimension, java.lang.Object defaultVal, java.lang.Object column)
name
- the name of the edge propertytype
- the type of the edge propertydimension
- the vector dimension of the propertydefaultVal
- the default value of the edge property (can be null
)column
- the column of the edge propertypublic T addNodeProperty(java.lang.String name, PropertyType type)
addVertexProperty(String, PropertyType)
.name
- type
- public T addNodeProperty(java.lang.String name, PropertyType type, java.lang.Object defaultVal)
name
- type
- defaultVal
- public T addVertexProperty(java.lang.String name, PropertyType type)
addVertexProperty(String, PropertyType, Object)
.name
- the name of the vertex propertytype
- the type of the vertex propertypublic T addVertexProperty(java.lang.String name, PropertyType type, java.lang.Object defaultVal)
name
- the name of the vertex propertytype
- the type of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)public T addVertexProperty(java.lang.String name, PropertyType type, java.lang.Object defaultVal, java.lang.Object column)
name
- the name of the vertex propertytype
- the type of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)column
- the column of the vertex propertypublic T addVertexStringProperty(java.lang.String name, int dimension, java.lang.Object defaultVal, java.lang.Object column, StringPoolingStrategy stringPoolingStrategy, java.lang.Integer maxDistinctStringPerPool)
name
- the name of the vertex propertydimension
- the dimension of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)column
- the column of the vertex propertystringPoolingStrategy
- which string pooling strategy to usemaxDistinctStringPerPool
- the amount of distinct strings per property after which to stop poolingpublic T addVertexStringProperty(java.lang.String name, java.lang.Object defaultVal, StringPoolingStrategy stringPoolingStrategy, java.lang.Integer maxDistinctStringPerPool)
addVertexStringProperty(String, int, Object, Object, StringPoolingStrategy, Integer)
.name
- the name of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)stringPoolingStrategy
- which string pooling strategy to usemaxDistinctStringPerPool
- the amount of distinct strings per property after which to stop poolingpublic T addVertexVectorProperty(java.lang.String name, PropertyType type, int dimension)
addVertexProperty(String, PropertyType, Object)
.name
- the name of the vertex propertytype
- the type of the vertex propertydimension
- the dimension of the vertex propertypublic T addVertexVectorProperty(java.lang.String name, PropertyType type, int dimension, java.lang.Object defaultVal)
name
- the name of the vertex propertytype
- the type of the vertex propertydimension
- the dimension of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)public T addVertexVectorProperty(java.lang.String name, PropertyType type, int dimension, java.lang.Object defaultVal, java.lang.Object column)
name
- the name of the vertex propertytype
- the type of the vertex propertydimension
- the dimension of the vertex propertydefaultVal
- the default value of the vertex property (can be null
)column
- the column of the vertex propertypublic GC build()
public T clearEdgeProperties()
public T clearVertexProperties()
public final T copyBaseFrom(GraphConfig graphConfig)
graphConfig
- the graph configuration from which to copy the valuespublic T copyFrom(GC graphConfig)
graphConfig
- the graph configuration from which to copy the valuespublic T enableEdgeIdDuplicateCheck(boolean checkEdgeIdDuplicates)
checkEdgeIdDuplicates
- boolean flag for whether or not to enable the checkpublic T enableVertexIdDuplicateCheck(boolean checkVertexIdDuplicates)
checkVertexIdDuplicates
- boolean flag for whether or not to enable the checkpublic T redactPassword()
public T removeEdgeProperty(java.lang.String name)
name
- the name of the edge propertypublic T removeVertexProperty(java.lang.String name)
name
- the name of the vertex propertypublic T setArrayCompactionThreshold(java.lang.Double arrayCompactionThreshold)
arrayCompactionThreshold
- the threshold to usepublic T setAutoRefresh(boolean autoRefresh)
public T setCreateEdgeIdIndex(boolean create)
create
- if true
, a edge ID index is createdpublic T setCreateEdgeIdMapping(boolean create)
create
- if true
, a edge ID mapping is createdpublic T setCreateLabelHistogram(boolean flag)
flag
- the flag that indicated whether the label histogram should be created when the graph is loadedpublic T setCreateVertexIdIndex(boolean create)
create
- if true
, a vertex ID index is createdpublic T setCreateVertexIdMapping(boolean create)
create
- if true
, a vertex ID mapping is createdpublic T setEdgeIdStrategy(IdStrategy idStrategy)
idStrategy
- the ID strategy to use for the edgespublic T setEdgeIdType(IdType edgeIdType)
edgeIdType
- the type of edge IDspublic T setErrorHandlingOnDuplicateEntityId(OnMismatch action)
action
- the actionpublic T setErrorHandlingOnMissedPropKey(OnMismatch action)
action
- the actionpublic T setErrorHandlingOnMissingVertex(OnMissingVertex action)
action
- the actionpublic T setErrorHandlingOnParsingIssue(OnMismatch action)
action
- the actionpublic T setErrorHandlingOnPropConversion(OnMismatch action)
action
- the actionpublic T setErrorHandlingOnTypeMismatch(OnMismatch action)
action
- the actionpublic T setErrorHandlingOnVectorLengthMismatch(OnMismatch action)
action
- the actionpublic T setFetchIntervalSec(int seconds)
seconds
- the interval in secondspublic T setKeystoreAlias(java.lang.String keystoreAlias)
keystoreAlias
- the keystore alias.public T setLabelValueDelimiter(java.lang.String delimiter)
null
read the whole String value as label. Otherwise, split the string using the specified
delimiter and use all values as vertex labelsdelimiter
- the delimiter to use. If null
read the whole String value as labelpublic T setLoadEdgeLabel(boolean flag)
flag
- sets to load the edge label if true
public T setLoadingProgressReportingFrequency(long frequency)
public T setLoadVertexLabels(boolean flag)
flag
- sets to load the vertex label if true
public T setLocalDateFormat(java.util.List<java.lang.String> localDateFormatList)
localDateFormatList
- the list of date formatspublic T setOptimizedFor(GraphOptimizedFor strategy)
strategy
- flag to indicate if the graph should use data-structures optimized for updates or for
read-intensive applicationspublic T setPartitionDiscardDefaultValues(boolean discardDefaultValues)
discardDefaultValues
- wether or not to discard properties filled with default valuespublic T setPartitionWhileLoading(PartitionWhileLoading partitionWhileLoading)
partitionWhileLoading
- string to indicate if the graph should be partitioned during loading.public T setPassword(java.lang.String password)
password
- the password.public T setPropertyValueDelimiter(java.lang.String delimiter)
use_vertex_property_value_as_label
) if null
read the whole
property value as label. Otherwise, split the string using the specified delimiter and use all values as vertex
labelsdelimiter
- the delimiter to use. If null
read the whole property as labelpublic T setSkipEdgeLoading(boolean flag)
flag
- sets to skip the edges if true
public T setSkipVertexLoading(boolean flag)
flag
- sets to skip the vertices if true
public T setSnapshotsSource(SnapshotsSource source)
source
- the source to set, of type SnapshotsSource
public T setStrictMode(boolean strictMode)
strictMode
- if true
, strict mode is enabled, otherwise strict mode is disabledpublic T setTimeFormat(java.util.List<java.lang.String> timeFormatList)
timeFormatList
- the list of date formatspublic T setTimestampFormat(java.util.List<java.lang.String> timestampFormatList)
timestampFormatList
- the list of date formatspublic T setTimestampWithTimezoneFormat(java.util.List<java.lang.String> timestampWithTimezoneFormatList)
timestampWithTimezoneFormatList
- the list of date formatspublic T setTimeWithTimezoneFormat(java.util.List<java.lang.String> timeWithTimezoneFormatList)
timeWithTimezoneFormatList
- the list of date formatspublic T setUpdateIntervalSec(int seconds)
public T setUpdatePropertiesInPlace(boolean updatePropertiesInPlace)
updatePropertiesInPlace
- if true
, non-structural updates are applied in-placepublic T setUpdateThreshold(int threshold)
public T setUseVertexPropertyValueAsLabel(java.lang.String labelPropertyName)
labelPropertyName
- the name of the property to load as labelpublic T setVertexIdStrategy(IdStrategy idStrategy)
idStrategy
- the ID strategy to use for the verticespublic T setVertexIdType(IdType vertexIdType)
vertexIdType
- the type of vertex IDspublic T toGraphConfigBuilder()
toGraphConfigBuilder
in interface oracle.pgx.config.internal.ConvertibleToGraphConfigBuilder