public DataObjectModel view(Collection<? extends DataObject> dos)
    {
        DataObjectModel view = clone();
        view.propertyList = new ArrayList<String>();
        Set<String> propertySet = new HashSet<String>();
        for (DataObject dob : dos)
        {
            for (String property : propertyList)    // TODO performance
            {
                Object value = dob.get(property);
                if (value != null)
                {
                    propertySet.add(property);
                }
            }
        }
        for (String property : propertyList)
        {
            if (propertySet.contains(property))
            {
                view.propertyList.add(property);
            }
        }
        return view;
    }
public DataObjectModel view ( Collection < ? extends DataObject > dos ) { DataObjectModel view = clone ( ) ; view . propertyList = new ArrayList < String > ( ) ; Set < String > propertySet = new HashSet < String > ( ) ; for ( DataObject dob : dos ) { for ( String property : propertyList ) { Object value = dob . get ( property ) ; if ( value != null ) { propertySet . add ( property ) ; } } } for ( String property : propertyList ) { if ( propertySet . contains ( property ) ) { view . propertyList . add ( property ) ; } } return view ; }
Returns a clone of this model where only properties that have values are present
@param dos
@return