public Builder( String[] namespace, String name ) { this.name = new QualifiedName( namespace, name ); }
private QualifiedName toLowerCaseName( QualifiedName name ) { String[] oldNs = name.namespace(); String[] lowerCaseNamespace = new String[oldNs.length]; for ( int i = 0; i < oldNs.length; i++ ) { lowerCaseNamespace[i] = oldNs[i].toLowerCase(); } String lowercaseName = name.name().toLowerCase(); return new QualifiedName( lowerCaseNamespace, lowercaseName ); } }
private String describeAndLogLoadFailure( QualifiedName name ) { String nameStr = name.toString(); String description = nameStr + " is unavailable because it is sandboxed and has dependencies outside of the sandbox. " + "Sandboxing is controlled by the " + procedure_unrestricted.name() + " setting. " + "Only unrestrict procedures you can trust with access to database internals."; log.warn( description ); return description; }
private static void rejectEmptyNamespace( QualifiedName name ) throws ProcedureException { if ( name.namespace() == null || name.namespace().length == 0 ) { throw new ProcedureException( Status.Procedure.ProcedureRegistrationFailed, "It is not allowed to define functions in the root namespace please use a namespace, " + "e.g. `@UserFunction(\"org.example.com.%s\")", name.name() ); } }
SubFunction( TemporalFunction<T> base, String name, List<FieldSignature> input, String description ) { this.function = base; this.signature = new UserFunctionSignature( new QualifiedName( new String[] {base.signature.name().name()}, name ), input, base.signature.outputType(), null, ALLOWED, description, true ); }
for ( CallableProcedure proc : procs ) String name = proc.signature().name().name(); proc.apply( new BasicContext(), new Object[0], resourceTracker ); switch ( name )
@Override public int hashCode() { return name.hashCode(); }
@Override public boolean equals( Object o ) { if ( this == o ) { return true; } if ( o == null || getClass() != o.getClass() ) { return false; } UserFunctionSignature that = (UserFunctionSignature) o; return name.equals( that.name ) && inputSignature.equals( that.inputSignature ) && type.equals( that.type ); }
SubFunction( TemporalFunction<T> base, String name, List<FieldSignature> input, String description ) { this.function = base; this.signature = new UserFunctionSignature( new QualifiedName( new String[] {base.signature.name().name()}, name ), input, base.signature.outputType(), null, ALLOWED, description, true ); }
for ( CallableUserFunction func : funcs ) String name = func.signature().name().name(); func.apply( new BasicContext(), new AnyValue[0] ); switch ( name )
@Override public int hashCode() { return name.hashCode(); }
@Override public boolean equals( Object o ) { if ( this == o ) { return true; } if ( o == null || getClass() != o.getClass() ) { return false; } ProcedureSignature that = (ProcedureSignature) o; return name.equals( that.name ) && inputSignature.equals( that.inputSignature ) && outputSignature.equals( that.outputSignature ) && isVoid() == that.isVoid(); }
public Builder( String[] namespace, String name ) { this.name = new QualifiedName( namespace, name ); }
private QualifiedName toLowerCaseName( QualifiedName name ) { String[] oldNs = name.namespace(); String[] lowerCaseNamespace = new String[oldNs.length]; for ( int i = 0; i < oldNs.length; i++ ) { lowerCaseNamespace[i] = oldNs[i].toLowerCase(); } String lowercaseName = name.name().toLowerCase(); return new QualifiedName( lowerCaseNamespace, lowercaseName ); } }
private FunctionResult( UserFunctionSignature signature ) { this.name = signature.name().toString(); this.signature = signature.toString(); this.description = signature.description().orElse( "" ); } }
for ( CallableUserAggregationFunction func : funcs ) String name = func.signature().name().name(); func.create( new BasicContext()); switch ( name )
@Override public int hashCode() { return name.hashCode(); }