encoded_id-rails 1.0.0.beta3 → 1.0.0.rc6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +77 -18
- data/LICENSE.txt +1 -1
- data/README.md +77 -368
- data/context/encoded_id-rails.md +433 -0
- data/context/encoded_id.md +283 -0
- data/lib/encoded_id/rails/active_record_finders.rb +52 -0
- data/lib/encoded_id/rails/annotated_id.rb +8 -0
- data/lib/encoded_id/rails/annotated_id_parser.rb +8 -1
- data/lib/encoded_id/rails/coder.rb +20 -2
- data/lib/encoded_id/rails/configuration.rb +45 -3
- data/lib/encoded_id/rails/encoder_methods.rb +9 -1
- data/lib/encoded_id/rails/finder_methods.rb +10 -0
- data/lib/encoded_id/rails/model.rb +65 -8
- data/lib/encoded_id/rails/path_param.rb +7 -0
- data/lib/encoded_id/rails/persists.rb +120 -0
- data/lib/encoded_id/rails/query_methods.rb +20 -4
- data/lib/encoded_id/rails/railtie.rb +13 -0
- data/lib/encoded_id/rails/salt.rb +7 -0
- data/lib/encoded_id/rails/slugged_id.rb +8 -0
- data/lib/encoded_id/rails/slugged_id_parser.rb +8 -1
- data/lib/encoded_id/rails/slugged_path_param.rb +7 -0
- data/lib/encoded_id/rails.rb +10 -6
- data/lib/generators/encoded_id/rails/USAGE +4 -0
- data/lib/generators/encoded_id/rails/add_columns_generator.rb +45 -0
- data/lib/generators/encoded_id/rails/templates/add_encoded_id_columns_migration.rb.erb +16 -0
- data/lib/generators/encoded_id/rails/templates/encoded_id.rb +28 -0
- metadata +27 -52
- data/.standard.yml +0 -3
- data/Appraisals +0 -14
- data/Gemfile +0 -18
- data/Rakefile +0 -14
- data/Steepfile +0 -4
- data/gemfiles/.bundle/config +0 -2
- data/gemfiles/rails_6.1.gemfile +0 -16
- data/gemfiles/rails_6.1.gemfile.lock +0 -130
- data/gemfiles/rails_7.0.gemfile +0 -16
- data/gemfiles/rails_7.0.gemfile.lock +0 -128
- data/gemfiles/rails_7.1.gemfile +0 -16
- data/gemfiles/rails_7.1.gemfile.lock +0 -140
- data/lib/encoded_id/rails/version.rb +0 -7
- data/rbs_collection.yaml +0 -24
- data/sig/encoded_id/rails.rbs +0 -141
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
PATH
|
|
2
|
-
remote: ..
|
|
3
|
-
specs:
|
|
4
|
-
encoded_id-rails (1.0.0.beta2)
|
|
5
|
-
activerecord (>= 6.0, < 8.0)
|
|
6
|
-
activesupport (>= 6.0, < 8.0)
|
|
7
|
-
encoded_id (~> 1.0.0.rc4)
|
|
8
|
-
|
|
9
|
-
GEM
|
|
10
|
-
remote: https://rubygems.org/
|
|
11
|
-
specs:
|
|
12
|
-
abbrev (0.1.2)
|
|
13
|
-
activemodel (7.0.8.1)
|
|
14
|
-
activesupport (= 7.0.8.1)
|
|
15
|
-
activerecord (7.0.8.1)
|
|
16
|
-
activemodel (= 7.0.8.1)
|
|
17
|
-
activesupport (= 7.0.8.1)
|
|
18
|
-
activesupport (7.0.8.1)
|
|
19
|
-
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
20
|
-
i18n (>= 1.6, < 2)
|
|
21
|
-
minitest (>= 5.1)
|
|
22
|
-
tzinfo (~> 2.0)
|
|
23
|
-
appraisal (2.5.0)
|
|
24
|
-
bundler
|
|
25
|
-
rake
|
|
26
|
-
thor (>= 0.14.0)
|
|
27
|
-
ast (2.4.2)
|
|
28
|
-
concurrent-ruby (1.2.3)
|
|
29
|
-
csv (3.3.0)
|
|
30
|
-
encoded_id (1.0.0.rc4)
|
|
31
|
-
hashids (~> 1.0)
|
|
32
|
-
ffi (1.16.3)
|
|
33
|
-
fileutils (1.7.2)
|
|
34
|
-
hashids (1.0.6)
|
|
35
|
-
i18n (1.14.4)
|
|
36
|
-
concurrent-ruby (~> 1.0)
|
|
37
|
-
json (2.7.2)
|
|
38
|
-
language_server-protocol (3.17.0.3)
|
|
39
|
-
lint_roller (1.1.0)
|
|
40
|
-
listen (3.9.0)
|
|
41
|
-
rb-fsevent (~> 0.10, >= 0.10.3)
|
|
42
|
-
rb-inotify (~> 0.9, >= 0.9.10)
|
|
43
|
-
logger (1.6.0)
|
|
44
|
-
minitest (5.22.3)
|
|
45
|
-
parallel (1.24.0)
|
|
46
|
-
parser (3.3.1.0)
|
|
47
|
-
ast (~> 2.4.1)
|
|
48
|
-
racc
|
|
49
|
-
racc (1.7.3)
|
|
50
|
-
rainbow (3.1.1)
|
|
51
|
-
rake (13.2.1)
|
|
52
|
-
rb-fsevent (0.11.2)
|
|
53
|
-
rb-inotify (0.10.1)
|
|
54
|
-
ffi (~> 1.0)
|
|
55
|
-
rbs (3.4.4)
|
|
56
|
-
abbrev
|
|
57
|
-
regexp_parser (2.9.0)
|
|
58
|
-
rexml (3.2.6)
|
|
59
|
-
rubocop (1.62.1)
|
|
60
|
-
json (~> 2.3)
|
|
61
|
-
language_server-protocol (>= 3.17.0)
|
|
62
|
-
parallel (~> 1.10)
|
|
63
|
-
parser (>= 3.3.0.2)
|
|
64
|
-
rainbow (>= 2.2.2, < 4.0)
|
|
65
|
-
regexp_parser (>= 1.8, < 3.0)
|
|
66
|
-
rexml (>= 3.2.5, < 4.0)
|
|
67
|
-
rubocop-ast (>= 1.31.1, < 2.0)
|
|
68
|
-
ruby-progressbar (~> 1.7)
|
|
69
|
-
unicode-display_width (>= 2.4.0, < 3.0)
|
|
70
|
-
rubocop-ast (1.31.3)
|
|
71
|
-
parser (>= 3.3.1.0)
|
|
72
|
-
rubocop-performance (1.20.2)
|
|
73
|
-
rubocop (>= 1.48.1, < 2.0)
|
|
74
|
-
rubocop-ast (>= 1.30.0, < 2.0)
|
|
75
|
-
ruby-progressbar (1.13.0)
|
|
76
|
-
securerandom (0.3.1)
|
|
77
|
-
sqlite3 (1.7.3-arm64-darwin)
|
|
78
|
-
standard (1.35.1)
|
|
79
|
-
language_server-protocol (~> 3.17.0.2)
|
|
80
|
-
lint_roller (~> 1.0)
|
|
81
|
-
rubocop (~> 1.62.0)
|
|
82
|
-
standard-custom (~> 1.0.0)
|
|
83
|
-
standard-performance (~> 1.3)
|
|
84
|
-
standard-custom (1.0.2)
|
|
85
|
-
lint_roller (~> 1.0)
|
|
86
|
-
rubocop (~> 1.50)
|
|
87
|
-
standard-performance (1.3.1)
|
|
88
|
-
lint_roller (~> 1.1)
|
|
89
|
-
rubocop-performance (~> 1.20.2)
|
|
90
|
-
steep (1.6.0)
|
|
91
|
-
activesupport (>= 5.1)
|
|
92
|
-
concurrent-ruby (>= 1.1.10)
|
|
93
|
-
csv (>= 3.0.9)
|
|
94
|
-
fileutils (>= 1.1.0)
|
|
95
|
-
json (>= 2.1.0)
|
|
96
|
-
language_server-protocol (>= 3.15, < 4.0)
|
|
97
|
-
listen (~> 3.0)
|
|
98
|
-
logger (>= 1.3.0)
|
|
99
|
-
parser (>= 3.1)
|
|
100
|
-
rainbow (>= 2.2.2, < 4.0)
|
|
101
|
-
rbs (>= 3.1.0)
|
|
102
|
-
securerandom (>= 0.1)
|
|
103
|
-
strscan (>= 1.0.0)
|
|
104
|
-
terminal-table (>= 2, < 4)
|
|
105
|
-
strscan (3.1.0)
|
|
106
|
-
terminal-table (3.0.2)
|
|
107
|
-
unicode-display_width (>= 1.1.1, < 3)
|
|
108
|
-
thor (1.3.1)
|
|
109
|
-
tzinfo (2.0.6)
|
|
110
|
-
concurrent-ruby (~> 1.0)
|
|
111
|
-
unicode-display_width (2.5.0)
|
|
112
|
-
|
|
113
|
-
PLATFORMS
|
|
114
|
-
arm64-darwin-23
|
|
115
|
-
|
|
116
|
-
DEPENDENCIES
|
|
117
|
-
activerecord (~> 7.0.4)
|
|
118
|
-
activesupport (~> 7.0.4)
|
|
119
|
-
appraisal
|
|
120
|
-
encoded_id-rails!
|
|
121
|
-
minitest (~> 5.0)
|
|
122
|
-
rake (~> 13.0)
|
|
123
|
-
sqlite3 (~> 1.5)
|
|
124
|
-
standard (~> 1.30)
|
|
125
|
-
steep (~> 1.5)
|
|
126
|
-
|
|
127
|
-
BUNDLED WITH
|
|
128
|
-
2.3.26
|
data/gemfiles/rails_7.1.gemfile
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
# This file was generated by Appraisal
|
|
2
|
-
|
|
3
|
-
source "https://rubygems.org"
|
|
4
|
-
|
|
5
|
-
gem "activesupport", "~> 7.1"
|
|
6
|
-
gem "activerecord", "~> 7.1"
|
|
7
|
-
|
|
8
|
-
group :development, :test do
|
|
9
|
-
gem "rake", "~> 13.0"
|
|
10
|
-
gem "minitest", "~> 5.0"
|
|
11
|
-
gem "standard", "~> 1.30"
|
|
12
|
-
gem "steep", "~> 1.5"
|
|
13
|
-
gem "sqlite3", "~> 1.5"
|
|
14
|
-
end
|
|
15
|
-
|
|
16
|
-
gemspec path: "../"
|
|
@@ -1,140 +0,0 @@
|
|
|
1
|
-
PATH
|
|
2
|
-
remote: ..
|
|
3
|
-
specs:
|
|
4
|
-
encoded_id-rails (1.0.0.beta2)
|
|
5
|
-
activerecord (>= 6.0, < 8.0)
|
|
6
|
-
activesupport (>= 6.0, < 8.0)
|
|
7
|
-
encoded_id (~> 1.0.0.rc4)
|
|
8
|
-
|
|
9
|
-
GEM
|
|
10
|
-
remote: https://rubygems.org/
|
|
11
|
-
specs:
|
|
12
|
-
abbrev (0.1.2)
|
|
13
|
-
activemodel (7.1.3.2)
|
|
14
|
-
activesupport (= 7.1.3.2)
|
|
15
|
-
activerecord (7.1.3.2)
|
|
16
|
-
activemodel (= 7.1.3.2)
|
|
17
|
-
activesupport (= 7.1.3.2)
|
|
18
|
-
timeout (>= 0.4.0)
|
|
19
|
-
activesupport (7.1.3.2)
|
|
20
|
-
base64
|
|
21
|
-
bigdecimal
|
|
22
|
-
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
23
|
-
connection_pool (>= 2.2.5)
|
|
24
|
-
drb
|
|
25
|
-
i18n (>= 1.6, < 2)
|
|
26
|
-
minitest (>= 5.1)
|
|
27
|
-
mutex_m
|
|
28
|
-
tzinfo (~> 2.0)
|
|
29
|
-
appraisal (2.5.0)
|
|
30
|
-
bundler
|
|
31
|
-
rake
|
|
32
|
-
thor (>= 0.14.0)
|
|
33
|
-
ast (2.4.2)
|
|
34
|
-
base64 (0.2.0)
|
|
35
|
-
bigdecimal (3.1.7)
|
|
36
|
-
concurrent-ruby (1.2.3)
|
|
37
|
-
connection_pool (2.4.1)
|
|
38
|
-
csv (3.3.0)
|
|
39
|
-
drb (2.2.1)
|
|
40
|
-
encoded_id (1.0.0.rc4)
|
|
41
|
-
hashids (~> 1.0)
|
|
42
|
-
ffi (1.16.3)
|
|
43
|
-
fileutils (1.7.2)
|
|
44
|
-
hashids (1.0.6)
|
|
45
|
-
i18n (1.14.4)
|
|
46
|
-
concurrent-ruby (~> 1.0)
|
|
47
|
-
json (2.7.2)
|
|
48
|
-
language_server-protocol (3.17.0.3)
|
|
49
|
-
lint_roller (1.1.0)
|
|
50
|
-
listen (3.9.0)
|
|
51
|
-
rb-fsevent (~> 0.10, >= 0.10.3)
|
|
52
|
-
rb-inotify (~> 0.9, >= 0.9.10)
|
|
53
|
-
logger (1.6.0)
|
|
54
|
-
minitest (5.22.3)
|
|
55
|
-
mutex_m (0.2.0)
|
|
56
|
-
parallel (1.24.0)
|
|
57
|
-
parser (3.3.1.0)
|
|
58
|
-
ast (~> 2.4.1)
|
|
59
|
-
racc
|
|
60
|
-
racc (1.7.3)
|
|
61
|
-
rainbow (3.1.1)
|
|
62
|
-
rake (13.2.1)
|
|
63
|
-
rb-fsevent (0.11.2)
|
|
64
|
-
rb-inotify (0.10.1)
|
|
65
|
-
ffi (~> 1.0)
|
|
66
|
-
rbs (3.4.4)
|
|
67
|
-
abbrev
|
|
68
|
-
regexp_parser (2.9.0)
|
|
69
|
-
rexml (3.2.6)
|
|
70
|
-
rubocop (1.62.1)
|
|
71
|
-
json (~> 2.3)
|
|
72
|
-
language_server-protocol (>= 3.17.0)
|
|
73
|
-
parallel (~> 1.10)
|
|
74
|
-
parser (>= 3.3.0.2)
|
|
75
|
-
rainbow (>= 2.2.2, < 4.0)
|
|
76
|
-
regexp_parser (>= 1.8, < 3.0)
|
|
77
|
-
rexml (>= 3.2.5, < 4.0)
|
|
78
|
-
rubocop-ast (>= 1.31.1, < 2.0)
|
|
79
|
-
ruby-progressbar (~> 1.7)
|
|
80
|
-
unicode-display_width (>= 2.4.0, < 3.0)
|
|
81
|
-
rubocop-ast (1.31.3)
|
|
82
|
-
parser (>= 3.3.1.0)
|
|
83
|
-
rubocop-performance (1.20.2)
|
|
84
|
-
rubocop (>= 1.48.1, < 2.0)
|
|
85
|
-
rubocop-ast (>= 1.30.0, < 2.0)
|
|
86
|
-
ruby-progressbar (1.13.0)
|
|
87
|
-
securerandom (0.3.1)
|
|
88
|
-
sqlite3 (1.7.3-arm64-darwin)
|
|
89
|
-
standard (1.35.1)
|
|
90
|
-
language_server-protocol (~> 3.17.0.2)
|
|
91
|
-
lint_roller (~> 1.0)
|
|
92
|
-
rubocop (~> 1.62.0)
|
|
93
|
-
standard-custom (~> 1.0.0)
|
|
94
|
-
standard-performance (~> 1.3)
|
|
95
|
-
standard-custom (1.0.2)
|
|
96
|
-
lint_roller (~> 1.0)
|
|
97
|
-
rubocop (~> 1.50)
|
|
98
|
-
standard-performance (1.3.1)
|
|
99
|
-
lint_roller (~> 1.1)
|
|
100
|
-
rubocop-performance (~> 1.20.2)
|
|
101
|
-
steep (1.6.0)
|
|
102
|
-
activesupport (>= 5.1)
|
|
103
|
-
concurrent-ruby (>= 1.1.10)
|
|
104
|
-
csv (>= 3.0.9)
|
|
105
|
-
fileutils (>= 1.1.0)
|
|
106
|
-
json (>= 2.1.0)
|
|
107
|
-
language_server-protocol (>= 3.15, < 4.0)
|
|
108
|
-
listen (~> 3.0)
|
|
109
|
-
logger (>= 1.3.0)
|
|
110
|
-
parser (>= 3.1)
|
|
111
|
-
rainbow (>= 2.2.2, < 4.0)
|
|
112
|
-
rbs (>= 3.1.0)
|
|
113
|
-
securerandom (>= 0.1)
|
|
114
|
-
strscan (>= 1.0.0)
|
|
115
|
-
terminal-table (>= 2, < 4)
|
|
116
|
-
strscan (3.1.0)
|
|
117
|
-
terminal-table (3.0.2)
|
|
118
|
-
unicode-display_width (>= 1.1.1, < 3)
|
|
119
|
-
thor (1.3.1)
|
|
120
|
-
timeout (0.4.1)
|
|
121
|
-
tzinfo (2.0.6)
|
|
122
|
-
concurrent-ruby (~> 1.0)
|
|
123
|
-
unicode-display_width (2.5.0)
|
|
124
|
-
|
|
125
|
-
PLATFORMS
|
|
126
|
-
arm64-darwin-23
|
|
127
|
-
|
|
128
|
-
DEPENDENCIES
|
|
129
|
-
activerecord (~> 7.1)
|
|
130
|
-
activesupport (~> 7.1)
|
|
131
|
-
appraisal
|
|
132
|
-
encoded_id-rails!
|
|
133
|
-
minitest (~> 5.0)
|
|
134
|
-
rake (~> 13.0)
|
|
135
|
-
sqlite3 (~> 1.5)
|
|
136
|
-
standard (~> 1.30)
|
|
137
|
-
steep (~> 1.5)
|
|
138
|
-
|
|
139
|
-
BUNDLED WITH
|
|
140
|
-
2.3.26
|
data/rbs_collection.yaml
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
# Download sources
|
|
2
|
-
sources:
|
|
3
|
-
- name: ruby/gem_rbs_collection
|
|
4
|
-
remote: https://github.com/ruby/gem_rbs_collection.git
|
|
5
|
-
revision: main
|
|
6
|
-
repo_dir: gems
|
|
7
|
-
|
|
8
|
-
# A directory to install the downloaded RBSs
|
|
9
|
-
path: .gem_rbs_collection
|
|
10
|
-
|
|
11
|
-
gems:
|
|
12
|
-
- name: cgi
|
|
13
|
-
# Skip loading rbs gem's RBS.
|
|
14
|
-
# It's unnecessary if you don't use rbs as a library.
|
|
15
|
-
- name: rbs
|
|
16
|
-
ignore: true
|
|
17
|
-
- name: rake
|
|
18
|
-
ignore: true
|
|
19
|
-
- name: minitest
|
|
20
|
-
ignore: true
|
|
21
|
-
- name: standard
|
|
22
|
-
ignore: true
|
|
23
|
-
- name: steep
|
|
24
|
-
ignore: true
|
data/sig/encoded_id/rails.rbs
DELETED
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
module EncodedId
|
|
2
|
-
module Rails
|
|
3
|
-
VERSION: ::String
|
|
4
|
-
|
|
5
|
-
class Configuration
|
|
6
|
-
attr_accessor salt: ::String
|
|
7
|
-
attr_accessor group_separator: ::String
|
|
8
|
-
attr_accessor character_group_size: ::Integer
|
|
9
|
-
attr_accessor alphabet: ::EncodedId::Alphabet
|
|
10
|
-
attr_accessor id_length: ::Integer
|
|
11
|
-
attr_accessor slug_value_method_name: ::Symbol
|
|
12
|
-
attr_accessor slugged_id_separator: ::String
|
|
13
|
-
attr_accessor annotation_method_name: ::Symbol
|
|
14
|
-
attr_accessor annotated_id_separator: ::String
|
|
15
|
-
|
|
16
|
-
def initialize: () -> void
|
|
17
|
-
end
|
|
18
|
-
|
|
19
|
-
attr_reader self.configuration: Configuration
|
|
20
|
-
|
|
21
|
-
def self.configure: () { (Configuration config) -> void } -> void
|
|
22
|
-
|
|
23
|
-
class Coder
|
|
24
|
-
def initialize: (salt: ::String, id_length: ::Integer, character_group_size: ::Integer, separator: ::String, alphabet: ::EncodedId::Alphabet) -> void
|
|
25
|
-
def encode: (::Integer | ::Array[::Integer]) -> String
|
|
26
|
-
def decode: (::String) -> ::Array[::Integer]?
|
|
27
|
-
|
|
28
|
-
@salt: ::String
|
|
29
|
-
@id_length: ::Integer
|
|
30
|
-
@character_group_size: ::Integer
|
|
31
|
-
@separator: ::String
|
|
32
|
-
@alphabet: ::EncodedId::Alphabet
|
|
33
|
-
|
|
34
|
-
private
|
|
35
|
-
|
|
36
|
-
def coder: -> ::EncodedId::ReversibleId
|
|
37
|
-
end
|
|
38
|
-
|
|
39
|
-
class Salt
|
|
40
|
-
def initialize: (Class klass, ::String salt) -> void
|
|
41
|
-
|
|
42
|
-
@klass: Class
|
|
43
|
-
@salt: ::String
|
|
44
|
-
|
|
45
|
-
def generate!: -> ::String
|
|
46
|
-
end
|
|
47
|
-
|
|
48
|
-
class SluggedId
|
|
49
|
-
def initialize: (slug_part: ::String, id_part: ::String, ?separator: ::String)-> void
|
|
50
|
-
@slug_part: ::String
|
|
51
|
-
@id_part: ::String
|
|
52
|
-
@separator: ::String
|
|
53
|
-
|
|
54
|
-
def slugged_id: -> ::String
|
|
55
|
-
end
|
|
56
|
-
|
|
57
|
-
class AnnotatedId
|
|
58
|
-
def initialize: (annotation: ::String, id_part: ::String, ?separator: ::String)-> void
|
|
59
|
-
@annotation: ::String
|
|
60
|
-
@id_part: ::String
|
|
61
|
-
@separator: ::String
|
|
62
|
-
|
|
63
|
-
def annotated_id: -> ::String
|
|
64
|
-
end
|
|
65
|
-
|
|
66
|
-
class SluggedIdParser
|
|
67
|
-
def initialize: (::String slugged_id, ?separator: ::String) -> void
|
|
68
|
-
|
|
69
|
-
attr_reader slug: ::String?
|
|
70
|
-
attr_reader id: ::String
|
|
71
|
-
end
|
|
72
|
-
|
|
73
|
-
class AnnotatedIdParser
|
|
74
|
-
def initialize: (::String annotated_id, ?separator: ::String) -> void
|
|
75
|
-
|
|
76
|
-
attr_reader annotation: ::String?
|
|
77
|
-
attr_reader id: ::String
|
|
78
|
-
end
|
|
79
|
-
|
|
80
|
-
module EncoderMethods
|
|
81
|
-
def encode_encoded_id: (::Array[::Integer] | ::Integer id, ?::Hash[::Symbol, untyped] options) -> ::String
|
|
82
|
-
def decode_encoded_id: (::String slugged_encoded_id, ?::Hash[::Symbol, untyped] options) -> ::Array[::Integer]?
|
|
83
|
-
def encoded_id_salt: () -> ::String
|
|
84
|
-
def encoded_id_coder: (?::Hash[::Symbol, untyped] options) -> ::EncodedId::Rails::Coder
|
|
85
|
-
end
|
|
86
|
-
|
|
87
|
-
interface _ActiveRecordFinderMethod
|
|
88
|
-
def find_by: (*untyped) -> (nil | untyped)
|
|
89
|
-
end
|
|
90
|
-
|
|
91
|
-
module FinderMethods : EncoderMethods, _ActiveRecordFinderMethod, _ActiveRecordQueryMethod
|
|
92
|
-
def find_by_encoded_id: (::String encoded_id, ?with_id: ::Symbol?) -> untyped?
|
|
93
|
-
def find_by_encoded_id!: (::String encoded_id, ?with_id: ::Symbol?) -> untyped
|
|
94
|
-
def find_all_by_encoded_id: (::String encoded_id) -> untyped?
|
|
95
|
-
def find_all_by_encoded_id!: (::String encoded_id) -> untyped
|
|
96
|
-
end
|
|
97
|
-
|
|
98
|
-
interface _ActiveRecordQueryMethod
|
|
99
|
-
def where: (*untyped) -> untyped
|
|
100
|
-
end
|
|
101
|
-
|
|
102
|
-
module QueryMethods : EncoderMethods, _ActiveRecordQueryMethod
|
|
103
|
-
def where_encoded_id: (::String slugged_encoded_id) -> untyped
|
|
104
|
-
end
|
|
105
|
-
|
|
106
|
-
module Model : ActiveRecord::Base
|
|
107
|
-
# From ActiveRecord
|
|
108
|
-
extend ActiveRecord::FinderMethods
|
|
109
|
-
extend ActiveRecord::QueryMethods
|
|
110
|
-
def id_changed?: -> bool
|
|
111
|
-
|
|
112
|
-
# From EncodedId::Rails::Model
|
|
113
|
-
extend EncoderMethods
|
|
114
|
-
extend FinderMethods
|
|
115
|
-
extend QueryMethods
|
|
116
|
-
|
|
117
|
-
@encoded_id: ::String
|
|
118
|
-
@slugged_encoded_id: ::String
|
|
119
|
-
|
|
120
|
-
def encoded_id_hash: -> ::String?
|
|
121
|
-
def encoded_id: -> ::String?
|
|
122
|
-
def slugged_encoded_id: -> ::String?
|
|
123
|
-
def name_for_encoded_id_slug: -> ::String
|
|
124
|
-
def annotation_for_encoded_id: -> ::String
|
|
125
|
-
end
|
|
126
|
-
|
|
127
|
-
interface _ActiveRecordToParam
|
|
128
|
-
def to_param: -> ::String
|
|
129
|
-
end
|
|
130
|
-
|
|
131
|
-
module PathParam : Model, _ActiveRecordToParam
|
|
132
|
-
end
|
|
133
|
-
|
|
134
|
-
module SluggedPathParam : Model, _ActiveRecordToParam
|
|
135
|
-
end
|
|
136
|
-
end
|
|
137
|
-
|
|
138
|
-
Model: singleton(Rails::Model)
|
|
139
|
-
PathParam: singleton(Rails::PathParam)
|
|
140
|
-
SluggedPathParam: singleton(Rails::SluggedPathParam)
|
|
141
|
-
end
|