Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:127779 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by lists.php.net (Postfix) with ESMTPS id 5C1B61A00BC for ; Fri, 27 Jun 2025 22:25:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1751063034; bh=Be6n5fC6OwAeUqCzORDLfPTZC9wchSpv6p3s1aMm0pg=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=LPF3LLtEoIUqHnlKblk3vivvQ2KBEIDraSqZ2V0PgCwIidNmxyEpYviu+24WgxN+l rqW6j9ts+5URtbK/BB7TTmIqWxErlcBt/ifhe+TGtlxq9RzHzEapYpFY0ybwt94EFm 0gqHVqZ06eiXmEi4ez7x1f/i5Pajt9iPsqxkFiY0mB9Oh6z2nZIc37uxQ6zPgukqDU EAqGA3OphPL03ezir3AWMC7rdooxGP+CLdcVcDh/9/7jU6qGLKBAM1zwnBelncZmtJ cJtb49icNv7cEyWgXhOxe+km/kNlesCImqoJKDyHJtTrcWaMWLdmNsVwRrVPQiVYU/ SlAGY34/eFylQ== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 081071805CC for ; Fri, 27 Jun 2025 22:23:53 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=0.6 required=5.0 tests=BAYES_50,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_PASS,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=4.0.1 X-Spam-Virus: Error (Cannot connect to unix socket '/var/run/clamav/clamd.ctl': connect: Connection refused) X-Envelope-From: Received: from forward502b.mail.yandex.net (forward502b.mail.yandex.net [178.154.239.146]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Fri, 27 Jun 2025 22:23:52 +0000 (UTC) Received: from mail-nwsmtp-smtp-production-main-55.sas.yp-c.yandex.net (mail-nwsmtp-smtp-production-main-55.sas.yp-c.yandex.net [IPv6:2a02:6b8:c23:2da7:0:640:ace9:0]) by forward502b.mail.yandex.net (Yandex) with ESMTPS id 100EB6143A for ; Sat, 28 Jun 2025 01:25:44 +0300 (MSK) Received: by mail-nwsmtp-smtp-production-main-55.sas.yp-c.yandex.net (smtp/Yandex) with ESMTPSA id gPf0BJKL2Os0-pQWiKLhq; Sat, 28 Jun 2025 01:25:43 +0300 X-Yandex-Fwd: 1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=php.watch; s=mail; t=1751063143; bh=Be6n5fC6OwAeUqCzORDLfPTZC9wchSpv6p3s1aMm0pg=; h=To:Subject:Message-ID:References:Date:From:Cc:In-Reply-To; b=f7cWoFSZh3mcISE0b7wtRZNEgu/ckiJyaP6g3z8PeP0qVc2g/3fq0+S63ZVycjqPu 2EwQ0oHKcrBsjQoTshhWg+o4qDzP6H7sUPEV512Sdlhfqlh7s3nMYCYm5YynB2hKqM +ksjxW4TuMVyvylk9VUlE4kv1s2Zor0ZM6HEQ7gg= Authentication-Results: mail-nwsmtp-smtp-production-main-55.sas.yp-c.yandex.net; dkim=pass header.i=@php.watch Received: by mail-ed1-f43.google.com with SMTP id 4fb4d7f45d1cf-60c01f70092so4285076a12.3 for ; Fri, 27 Jun 2025 15:25:43 -0700 (PDT) X-Forwarded-Encrypted: i=1; AJvYcCUDWpWutL4h/9NBVkj2rscV2fJxatLxg4uz54DR/wH3scaOpOtIX3IZoxyCEtaUWcp3UhB8YkmF0L8=@lists.php.net X-Gm-Message-State: AOJu0YwL7tmcbe+PVGLwHnPgTeyubi1QOFOaWj9JadbqAbZ6J3h7hpct kYhDl07wgrdTpl3KSeYUKtf+/Ip+OzQrsGBqBRmIKGtYsWE97PFDJGn38KXy5NmSdaqW0OvWsIP wOyAvYUkF3aETfeYY4CY/JEJ9MSY50Kw= X-Google-Smtp-Source: AGHT+IH0QN6qLXZ4D6q1rjtxr+GQ1ZUM51HcAdnLadeYZ117sVVzULEHv53gqLdxGDBzAoTUAt3DuOUp+3weSGeJ1uY= X-Received: by 2002:a05:6402:254f:b0:602:ddbe:480f with SMTP id 4fb4d7f45d1cf-60c88b1fa3emr3810569a12.9.1751063142666; Fri, 27 Jun 2025 15:25:42 -0700 (PDT) Precedence: bulk list-help: list-post: List-Id: internals.lists.php.net x-ms-reactions: disallow MIME-Version: 1.0 References: In-Reply-To: Date: Sat, 28 Jun 2025 03:55:15 +0530 X-Gmail-Original-Message-ID: X-Gm-Features: Ac12FXymXVAGOSGBhfz0i04G4c-QIqPpFyXK-hYuVqZnnTsf2EwoVzh2dJ-s4s4 Message-ID: Subject: Re: [PHP-DEV] [RFC][DISCUSSION] Object-oriented curl API v2 To: Nicolas Grekas Cc: erictnorris@gmail.com, PHP internals Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable From: ayesh@php.watch (Ayesh Karunaratne) > I'm not even sure it's a good idea to add those namespaced options: using= CURLOPT_SSL_VERIFYHOST is perfect to find the corresponding curl documenta= tion with your favorite search engine. php's doc is awesome, but it cannot = compete with the details provided by curl's doc on the topic. > > Nicolas Hi Nicolas, You are right, if we were to rename those constants, we would lose the "grep-ability" in both libcurl source/docs and many years of existing open source projects and discussions. So while keeping the existing option consts, info consts, we do not have a lot of room to improve it. Perhaps the `CurlHandle` objects can accept options similar to how we have `date_*` functions alongside `DateTime` methods. I personally continue to use the functions, but I won't mind having an OOP API. We can leave it to the library authors (such as you, Nicolas =F0=9F=92=9F, Symfony HTTP client is just awesome) to design more intuitive APIs. Ayesh.