(InstanceScope scope, List<Object> list, Object o)
| 948 | } |
| 949 | |
| 950 | protected void addToList(InstanceScope scope, List<Object> list, Object o) { |
| 951 | o = convertAnythingIteratableToIterator(scope, o); |
| 952 | if ( o instanceof Iterator) { |
| 953 | // copy of elements into our temp list |
| 954 | Iterator<?> it = (Iterator<?>)o; |
| 955 | while ( it.hasNext() ) list.add(it.next()); |
| 956 | } |
| 957 | else { |
| 958 | list.add(o); |
| 959 | } |
| 960 | } |
| 961 | |
| 962 | /** |
| 963 | * Return the first attribute if multi-valued, or the attribute itself if |
no test coverage detected