Package java.util

Examples of java.util.ArrayList.addAll()


              for (ManagedObject mo : managedObjects) {
                list.add(buildAO(mo, mo.getAttachment().getClass()));
              }
            }
            else if (elementType == SimpleMetaType.STRING) {
              list.addAll((List<String>) MetaValueFactory.getInstance().unwrap(value));
            }
            else if (elementType.isComposite()) {
              list.addAll((List)MetaValueFactory.getInstance().unwrap(value));
            }
            else {
View Full Code Here


            }
            else if (elementType == SimpleMetaType.STRING) {
              list.addAll((List<String>) MetaValueFactory.getInstance().unwrap(value));
            }
            else if (elementType.isComposite()) {
              list.addAll((List)MetaValueFactory.getInstance().unwrap(value));
            }
            else {
              throw new TeiidRuntimeException("unsupported type"); //$NON-NLS-1$
            }
            PropertiesUtils.setBeanProperty(t, mp.getMappedName(), list);
View Full Code Here

    }

  @Override
    public List getSupportedFunctions() {
        List supportedFunctons = new ArrayList();
        supportedFunctons.addAll(super.getSupportedFunctions());
        supportedFunctons.add("CAST"); //$NON-NLS-1$
        supportedFunctons.add("CONVERT"); //$NON-NLS-1$
        return supportedFunctons;
    }
}
View Full Code Here

    public List<?> translate(Function function) {
        Expression expr1 =  function.getParameters().get(0);
        Expression expr2 =  function.getParameters().get(1);
        ArrayList target = new ArrayList();
        target.add("position("); //$NON-NLS-1$
        target.addAll(expressionToString(expr1, this.convertModifier));
        target.add( " in "); //$NON-NLS-1$
        target.addAll(expressionToString(expr2, this.convertModifier));
        target.add(")"); //$NON-NLS-1$
        return target;
    }
View Full Code Here

        Expression expr2 =  function.getParameters().get(1);
        ArrayList target = new ArrayList();
        target.add("position("); //$NON-NLS-1$
        target.addAll(expressionToString(expr1, this.convertModifier));
        target.add( " in "); //$NON-NLS-1$
        target.addAll(expressionToString(expr2, this.convertModifier));
        target.add(")"); //$NON-NLS-1$
        return target;
    }
  }
   
View Full Code Here

    public List<?> translate(Function function) {
      Expression expr = function.getParameters().get(0);
      ArrayList target = new ArrayList();
      target.add(this.funcName);
      target.add("("); //$NON-NLS-1$
      target.addAll(expressionToString(expr, this.convertModifier));
      target.add(")"); //$NON-NLS-1$
      return target;
    }
  }
   
View Full Code Here

            List<Expression> args = function.getParameters();
            ArrayList target = new ArrayList();
            if (function.getName().equalsIgnoreCase("left")) { //$NON-NLS-1$
              //substr(string, 1, length)
              target.add("substr("); //$NON-NLS-1$
              target.addAll(expressionToString(args.get(0), this.convertModifier));
              target.add(langFactory.createLiteral(Integer.valueOf(1), TypeFacility.RUNTIME_TYPES.INTEGER));
              target.add(args.get(1));
              target.add(")"); //$NON-NLS-1$
            } else if (function.getName().equalsIgnoreCase("right")) { //$NON-NLS-1$
              //substr(case_size, character_length(case_size) -4)
View Full Code Here

              target.add(args.get(1));
              target.add(")"); //$NON-NLS-1$
            } else if (function.getName().equalsIgnoreCase("right")) { //$NON-NLS-1$
              //substr(case_size, character_length(case_size) -4)
              target.add("substr("); //$NON-NLS-1$
              target.addAll(expressionToString(args.get(0), this.convertModifier));
             
              target.add(",(character_length("); //$NON-NLS-1$
              target.addAll(expressionToString(args.get(0), this.convertModifier));
              target.add(")-"); //$NON-NLS-1$
              target.add(args.get(1));
View Full Code Here

        this.resourceResolvers = resourceResolvers;
    }

    public List getDataSources() throws Exception {
        List resources = new ArrayList();
        resources.addAll(getPrivateDataSources());
        resources.addAll(getGlobalDataSources());
        return resources;
    }

    public List getPrivateDataSources() throws Exception {
View Full Code Here

    }

    public List getDataSources() throws Exception {
        List resources = new ArrayList();
        resources.addAll(getPrivateDataSources());
        resources.addAll(getGlobalDataSources());
        return resources;
    }

    public List getPrivateDataSources() throws Exception {
        List resources = new ArrayList();
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.