HEX
Server: Apache
System: Linux s198.coreserver.jp 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC 2025 x86_64
User: nagasaki (10062)
PHP: 7.1.33
Disabled: NONE
Upload Files
File: //usr/local/rvm/gems/ruby-2.7.4/doc/globalid-0.5.2/ri/GlobalID/Locator/use-c.ri
U:RDoc::AnyMethod[iI"use:ETI"GlobalID::Locator::use;TT:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph;	[I"Tie a locator to an app. ;TI"RUseful when different apps collaborate and reference each others' Global IDs.;To:RDoc::Markup::BlankLineo;
;	[I"2The locator can be either a block or a class.;T@o;
;	[I"Using a block:;T@o:RDoc::Markup::Verbatim;	[I")GlobalID::Locator.use :foo do |gid|
;TI">  FooRemote.const_get(gid.model_name).find(gid.model_id)
;TI"	end
;T:@format0o;
;	[I"Using a class:;T@o;;	[I"0GlobalID::Locator.use :bar, BarLocator.new
;TI"
;TI"class BarLocator
;TI"  def locate(gid)
;TI"F    @search_client.search name: gid.model_name, id: gid.model_id
;TI"  end
;TI"end;T;
0:
@fileI"lib/global_id/locator.rb;T:0@omit_headings_from_table_of_contents_below000[I")(app, locator = nil, &locator_block);T@'FI"Locator;TcRDoc::NormalModule00