alimento_0100763478 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (60) hide show
  1. checksums.yaml +7 -0
  2. data/.coveralls.yml +1 -0
  3. data/.gitignore +12 -0
  4. data/.rspec_status +40 -0
  5. data/.travis.yml +6 -0
  6. data/CODE_OF_CONDUCT.md +74 -0
  7. data/Gemfile +6 -0
  8. data/Guardfile +82 -0
  9. data/LICENSE.txt +21 -0
  10. data/README.md +19 -0
  11. data/Rakefile +6 -0
  12. data/alimento.gemspec +44 -0
  13. data/bin/console +14 -0
  14. data/bin/setup +8 -0
  15. data/docs/AGrupos.html +368 -0
  16. data/docs/Alimento.html +115 -0
  17. data/docs/Alimentos.html +683 -0
  18. data/docs/Lista.html +635 -0
  19. data/docs/Node.html +398 -0
  20. data/docs/_index.html +143 -0
  21. data/docs/class_list.html +51 -0
  22. data/docs/css/common.css +1 -0
  23. data/docs/css/full_list.css +58 -0
  24. data/docs/css/style.css +492 -0
  25. data/docs/doc/AGrupos.html +368 -0
  26. data/docs/doc/Aliementos.html +105 -0
  27. data/docs/doc/Alimento.html +115 -0
  28. data/docs/doc/Alimentos.html +683 -0
  29. data/docs/doc/Lista.html +635 -0
  30. data/docs/doc/Node.html +398 -0
  31. data/docs/doc/_index.html +148 -0
  32. data/docs/doc/class_list.html +51 -0
  33. data/docs/doc/css/common.css +1 -0
  34. data/docs/doc/css/full_list.css +58 -0
  35. data/docs/doc/css/style.css +492 -0
  36. data/docs/doc/file.README.html +99 -0
  37. data/docs/doc/file_list.html +56 -0
  38. data/docs/doc/frames.html +17 -0
  39. data/docs/doc/index.html +99 -0
  40. data/docs/doc/js/app.js +248 -0
  41. data/docs/doc/js/full_list.js +216 -0
  42. data/docs/doc/js/jquery.js +4 -0
  43. data/docs/doc/method_list.html +219 -0
  44. data/docs/doc/top-level-namespace.html +112 -0
  45. data/docs/file.README.html +99 -0
  46. data/docs/file_list.html +56 -0
  47. data/docs/frames.html +17 -0
  48. data/docs/index.html +99 -0
  49. data/docs/js/app.js +248 -0
  50. data/docs/js/full_list.js +216 -0
  51. data/docs/js/jquery.js +4 -0
  52. data/docs/method_list.html +219 -0
  53. data/docs/top-level-namespace.html +112 -0
  54. data/lib/alimento.rb +10 -0
  55. data/lib/alimento/alimento.rb +93 -0
  56. data/lib/alimento/funcional.rb +32 -0
  57. data/lib/alimento/lista.rb +47 -0
  58. data/lib/alimento/plato.rb +108 -0
  59. data/lib/alimento/version.rb +3 -0
  60. metadata +231 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: d55f2dbbb19201055f28c8a8769814894358df69
