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.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 Also:
GraphModel
-
-
Constructor Summary
Constructors Constructor Description Configuration()Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Configurationcopy()Copy this configuration.booleanequals(Object obj)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()voidsetEdgeIdType(Class edgeIdType)Sets the edge id type.voidsetEdgeLabelType(Class edgeLabelType)Sets the edge label type.voidsetEdgeWeightColumn(Boolean edgeWeightColumn)Sets whether to create an edge weight column.voidsetEdgeWeightType(Class edgeWeightType)Sets the edge weight type.voidsetNodeIdType(Class nodeIdType)Sets the node id type.voidsetTimeRepresentation(TimeRepresentation timeRepresentation)Sets the time representation.
-
-
-
Method Detail
-
getNodeIdType
public Class getNodeIdType()
Returns the node id type.- Returns:
- node id type
-
setNodeIdType
public void setNodeIdType(Class nodeIdType)
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
public void setEdgeIdType(Class edgeIdType)
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
public void setEdgeLabelType(Class edgeLabelType)
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
public void setEdgeWeightType(Class edgeWeightType)
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
public void setTimeRepresentation(TimeRepresentation timeRepresentation)
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
public void setEdgeWeightColumn(Boolean edgeWeightColumn)
Sets whether to create an edge weight column.- Parameters:
edgeWeightColumn- edge weight column
-
copy
public Configuration copy()
Copy this configuration.- Returns:
- a copy of this configuration
-
-