org.neo4j.procedure.Procedure.mode()方法的使用及代码示例

x33g5p2x  于2022-01-26 转载在 其他  
字(2.9k)|赞(0)|评价(0)|浏览(117)

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

Procedure.mode介绍

暂无

代码示例

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

@Override
public Stream<CompilationMessage> visitExecutable( ExecutableElement method, Void ignored )
{
  Procedure procedure = method.getAnnotation( Procedure.class );
  if ( procedure == null )
  {
    return Stream.of( new PerformsWriteMisuseError( method, "@%s usage error: missing @%s annotation on method",
        PerformsWrites.class.getSimpleName(), Procedure.class.getSimpleName() ) );
  }
  if ( procedure.mode() != Mode.DEFAULT )
  {
    return Stream.of( new PerformsWriteMisuseError( method,
        "@%s usage error: cannot use mode other than Mode.DEFAULT",
        PerformsWrites.class.getSimpleName() ) );
  }
  return Stream.empty();
}

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

Mode mode = procedure.mode();
boolean admin = method.isAnnotationPresent( Admin.class );
if ( method.isAnnotationPresent( PerformsWrites.class ) )
  if ( procedure.mode() != org.neo4j.procedure.Mode.DEFAULT )

代码示例来源:origin: net.biville.florent/neo4j-sproc-compiler

@Override
public Stream<CompilationMessage> visitExecutable( ExecutableElement method, Void ignored )
{
  Procedure procedure = method.getAnnotation( Procedure.class );
  if ( procedure == null )
  {
    return Stream.of( new PerformsWriteMisuseError( method, "@%s usage error: missing @%s annotation on method",
        PerformsWrites.class.getSimpleName(), Procedure.class.getSimpleName() ) );
  }
  if ( procedure.mode() != Mode.DEFAULT )
  {
    return Stream.of( new PerformsWriteMisuseError( method,
        "@%s usage error: cannot use mode other than Mode.DEFAULT",
        PerformsWrites.class.getSimpleName() ) );
  }
  return Stream.empty();
}

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

@Override
public Stream<CompilationMessage> visitExecutable( ExecutableElement method, Void ignored )
{
  Procedure procedure = method.getAnnotation( Procedure.class );
  if ( procedure == null )
  {
    return Stream.of( new PerformsWriteMisuseError( method, "@%s usage error: missing @%s annotation on method",
        PerformsWrites.class.getSimpleName(), Procedure.class.getSimpleName() ) );
  }
  if ( procedure.mode() != Mode.DEFAULT )
  {
    return Stream.of( new PerformsWriteMisuseError( method,
        "@%s usage error: cannot use mode other than Mode.DEFAULT",
        PerformsWrites.class.getSimpleName() ) );
  }
  return Stream.empty();
}

代码示例来源:origin: net.biville.florent/neo4j-sproc-compiler

public Either<DsvExportError,String> executionMode( ExecutableElement method )
{
  PerformsWrites performsWrites = method.getAnnotation( PerformsWrites.class );
  if ( performsWrites != null )
  {
    return Either.right( "PERFORMS_WRITE" );
  }
  Procedure procedure = method.getAnnotation( Procedure.class );
  if ( procedure != null )
  {
    return Either.right( procedure.mode().name() );
  }
  return Either.right( "" );
}

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

Mode mode = procedure.mode();
boolean admin = method.isAnnotationPresent( Admin.class );
if ( method.isAnnotationPresent( PerformsWrites.class ) )
  if ( procedure.mode() != org.neo4j.procedure.Mode.DEFAULT )

相关文章