Examples of FunctionType


Examples of com.neuralnetwork.shared.functions.FunctionType

     * .SigmoidFunction#getFunctionType()}.
     */
    @Test
    public final void testGetFunctionType() {
        IActivationFunction f = new SigmoidFunction();
        FunctionType t = f.getFunctionType();
        assertEquals(t, FunctionType.SIGMOID);
    }
View Full Code Here

Examples of kiss.lang.type.FunctionType

 
  static final Object[] testObjects={null,0,1,true,false,"Foo",1.0,new Object(),Anything.INSTANCE};


  @Test public void testFnType() {
    FunctionType t=FunctionType.create(Null.INSTANCE,JavaType.create(Integer.class));
    assertEquals(1,t.getArity());
   
    assertTrue(t.contains(FunctionType.create(Null.INSTANCE,JavaType.create(Number.class))));
    assertFalse(t.contains(FunctionType.create(Null.INSTANCE,JavaType.create(String.class))));
  }
View Full Code Here

Examples of net.opengis.fes20.FunctionType

     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->
     * @generated
     */
    public NotificationChain basicSetFunction(FunctionType newFunction, NotificationChain msgs) {
        FunctionType oldFunction = function;
        function = newFunction;
        if (eNotificationRequired()) {
            ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, Fes20Package.UNARY_LOGIC_OP_TYPE__FUNCTION, oldFunction, newFunction);
            if (msgs == null) msgs = notification; else msgs.add(notification);
        }
View Full Code Here

Examples of org.apache.hadoop.hive.metastore.api.FunctionType

    String funcName = "test_func";
    String className = "org.apache.hadoop.hive.ql.udf.generic.GenericUDFUpper";
    String owner = "test_owner";
    PrincipalType ownerType = PrincipalType.USER;
    int createTime = (int) (System.currentTimeMillis() / 1000);
    FunctionType funcType = FunctionType.JAVA;

    try {
      cleanUp(dbName, null, null);

      createDb(dbName);
View Full Code Here

Examples of org.apache.metamodel.query.FunctionType

        if ("COUNT(*)".equalsIgnoreCase(expression)) {
            return SelectItem.getCountAllItem();
        }

        final FunctionType function;
        final int startParenthesis = expression.indexOf('(');
        if (startParenthesis > 0 && expression.endsWith(")")) {
            String functionName = expression.substring(0, startParenthesis);
            function = FunctionType.get(functionName);
            if (function != null) {
View Full Code Here

Examples of org.apache.tajo.catalog.proto.CatalogProtos.FunctionType

        GeneralSetFunctionExpr setFunction = (GeneralSetFunctionExpr) expr;
        Expr[] params = setFunction.getParams();
        EvalNode[] givenArgs = new EvalNode[params.length];
        DataType[] paramTypes = new DataType[params.length];

        FunctionType functionType = setFunction.isDistinct() ?
            FunctionType.DISTINCT_AGGREGATION : FunctionType.AGGREGATION;
        givenArgs[0] = createEvalTree(plan, block, params[0]);
        if (setFunction.getSignature().equalsIgnoreCase("count")) {
          paramTypes[0] = CatalogUtil.newSimpleDataType(TajoDataTypes.Type.ANY);
        } else {
          paramTypes[0] = givenArgs[0].getValueType();
        }

        if (!catalog.containFunction(setFunction.getSignature(), functionType, paramTypes)) {
          throw new UndefinedFunctionException(CatalogUtil. getCanonicalName(setFunction.getSignature(), paramTypes));
        }

        FunctionDesc funcDesc = catalog.getFunction(setFunction.getSignature(), functionType, paramTypes);
        if (!block.hasGroupbyNode()) {
          block.setHasGrouping();
        }
        try {
          return new AggregationFunctionCallEval(funcDesc, (AggFunction) funcDesc.newInstance(), givenArgs);
        } catch (InternalException e) {
          e.printStackTrace();
        }
      }
      break;

      case Function:
        FunctionExpr function = (FunctionExpr) expr;
        // Given parameters
        Expr[] params = function.getParams();
        EvalNode[] givenArgs = new EvalNode[params.length];
        DataType[] paramTypes = new DataType[params.length];

        for (int i = 0; i < params.length; i++) {
            givenArgs[i] = createEvalTree(plan, block, params[i]);
            paramTypes[i] = givenArgs[i].getValueType();
        }

        if (!catalog.containFunction(function.getSignature(), paramTypes)) {
            throw new UndefinedFunctionException(CatalogUtil.getCanonicalName(function.getSignature(), paramTypes));
        }

        FunctionDesc funcDesc = catalog.getFunction(function.getSignature(), paramTypes);

        try {

          FunctionType functionType = funcDesc.getFuncType();
          if (functionType == FunctionType.GENERAL || functionType == FunctionType.UDF) {
            return new GeneralFunctionEval(funcDesc, (GeneralFunction) funcDesc.newInstance(), givenArgs);
          } else if (functionType == FunctionType.AGGREGATION || functionType == FunctionType.UDA) {
            if (!block.hasGroupbyNode()) {
              block.setHasGrouping();
View Full Code Here

Examples of org.dmg.pmml._40.FunctionType

   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setFunction(FunctionType newFunction) {
    FunctionType oldFunction = function;
    function = newFunction == null ? FUNCTION_EDEFAULT : newFunction;
    boolean oldFunctionESet = functionESet;
    functionESet = true;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, _40Package.AGGREGATE_TYPE__FUNCTION, oldFunction, function, !oldFunctionESet));
View Full Code Here

Examples of org.fenixedu.academic.domain.organizationalStructure.FunctionType

        super.gc();
    }

    public static PersistentUnitGroup getInstance(final Unit unit, final AccountabilityTypeEnum relationType,
            FunctionType relationFunctionType, final Boolean includeSubUnits) {
        final FunctionType relationFunctionType1 = relationFunctionType;
        return singleton(
                () -> unit
                        .getUnitGroupSet()
                        .stream()
                        .filter(group -> Objects.equals(group.getRelationType(), relationType)
View Full Code Here

Examples of org.jboss.security.xacml.core.model.policy.FunctionType

      permitRuleActionsType.getAction().add(permitRuleActionType);
      permitRuleTargetType.setActions(permitRuleActionsType);
      permitRule.setTarget(permitRuleTargetType);

      ConditionType permitRuleConditionType = new ConditionType();
      FunctionType functionType = new FunctionType();
      functionType.setFunctionId(XACMLConstants.FUNCTION_STRING_EQUAL);
      JAXBElement<ExpressionType> jaxbElementFunctionType = objectFactory.createExpression(functionType);
      permitRuleConditionType.setExpression(jaxbElementFunctionType);

      ApplyType permitRuleApplyType = new ApplyType();
      permitRuleApplyType.setFunctionId(XACMLConstants.FUNCTION_STRING_IS_IN);
View Full Code Here

Examples of org.opensaml.xacml.policy.FunctionType

   
    /** {@inheritDoc} */
    protected void processAttribute(XMLObject xmlObject, Attr attribute) throws UnmarshallingException {
       
        if(attribute.getLocalName().equals(FunctionType.FUNCTION_ID_ATTRIB_NAME)){
            FunctionType functionType = (FunctionType) xmlObject;
            functionType.setFunctionId(DatatypeHelper.safeTrimOrNullString(attribute.getValue()));
        } else {
            super.processAttribute(xmlObject, attribute);
        }

    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.