halation 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +211 -0
- data/bin/halation +4 -1
- data/doc/Halation.html +14 -4
- data/doc/Halation/AttrHelpers.html +288 -0
- data/doc/Halation/Coerce.html +373 -0
- data/doc/Halation/Config.html +732 -0
- data/doc/Halation/Config/Camera.html +628 -0
- data/doc/Halation/Config/Lens.html +540 -0
- data/doc/Halation/Engine.html +928 -0
- data/doc/Halation/ExifToolImage.html +486 -0
- data/doc/Halation/Roll.html +916 -0
- data/doc/Halation/Roll/Frame.html +842 -0
- data/doc/Halation/Script.html +506 -0
- data/doc/_index.html +112 -1
- data/doc/class_list.html +1 -1
- data/doc/file.LICENSE.html +1 -1
- data/doc/file.README.html +211 -1
- data/doc/index.html +211 -1
- data/doc/method_list.html +432 -0
- data/doc/top-level-namespace.html +1 -1
- data/lib/halation.rb +4 -0
- data/lib/halation/coerce.rb +21 -0
- data/lib/halation/config.rb +53 -0
- data/lib/halation/config/camera.rb +42 -0
- data/lib/halation/config/lens.rb +32 -0
- data/lib/halation/engine.rb +91 -0
- data/lib/halation/roll.rb +57 -0
- data/lib/halation/roll/frame.rb +47 -0
- data/lib/halation/script.rb +150 -0
- data/lib/halation/tools/exif_tool/image.rb +33 -0
- data/lib/halation/version.rb +1 -1
- metadata +42 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3f17cbb31bfe6de7fa8a260e962b84443392cccf
|
4
|
+
data.tar.gz: 709958a6604ad60526a116c8c4850d70992194cb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9bda60501dde8ab1d422326094d559c4a0265ecb51bba5bec00ba5bb1b5944215d083bae11918d4bc550cf2b50a9ab2978e01e4bef2c17a9dacd06de8b106439
|
7
|
+
data.tar.gz: 07b54f563fa6186b1d973c1b2d3bc0c7e05bc4fa29f38f98ff2844825b982f065e492e0405fb8c2b24b51580ba67666629ae4ad4982837a32ff020484903d7e3
|
data/README.md
CHANGED
@@ -1,3 +1,214 @@
|
|
1
1
|
# Halation
|
2
2
|
|
3
|
+
[![Gem Version](https://badge.fury.io/rb/halation.svg)](https://badge.fury.io/rb/halation)
|
4
|
+
[![Coverage Status](https://coveralls.io/repos/github/amclain/halation/badge.svg?branch=master)](https://coveralls.io/github/amclain/halation?branch=master)
|
5
|
+
[![API Documentation](https://img.shields.io/badge/docs-api-blue.svg)](http://www.rubydoc.info/gems/halation)
|
6
|
+
[![MIT License](https://img.shields.io/badge/license-MIT-yellowgreen.svg)](https://github.com/amclain/halation/blob/master/LICENSE)
|
7
|
+
|
3
8
|
Add Exif metadata to film photographs.
|
9
|
+
|
10
|
+
## Issues, Bugs, Feature Requests
|
11
|
+
|
12
|
+
Any bugs and feature requests should be reported on the GitHub issue tracker:
|
13
|
+
|
14
|
+
https://github.com/amclain/halation/issues
|
15
|
+
|
16
|
+
|
17
|
+
**Pull requests are preferred via GitHub.**
|
18
|
+
|
19
|
+
Mercurial users can use [Hg-Git](http://hg-git.github.io/) to interact with
|
20
|
+
GitHub repositories.
|
21
|
+
|
22
|
+
## Installation
|
23
|
+
|
24
|
+
Halation is available as a Ruby gem.
|
25
|
+
|
26
|
+
1. Install [Ruby](https://www.ruby-lang.org) 2.1 or higher.
|
27
|
+
* Windows: Use [RubyInstaller](http://rubyinstaller.org/downloads/).
|
28
|
+
* Mac: Use [homebrew](https://www.ruby-lang.org/en/documentation/installation/#homebrew).
|
29
|
+
* Linux: Use [rbenv](https://github.com/sstephenson/rbenv#basic-github-checkout).
|
30
|
+
* [Additional installation instructions](https://www.ruby-lang.org/en/documentation/installation)
|
31
|
+
|
32
|
+
2. Install [ExifTool](http://www.sno.phy.queensu.ca/~phil/exiftool/).
|
33
|
+
|
34
|
+
3. Open the [command line](http://www.addictivetips.com/windows-tips/windows-7-elevated-command-prompt-in-context-menu/)
|
35
|
+
and type:
|
36
|
+
|
37
|
+
```text
|
38
|
+
gem install halation
|
39
|
+
```
|
40
|
+
|
41
|
+
## Configuration
|
42
|
+
|
43
|
+
Halation stores its global configuration data in `.halation` in the system's
|
44
|
+
user directory. This is typically `~/.halation` on Mac and *nix-based systems,
|
45
|
+
or `C:\Users\.halation` on Windows.
|
46
|
+
|
47
|
+
>Halation uses the [YAML syntax](http://www.yaml.org/spec/1.2/spec.html#Preview)
|
48
|
+
for its configuration files.
|
49
|
+
|
50
|
+
By default Halation uses a global configuration file, `~/.halation/config.yml`.
|
51
|
+
This is where your generic settings are stored, like your name, copyright info,
|
52
|
+
and information about your cameras.
|
53
|
+
|
54
|
+
```yaml
|
55
|
+
# Example config.yml
|
56
|
+
---
|
57
|
+
artist: "Example User"
|
58
|
+
copyright: "2016 Example User"
|
59
|
+
cameras:
|
60
|
+
- tag: "rz67"
|
61
|
+
make: "Mamiya"
|
62
|
+
model: "Mamiya RZ67 Pro II"
|
63
|
+
lenses:
|
64
|
+
- tag: 65
|
65
|
+
model: "M65mm f/4L-A"
|
66
|
+
focal_length: 65
|
67
|
+
- tag: 110
|
68
|
+
model: "Z110mm f/2.8W"
|
69
|
+
focal_length: 110
|
70
|
+
- tag: 180
|
71
|
+
model: "Z180mm f/4.5W-N"
|
72
|
+
focal_length: 180
|
73
|
+
- tag: 250
|
74
|
+
model: "M65mm f/4L-A"
|
75
|
+
focal_length: 250
|
76
|
+
```
|
77
|
+
|
78
|
+
## Tags
|
79
|
+
|
80
|
+
Tags are user-defined values that serve as a quick and simple way to reference
|
81
|
+
complex information.
|
82
|
+
|
83
|
+
Why is this important? Let's say you shot a roll of ten images with several
|
84
|
+
different lenses. It would be cumbersome to have to specify a model number
|
85
|
+
like `Z110mm f/2.8W` (and all the other lens information) on each of the frames.
|
86
|
+
Even more importantly, if you're processing batches of images over a long period
|
87
|
+
of time (months, years), you're bound to make mistakes in the spelling of the
|
88
|
+
model number. This is important because any software that catalogs images based
|
89
|
+
on Exif data (Lightroom, Flickr) doesn't know how to deal with these
|
90
|
+
inconsistencies. This means `Z110mm f/2.8W` and `Z110mm f/2.8 W` will be
|
91
|
+
considered two different lenses by the software (did you see the difference?),
|
92
|
+
even though we as humans understand they're the same thing. If you try to filter
|
93
|
+
by lens in Lightroom, some of the images will be under one spelling and some
|
94
|
+
will be under the other, even though they were both shot with the same
|
95
|
+
110mm lens.
|
96
|
+
|
97
|
+
Tags solve this problem by letting us define all of the complex,
|
98
|
+
infrequently-changing data in one place. We can then reference that complex
|
99
|
+
data by its `tag`. For example, if we have a 65mm lens and a 110mm lens we can
|
100
|
+
define their information once and tag them as `65` and `110` respectively (we
|
101
|
+
choose the tag names).
|
102
|
+
|
103
|
+
```yaml
|
104
|
+
lenses:
|
105
|
+
- tag: 65
|
106
|
+
model: "M65mm f/4L-A"
|
107
|
+
focal_length: 65
|
108
|
+
- tag: 110
|
109
|
+
model: "Z110mm f/2.8W"
|
110
|
+
focal_length: 110
|
111
|
+
```
|
112
|
+
|
113
|
+
Now when we want to reference which lens was used when capturing a particular
|
114
|
+
frame, all we have to do is specify the tag and Halation will fill in the
|
115
|
+
correct Exif data for that lens when the image file is processed.
|
116
|
+
|
117
|
+
```yaml
|
118
|
+
frames:
|
119
|
+
- number: 1
|
120
|
+
lens: 110
|
121
|
+
- number: 2
|
122
|
+
lens: 65
|
123
|
+
- number: 3
|
124
|
+
lens: 110
|
125
|
+
```
|
126
|
+
|
127
|
+
## Processing A Roll
|
128
|
+
|
129
|
+
Halation requires all of the image files for a roll of film to be in the same
|
130
|
+
directory. The images should be named in ascending alphabetical order, with the
|
131
|
+
first frame of the roll at the start of the list and the last frame at the end.
|
132
|
+
This is typically the default when scanners save files. Halation will scan for
|
133
|
+
tiff files (`.tif`, `.tiff`), which is the ideal format, as well as jpeg files
|
134
|
+
(`.jpg`, `.jpeg`).
|
135
|
+
|
136
|
+
This directory should also contain a `roll.yml` file, which specifies the data
|
137
|
+
for each frame (image file) on the roll of film. A new `roll.yml` file can be
|
138
|
+
generated in the current directory with the following command:
|
139
|
+
|
140
|
+
```text
|
141
|
+
halation --new-roll
|
142
|
+
```
|
143
|
+
|
144
|
+
The data for the roll can then be entered into the file:
|
145
|
+
|
146
|
+
```yaml
|
147
|
+
# Example roll.yml
|
148
|
+
---
|
149
|
+
date: "2016-01-01"
|
150
|
+
camera: "rz67"
|
151
|
+
lens: 110
|
152
|
+
iso: 100
|
153
|
+
frames:
|
154
|
+
- number: 1
|
155
|
+
shutter: "1/125"
|
156
|
+
aperture: 8
|
157
|
+
- number: 2
|
158
|
+
shutter: "2"
|
159
|
+
lens: 65
|
160
|
+
aperture: 16
|
161
|
+
- number: 3
|
162
|
+
lens: 65
|
163
|
+
shutter: "0.5"
|
164
|
+
aperture: 16
|
165
|
+
- number: 4
|
166
|
+
lens: 65
|
167
|
+
shutter: "0.5"
|
168
|
+
aperture: 16
|
169
|
+
- number: 5
|
170
|
+
shutter: "1/250"
|
171
|
+
aperture: 4
|
172
|
+
- number: 6
|
173
|
+
shutter: "1/125"
|
174
|
+
aperture: 8
|
175
|
+
- number: 7
|
176
|
+
shutter: "1/125"
|
177
|
+
aperture: 8
|
178
|
+
- number: 8
|
179
|
+
shutter: "1/60"
|
180
|
+
aperture: 22
|
181
|
+
- number: 9
|
182
|
+
date: "2016-01-02"
|
183
|
+
shutter: "1/400"
|
184
|
+
aperture: 8
|
185
|
+
flash: yes
|
186
|
+
- number: 10
|
187
|
+
date: "2016-01-02"
|
188
|
+
shutter: "1/400"
|
189
|
+
aperture: 8
|
190
|
+
flash: yes
|
191
|
+
```
|
192
|
+
|
193
|
+
Default values can be set at the beginning of the file so that these settings
|
194
|
+
don't have to be specified for each frame. For example, the roll of film has
|
195
|
+
one ISO speed for all of the frames, so this can be specified at the top instead
|
196
|
+
of for each individual frame.
|
197
|
+
|
198
|
+
Values like the date are a little different, because maybe the whole roll was
|
199
|
+
shot during the same day, or maybe it was shot over the course of several days.
|
200
|
+
This is where the `roll.yml` file provides flexibility. Specifying `date` at the
|
201
|
+
beginning of the file will make it the default date for all of the frames on the
|
202
|
+
roll. If not all of the frames were shot on the same day, `date` can then be
|
203
|
+
specified for each of the frames that have a different date (`9` and `10` in
|
204
|
+
the example above). This concept works for most of the values.
|
205
|
+
|
206
|
+
>A complete list of keywords are available in the [Halation API documentation](http://www.rubydoc.info/gems/halation),
|
207
|
+
as well as in the [sample files](https://github.com/amclain/halation/tree/master/spec/samples).
|
208
|
+
|
209
|
+
After all of the necessary values are entered into `roll.yml`, the images can
|
210
|
+
be processed by running the following command:
|
211
|
+
|
212
|
+
```text
|
213
|
+
halation
|
214
|
+
```
|
data/bin/halation
CHANGED
data/doc/Halation.html
CHANGED
@@ -81,7 +81,7 @@
|
|
81
81
|
<dl>
|
82
82
|
<dt>Defined in:</dt>
|
83
83
|
<dd>lib/halation.rb<span class="defines">,<br />
|
84
|
-
lib/halation/version.rb</span>
|
84
|
+
lib/halation/roll.rb,<br /> lib/halation/coerce.rb,<br /> lib/halation/config.rb,<br /> lib/halation/engine.rb,<br /> lib/halation/script.rb,<br /> lib/halation/version.rb,<br /> lib/halation/roll/frame.rb,<br /> lib/halation/config/lens.rb,<br /> lib/halation/config/camera.rb,<br /> lib/halation/tools/exif_tool/image.rb</span>
|
85
85
|
</dd>
|
86
86
|
</dl>
|
87
87
|
|
@@ -98,7 +98,17 @@
|
|
98
98
|
<div class="tags">
|
99
99
|
|
100
100
|
|
101
|
-
</div>
|
101
|
+
</div><h2>Defined Under Namespace</h2>
|
102
|
+
<p class="children">
|
103
|
+
|
104
|
+
|
105
|
+
|
106
|
+
|
107
|
+
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Halation/Coerce.html" title="Halation::Coerce (class)">Coerce</a></span>, <span class='object_link'><a href="Halation/Config.html" title="Halation::Config (class)">Config</a></span>, <span class='object_link'><a href="Halation/Engine.html" title="Halation::Engine (class)">Engine</a></span>, <span class='object_link'><a href="Halation/ExifToolImage.html" title="Halation::ExifToolImage (class)">ExifToolImage</a></span>, <span class='object_link'><a href="Halation/Roll.html" title="Halation::Roll (class)">Roll</a></span>, <span class='object_link'><a href="Halation/Script.html" title="Halation::Script (class)">Script</a></span>
|
108
|
+
|
109
|
+
|
110
|
+
</p>
|
111
|
+
|
102
112
|
<h2>Constant Summary</h2>
|
103
113
|
|
104
114
|
<dl class="constants">
|
@@ -117,7 +127,7 @@
|
|
117
127
|
|
118
128
|
</div>
|
119
129
|
</dt>
|
120
|
-
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0.
|
130
|
+
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0.2.0</span><span class='tstring_end'>"</span></span></pre></dd>
|
121
131
|
|
122
132
|
</dl>
|
123
133
|
|
@@ -133,7 +143,7 @@
|
|
133
143
|
</div>
|
134
144
|
|
135
145
|
<div id="footer">
|
136
|
-
Generated on
|
146
|
+
Generated on Sat May 28 22:28:56 2016 by
|
137
147
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
138
148
|
0.8.7.6 (ruby-2.1.7).
|
139
149
|
</div>
|
@@ -0,0 +1,288 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6
|
+
<title>
|
7
|
+
Module: Halation::AttrHelpers
|
8
|
+
|
9
|
+
— Documentation by YARD 0.8.7.6
|
10
|
+
|
11
|
+
</title>
|
12
|
+
|
13
|
+
<link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
|
14
|
+
|
15
|
+
<link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
|
16
|
+
|
17
|
+
<script type="text/javascript" charset="utf-8">
|
18
|
+
pathId = "Halation::AttrHelpers";
|
19
|
+
relpath = '../';
|
20
|
+
</script>
|
21
|
+
|
22
|
+
|
23
|
+
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
24
|
+
|
25
|
+
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
26
|
+
|
27
|
+
|
28
|
+
</head>
|
29
|
+
<body>
|
30
|
+
<div class="nav_wrap">
|
31
|
+
<iframe id="nav" src="../class_list.html"></iframe>
|
32
|
+
<div id="resizer"></div>
|
33
|
+
</div>
|
34
|
+
|
35
|
+
<div id="main" tabindex="-1">
|
36
|
+
<div id="header">
|
37
|
+
<div id="menu">
|
38
|
+
|
39
|
+
<a href="../_index.html">Index (A)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../Halation.html" title="Halation (module)">Halation</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">AttrHelpers</span>
|
43
|
+
|
44
|
+
</div>
|
45
|
+
|
46
|
+
<div id="search">
|
47
|
+
|
48
|
+
<a class="full_list_link" id="class_list_link"
|
49
|
+
href="../class_list.html">
|
50
|
+
|
51
|
+
<svg width="24" height="24">
|
52
|
+
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
|
53
|
+
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
|
54
|
+
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
|
55
|
+
</svg>
|
56
|
+
</a>
|
57
|
+
|
58
|
+
</div>
|
59
|
+
<div class="clear"></div>
|
60
|
+
</div>
|
61
|
+
|
62
|
+
<iframe id="search_frame" src="../class_list.html"></iframe>
|
63
|
+
|
64
|
+
<div id="content"><h1>Module: Halation::AttrHelpers
|
65
|
+
|
66
|
+
|
67
|
+
|
68
|
+
</h1>
|
69
|
+
<div class="box_info">
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<dl>
|
80
|
+
<dt>Included in:</dt>
|
81
|
+
<dd><span class='object_link'><a href="Config/Camera.html" title="Halation::Config::Camera (class)">Config::Camera</a></span>, <span class='object_link'><a href="Config/Lens.html" title="Halation::Config::Lens (class)">Config::Lens</a></span></dd>
|
82
|
+
</dl>
|
83
|
+
|
84
|
+
|
85
|
+
|
86
|
+
<dl>
|
87
|
+
<dt>Defined in:</dt>
|
88
|
+
<dd>lib/halation/attr_helpers.rb</dd>
|
89
|
+
</dl>
|
90
|
+
|
91
|
+
</div>
|
92
|
+
|
93
|
+
<h2>Overview</h2><div class="docstring">
|
94
|
+
<div class="discussion">
|
95
|
+
|
96
|
+
<p>Class attr helpers. Extend this module to opt-in to its functionality.</p>
|
97
|
+
|
98
|
+
|
99
|
+
</div>
|
100
|
+
</div>
|
101
|
+
<div class="tags">
|
102
|
+
|
103
|
+
|
104
|
+
</div>
|
105
|
+
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
|
112
|
+
<h2>
|
113
|
+
Instance Method Summary
|
114
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
115
|
+
</h2>
|
116
|
+
|
117
|
+
<ul class="summary">
|
118
|
+
|
119
|
+
<li class="public ">
|
120
|
+
<span class="summary_signature">
|
121
|
+
|
122
|
+
<a href="#attr_reader_int_or_nil-instance_method" title="#attr_reader_int_or_nil (instance method)">#<strong>attr_reader_int_or_nil</strong>(*sym) ⇒ Integer<sup>?</sup> </a>
|
123
|
+
|
124
|
+
|
125
|
+
|
126
|
+
</span>
|
127
|
+
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
137
|
+
|
138
|
+
</li>
|
139
|
+
|
140
|
+
|
141
|
+
<li class="public ">
|
142
|
+
<span class="summary_signature">
|
143
|
+
|
144
|
+
<a href="#attr_reader_str_or_nil-instance_method" title="#attr_reader_str_or_nil (instance method)">#<strong>attr_reader_str_or_nil</strong>(*sym) ⇒ String<sup>?</sup> </a>
|
145
|
+
|
146
|
+
|
147
|
+
|
148
|
+
</span>
|
149
|
+
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
159
|
+
|
160
|
+
</li>
|
161
|
+
|
162
|
+
|
163
|
+
</ul>
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
|
168
|
+
<div id="instance_method_details" class="method_details_list">
|
169
|
+
<h2>Instance Method Details</h2>
|
170
|
+
|
171
|
+
|
172
|
+
<div class="method_details first">
|
173
|
+
<h3 class="signature first" id="attr_reader_int_or_nil-instance_method">
|
174
|
+
|
175
|
+
#<strong>attr_reader_int_or_nil</strong>(*sym) ⇒ <tt>Integer</tt><sup>?</sup>
|
176
|
+
|
177
|
+
|
178
|
+
|
179
|
+
|
180
|
+
|
181
|
+
</h3><div class="docstring">
|
182
|
+
<div class="discussion">
|
183
|
+
|
184
|
+
|
185
|
+
</div>
|
186
|
+
</div>
|
187
|
+
<div class="tags">
|
188
|
+
|
189
|
+
<p class="tag_title">Returns:</p>
|
190
|
+
<ul class="return">
|
191
|
+
|
192
|
+
<li>
|
193
|
+
|
194
|
+
|
195
|
+
<span class='type'>(<tt>Integer</tt>, <tt>nil</tt>)</span>
|
196
|
+
|
197
|
+
|
198
|
+
|
199
|
+
</li>
|
200
|
+
|
201
|
+
</ul>
|
202
|
+
|
203
|
+
</div><table class="source_code">
|
204
|
+
<tr>
|
205
|
+
<td>
|
206
|
+
<pre class="lines">
|
207
|
+
|
208
|
+
|
209
|
+
11
|
210
|
+
12
|
211
|
+
13</pre>
|
212
|
+
</td>
|
213
|
+
<td>
|
214
|
+
<pre class="code"><span class="info file"># File 'lib/halation/attr_helpers.rb', line 11</span>
|
215
|
+
|
216
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_attr_reader_int_or_nil'>attr_reader_int_or_nil</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_sym'>sym</span><span class='rparen'>)</span>
|
217
|
+
<span class='id identifier rubyid_with_instance_variables'>with_instance_variables</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_sym'>sym</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_value'>value</span><span class='op'>|</span> <span class='id identifier rubyid_value'>value</span> <span class='op'>&&=</span> <span class='id identifier rubyid_value'>value</span><span class='period'>.</span><span class='id identifier rubyid_to_i'>to_i</span> <span class='rbrace'>}</span>
|
218
|
+
<span class='kw'>end</span></pre>
|
219
|
+
</td>
|
220
|
+
</tr>
|
221
|
+
</table>
|
222
|
+
</div>
|
223
|
+
|
224
|
+
<div class="method_details ">
|
225
|
+
<h3 class="signature " id="attr_reader_str_or_nil-instance_method">
|
226
|
+
|
227
|
+
#<strong>attr_reader_str_or_nil</strong>(*sym) ⇒ <tt>String</tt><sup>?</sup>
|
228
|
+
|
229
|
+
|
230
|
+
|
231
|
+
|
232
|
+
|
233
|
+
</h3><div class="docstring">
|
234
|
+
<div class="discussion">
|
235
|
+
|
236
|
+
|
237
|
+
</div>
|
238
|
+
</div>
|
239
|
+
<div class="tags">
|
240
|
+
|
241
|
+
<p class="tag_title">Returns:</p>
|
242
|
+
<ul class="return">
|
243
|
+
|
244
|
+
<li>
|
245
|
+
|
246
|
+
|
247
|
+
<span class='type'>(<tt>String</tt>, <tt>nil</tt>)</span>
|
248
|
+
|
249
|
+
|
250
|
+
|
251
|
+
</li>
|
252
|
+
|
253
|
+
</ul>
|
254
|
+
|
255
|
+
</div><table class="source_code">
|
256
|
+
<tr>
|
257
|
+
<td>
|
258
|
+
<pre class="lines">
|
259
|
+
|
260
|
+
|
261
|
+
6
|
262
|
+
7
|
263
|
+
8</pre>
|
264
|
+
</td>
|
265
|
+
<td>
|
266
|
+
<pre class="code"><span class="info file"># File 'lib/halation/attr_helpers.rb', line 6</span>
|
267
|
+
|
268
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_attr_reader_str_or_nil'>attr_reader_str_or_nil</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_sym'>sym</span><span class='rparen'>)</span>
|
269
|
+
<span class='id identifier rubyid_with_instance_variables'>with_instance_variables</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_sym'>sym</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_value'>value</span><span class='op'>|</span> <span class='id identifier rubyid_value'>value</span> <span class='op'>&&=</span> <span class='id identifier rubyid_value'>value</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span> <span class='rbrace'>}</span>
|
270
|
+
<span class='kw'>end</span></pre>
|
271
|
+
</td>
|
272
|
+
</tr>
|
273
|
+
</table>
|
274
|
+
</div>
|
275
|
+
|
276
|
+
</div>
|
277
|
+
|
278
|
+
</div>
|
279
|
+
|
280
|
+
<div id="footer">
|
281
|
+
Generated on Thu May 5 23:51:49 2016 by
|
282
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
283
|
+
0.8.7.6 (ruby-2.1.7).
|
284
|
+
</div>
|
285
|
+
|
286
|
+
</div>
|
287
|
+
</body>
|
288
|
+
</html>
|