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