Examples of LinkedHashSet


Examples of java.util.LinkedHashSet

          copy = (Expression) getExpression().clone();
     
     
      Collection copyValues = null;
      if (isAllConstants()) {
        copyValues = new LinkedHashSet(values);
      } else {
        copyValues = LanguageObject.Util.deepClone(new ArrayList(values), Expression.class);
      }
     
        SetCriteria criteriaCopy = new SetCriteria(copy, copyValues);
View Full Code Here

Examples of java.util.LinkedHashSet

            return UNKNOWN_CRITERIA;
        }

    Collection vals = criteria.getValues();

        LinkedHashSet newVals = new LinkedHashSet(vals.size());
        Iterator valIter = vals.iterator();
        boolean allConstants = true;
        boolean hasNull = false;
        while(valIter.hasNext()) {
            Expression value = rewriteExpressionDirect( (Expression) valIter.next());
            if (isNull(value)) {
              hasNull = true;
              continue;
            }
            allConstants &= value instanceof Constant;
            newVals.add(value);
        }
       
        int size = newVals.size();
        if (size == 1) {
            Expression value = (Expression)newVals.iterator().next();
            return rewriteCriteria(new CompareCriteria(criteria.getExpression(), criteria.isNegated()?CompareCriteria.NE:CompareCriteria.EQ, value));
        }
       
        criteria.setValues(newVals);
        if (allConstants) {
View Full Code Here

Examples of java.util.LinkedHashSet

       
        ResultSetInfo rsInfo = contextNode.getResultSetInfo();
       
        // this list of all the source nodes below the context, which are directly ro indirectly
        // involved in the criteria
        LinkedHashSet resultSets = new LinkedHashSet();
       
        boolean singleParentage = getResultSets(contextNode, rsInfo.getCriteriaResultSets(), resultSets);
       
        Query contextQuery = null;
       
        if (rsInfo.isCriteriaRaised()) {
            contextQuery = (Query)QueryUtil.getQueryFromQueryNode(rsInfo.getResultSetName(), planEnv);
            String inlineViewName = planEnv.getAliasName(rsInfo.getResultSetName());
            updateSymbolMap(symbolMap, rsInfo.getResultSetName(), inlineViewName, planEnv.getGlobalMetadata());
        } else {
            contextQuery = (Query)rsInfo.getCommand();
        }
       
        Query currentQuery = contextQuery;
       
        for (Iterator i = resultSets.iterator(); i.hasNext();) {
            MappingSourceNode rsNode = (MappingSourceNode)i.next();
           
            ResultSetInfo childRsInfo = rsNode.getResultSetInfo();
           
            QueryNode planNode = QueryUtil.getQueryNode(childRsInfo.getResultSetName(), planEnv.getGlobalMetadata());   
View Full Code Here

Examples of java.util.LinkedHashSet

    Iterator iterator = valueObjects.iterator();
    if (iterator.hasNext()) {
      Object valueObject = iterator.next();
      ReflectionInfo info = getReflectionInfo(valueObject);
     
      Set valueRows = new LinkedHashSet();
      valueRows.add(new ValueObjectTableRow(info, valueObject));

      while (iterator.hasNext()) {
        valueRows.add(new ValueObjectTableRow(info, iterator.next()));
      }
     
      insertRows(null, index, valueRows);
    }
  }
View Full Code Here

Examples of java.util.LinkedHashSet

    }

    protected List handleGetIncomingActions()
    {
        final List incomingActionsList = new ArrayList();
        collectIncomingActions(this, new LinkedHashSet(), incomingActionsList);
        return incomingActionsList;
    }
View Full Code Here

Examples of java.util.LinkedHashSet

     * @param clazz the class to retrieve the methods.
     * @return the loaded methods.
     */
    public static List getAllMethods(final Class clazz)
    {
        final Set methods = new LinkedHashSet();
        loadMethods(clazz, methods);
        return new ArrayList(methods);
    }
View Full Code Here

Examples of java.util.LinkedHashSet

     * Initializes all action states, action forwards, decision transitions and transitions in one shot, so that they
     * can be queried more effiencently later on.
     */
    private void initializeCollections()
    {
        this.actionStates = new LinkedHashSet();
        this.collectTransitions(
            this,
            new LinkedHashSet());
    }
View Full Code Here

Examples of java.util.LinkedHashSet

    /**
     * @see org.andromda.metafacades.uml.FrontEndAction#getActions()
     */
    protected java.util.List handleGetActions()
    {
        final Set actions = new LinkedHashSet();
        this.findActions(
            actions,
            new LinkedHashSet());
        return new ArrayList(actions);
    }
View Full Code Here

Examples of java.util.LinkedHashSet

    /**
     * @see org.andromda.metafacades.uml.GeneralizableElementFacade#getAllSpecializations()
     */
    protected Collection handleGetAllSpecializations()
    {
        final Set allSpecializations = new LinkedHashSet();
        if (this.getSpecializations() != null)
        {
            allSpecializations.addAll(this.getSpecializations());
            for (final Iterator iterator = this.getSpecializations().iterator(); iterator.hasNext();)
            {
                final GeneralizableElementFacade element = (GeneralizableElementFacade)iterator.next();
                allSpecializations.addAll(element.getAllSpecializations());
            }
        }
        return allSpecializations;
    }
View Full Code Here

Examples of java.util.LinkedHashSet

    /**
     * @see org.andromda.metafacades.uml.FrontEndPseudostate#getContainerActions()
     */
    protected List handleGetContainerActions()
    {
        final Collection actionSet = new LinkedHashSet();
        final StateMachineFacade graphContext = getStateMachine();

        if (graphContext instanceof ActivityGraphFacade)
        {
            final UseCaseFacade useCase = ((ActivityGraphFacade)graphContext).getUseCase();

            if (useCase instanceof FrontEndUseCase)
            {
                for (
                    final Iterator actionIterator = ((FrontEndUseCase)useCase).getActions().iterator();
                    actionIterator.hasNext();)
                {
                    final FrontEndAction action = (FrontEndAction)actionIterator.next();
                    final Collection transitions = action.getTransitions();
                    for (final Iterator transitionIterator = transitions.iterator(); transitionIterator.hasNext();)
                    {
                        TransitionFacade transition = (TransitionFacade)transitionIterator.next();
                        if (this.equals(transition.getTarget()))
                        {
                            actionSet.add(action);
                        }
                    }
                }
            }
        }
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.