本文整理汇总了Java中prefuse.action.layout.Layout类的典型用法代码示例。如果您正苦于以下问题:Java Layout类的具体用法?Java Layout怎么用?Java Layout使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Layout类属于prefuse.action.layout包,在下文中一共展示了Layout类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: createLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
@Override
protected Layout createLayout(final IScope scope, final long timeout, final Map<String, Object> options) {
if (options.containsKey(OPTION_NAME_MAXITER)) {
try {
return new FruchtermanReingoldLayout(PREFUSE_GRAPH, (Integer) options.get(OPTION_NAME_MAXITER));
} catch (final ClassCastException e) {
throw GamaRuntimeException.error(
"Option " + OPTION_NAME_MAXITER + " of this layout is supposed to be an integer.", scope);
}
} else {
return new FruchtermanReingoldLayout(PREFUSE_GRAPH);
}
}
开发者ID:gama-platform,项目名称:gama,代码行数:17,代码来源:PrefuseStaticLayoutFruchtermanReingoldLayout.java
示例2: createLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
@Override
protected Layout createLayout(final IScope scope, final long timeout, final Map<String, Object> options) {
if (options.containsKey(OPTION_NAME_RADIUS)) {
try {
return new RadialTreeLayout(PREFUSE_GRAPH, (Integer) options.get(OPTION_NAME_RADIUS));
} catch (final ClassCastException e) {
throw GamaRuntimeException
.error("Option " + OPTION_NAME_RADIUS + " of this layout is supposed to be an integer.", scope);
}
} else {
return new RadialTreeLayout(PREFUSE_GRAPH);
}
}
开发者ID:gama-platform,项目名称:gama,代码行数:18,代码来源:PrefuseStaticLayoutRadialTree.java
示例3: createLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
@Override
protected Layout createLayout(final IScope scope, final long timeout, final Map<String, Object> options) {
if (options.containsKey(OPTION_NAME_FRAME)) {
try {
return new SquarifiedTreeMapLayout(PREFUSE_GRAPH, (Double) options.get(OPTION_NAME_FRAME));
} catch (final ClassCastException e) {
throw GamaRuntimeException
.error("Option " + OPTION_NAME_FRAME + " of this layout is supposed to be an double.", scope);
}
} else {
return new SquarifiedTreeMapLayout(PREFUSE_GRAPH);
}
}
开发者ID:gama-platform,项目名称:gama,代码行数:18,代码来源:PrefuseStaticLayoutSquarifiedTreeMap.java
示例4: createLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
@Override
protected Layout createLayout(final IScope scope, final long timeout, final Map<String, Object> options) {
final ForceDirectedLayout l = new ForceDirectedLayout(PREFUSE_GRAPH, true, false);
return l;
}
开发者ID:gama-platform,项目名称:gama,代码行数:6,代码来源:PrefuseStaticLayoutForceDirected.java
示例5: createLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
@Override
protected Layout createLayout(final IScope scope, final long timeout, final Map<String, Object> options) {
return new RandomLayout(PREFUSE_GRAPH);
}
开发者ID:gama-platform,项目名称:gama,代码行数:5,代码来源:PrefuseStaticLayoutRandom.java
示例6: createLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
@Override
protected Layout createLayout(final IScope scope, final long timeout, final Map<String, Object> options) {
final CircleLayout l = new CircleLayout(PREFUSE_GRAPH);
return l;
}
开发者ID:gama-platform,项目名称:gama,代码行数:6,代码来源:PrefuseStaticLayoutCircle.java
示例7: LayoutInfo
import prefuse.action.layout.Layout; //导入依赖的package包/类
public LayoutInfo(String name, Layout layout) {
super();
this.name = name;
this.layout = layout;
}
开发者ID:jdepend,项目名称:cooper,代码行数:6,代码来源:LayoutInfo.java
示例8: getLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
public Layout getLayout() {
return layout;
}
开发者ID:jdepend,项目名称:cooper,代码行数:4,代码来源:LayoutInfo.java
示例9: setLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
public void setLayout(Layout layout) {
this.layout = layout;
}
开发者ID:jdepend,项目名称:cooper,代码行数:4,代码来源:LayoutInfo.java
示例10: AnchorUpdateControl
import prefuse.action.layout.Layout; //导入依赖的package包/类
/**
* Create a new AnchorUpdateControl.
* @param layout the layouts for which to update the anchor point
* @param action the name of an action to run upon anchor updates
* @param overItem indicates if anchor update events should be processed
* while the mouse cursor is hovered over a VisualItem.
*/
public AnchorUpdateControl(Layout[] layout, String action, boolean overItem)
{
m_layouts = (Layout[])layout.clone();
m_action = action;
m_anchorOverItem = overItem;
}
开发者ID:dritanlatifi,项目名称:AndroidPrefuse,代码行数:14,代码来源:AnchorUpdateControl.java
示例11: renderLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
/**
* Takes a prefuse graph and applies a prefuse layout, with a max time for execution. Layout will use the space
* defined by the world agent found through the gama scope.
*
* @param prefuseGraph
* @param prefuseLayout
* @param scope
* @param maxtime
*/
private void renderLayout(final Graph prefuseGraph, final Layout prefuseLayout, final IScope scope,
final long maxtime) {
final Envelope envelope = scope.getSimulation().getEnvelope();
final Rectangle bounds =
new Rectangle((int) Math.floor(envelope.getMinX()), (int) Math.floor(envelope.getMinY()),
(int) Math.ceil(envelope.getWidth()), (int) Math.ceil(envelope.getHeight()));
renderLayout(prefuseGraph, prefuseLayout, bounds, maxtime);
}
开发者ID:gama-platform,项目名称:gama,代码行数:22,代码来源:PrefuseStaticLayoutAbstract.java
示例12: createLayout
import prefuse.action.layout.Layout; //导入依赖的package包/类
/**
* The actual creation of the prefuse layout to be used by the layout process.
*
* @param timeout
* @param options
* @return
*/
protected abstract Layout createLayout(final IScope scope, long timeout, Map<String, Object> options);
开发者ID:gama-platform,项目名称:gama,代码行数:9,代码来源:PrefuseStaticLayoutAbstract.java
注:本文中的prefuse.action.layout.Layout类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论