(InstanceScope scope, List<Object> list, Object o)
| 924 | } |
| 925 | |
| 926 | protected void addToList(InstanceScope scope, List<Object> list, Object o) { |
| 927 | o = convertAnythingIteratableToIterator(scope, o); |
| 928 | if ( o instanceof Iterator ) { |
| 929 | // copy of elements into our temp list |
| 930 | Iterator<?> it = (Iterator<?>)o; |
| 931 | while ( it.hasNext() ) list.add(it.next()); |
| 932 | } |
| 933 | else { |
| 934 | list.add(o); |
| 935 | } |
| 936 | } |
| 937 | |
| 938 | /** |
| 939 | * Return the first attribute if multi-valued, or the attribute itself if |
no test coverage detected