module Patron
Constants
- VERSION
Public Class Methods
Source
static VALUE libcurl_version(VALUE klass) {
char* value = curl_version();
UNUSED_ARGUMENT(klass);
return rb_str_new2(value);
}
Returns the version of the embedded libcurl.
@return [String] libcurl version string
Source
static VALUE libcurl_version_exact(VALUE klass) {
UNUSED_ARGUMENT(klass);
VALUE cv_major = INT2FIX(LIBCURL_VERSION_MAJOR);
VALUE cv_minor = INT2FIX(LIBCURL_VERSION_MINOR);
VALUE cv_patch = INT2FIX(LIBCURL_VERSION_PATCH);
VALUE version_arr = rb_ary_new3(3, cv_major, cv_minor, cv_patch);
return version_arr;
}
Returns the version of the embedded libcurl.
@return [Array] an array of MAJOR, MINOR, PATCH integers
Source
# File lib/patron.rb, line 17 def self.user_agent_string @ua ||= "Patron/Ruby-%s-%s" % [version, libcurl_version] end
Returns the default User-Agent string @return [String]
Source
# File lib/patron.rb, line 11 def self.version VERSION end
Returns the version number of the gem @return [String]