Module: URI::Component::QueryMixin

Defined in:
lib/uri/component/query.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#initialize_copy(uri) ⇒ Object



209
210
211
212
213
214
215
# File 'lib/uri/component/query.rb', line 209

def initialize_copy(uri)
	if (query = uri.instance_variable_get('@query_component'))
	  @query_component = query.dup
	end

	super(uri)
end

#queryObject



217
218
219
# File 'lib/uri/component/query.rb', line 217

def query
	return @query_component ? @query_component.to_uri : @query
end

#query=(query_str) ⇒ Object



221
222
223
224
225
226
# File 'lib/uri/component/query.rb', line 221

def query=(query_str)
	super(query_str)

	parse_query!
	return self.query
end

#query_componentObject Also known as: query_c



228
229
230
231
# File 'lib/uri/component/query.rb', line 228

def query_component
	parse_query! unless @query_component
	return @query_component
end