Package java.util

Examples of java.util.Collection.addAll()


        }

        final Collection exceptions = new ArrayList();
        for (final Iterator iterator = this.getAllowedOperations().iterator(); iterator.hasNext();)
        {
            exceptions.addAll(((OperationFacade)iterator.next()).getExceptions());
        }

        types.addAll(exceptions);

        // now since we're at the end, and we know the
View Full Code Here


            {
                public void execute(Object object)
                {
                    if (object != null && ServiceOperation.class.isAssignableFrom(object.getClass()))
                    {
                        roles.addAll(((ServiceOperation)object).getRoles());
                    }
                }
            });
        return roles;
    }
View Full Code Here

        // collect the exceptions of all allowed operations into a single set
        for (Iterator i = this.getAllowedOperations().iterator(); i.hasNext();)
        {
            final OperationFacade operation = (OperationFacade)i.next();
            exceptions.addAll(operation.getExceptions());
        }

        return exceptions;
    }
}
View Full Code Here

            {
                public void execute(Object object)
                {
                    if (object != null && Service.class.isAssignableFrom(object.getClass()))
                    {
                        allRoles.addAll(((Service)object).getAllRoles());
                    }
                }
            });
        return allRoles;
    }
View Full Code Here

      //System.out.println("CollectionDescriptor.setPropertyValue2(" + value + ")" );
      if( value instanceof Collection )
      {
        if( type != null )
          // Check the type before adding
          col.addAll( new UnmodifiableFilteredCollection( (Collection)value, new TypeFilter(request) ) );
        else
          col.addAll( (Collection)value);
      }
      else
      {
View Full Code Here

      {
        if( type != null )
          // Check the type before adding
          col.addAll( new UnmodifiableFilteredCollection( (Collection)value, new TypeFilter(request) ) );
        else
          col.addAll( (Collection)value);
      }
      else
      {
        // Check the type
        if( ! isOfSpecifiedType(value, request) )
View Full Code Here

      }
      Collection listeners = (Collection) _listeners.get(_state);
      Collection listeners999 = (Collection) _listeners.get(999);
      Collection allListeners = new HashSet();
      if (listeners != null)
        allListeners.addAll(listeners);
      if (listeners999 != null)
        allListeners.addAll(listeners999);

      for (Iterator it = allListeners.iterator(); it.hasNext();)
      {
View Full Code Here

      Collection listeners999 = (Collection) _listeners.get(999);
      Collection allListeners = new HashSet();
      if (listeners != null)
        allListeners.addAll(listeners);
      if (listeners999 != null)
        allListeners.addAll(listeners999);

      for (Iterator it = allListeners.iterator(); it.hasNext();)
      {
        StateChangeListener listener = (StateChangeListener) it.next();
        if (listener != null)
View Full Code Here

  @Override
  public Collection cast(Collection src, Class<?> toType, String... args)
      throws FailToCastObjectException {
    Collection coll = createCollection(src, toType);
    coll.addAll(src);
    return coll;
  }

}
View Full Code Here

                }
                return array;
            }
            else if (Collection.class.isAssignableFrom(toType)) {
                Collection collection = allocateCollection(toType);
                collection.addAll((Collection) object);
                return unmodifiableCollection(collection);
            }
            else if (length == 1) {
                Object value;
                if (object instanceof List) {
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.