org.neo4j.kernel.internal.Version.getReleaseVersion()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(3.3k)|赞(0)|评价(0)|浏览(73)

本文整理了Java中org.neo4j.kernel.internal.Version.getReleaseVersion()方法的一些代码示例,展示了Version.getReleaseVersion()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Version.getReleaseVersion()方法的具体详情如下:
包路径:org.neo4j.kernel.internal.Version
类名称:Version
方法名:getReleaseVersion

Version.getReleaseVersion介绍

暂无

代码示例

代码示例来源:origin: neo4j/neo4j

public static String getNeo4jVersion()
{
  return getKernel().getReleaseVersion();
}

代码示例来源:origin: neo4j/neo4j

private String neoDatabaseVersion( NeoServer neoServer )
{
  return neoServer.getDatabase().getGraph().getDependencyResolver().resolveDependency( KernelData.class )
      .version().getReleaseVersion();
}

代码示例来源:origin: neo4j/neo4j

@Test
public void shouldExposeCleanAndDetailedVersions()
{
  assertThat( version( "1.2.3-M01,abcdef012345" ).getReleaseVersion(), equalTo( "1.2.3-M01" ));
  assertThat( version( "1.2.3-M01,abcdef012345" ).getVersion(),        equalTo( "1.2.3-M01,abcdef012345" ));
  assertThat( version( "1.2.3-M01,abcdef012345-dirty" ).getVersion(),  equalTo( "1.2.3-M01,abcdef012345-dirty" ));
  assertThat( version( "1.2.3,abcdef012345" ).getReleaseVersion(),     equalTo( "1.2.3" ));
  assertThat( version( "1.2.3,abcdef012345" ).getVersion(),            equalTo( "1.2.3,abcdef012345" ));
  assertThat( version( "1.2.3,abcdef012345-dirty" ).getVersion(),      equalTo( "1.2.3,abcdef012345-dirty" ));
  assertThat( version( "1.2.3-GA,abcdef012345" ).getReleaseVersion(),  equalTo( "1.2.3-GA" ));
  assertThat( version( "1.2.3-GA,abcdef012345" ).getVersion(),         equalTo( "1.2.3-GA,abcdef012345" ));
  assertThat( version( "1.2.3-GA,abcdef012345-dirty" ).getVersion(),   equalTo( "1.2.3-GA,abcdef012345-dirty" ));
  assertThat( version( "1.2.3M01,abcdef012345" ).getReleaseVersion(),  equalTo( "1.2.3M01" ));
  assertThat( version( "1.2.3M01,abcdef012345" ).getVersion(),         equalTo( "1.2.3M01,abcdef012345" ));
  assertThat( version( "1.2.3M01,abcdef012345-dirty" ).getVersion(),   equalTo( "1.2.3M01,abcdef012345-dirty" ));
  assertThat( version( "1.2" ).getReleaseVersion(),  equalTo( "1.2" ));
  assertThat( version( "1.2" ).getVersion(),         equalTo( "1.2" ));
  assertThat( version( "0" ).getReleaseVersion(),    equalTo( "0" ));
  assertThat( version( "0" ).getVersion(),           equalTo( "0" ));
}

代码示例来源:origin: neo4j/neo4j

@Test
  public void shouldReportCommunityEdition() throws Exception
  {
    // Given
    String releaseVersion = server.getDatabase().getGraph().getDependencyResolver().resolveDependency( KernelData
        .class ).version().getReleaseVersion();
    // When
    HTTP.Response res =
        HTTP.GET( functionalTestHelper.managementUri() + "/" + VersionAndEditionService.SERVER_PATH );
    // Then
    assertEquals( 200, res.status() );
    assertThat( res.get( "edition" ).asText(), equalTo( "community" ) );
    assertThat( res.get( "version" ).asText(), equalTo( releaseVersion ) );
  }
}

代码示例来源:origin: org.neo4j/neo4j-kernel

public static String getNeo4jVersion()
{
  return getKernel().getReleaseVersion();
}

代码示例来源:origin: org.neo4j.app/neo4j-server

private String neoDatabaseVersion( NeoServer neoServer )
{
  return neoServer.getDatabase().getGraph().getDependencyResolver().resolveDependency( KernelData.class )
      .version().getReleaseVersion();
}

相关文章