4
+ data.tar.gz: b8f37d6687c499bb4fd4e11828f1997817f52003
5
+ SHA512:
6
+ metadata.gz: f4534e1eb72714e696b35bd1a8c02d4558cc6e42c5593955ade0a43e775fbdf8b5c45cd7432d60cf9eafb88b4a19c64b236261e1d0587d53ad88f6e6021479f9
7
+ data.tar.gz: 55453d6a8f8bba685a235e277c8f292c245d94de09bfb4d3397f8ad1b6bcaaeeadc3dee76e2ed35a9bf127dc5ebce4b587afbd06223dae47751dcd6b1159c4b5
@@ -0,0 +1 @@
1
+ service_name: travis-ci
@@ -0,0 +1,12 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+ *~
11
+ *.old
12
+ *.swp
@@ -0,0 +1,40 @@
1
+ example_id | status | run_time |
2
+ ---------------------------------- | ------ | --------------- |
3
+ ./spec/alimento_spec.rb[1:1:1:1:1] | passed | 0.00076 seconds |
4
+ ./spec/alimento_spec.rb[1:1:1:1:2] | passed | 0.0002 seconds |
5
+ ./spec/alimento_spec.rb[1:1:1:1:3] | passed | 0.00015 seconds |
6
+ ./spec/alimento_spec.rb[1:1:1:1:4] | passed | 0.00015 seconds |
7
+ ./spec/alimento_spec.rb[1:1:1:2:1] | passed | 0.00039 seconds |
8
+ ./spec/alimento_spec.rb[1:1:1:3:1] | passed | 0.00024 seconds |
9
+ ./spec/alimento_spec.rb[1:1:2:1:1] | passed | 0.00102 seconds |
10
+ ./spec/alimento_spec.rb[1:1:2:1:2] | passed | 0.00017 seconds |
11
+ ./spec/alimento_spec.rb[1:1:2:1:3] | passed | 0.0002 seconds |
12
+ ./spec/alimento_spec.rb[1:1:2:1:4] | passed | 0.00075 seconds |
13
+ ./spec/alimento_spec.rb[1:1:2:1:5] | passed | 0.00019 seconds |
14
+ ./spec/alimento_spec.rb[1:1:2:1:6] | passed | 0.00018 seconds |
15
+ ./spec/alimento_spec.rb[1:1:2:2:1] | passed | 0.00138 seconds |
16
+ ./spec/alimento_spec.rb[1:1:2:2:2] | passed | 0.00019 seconds |
17
+ ./spec/alimento_spec.rb[1:1:3:1:1] | passed | 0.00026 seconds |
18
+ ./spec/alimento_spec.rb[1:1:3:1:2] | passed | 0.00021 seconds |
19
+ ./spec/alimento_spec.rb[1:2:1:1:1] | passed | 0.00027 seconds |
20
+ ./spec/alimento_spec.rb[1:2:2:1:1] | passed | 0.00023 seconds |
21
+ ./spec/alimento_spec.rb[1:2:2:1:2] | passed | 0.00016 seconds |
22
+ ./spec/alimento_spec.rb[1:2:2:1:3] | passed | 0.00019 seconds |
23
+ ./spec/alimento_spec.rb[1:2:3:1:1] | passed | 0.00041 seconds |
24
+ ./spec/alimento_spec.rb[1:2:3:1:2] | passed | 0.00021 seconds |
25
+ ./spec/alimento_spec.rb[1:2:3:1:3] | passed | 0.00018 seconds |
26
+ ./spec/alimento_spec.rb[1:2:3:1:4] | passed | 0.00041 seconds |
27
+ ./spec/alimento_spec.rb[1:2:3:1:5] | passed | 0.00022 seconds |
28
+ ./spec/alimento_spec.rb[1:2:3:1:6] | passed | 0.00025 seconds |
29
+ ./spec/alimento_spec.rb[1:2:3:2:1] | passed | 0.00024 seconds |
30
+ ./spec/alimento_spec.rb[1:2:3:2:2] | passed | 0.00018 seconds |
31
+ ./spec/alimento_spec.rb[1:2:3:2:3] | passed | 0.00023 seconds |
32
+ ./spec/alimento_spec.rb[1:2:3:3:1] | passed | 0.00038 seconds |
33
+ ./spec/alimento_spec.rb[1:2:4:1:1] | passed | 0.00031 seconds |
34
+ ./spec/alimento_spec.rb[1:2:5:1:1] | passed | 0.00028 seconds |
35
+ ./spec/alimento_spec.rb[1:2:5:1:2] | passed | 0.00026 seconds |
36
+ ./spec/alimento_spec.rb[1:2:5:1:3] | passed | 0.00029 seconds |
37
+ ./spec/alimento_spec.rb[1:2:6:2] | passed | 0.0008 seconds |
38
+ ./spec/alimento_spec.rb[1:2:6:3] | passed | 0.00075 seconds |
39
+ ./spec/alimento_spec.rb[1:2:6:4] | passed | 0.00272 seconds |
40
+ ./spec/alimento_spec.rb[1:3:1:1] | passed | 0.00026 seconds |
@@ -0,0 +1,6 @@
1
+ sudo: false
2
+ language: ruby
3
+ rvm:
4
+ - 1.29.3
5
+
6
+ before_install: gem install bundler -v 1.15.4
@@ -0,0 +1,74 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at alu0100763478@ull.edu.es. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [http://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: http://contributor-covenant.org
74
+ [version]: http://contributor-covenant.org/version/1/4/
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ source "https://rubygems.org"
2
+
3
+ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
4
+
5
+ # Specify your gem's dependencies in alimento.gemspec
6
+ gemspec
@@ -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
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2017 Rossiel Gonzalez
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.
@@ -0,0 +1,19 @@
1
+ # Práctica de Laboratorio #6.
2
+ >Desarrollo Dirigido por Pruebas (TDD).
3
+
4
+ ## Alumna
5
+ Rossiel D. González Ramírez
6
+
7
+ ----
8
+ ## Objetivo
9
+
10
+ Desarrollar una clase Ruby para representar Alimentos en donde se incluya los grupos de nutrientes energéticos y sus cantidades.
11
+
12
+ ----
13
+ ## Metodología y herramientas
14
+
15
+ * Metodología de desarrollo dirigido por pruebas (Test Driven Development - TDD)
16
+ * Bundler
17
+ * RSpec
18
+
19
+
@@ -0,0 +1,6 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
@@ -0,0 +1,44 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path("../lib", __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require "alimento/version"
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "alimento_0100763478"
8
+ spec.version = Alimento::VERSION
9
+ spec.authors = ["Rossiel Gonzalez"]
10
+ spec.email = ["alu0100763478@ull.edu.es"]
11
+
12
+ spec.summary = %q{Práctica 06}
13
+ spec.description = %q{Crear una clase Alimento que contenga los grupos de nutrientes y sus cantidades}
14
+ spec.homepage = "https://github.com/ULL-ESIT-LPP-1718/tdd-alu0100763478.git"
15
+ spec.license = "MIT"
16
+
17
+ # Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
18
+ # to allow pushing to a single host or delete this section to allow pushing to any host.
19
+ if spec.respond_to?(:metadata)
20
+ spec.metadata["allowed_push_host"] = "https://rubygems.org"
21
+ else
22
+ raise "RubyGems 2.0 or newer is required to protect against " \
23
+ "public gem pushes."
24
+ end
25
+
26
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
27
+ f.match(%r{^(test|spec|features)/})
28
+ end
29
+ spec.bindir = "exe"
30
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
31
+ spec.require_paths = ["lib"]
32
+
33
+ spec.metadata["yard.run"] = "yri" # use "yard" to build full HTML docs.
34
+
35
+ spec.add_development_dependency "bundler", "~> 1.15"
36
+ spec.add_development_dependency "rake", "~> 10.0"
37
+ spec.add_development_dependency "rspec", "~> 3.0"
38
+ spec.add_development_dependency "guard"
39
+ spec.add_development_dependency "guard-rspec"
40
+ spec.add_development_dependency "guard-bundler"
41
+ spec.add_development_dependency "yard"
42
+ spec.add_development_dependency "yard-rspec"
43
+ spec.add_development_dependency "coveralls"
44
+ end
@@ -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__)
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,368 @@
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: AGrupos
8
+
9
+ &mdash; 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 = "AGrupos";
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> &raquo;
40
+
41
+
42
+ <span class="title">AGrupos</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: AGrupos
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+ <dl>
70
+ <dt>Inherits:</dt>
71
+ <dd>
72
+ <span class="inheritName"><span class='object_link'><a href="Alimentos.html" title="Alimentos (class)">Alimentos</a></span></span>
73
+
74
+ <ul class="fullTree">
75
+ <li>Object</li>
76
+
77
+ <li class="next"><span class='object_link'><a href="Alimentos.html" title="Alimentos (class)">Alimentos</a></span></li>
78
+
79
+ <li class="next">AGrupos</li>
80
+
81
+ </ul>
82
+ <a href="#" class="inheritanceTree">show all</a>
83
+
84
+ </dd>
85
+ </dl>
86
+
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+
96
+
97
+ <dl>
98
+ <dt>Defined in:</dt>
99
+ <dd>lib/alimento.rb</dd>
100
+ </dl>
101
+
102
+ </div>
103
+
104
+
105
+
106
+
107
+
108
+ <h2>Instance Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
109
+ <ul class="summary">
110
+
111
+ <li class="public ">
112
+ <span class="summary_signature">
113
+
114
+ <a href="#ngrupo-instance_method" title="#ngrupo (instance method)">#<strong>ngrupo</strong> &#x21d2; Object </a>
115
+
116
+
117
+
118
+ </span>
119
+
120
+
121
+
122
+
123
+ <span class="note title readonly">readonly</span>
124
+
125
+
126
+
127
+
128
+
129
+
130
+
131
+
132
+
133
+ <span class="summary_desc"><div class='inline'>
134
+ <p>Returns the value of attribute ngrupo.</p>
135
+ </div></span>
136
+
137
+ </li>
138
+
139
+
140
+ </ul>
141
+
142
+
143
+
144
+
145
+
146
+ <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Alimentos.html" title="Alimentos (class)">Alimentos</a></span></h3>
147
+ <p class="inherited"><span class='object_link'><a href="Alimentos.html#glucidos-instance_method" title="Alimentos#glucidos (method)">#glucidos</a></span>, <span class='object_link'><a href="Alimentos.html#lipidos-instance_method" title="Alimentos#lipidos (method)">#lipidos</a></span>, <span class='object_link'><a href="Alimentos.html#nombre-instance_method" title="Alimentos#nombre (method)">#nombre</a></span>, <span class='object_link'><a href="Alimentos.html#proteinas-instance_method" title="Alimentos#proteinas (method)">#proteinas</a></span></p>
148
+
149
+
150
+
151
+ <h2>
152
+ Instance Method Summary
153
+ <small><a href="#" class="summary_toggle">collapse</a></small>
154
+ </h2>
155
+
156
+ <ul class="summary">
157
+
158
+ <li class="public ">
159
+ <span class="summary_signature">
160
+
161
+ <a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(nombre, proteinas, glucidos, lipidos, ngrupo) &#x21d2; AGrupos </a>
162
+
163
+
164
+
165
+ </span>
166
+
167
+
168
+ <span class="note title constructor">constructor</span>
169
+
170
+
171
+
172
+
173
+
174
+
175
+
176
+
177
+ <span class="summary_desc"><div class='inline'>
178
+ <p>A new instance of AGrupos.</p>
179
+ </div></span>
180
+
181
+ </li>
182
+
183
+
184
+ <li class="public ">
185
+ <span class="summary_signature">
186
+
187
+ <a href="#to_s-instance_method" title="#to_s (instance method)">#<strong>to_s</strong> &#x21d2; Object </a>
188
+
189
+
190
+
191
+ </span>
192
+
193
+
194
+
195
+
196
+
197
+
198
+
199
+
200
+
201
+ <span class="summary_desc"><div class='inline'></div></span>
202
+
203
+ </li>
204
+
205
+
206
+ </ul>
207
+
208
+
209
+
210
+
211
+
212
+
213
+
214
+
215
+
216
+
217
+
218
+ <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Alimentos.html" title="Alimentos (class)">Alimentos</a></span></h3>
219
+ <p class="inherited"><span class='object_link'><a href="Alimentos.html#<=>-instance_method" title="Alimentos#&lt;=&gt; (method)">#<=></a></span>, <span class='object_link'><a href="Alimentos.html#ve-instance_method" title="Alimentos#ve (method)">#ve</a></span></p>
220
+
221
+ <div id="constructor_details" class="method_details_list">
222
+ <h2>Constructor Details</h2>
223
+
224
+ <div class="method_details first">
225
+ <h3 class="signature first" id="initialize-instance_method">
226
+
227
+ #<strong>initialize</strong>(nombre, proteinas, glucidos, lipidos, ngrupo) &#x21d2; <tt><span class='object_link'><a href="" title="AGrupos (class)">AGrupos</a></span></tt>
228
+
229
+
230
+
231
+
232
+
233
+ </h3><div class="docstring">
234
+ <div class="discussion">
235
+
236
+ <p>Returns a new instance of AGrupos</p>
237
+
238
+
239
+ </div>
240
+ </div>
241
+ <div class="tags">
242
+
243
+
244
+ </div><table class="source_code">
245
+ <tr>
246
+ <td>
247
+ <pre class="lines">
248
+
249
+
250
+ 37
251
+ 38
252
+ 39
253
+ 40</pre>
254
+ </td>
255
+ <td>
256
+ <pre class="code"><span class="info file"># File 'lib/alimento.rb', line 37</span>
257
+
258
+ <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_proteinas'>proteinas</span><span class='comma'>,</span><span class='id identifier rubyid_glucidos'>glucidos</span><span class='comma'>,</span><span class='id identifier rubyid_lipidos'>lipidos</span><span class='comma'>,</span><span class='id identifier rubyid_ngrupo'>ngrupo</span><span class='rparen'>)</span>
259
+ <span class='kw'>super</span><span class='lparen'>(</span><span class='id identifier rubyid_nombre'>nombre</span><span class='comma'>,</span><span class='id identifier rubyid_proteinas'>proteinas</span><span class='comma'>,</span><span class='id identifier rubyid_glucidos'>glucidos</span><span class='comma'>,</span><span class='id identifier rubyid_lipidos'>lipidos</span><span class='rparen'>)</span>
260
+ <span class='ivar'>@ngrupo</span> <span class='op'>=</span> <span class='id identifier rubyid_ngrupo'>ngrupo</span>
261
+ <span class='kw'>end</span></pre>
262
+ </td>
263
+ </tr>
264
+ </table>
265
+ </div>
266
+
267
+ </div>
268
+
269
+ <div id="instance_attr_details" class="attr_details">
270
+ <h2>Instance Attribute Details</h2>
271
+
272
+
273
+ <span id=""></span>
274
+ <div class="method_details first">
275
+ <h3 class="signature first" id="ngrupo-instance_method">
276
+
277
+ #<strong>ngrupo</strong> &#x21d2; <tt>Object</tt> <span class="extras">(readonly)</span>
278
+
279
+
280
+
281
+
282
+
283
+ </h3><div class="docstring">
284
+ <div class="discussion">
285
+
286
+ <p>Returns the value of attribute ngrupo</p>
287
+
288
+
289
+ </div>
290
+ </div>
291
+ <div class="tags">
292
+
293
+
294
+ </div><table class="source_code">
295
+ <tr>
296
+ <td>
297
+ <pre class="lines">
298
+
299
+
300
+ 35
301
+ 36
302
+ 37</pre>
303
+ </td>
304
+ <td>
305
+ <pre class="code"><span class="info file"># File 'lib/alimento.rb', line 35</span>
306
+
307
+ <span class='kw'>def</span> <span class='id identifier rubyid_ngrupo'>ngrupo</span>
308
+ <span class='ivar'>@ngrupo</span>
309
+ <span class='kw'>end</span></pre>
310
+ </td>
311
+ </tr>
312
+ </table>
313
+ </div>
314
+
315
+ </div>
316
+
317
+
318
+ <div id="instance_method_details" class="method_details_list">
319
+ <h2>Instance Method Details</h2>
320
+
321
+
322
+ <div class="method_details first">
323
+ <h3 class="signature first" id="to_s-instance_method">
324
+
325
+ #<strong>to_s</strong> &#x21d2; <tt>Object</tt>
326
+
327
+
328
+
329
+
330
+
331
+ </h3><table class="source_code">
332
+ <tr>
333
+ <td>
334
+ <pre class="lines">
335
+
336
+
337
+ 42
338
+ 43
339
+ 44
340
+ 45
341
+ 46</pre>
342
+ </td>
343
+ <td>
344
+ <pre class="code"><span class="info file"># File 'lib/alimento.rb', line 42</span>
345
+
346
+ <span class='kw'>def</span> <span class='id identifier rubyid_to_s'>to_s</span>
347
+ <span class='id identifier rubyid_s'>s</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>Grupo: </span><span class='embexpr_beg'>#{</span><span class='ivar'>@ngrupo</span><span class='embexpr_end'>}</span><span class='tstring_content'>\n</span><span class='tstring_end'>&quot;</span></span>
348
+ <span class='id identifier rubyid_s'>s</span> <span class='op'>&lt;&lt;</span> <span class='kw'>super</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span>
349
+ <span class='id identifier rubyid_s'>s</span>
350
+ <span class='kw'>end</span></pre>
351
+ </td>
352
+ </tr>
353
+ </table>
354
+ </div>
355
+
356
+ </div>
357
+
358
+ </div>
359
+
360
+ <div id="footer">
361
+ Generated on Wed Nov 15 09:52:59 2017 by
362
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
363
+ 0.9.9 (ruby-2.3.0).
364
+ </div>
365
+
366
+ </div>
367
+ </body>
368
+ </html>