alimento0100886306 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.coveralls.yml +2 -0
- data/.gitignore +12 -0
- data/.rake_tasks~ +7 -0
- data/.rspec +2 -0
- data/.travis.yml +5 -0
- data/Gemfile +6 -0
- data/Guardfile +82 -0
- data/LICENSE.txt +21 -0
- data/README.md +39 -0
- data/Rakefile +6 -0
- data/alimento.gemspec +41 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/docs/Alimento.html +127 -0
- data/docs/Alimento/Alimento.html +679 -0
- data/docs/Alimento/Grupo.html +282 -0
- data/docs/Lista.html +885 -0
- data/docs/Nodo.html +398 -0
- data/docs/_index.html +155 -0
- data/docs/class_list.html +51 -0
- data/docs/css/common.css +1 -0
- data/docs/css/full_list.css +58 -0
- data/docs/css/style.css +492 -0
- data/docs/file.README.html +122 -0
- data/docs/file_list.html +56 -0
- data/docs/frames.html +17 -0
- data/docs/index.html +122 -0
- data/docs/js/app.js +248 -0
- data/docs/js/full_list.js +216 -0
- data/docs/js/jquery.js +4 -0
- data/docs/method_list.html +235 -0
- data/docs/top-level-namespace.html +112 -0
- data/lib/.alimento.rb.swo +0 -0
- data/lib/.alimento.rb.swp +0 -0
- data/lib/alimento.rb +124 -0
- data/lib/alimento/IG_fun.rb +15 -0
- data/lib/alimento/alimento.rb +35 -0
- data/lib/alimento/lista.rb +115 -0
- data/lib/alimento/ordenar.rb +28 -0
- data/lib/alimento/plato.rb +70 -0
- data/lib/alimento/version.rb +3 -0
- data//303/247 +82 -0
- metadata +185 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 0fc173438ee733f2429296891f3244b50576cebd
|
4
|
+
data.tar.gz: 3e24274b778b95dfdd713c97c06d14c4db94f549
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: c543df9f1482773643c03c15b5ffc4cfb04e13b0a4e03b2e6e81bc3591ce408377eda761afc5a9a739db2392e709bfa8a0f9b8f586269c6c538e0f7d9438fb6b
|
7
|
+
data.tar.gz: d708c7844c7c3d0aa884c4bc08fd83114685065c690041d89668715746161aa19fa4407f619aff01c167e6513c80d08157f7942cc0d9394e42bdb66b52ccfd2d
|
data/.coveralls.yml
ADDED
data/.gitignore
ADDED
data/.rake_tasks~
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/Gemfile
ADDED
data/Guardfile
ADDED
@@ -0,0 +1,82 @@
|
|
1
|
+
# A sample Guardfile
|
2
|
+
# More info at https://github.com/guard/guard#readme
|
3
|
+
|
4
|
+
## Uncomment and set this to only include directories you want to watch
|
5
|
+
# directories %w(app lib config test spec features) \
|
6
|
+
# .select{|d| Dir.exists?(d) ? d : UI.warning("Directory #{d} does not exist")}
|
7
|
+
|
8
|
+
## Note: if you are using the `directories` clause above and you are not
|
9
|
+
## watching the project directory ('.'), then you will want to move
|
10
|
+
## the Guardfile to a watched dir and symlink it back, e.g.
|
11
|
+
#
|
12
|
+
# $ mkdir config
|
13
|
+
# $ mv Guardfile config/
|
14
|
+
# $ ln -s config/Guardfile .
|
15
|
+
#
|
16
|
+
# and, you'll have to watch "config/Guardfile" instead of "Guardfile"
|
17
|
+
|
18
|
+
guard :bundler do
|
19
|
+
require 'guard/bundler'
|
20
|
+
require 'guard/bundler/verify'
|
21
|
+
helper = Guard::Bundler::Verify.new
|
22
|
+
|
23
|
+
files = ['Gemfile']
|
24
|
+
files += Dir['*.gemspec'] if files.any? { |f| helper.uses_gemspec?(f) }
|
25
|
+
|
26
|
+
# Assume files are symlinked from somewhere
|
27
|
+
files.each { |file| watch(helper.real_path(file)) }
|
28
|
+
end
|
29
|
+
|
30
|
+
# Note: The cmd option is now required due to the increasing number of ways
|
31
|
+
# rspec may be run, below are examples of the most common uses.
|
32
|
+
# * bundler: 'bundle exec rspec'
|
33
|
+
# * bundler binstubs: 'bin/rspec'
|
34
|
+
# * spring: 'bin/rspec' (This will use spring if running and you have
|
35
|
+
# installed the spring binstubs per the docs)
|
36
|
+
# * zeus: 'zeus rspec' (requires the server to be started separately)
|
37
|
+
# * 'just' rspec: 'rspec'
|
38
|
+
|
39
|
+
guard :rspec, cmd: "bundle exec rspec" do
|
40
|
+
require "guard/rspec/dsl"
|
41
|
+
dsl = Guard::RSpec::Dsl.new(self)
|
42
|
+
|
43
|
+
# Feel free to open issues for suggestions and improvements
|
44
|
+
|
45
|
+
# RSpec files
|
46
|
+
rspec = dsl.rspec
|
47
|
+
watch(rspec.spec_helper) { rspec.spec_dir }
|
48
|
+
watch(rspec.spec_support) { rspec.spec_dir }
|
49
|
+
watch(rspec.spec_files)
|
50
|
+
|
51
|
+
# Ruby files
|
52
|
+
ruby = dsl.ruby
|
53
|
+
dsl.watch_spec_files_for(ruby.lib_files)
|
54
|
+
|
55
|
+
# Rails files
|
56
|
+
rails = dsl.rails(view_extensions: %w(erb haml slim))
|
57
|
+
dsl.watch_spec_files_for(rails.app_files)
|
58
|
+
dsl.watch_spec_files_for(rails.views)
|
59
|
+
|
60
|
+
watch(rails.controllers) do |m|
|
61
|
+
[
|
62
|
+
rspec.spec.call("routing/#{m[1]}_routing"),
|
63
|
+
rspec.spec.call("controllers/#{m[1]}_controller"),
|
64
|
+
rspec.spec.call("acceptance/#{m[1]}")
|
65
|
+
]
|
66
|
+
end
|
67
|
+
|
68
|
+
# Rails config changes
|
69
|
+
watch(rails.spec_helper) { rspec.spec_dir }
|
70
|
+
watch(rails.routes) { "#{rspec.spec_dir}/routing" }
|
71
|
+
watch(rails.app_controller) { "#{rspec.spec_dir}/controllers" }
|
72
|
+
|
73
|
+
# Capybara features specs
|
74
|
+
watch(rails.view_dirs) { |m| rspec.spec.call("features/#{m[1]}") }
|
75
|
+
watch(rails.layouts) { |m| rspec.spec.call("features/#{m[1]}") }
|
76
|
+
|
77
|
+
# Turnip features and steps
|
78
|
+
watch(%r{^spec/acceptance/(.+)\.feature$})
|
79
|
+
watch(%r{^spec/acceptance/steps/(.+)_steps\.rb$}) do |m|
|
80
|
+
Dir[File.join("**/#{m[1]}.feature")][0] || "spec/acceptance"
|
81
|
+
end
|
82
|
+
end
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2017 Christian
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,39 @@
|
|
1
|
+
# Alimento
|
2
|
+
|
3
|
+
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/alimento`. To experiment with that code, run `bin/console` for an interactive prompt.
|
4
|
+
|
5
|
+
TODO: Delete this and the text above, and describe your gem
|
6
|
+
|
7
|
+
## Installation
|
8
|
+
|
9
|
+
Add this line to your application's Gemfile:
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
gem 'alimento'
|
13
|
+
```
|
14
|
+
|
15
|
+
And then execute:
|
16
|
+
|
17
|
+
$ bundle
|
18
|
+
|
19
|
+
Or install it yourself as:
|
20
|
+
|
21
|
+
$ gem install alimento
|
22
|
+
|
23
|
+
## Usage
|
24
|
+
|
25
|
+
TODO: Write usage instructions here
|
26
|
+
|
27
|
+
## Development
|
28
|
+
|
29
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
30
|
+
|
31
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
32
|
+
|
33
|
+
## Contributing
|
34
|
+
|
35
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/alimento.
|
36
|
+
|
37
|
+
## License
|
38
|
+
|
39
|
+
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
data/Rakefile
ADDED
data/alimento.gemspec
ADDED
@@ -0,0 +1,41 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
lib = File.expand_path("../lib", __FILE__)
|
4
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
5
|
+
require "alimento/version"
|
6
|
+
|
7
|
+
Gem::Specification.new do |spec|
|
8
|
+
spec.name = "alimento0100886306"
|
9
|
+
spec.version = Alimento::VERSION
|
10
|
+
spec.authors = ["Christian"]
|
11
|
+
spec.email = ["alu0100886306@ull.edu.es"]
|
12
|
+
|
13
|
+
spec.summary = %q{Write a short summary, because Rubygems requires one.}
|
14
|
+
spec.description = %q{Write a longer description or delete this line.}
|
15
|
+
spec.homepage = "https://github.com/ULL-ESIT-LPP-1718/tdd-alu0100886306.git"
|
16
|
+
spec.license = "MIT"
|
17
|
+
|
18
|
+
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
19
|
+
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
20
|
+
if spec.respond_to?(:metadata)
|
21
|
+
spec.metadata["allowed_push_host"] = "https://rubygems.org"
|
22
|
+
else
|
23
|
+
raise "RubyGems 2.0 or newer is required to protect against " \
|
24
|
+
"public gem pushes."
|
25
|
+
end
|
26
|
+
|
27
|
+
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
28
|
+
f.match(%r{^(test|spec|features)/})
|
29
|
+
end
|
30
|
+
spec.bindir = "exe"
|
31
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
32
|
+
spec.require_paths = ["lib"]
|
33
|
+
|
34
|
+
spec.add_development_dependency "bundler", "~> 1.15"
|
35
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
36
|
+
spec.add_development_dependency "rspec", "~> 3.0"
|
37
|
+
spec.add_development_dependency "guard"
|
38
|
+
spec.add_development_dependency "guard-rspec"
|
39
|
+
spec.add_development_dependency "guard-bundler"
|
40
|
+
spec.add_development_dependency "coveralls"
|
41
|
+
end
|
data/bin/console
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require "bundler/setup"
|
4
|
+
require "alimento"
|
5
|
+
|
6
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
+
# with your gem easier. You can also use a different console, if you like.
|
8
|
+
|
9
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
+
# require "pry"
|
11
|
+
# Pry.start
|
12
|
+
|
13
|
+
require "irb"
|
14
|
+
IRB.start(__FILE__)
|
data/bin/setup
ADDED
data/docs/Alimento.html
ADDED
@@ -0,0 +1,127 @@
|
|
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: Alimento
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.9
|
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 = "Alimento";
|
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?1"></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
|
+
|
41
|
+
|
42
|
+
<span class="title">Alimento</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
|
+
<div id="content"><h1>Module: Alimento
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<dl>
|
80
|
+
<dt>Defined in:</dt>
|
81
|
+
<dd>lib/alimento.rb<span class="defines">,<br />
|
82
|
+
lib/alimento/version.rb</span>
|
83
|
+
</dd>
|
84
|
+
</dl>
|
85
|
+
|
86
|
+
</div>
|
87
|
+
|
88
|
+
<h2>Defined Under Namespace</h2>
|
89
|
+
<p class="children">
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Alimento/Alimento.html" title="Alimento::Alimento (class)">Alimento</a></span>, <span class='object_link'><a href="Alimento/Grupo.html" title="Alimento::Grupo (class)">Grupo</a></span>
|
95
|
+
|
96
|
+
|
97
|
+
</p>
|
98
|
+
|
99
|
+
<h2>Constant Summary</h2>
|
100
|
+
<dl class="constants">
|
101
|
+
|
102
|
+
<dt id="VERSION-constant" class="">VERSION =
|
103
|
+
|
104
|
+
</dt>
|
105
|
+
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0.1.0</span><span class='tstring_end'>"</span></span></pre></dd>
|
106
|
+
|
107
|
+
</dl>
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
</div>
|
118
|
+
|
119
|
+
<div id="footer">
|
120
|
+
Generated on Tue Nov 14 14:50:59 2017 by
|
121
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
122
|
+
0.9.9 (ruby-2.3.0).
|
123
|
+
</div>
|
124
|
+
|
125
|
+
</div>
|
126
|
+
</body>
|
127
|
+
</html>
|
@@ -0,0 +1,679 @@
|
|
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
|
+
Class: Alimento::Alimento
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.9
|
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 = "Alimento::Alimento";
|
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?1"></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="../Alimento.html" title="Alimento (module)">Alimento</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">Alimento</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
|
+
<div id="content"><h1>Class: Alimento::Alimento
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
<dl>
|
70
|
+
<dt>Inherits:</dt>
|
71
|
+
<dd>
|
72
|
+
<span class="inheritName">Object</span>
|
73
|
+
|
74
|
+
<ul class="fullTree">
|
75
|
+
<li>Object</li>
|
76
|
+
|
77
|
+
<li class="next">Alimento::Alimento</li>
|
78
|
+
|
79
|
+
</ul>
|
80
|
+
<a href="#" class="inheritanceTree">show all</a>
|
81
|
+
|
82
|
+
</dd>
|
83
|
+
</dl>
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
<dl>
|
91
|
+
<dt>Includes:</dt>
|
92
|
+
<dd>Comparable</dd>
|
93
|
+
</dl>
|
94
|
+
|
95
|
+
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
|
100
|
+
<dl>
|
101
|
+
<dt>Defined in:</dt>
|
102
|
+
<dd>lib/alimento.rb</dd>
|
103
|
+
</dl>
|
104
|
+
|
105
|
+
</div>
|
106
|
+
|
107
|
+
<div id="subclasses">
|
108
|
+
<h2>Direct Known Subclasses</h2>
|
109
|
+
<p class="children"><span class='object_link'><a href="Grupo.html" title="Alimento::Grupo (class)">Grupo</a></span></p>
|
110
|
+
</div>
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
<h2>Instance Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
|
116
|
+
<ul class="summary">
|
117
|
+
|
118
|
+
<li class="public ">
|
119
|
+
<span class="summary_signature">
|
120
|
+
|
121
|
+
<a href="#gluc-instance_method" title="#gluc (instance method)">#<strong>gluc</strong> ⇒ Object </a>
|
122
|
+
|
123
|
+
|
124
|
+
|
125
|
+
</span>
|
126
|
+
|
127
|
+
|
128
|
+
|
129
|
+
|
130
|
+
<span class="note title readonly">readonly</span>
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
|
140
|
+
<span class="summary_desc"><div class='inline'>
|
141
|
+
<p>Returns the value of attribute gluc.</p>
|
142
|
+
</div></span>
|
143
|
+
|
144
|
+
</li>
|
145
|
+
|
146
|
+
|
147
|
+
<li class="public ">
|
148
|
+
<span class="summary_signature">
|
149
|
+
|
150
|
+
<a href="#lip-instance_method" title="#lip (instance method)">#<strong>lip</strong> ⇒ Object </a>
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
</span>
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
<span class="note title readonly">readonly</span>
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
|
168
|
+
|
169
|
+
<span class="summary_desc"><div class='inline'>
|
170
|
+
<p>Returns the value of attribute lip.</p>
|
171
|
+
</div></span>
|
172
|
+
|
173
|
+
</li>
|
174
|
+
|
175
|
+
|
176
|
+
<li class="public ">
|
177
|
+
<span class="summary_signature">
|
178
|
+
|
179
|
+
<a href="#nombre-instance_method" title="#nombre (instance method)">#<strong>nombre</strong> ⇒ Object </a>
|
180
|
+
|
181
|
+
|
182
|
+
|
183
|
+
</span>
|
184
|
+
|
185
|
+
|
186
|
+
|
187
|
+
|
188
|
+
<span class="note title readonly">readonly</span>
|
189
|
+
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
|
194
|
+
|
195
|
+
|
196
|
+
|
197
|
+
|
198
|
+
<span class="summary_desc"><div class='inline'>
|
199
|
+
<p>Returns the value of attribute nombre.</p>
|
200
|
+
</div></span>
|
201
|
+
|
202
|
+
</li>
|
203
|
+
|
204
|
+
|
205
|
+
<li class="public ">
|
206
|
+
<span class="summary_signature">
|
207
|
+
|
208
|
+
<a href="#prt-instance_method" title="#prt (instance method)">#<strong>prt</strong> ⇒ Object </a>
|
209
|
+
|
210
|
+
|
211
|
+
|
212
|
+
</span>
|
213
|
+
|
214
|
+
|
215
|
+
|
216
|
+
|
217
|
+
<span class="note title readonly">readonly</span>
|
218
|
+
|
219
|
+
|
220
|
+
|
221
|
+
|
222
|
+
|
223
|
+
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
<span class="summary_desc"><div class='inline'>
|
228
|
+
<p>Returns the value of attribute prt.</p>
|
229
|
+
</div></span>
|
230
|
+
|
231
|
+
</li>
|
232
|
+
|
233
|
+
|
234
|
+
</ul>
|
235
|
+
|
236
|
+
|
237
|
+
|
238
|
+
|
239
|
+
|
240
|
+
<h2>
|
241
|
+
Instance Method Summary
|
242
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
243
|
+
</h2>
|
244
|
+
|
245
|
+
<ul class="summary">
|
246
|
+
|
247
|
+
<li class="public ">
|
248
|
+
<span class="summary_signature">
|
249
|
+
|
250
|
+
<a href="#<=>-instance_method" title="#<=> (instance method)">#<strong><=></strong>(another) ⇒ Object </a>
|
251
|
+
|
252
|
+
|
253
|
+
|
254
|
+
</span>
|
255
|
+
|
256
|
+
|
257
|
+
|
258
|
+
|
259
|
+
|
260
|
+
|
261
|
+
|
262
|
+
|
263
|
+
|
264
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
265
|
+
|
266
|
+
</li>
|
267
|
+
|
268
|
+
|
269
|
+
<li class="public ">
|
270
|
+
<span class="summary_signature">
|
271
|
+
|
272
|
+
<a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(nombre, prt, gluc, lip) ⇒ Alimento </a>
|
273
|
+
|
274
|
+
|
275
|
+
|
276
|
+
</span>
|
277
|
+
|
278
|
+
|
279
|
+
<span class="note title constructor">constructor</span>
|
280
|
+
|
281
|
+
|
282
|
+
|
283
|
+
|
284
|
+
|
285
|
+
|
286
|
+
|
287
|
+
|
288
|
+
<span class="summary_desc"><div class='inline'>
|
289
|
+
<p>A new instance of Alimento.</p>
|
290
|
+
</div></span>
|
291
|
+
|
292
|
+
</li>
|
293
|
+
|
294
|
+
|
295
|
+
<li class="public ">
|
296
|
+
<span class="summary_signature">
|
297
|
+
|
298
|
+
<a href="#kcal-instance_method" title="#kcal (instance method)">#<strong>kcal</strong> ⇒ Object </a>
|
299
|
+
|
300
|
+
|
301
|
+
|
302
|
+
</span>
|
303
|
+
|
304
|
+
|
305
|
+
|
306
|
+
|
307
|
+
|
308
|
+
|
309
|
+
|
310
|
+
|
311
|
+
|
312
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
313
|
+
|
314
|
+
</li>
|
315
|
+
|
316
|
+
|
317
|
+
<li class="public ">
|
318
|
+
<span class="summary_signature">
|
319
|
+
|
320
|
+
<a href="#to_s-instance_method" title="#to_s (instance method)">#<strong>to_s</strong> ⇒ Object </a>
|
321
|
+
|
322
|
+
|
323
|
+
|
324
|
+
</span>
|
325
|
+
|
326
|
+
|
327
|
+
|
328
|
+
|
329
|
+
|
330
|
+
|
331
|
+
|
332
|
+
|
333
|
+
|
334
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
335
|
+
|
336
|
+
</li>
|
337
|
+
|
338
|
+
|
339
|
+
</ul>
|
340
|
+
|
341
|
+
|
342
|
+
|
343
|
+
<div id="constructor_details" class="method_details_list">
|
344
|
+
<h2>Constructor Details</h2>
|
345
|
+
|
346
|
+
<div class="method_details first">
|
347
|
+
<h3 class="signature first" id="initialize-instance_method">
|
348
|
+
|
349
|
+
#<strong>initialize</strong>(nombre, prt, gluc, lip) ⇒ <tt><span class='object_link'><a href="" title="Alimento::Alimento (class)">Alimento</a></span></tt>
|
350
|
+
|
351
|
+
|
352
|
+
|
353
|
+
|
354
|
+
|
355
|
+
</h3><div class="docstring">
|
356
|
+
<div class="discussion">
|
357
|
+
|
358
|
+
<p>Returns a new instance of Alimento</p>
|
359
|
+
|
360
|
+
|
361
|
+
</div>
|
362
|
+
</div>
|
363
|
+
<div class="tags">
|
364
|
+
|
365
|
+
|
366
|
+
</div><table class="source_code">
|
367
|
+
<tr>
|
368
|
+
<td>
|
369
|
+
<pre class="lines">
|
370
|
+
|
371
|
+
|
372
|
+
13
|
373
|
+
14
|
374
|
+
15
|
375
|
+
16
|
376
|
+
17
|
377
|
+
18</pre>
|
378
|
+
</td>
|
379
|
+
<td>
|
380
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 13</span>
|
381
|
+
|
382
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_nombre'>nombre</span><span class='comma'>,</span><span class='id identifier rubyid_prt'>prt</span><span class='comma'>,</span><span class='id identifier rubyid_gluc'>gluc</span><span class='comma'>,</span><span class='id identifier rubyid_lip'>lip</span><span class='rparen'>)</span>
|
383
|
+
<span class='ivar'>@nombre</span><span class='op'>=</span><span class='id identifier rubyid_nombre'>nombre</span>
|
384
|
+
<span class='ivar'>@prt</span><span class='op'>=</span><span class='id identifier rubyid_prt'>prt</span>
|
385
|
+
<span class='ivar'>@gluc</span><span class='op'>=</span><span class='id identifier rubyid_gluc'>gluc</span>
|
386
|
+
<span class='ivar'>@lip</span><span class='op'>=</span><span class='id identifier rubyid_lip'>lip</span>
|
387
|
+
<span class='kw'>end</span></pre>
|
388
|
+
</td>
|
389
|
+
</tr>
|
390
|
+
</table>
|
391
|
+
</div>
|
392
|
+
|
393
|
+
</div>
|
394
|
+
|
395
|
+
<div id="instance_attr_details" class="attr_details">
|
396
|
+
<h2>Instance Attribute Details</h2>
|
397
|
+
|
398
|
+
|
399
|
+
<span id=""></span>
|
400
|
+
<div class="method_details first">
|
401
|
+
<h3 class="signature first" id="gluc-instance_method">
|
402
|
+
|
403
|
+
#<strong>gluc</strong> ⇒ <tt>Object</tt> <span class="extras">(readonly)</span>
|
404
|
+
|
405
|
+
|
406
|
+
|
407
|
+
|
408
|
+
|
409
|
+
</h3><div class="docstring">
|
410
|
+
<div class="discussion">
|
411
|
+
|
412
|
+
<p>Returns the value of attribute gluc</p>
|
413
|
+
|
414
|
+
|
415
|
+
</div>
|
416
|
+
</div>
|
417
|
+
<div class="tags">
|
418
|
+
|
419
|
+
|
420
|
+
</div><table class="source_code">
|
421
|
+
<tr>
|
422
|
+
<td>
|
423
|
+
<pre class="lines">
|
424
|
+
|
425
|
+
|
426
|
+
6
|
427
|
+
7
|
428
|
+
8</pre>
|
429
|
+
</td>
|
430
|
+
<td>
|
431
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 6</span>
|
432
|
+
|
433
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_gluc'>gluc</span>
|
434
|
+
<span class='ivar'>@gluc</span>
|
435
|
+
<span class='kw'>end</span></pre>
|
436
|
+
</td>
|
437
|
+
</tr>
|
438
|
+
</table>
|
439
|
+
</div>
|
440
|
+
|
441
|
+
|
442
|
+
<span id=""></span>
|
443
|
+
<div class="method_details ">
|
444
|
+
<h3 class="signature " id="lip-instance_method">
|
445
|
+
|
446
|
+
#<strong>lip</strong> ⇒ <tt>Object</tt> <span class="extras">(readonly)</span>
|
447
|
+
|
448
|
+
|
449
|
+
|
450
|
+
|
451
|
+
|
452
|
+
</h3><div class="docstring">
|
453
|
+
<div class="discussion">
|
454
|
+
|
455
|
+
<p>Returns the value of attribute lip</p>
|
456
|
+
|
457
|
+
|
458
|
+
</div>
|
459
|
+
</div>
|
460
|
+
<div class="tags">
|
461
|
+
|
462
|
+
|
463
|
+
</div><table class="source_code">
|
464
|
+
<tr>
|
465
|
+
<td>
|
466
|
+
<pre class="lines">
|
467
|
+
|
468
|
+
|
469
|
+
6
|
470
|
+
7
|
471
|
+
8</pre>
|
472
|
+
</td>
|
473
|
+
<td>
|
474
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 6</span>
|
475
|
+
|
476
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_lip'>lip</span>
|
477
|
+
<span class='ivar'>@lip</span>
|
478
|
+
<span class='kw'>end</span></pre>
|
479
|
+
</td>
|
480
|
+
</tr>
|
481
|
+
</table>
|
482
|
+
</div>
|
483
|
+
|
484
|
+
|
485
|
+
<span id=""></span>
|
486
|
+
<div class="method_details ">
|
487
|
+
<h3 class="signature " id="nombre-instance_method">
|
488
|
+
|
489
|
+
#<strong>nombre</strong> ⇒ <tt>Object</tt> <span class="extras">(readonly)</span>
|
490
|
+
|
491
|
+
|
492
|
+
|
493
|
+
|
494
|
+
|
495
|
+
</h3><div class="docstring">
|
496
|
+
<div class="discussion">
|
497
|
+
|
498
|
+
<p>Returns the value of attribute nombre</p>
|
499
|
+
|
500
|
+
|
501
|
+
</div>
|
502
|
+
</div>
|
503
|
+
<div class="tags">
|
504
|
+
|
505
|
+
|
506
|
+
</div><table class="source_code">
|
507
|
+
<tr>
|
508
|
+
<td>
|
509
|
+
<pre class="lines">
|
510
|
+
|
511
|
+
|
512
|
+
6
|
513
|
+
7
|
514
|
+
8</pre>
|
515
|
+
</td>
|
516
|
+
<td>
|
517
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 6</span>
|
518
|
+
|
519
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_nombre'>nombre</span>
|
520
|
+
<span class='ivar'>@nombre</span>
|
521
|
+
<span class='kw'>end</span></pre>
|
522
|
+
</td>
|
523
|
+
</tr>
|
524
|
+
</table>
|
525
|
+
</div>
|
526
|
+
|
527
|
+
|
528
|
+
<span id=""></span>
|
529
|
+
<div class="method_details ">
|
530
|
+
<h3 class="signature " id="prt-instance_method">
|
531
|
+
|
532
|
+
#<strong>prt</strong> ⇒ <tt>Object</tt> <span class="extras">(readonly)</span>
|
533
|
+
|
534
|
+
|
535
|
+
|
536
|
+
|
537
|
+
|
538
|
+
</h3><div class="docstring">
|
539
|
+
<div class="discussion">
|
540
|
+
|
541
|
+
<p>Returns the value of attribute prt</p>
|
542
|
+
|
543
|
+
|
544
|
+
</div>
|
545
|
+
</div>
|
546
|
+
<div class="tags">
|
547
|
+
|
548
|
+
|
549
|
+
</div><table class="source_code">
|
550
|
+
<tr>
|
551
|
+
<td>
|
552
|
+
<pre class="lines">
|
553
|
+
|
554
|
+
|
555
|
+
6
|
556
|
+
7
|
557
|
+
8</pre>
|
558
|
+
</td>
|
559
|
+
<td>
|
560
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 6</span>
|
561
|
+
|
562
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_prt'>prt</span>
|
563
|
+
<span class='ivar'>@prt</span>
|
564
|
+
<span class='kw'>end</span></pre>
|
565
|
+
</td>
|
566
|
+
</tr>
|
567
|
+
</table>
|
568
|
+
</div>
|
569
|
+
|
570
|
+
</div>
|
571
|
+
|
572
|
+
|
573
|
+
<div id="instance_method_details" class="method_details_list">
|
574
|
+
<h2>Instance Method Details</h2>
|
575
|
+
|
576
|
+
|
577
|
+
<div class="method_details first">
|
578
|
+
<h3 class="signature first" id="<=>-instance_method">
|
579
|
+
|
580
|
+
#<strong><=></strong>(another) ⇒ <tt>Object</tt>
|
581
|
+
|
582
|
+
|
583
|
+
|
584
|
+
|
585
|
+
|
586
|
+
</h3><table class="source_code">
|
587
|
+
<tr>
|
588
|
+
<td>
|
589
|
+
<pre class="lines">
|
590
|
+
|
591
|
+
|
592
|
+
9
|
593
|
+
10
|
594
|
+
11</pre>
|
595
|
+
</td>
|
596
|
+
<td>
|
597
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 9</span>
|
598
|
+
|
599
|
+
<span class='kw'>def</span> <span class='op'><=></span><span class='lparen'>(</span><span class='id identifier rubyid_another'>another</span><span class='rparen'>)</span>
|
600
|
+
<span class='id identifier rubyid_kcal'>kcal</span> <span class='op'><=></span> <span class='id identifier rubyid_another'>another</span><span class='period'>.</span><span class='id identifier rubyid_kcal'>kcal</span>
|
601
|
+
<span class='kw'>end</span></pre>
|
602
|
+
</td>
|
603
|
+
</tr>
|
604
|
+
</table>
|
605
|
+
</div>
|
606
|
+
|
607
|
+
<div class="method_details ">
|
608
|
+
<h3 class="signature " id="kcal-instance_method">
|
609
|
+
|
610
|
+
#<strong>kcal</strong> ⇒ <tt>Object</tt>
|
611
|
+
|
612
|
+
|
613
|
+
|
614
|
+
|
615
|
+
|
616
|
+
</h3><table class="source_code">
|
617
|
+
<tr>
|
618
|
+
<td>
|
619
|
+
<pre class="lines">
|
620
|
+
|
621
|
+
|
622
|
+
24
|
623
|
+
25
|
624
|
+
26</pre>
|
625
|
+
</td>
|
626
|
+
<td>
|
627
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 24</span>
|
628
|
+
|
629
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_kcal'>kcal</span><span class='lparen'>(</span><span class='rparen'>)</span>
|
630
|
+
<span class='ivar'>@prt</span><span class='op'>*</span><span class='int'>4</span><span class='op'>+</span><span class='ivar'>@gluc</span><span class='op'>*</span><span class='int'>4</span><span class='op'>+</span><span class='ivar'>@lip</span><span class='op'>*</span><span class='int'>9</span>
|
631
|
+
<span class='kw'>end</span></pre>
|
632
|
+
</td>
|
633
|
+
</tr>
|
634
|
+
</table>
|
635
|
+
</div>
|
636
|
+
|
637
|
+
<div class="method_details ">
|
638
|
+
<h3 class="signature " id="to_s-instance_method">
|
639
|
+
|
640
|
+
#<strong>to_s</strong> ⇒ <tt>Object</tt>
|
641
|
+
|
642
|
+
|
643
|
+
|
644
|
+
|
645
|
+
|
646
|
+
</h3><table class="source_code">
|
647
|
+
<tr>
|
648
|
+
<td>
|
649
|
+
<pre class="lines">
|
650
|
+
|
651
|
+
|
652
|
+
20
|
653
|
+
21
|
654
|
+
22</pre>
|
655
|
+
</td>
|
656
|
+
<td>
|
657
|
+
<pre class="code"><span class="info file"># File 'lib/alimento.rb', line 20</span>
|
658
|
+
|
659
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_to_s'>to_s</span><span class='lparen'>(</span><span class='rparen'>)</span>
|
660
|
+
<span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='ivar'>@nombre</span><span class='embexpr_end'>}</span><span class='tstring_content'> prt=</span><span class='embexpr_beg'>#{</span><span class='ivar'>@prt</span><span class='embexpr_end'>}</span><span class='tstring_content'>g gluc=</span><span class='embexpr_beg'>#{</span><span class='ivar'>@gluc</span><span class='embexpr_end'>}</span><span class='tstring_content'>g lip=</span><span class='embexpr_beg'>#{</span><span class='ivar'>@lip</span><span class='embexpr_end'>}</span><span class='tstring_content'>g</span><span class='tstring_end'>"</span></span>
|
661
|
+
<span class='kw'>end</span></pre>
|
662
|
+
</td>
|
663
|
+
</tr>
|
664
|
+
</table>
|
665
|
+
</div>
|
666
|
+
|
667
|
+
</div>
|
668
|
+
|
669
|
+
</div>
|
670
|
+
|
671
|
+
<div id="footer">
|
672
|
+
Generated on Tue Nov 14 14:50:59 2017 by
|
673
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
674
|
+
0.9.9 (ruby-2.3.0).
|
675
|
+
</div>
|
676
|
+
|
677
|
+
</div>
|
678
|
+
</body>
|
679
|
+
</html>
|