Package org.gephi.graph.api
Class Configuration
- java.lang.Object
-
- org.gephi.graph.api.Configuration
-
public class Configuration extends Object
Global configuration set at initialization.This class can be passed as a parameter to
GraphModel.Factory.newInstance(org.gephi.graph.api.Configuration)to create a GraphModel with custom configuration.Create instances by using the builder:
Configuration config = Configuration.builder().build();
Note that setting configurations after the GraphModel has been created won't have any effect.
By default, both node and edge id types are
String.classand the time representation isTIMESTAMP.See the builder documentation for more information on default values.
- See Also:
GraphModel,Configuration.Builder
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classConfiguration.BuilderConfiguration builder.
-
Constructor Summary
Constructors Constructor Description Configuration()Deprecated.Use thebuilder()method instead.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static Configuration.Builderbuilder()Creates a new builder.Configurationcopy()Copy this configuration.StringdiffAsString(Configuration other)Returns a string representation of the differences between this configuration and another one.booleanequals(Object o)ClassgetEdgeIdType()Returns the edge id type.ClassgetEdgeLabelType()Returns the edge label type.BooleangetEdgeWeightColumn()Returns whether an edge weight column is created.ClassgetEdgeWeightType()Returns the edge weight type.ClassgetNodeIdType()Returns the node id type.TimeRepresentationgetTimeRepresentation()Returns the time representation.inthashCode()booleanisEnableAutoEdgeTypeRegistration()booleanisEnableAutoLocking()booleanisEnableEdgeProperties()booleanisEnableIndexEdges()booleanisEnableIndexNodes()booleanisEnableIndexTime()booleanisEnableNodeProperties()booleanisEnableObservers()booleanisEnableParallelEdgesSameType()booleanisEnableSpatialIndex()voidsetEdgeIdType(Class edgeIdType)Deprecated.Usebuilder()instead.voidsetEdgeLabelType(Class edgeLabelType)Deprecated.Usebuilder()instead.voidsetEdgeWeightColumn(Boolean edgeWeightColumn)Deprecated.Usebuilder()instead.voidsetEdgeWeightType(Class edgeWeightType)Deprecated.Usebuilder()instead.voidsetNodeIdType(Class nodeIdType)Deprecated.Usebuilder()instead.voidsetTimeRepresentation(TimeRepresentation timeRepresentation)Deprecated.Usebuilder()instead.StringtoString()
-
-
-
Constructor Detail
-
Configuration
@Deprecated public Configuration()
Deprecated.Use thebuilder()method instead.Default constructor.
-
-
Method Detail
-
builder
public static Configuration.Builder builder()
Creates a new builder.- Returns:
- a new builder
-
getNodeIdType
public Class getNodeIdType()
Returns the node id type.- Returns:
- node id type
-
setNodeIdType
@Deprecated public void setNodeIdType(Class nodeIdType)
Deprecated.Usebuilder()instead.Sets the node id type.Only simple types such as primitives, wrappers and String are supported.
- Parameters:
nodeIdType- node id type- Throws:
IllegalArgumentException- if the type isn't supported
-
getEdgeIdType
public Class getEdgeIdType()
Returns the edge id type.- Returns:
- edge id type
-
setEdgeIdType
@Deprecated public void setEdgeIdType(Class edgeIdType)
Deprecated.Usebuilder()instead.Sets the edge id type.Only simple types such as primitives, wrappers and String are supported.
- Parameters:
edgeIdType- edge id type- Throws:
IllegalArgumentException- if the type isn't supported
-
getEdgeLabelType
public Class getEdgeLabelType()
Returns the edge label type.- Returns:
- edge label type
-
setEdgeLabelType
@Deprecated public void setEdgeLabelType(Class edgeLabelType)
Deprecated.Usebuilder()instead.Sets the edge label type.- Parameters:
edgeLabelType- edge label type- Throws:
IllegalArgumentException- if the type isn't supported
-
getEdgeWeightType
public Class getEdgeWeightType()
Returns the edge weight type.- Returns:
- edge weight type
-
setEdgeWeightType
@Deprecated public void setEdgeWeightType(Class edgeWeightType)
Deprecated.Usebuilder()instead.Sets the edge weight type.- Parameters:
edgeWeightType- edge weight type- Throws:
IllegalArgumentException- if the type isn't supported
-
getTimeRepresentation
public TimeRepresentation getTimeRepresentation()
Returns the time representation.- Returns:
- time representation
-
setTimeRepresentation
@Deprecated public void setTimeRepresentation(TimeRepresentation timeRepresentation)
Deprecated.Usebuilder()instead.Sets the time representation.- Parameters:
timeRepresentation- time representation
-
getEdgeWeightColumn
public Boolean getEdgeWeightColumn()
Returns whether an edge weight column is created.- Returns:
- edge weight column
-
setEdgeWeightColumn
@Deprecated public void setEdgeWeightColumn(Boolean edgeWeightColumn)
Deprecated.Usebuilder()instead.Sets whether to create an edge weight column.- Parameters:
edgeWeightColumn- edge weight column
-
isEnableAutoLocking
public boolean isEnableAutoLocking()
-
isEnableAutoEdgeTypeRegistration
public boolean isEnableAutoEdgeTypeRegistration()
-
isEnableIndexNodes
public boolean isEnableIndexNodes()
-
isEnableIndexEdges
public boolean isEnableIndexEdges()
-
isEnableIndexTime
public boolean isEnableIndexTime()
-
isEnableObservers
public boolean isEnableObservers()
-
isEnableNodeProperties
public boolean isEnableNodeProperties()
-
isEnableEdgeProperties
public boolean isEnableEdgeProperties()
-
isEnableSpatialIndex
public boolean isEnableSpatialIndex()
-
isEnableParallelEdgesSameType
public boolean isEnableParallelEdgesSameType()
-
copy
public Configuration copy()
Copy this configuration.- Returns:
- a copy of this configuration
-
diffAsString
public String diffAsString(Configuration other)
Returns a string representation of the differences between this configuration and another one.- Parameters:
other- the other configuration- Returns:
- a string representation of the differences
-
-