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.class
and 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 Configuration
copy()
Copy this configuration.boolean
equals(Object obj)
Class
getEdgeIdType()
Returns the edge id type.Class
getEdgeLabelType()
Returns the edge label type.Boolean
getEdgeWeightColumn()
Returns whether an edge weight column is created.Class
getEdgeWeightType()
Returns the edge weight type.Class
getNodeIdType()
Returns the node id type.TimeRepresentation
getTimeRepresentation()
Returns the time representation.int
hashCode()
void
setEdgeIdType(Class edgeIdType)
Sets the edge id type.void
setEdgeLabelType(Class edgeLabelType)
Sets the edge label type.void
setEdgeWeightColumn(Boolean edgeWeightColumn)
Sets whether to create an edge weight column.void
setEdgeWeightType(Class edgeWeightType)
Sets the edge weight type.void
setNodeIdType(Class nodeIdType)
Sets the node id type.void
setTimeRepresentation(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
-
-