当前位置: 首页>>代码示例>>Java>>正文


Java BasicComputation类代码示例

本文整理汇总了Java中org.apache.giraph.graph.BasicComputation的典型用法代码示例。如果您正苦于以下问题:Java BasicComputation类的具体用法?Java BasicComputation怎么用?Java BasicComputation使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


BasicComputation类属于org.apache.giraph.graph包,在下文中一共展示了BasicComputation类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setUp

import org.apache.giraph.graph.BasicComputation; //导入依赖的package包/类
@Before
public void setUp() throws IOException, InterruptedException {
    rr = mock(RecordReader.class);
    GiraphConfiguration giraphConf = new GiraphConfiguration();
    giraphConf.setComputationClass(BasicComputation.class);
    giraphConf.set(DGALongEdgeValueInputFormat.LINE_TOKENIZE_VALUE, ",");
    conf = new ImmutableClassesGiraphConfiguration<Text, Text, Text>(giraphConf);
    tac = mock(TaskAttemptContext.class);
    when(tac.getConfiguration()).thenReturn(conf);
}
 
开发者ID:Sotera,项目名称:distributed-graph-analytics,代码行数:11,代码来源:DGATextEdgeValueInputFormatTest.java

示例2: setUp

import org.apache.giraph.graph.BasicComputation; //导入依赖的package包/类
@Before
public void setUp() throws Exception {
    tw = mock(RecordWriter.class);
    GiraphConfiguration giraphConfiguration = new GiraphConfiguration();
    giraphConfiguration.setComputationClass(BasicComputation.class);
    conf = new ImmutableClassesGiraphConfiguration<Text, VertexData, Text>(giraphConfiguration);
    vertex = mock(Vertex.class);
    vertex2 = mock(Vertex.class);
    when(vertex.getId()).thenReturn(new Text("1"));
    when(vertex.getValue()).thenReturn(new VertexData());
    when(vertex2.getId()).thenReturn(new Text("2"));
    vertexData = new VertexData();
    vertexData.setApproxBetweenness(1.0);
    when(vertex2.getValue()).thenReturn(vertexData);
}
 
开发者ID:Sotera,项目名称:distributed-graph-analytics,代码行数:16,代码来源:HBSEOutputFormatTest.java

示例3: testInferTypeParams

import org.apache.giraph.graph.BasicComputation; //导入依赖的package包/类
@Test
public void testInferTypeParams() {
  checkTypes(TypesHolder.class, IntTypes.class, 5);
  checkTypes(TypesHolder.class, IntComputation.class, 5);
  checkTypes(Computation.class, IntComputation.class, 5);
  checkTypes(TypesHolder.class, IntBasicComputation.class, 5);
  checkTypes(Computation.class, IntBasicComputation.class, 5);
  checkTypes(BasicComputation.class, IntBasicComputation.class, 4);
}
 
开发者ID:renato2099,项目名称:giraph-gora,代码行数:10,代码来源:TestReflectionUtils.java


注:本文中的org.apache.giraph.graph.BasicComputation类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。