/** * Filter the query by a related PedidoProveedor object * * @param PedidoProveedor|PropelObjectCollection $pedidoProveedor the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return UsuarioQuery The current query, for fluid interface * @throws PropelException - if the provided filter is invalid. */ public function filterByPedidoProveedor($pedidoProveedor, $comparison = null) { if ($pedidoProveedor instanceof PedidoProveedor) { return $this->addUsingAlias(UsuarioPeer::ID, $pedidoProveedor->getUsuarioId(), $comparison); } elseif ($pedidoProveedor instanceof PropelObjectCollection) { return $this->usePedidoProveedorQuery()->filterByPrimaryKeys($pedidoProveedor->getPrimaryKeys())->endUse(); } else { throw new PropelException('filterByPedidoProveedor() only accepts arguments of type PedidoProveedor or PropelCollection'); } }