void resolve(EObject object, EReference reference, EObject proxy) {
   EReference opposite = reference.getEOpposite();
   if (opposite != null) {
     if (opposite.isMany()) {
       InternalEList<?> list = (InternalEList<?>) object.eGet(opposite, false);
       int index = list.basicIndexOf(proxy);
       if (index >= 0) {
         list.get(index); // resolve just this index
       }
     } else {
       object.eGet(opposite, true); // resolve the scalar reference
     }
   }
 }
 public int basicIndexOf(Object object) {
   return copy.basicIndexOf(object);
 }