biblio-refs-v2 0.1.0

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.
Files changed (81) hide show
  1. checksums.yaml +7 -0
  2. data/.coveralls.yml +1 -0
  3. data/.gitignore +9 -0
  4. data/.rspec +2 -0
  5. data/.travis.yml +4 -0
  6. data/Gemfile +4 -0
  7. data/Guardfile +82 -0
  8. data/LICENSE.txt +21 -0
  9. data/README.md +46 -0
  10. data/README.rdoc +18 -0
  11. data/Rakefile +12 -0
  12. data/biblio-refs.gemspec +28 -0
  13. data/bin/console +14 -0
  14. data/bin/setup +7 -0
  15. data/html/BiblioRefs.html +109 -0
  16. data/html/BiblioRefs/Articulo.html +339 -0
  17. data/html/BiblioRefs/ArticuloPeriodico.html +276 -0
  18. data/html/BiblioRefs/DocumentoElectronico.html +327 -0
  19. data/html/BiblioRefs/Libro.html +312 -0
  20. data/html/BiblioRefs/List.html +372 -0
  21. data/html/BiblioRefs/ListAPA.html +271 -0
  22. data/html/BiblioRefs/PublicacionPeriodica.html +210 -0
  23. data/html/BiblioRefs/Referencia.html +927 -0
  24. data/html/Object.html +116 -0
  25. data/html/README_rdoc.html +110 -0
  26. data/html/created.rid +11 -0
  27. data/html/css/fonts.css +167 -0
  28. data/html/css/rdoc.css +590 -0
  29. data/html/fonts/Lato-Light.ttf +0 -0
  30. data/html/fonts/Lato-LightItalic.ttf +0 -0
  31. data/html/fonts/Lato-Regular.ttf +0 -0
  32. data/html/fonts/Lato-RegularItalic.ttf +0 -0
  33. data/html/fonts/SourceCodePro-Bold.ttf +0 -0
  34. data/html/fonts/SourceCodePro-Regular.ttf +0 -0
  35. data/html/images/add.png +0 -0
  36. data/html/images/arrow_up.png +0 -0
  37. data/html/images/brick.png +0 -0
  38. data/html/images/brick_link.png +0 -0
  39. data/html/images/bug.png +0 -0
  40. data/html/images/bullet_black.png +0 -0
  41. data/html/images/bullet_toggle_minus.png +0 -0
  42. data/html/images/bullet_toggle_plus.png +0 -0
  43. data/html/images/date.png +0 -0
  44. data/html/images/delete.png +0 -0
  45. data/html/images/find.png +0 -0
  46. data/html/images/loadingAnimation.gif +0 -0
  47. data/html/images/macFFBgHack.png +0 -0
  48. data/html/images/package.png +0 -0
  49. data/html/images/page_green.png +0 -0
  50. data/html/images/page_white_text.png +0 -0
  51. data/html/images/page_white_width.png +0 -0
  52. data/html/images/plugin.png +0 -0
  53. data/html/images/ruby.png +0 -0
  54. data/html/images/tag_blue.png +0 -0
  55. data/html/images/tag_green.png +0 -0
  56. data/html/images/transparent.png +0 -0
  57. data/html/images/wrench.png +0 -0
  58. data/html/images/wrench_orange.png +0 -0
  59. data/html/images/zoom.png +0 -0
  60. data/html/index.html +129 -0
  61. data/html/js/darkfish.js +161 -0
  62. data/html/js/jquery.js +4 -0
  63. data/html/js/navigation.js +142 -0
  64. data/html/js/navigation.js.gz +0 -0
  65. data/html/js/search.js +109 -0
  66. data/html/js/search_index.js +1 -0
  67. data/html/js/search_index.js.gz +0 -0
  68. data/html/js/searcher.js +228 -0
  69. data/html/js/searcher.js.gz +0 -0
  70. data/html/table_of_contents.html +293 -0
  71. data/lib/biblio_refs.rb +9 -0
  72. data/lib/biblio_refs/articulo.rb +46 -0
  73. data/lib/biblio_refs/articulo_periodico.rb +25 -0
  74. data/lib/biblio_refs/documento_electronico.rb +32 -0
  75. data/lib/biblio_refs/libro.rb +31 -0
  76. data/lib/biblio_refs/list.rb +59 -0
  77. data/lib/biblio_refs/list_apa.rb +39 -0
  78. data/lib/biblio_refs/publicacion_periodica.rb +22 -0
  79. data/lib/biblio_refs/referencia.rb +179 -0
  80. data/lib/biblio_refs/version.rb +3 -0
  81. metadata +221 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 6ad449059c956295a10176a524b2b9e46d69f72b
4
+ data.tar.gz: 97e9cd88fc01fa49789e4821bbfcdf7cd0398d97
5
+ SHA512:
6
+ metadata.gz: a821d9bbd9cdbcf6cbbff539c93b395bc1bae0adda68f6791b6777dc7bb423db233b420aa7f5ba20c3a9991303ff286d928e044ddfd7c8a0f3c1618733570d48
7
+ data.tar.gz: 77222744daf640cd4b4f5d7419f94ff2884838abea50d9f4c6ed585d9b3a8df336a9b090c7a7e7bcad704df4093d8d670b3cb036b33981d200c2bfc7d0cecca1
@@ -0,0 +1 @@
1
+ service_name: travis-ci
@@ -0,0 +1,9 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --format documentation
2
+ --color
@@ -0,0 +1,4 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.2.1
4
+ before_install: gem install bundler -v 1.10.6
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in biblio-refs.gemspec
4
+ 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.("routing/#{m[1]}_routing"),
63
+ rspec.spec.("controllers/#{m[1]}_controller"),
64
+ rspec.spec.("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.("features/#{m[1]}") }
75
+ watch(rails.layouts) { |m| rspec.spec.("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) 2015 Sergio Rodríguez
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,46 @@
1
+ # Biblio::Refs
2
+
3
+ [![Build Status](https://travis-ci.org/alu0100699968/biblio_refs.svg?branch=jonathan)](https://travis-ci.org/alu0100699968/biblio_refs)
4
+ [![Coverage Status](https://coveralls.io/repos/alu0100699968/biblio_refs/badge.svg?branch=jonathan&service=github)](https://coveralls.io/github/alu0100699968/biblio_refs?branch=jonathan)
5
+
6
+ Gema para la representación de referencias de una Bibliografía. Realizada para la práctica 6 de la asignatura Lenguajes y Paradigmas de la Programación.
7
+
8
+ ### Autores
9
+
10
+ * Sergio Rodríguez Martín
11
+ * Jonathan Expósito Martín
12
+
13
+ ## Installation
14
+
15
+ Add this line to your application's Gemfile:
16
+
17
+ ```ruby
18
+ gem 'biblio-refs'
19
+ ```
20
+
21
+ And then execute:
22
+
23
+ $ bundle
24
+
25
+ Or install it yourself as:
26
+
27
+ $ gem install biblio-refs
28
+
29
+ ## Usage
30
+
31
+ TODO: Write usage instructions here
32
+
33
+ ## Development
34
+
35
+ 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.
36
+
37
+ 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).
38
+
39
+ ## Contributing
40
+
41
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/biblio-refs.
42
+
43
+
44
+ ## License
45
+
46
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
@@ -0,0 +1,18 @@
1
+ == Autores
2
+
3
+ * Sergio Rodríguez Martín
4
+ * Jonathan Expósito Martín
5
+
6
+ == Installation
7
+
8
+ Add this line to your application's Gemfile:
9
+
10
+ gem 'biblio-refs'
11
+
12
+ And then execute:
13
+
14
+ $ bundle
15
+
16
+ Or install it yourself as:
17
+
18
+ $ gem install biblio-refs
@@ -0,0 +1,12 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+ require "rdoc/task"
4
+
5
+ RSpec::Core::RakeTask.new(:spec)
6
+
7
+ RDoc::Task.new do |rdoc|
8
+ rdoc.main = "README.rdoc"
9
+ rdoc.rdoc_files.include("README.rdoc", "lib/biblio_refs/*.rb")
10
+ end
11
+
12
+ task :default => :spec
@@ -0,0 +1,28 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'biblio_refs/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "biblio-refs-v2"
8
+ spec.version = BiblioRefs::VERSION
9
+ spec.authors = ["Jonathan Expósito"]
10
+ spec.email = ["alu0100696455@ull.edu.es"]
11
+
12
+ spec.summary = %q{Gema para representar un conjunto de referencias.}
13
+ spec.homepage = "https://github.com/alu0100696455/biblio_refs/"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
17
+ spec.bindir = "exe"
18
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_development_dependency "bundler", "~> 1.10"
22
+ spec.add_development_dependency "rake", "~> 10.0"
23
+ spec.add_development_dependency "rspec"
24
+ spec.add_development_dependency "guard"
25
+ spec.add_development_dependency "guard-rspec"
26
+ spec.add_development_dependency "guard-bundler"
27
+ spec.add_development_dependency "coveralls"
28
+ end
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "biblio/refs"
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
@@ -0,0 +1,7 @@
1
+ #!/bin/bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+
5
+ bundle install
6
+
7
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,109 @@
1
+ <!DOCTYPE html>
2
+
3
+ <html>
4
+ <head>
5
+ <meta charset="UTF-8">
6
+
7
+ <title>module BiblioRefs - RDoc Documentation</title>
8
+
9
+ <script type="text/javascript">
10
+ var rdoc_rel_prefix = "./";
11
+ </script>
12
+
13
+ <script src="./js/jquery.js"></script>
14
+ <script src="./js/darkfish.js"></script>
15
+
16
+ <link href="./css/fonts.css" rel="stylesheet">
17
+ <link href="./css/rdoc.css" rel="stylesheet">
18
+
19
+
20
+
21
+ <body id="top" role="document" class="module">
22
+ <nav role="navigation">
23
+ <div id="project-navigation">
24
+ <div id="home-section" role="region" title="Quick navigation" class="nav-section">
25
+ <h2>
26
+ <a href="./index.html" rel="home">Home</a>
27
+ </h2>
28
+
29
+ <div id="table-of-contents-navigation">
30
+ <a href="./table_of_contents.html#pages">Pages</a>
31
+ <a href="./table_of_contents.html#classes">Classes</a>
32
+ <a href="./table_of_contents.html#methods">Methods</a>
33
+ </div>
34
+ </div>
35
+
36
+ <div id="search-section" role="search" class="project-section initially-hidden">
37
+ <form action="#" method="get" accept-charset="utf-8">
38
+ <div id="search-field-wrapper">
39
+ <input id="search-field" role="combobox" aria-label="Search"
40
+ aria-autocomplete="list" aria-controls="search-results"
41
+ type="text" name="search" placeholder="Search" spellcheck="false"
42
+ title="Type to search, Up and Down to navigate, Enter to load">
43
+ </div>
44
+
45
+ <ul id="search-results" aria-label="Search Results"
46
+ aria-busy="false" aria-expanded="false"
47
+ aria-atomic="false" class="initially-hidden"></ul>
48
+ </form>
49
+ </div>
50
+
51
+ </div>
52
+
53
+
54
+
55
+ <div id="class-metadata">
56
+
57
+
58
+
59
+
60
+
61
+ </div>
62
+ </nav>
63
+
64
+ <main role="main" aria-labelledby="module-BiblioRefs">
65
+ <h1 id="module-BiblioRefs" class="module">
66
+ module BiblioRefs
67
+ </h1>
68
+
69
+ <section class="description">
70
+
71
+ </section>
72
+
73
+
74
+
75
+
76
+ <section id="5Buntitled-5D" class="documentation-section">
77
+
78
+
79
+
80
+
81
+
82
+ <section class="constants-list">
83
+ <header>
84
+ <h3>Constants</h3>
85
+ </header>
86
+ <dl>
87
+
88
+ <dt id="VERSION">VERSION
89
+
90
+ <dd>
91
+
92
+
93
+ </dl>
94
+ </section>
95
+
96
+
97
+
98
+
99
+
100
+ </section>
101
+ </main>
102
+
103
+
104
+ <footer id="validator-badges" role="contentinfo">
105
+ <p><a href="http://validator.w3.org/check/referer">Validate</a>
106
+ <p>Generated by <a href="http://docs.seattlerb.org/rdoc/">RDoc</a> 4.2.0.
107
+ <p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
108
+ </footer>
109
+
@@ -0,0 +1,339 @@
1
+ <!DOCTYPE html>
2
+
3
+ <html>
4
+ <head>
5
+ <meta charset="UTF-8">
6
+
7
+ <title>class BiblioRefs::Articulo - RDoc Documentation</title>
8
+
9
+ <script type="text/javascript">
10
+ var rdoc_rel_prefix = "../";
11
+ </script>
12
+
13
+ <script src="../js/jquery.js"></script>
14
+ <script src="../js/darkfish.js"></script>
15
+
16
+ <link href="../css/fonts.css" rel="stylesheet">
17
+ <link href="../css/rdoc.css" rel="stylesheet">
18
+
19
+
20
+
21
+ <body id="top" role="document" class="class">
22
+ <nav role="navigation">
23
+ <div id="project-navigation">
24
+ <div id="home-section" role="region" title="Quick navigation" class="nav-section">
25
+ <h2>
26
+ <a href="../index.html" rel="home">Home</a>
27
+ </h2>
28
+
29
+ <div id="table-of-contents-navigation">
30
+ <a href="../table_of_contents.html#pages">Pages</a>
31
+ <a href="../table_of_contents.html#classes">Classes</a>
32
+ <a href="../table_of_contents.html#methods">Methods</a>
33
+ </div>
34
+ </div>
35
+
36
+ <div id="search-section" role="search" class="project-section initially-hidden">
37
+ <form action="#" method="get" accept-charset="utf-8">
38
+ <div id="search-field-wrapper">
39
+ <input id="search-field" role="combobox" aria-label="Search"
40
+ aria-autocomplete="list" aria-controls="search-results"
41
+ type="text" name="search" placeholder="Search" spellcheck="false"
42
+ title="Type to search, Up and Down to navigate, Enter to load">
43
+ </div>
44
+
45
+ <ul id="search-results" aria-label="Search Results"
46
+ aria-busy="false" aria-expanded="false"
47
+ aria-atomic="false" class="initially-hidden"></ul>
48
+ </form>
49
+ </div>
50
+
51
+ </div>
52
+
53
+
54
+
55
+ <div id="class-metadata">
56
+
57
+ <div id="parent-class-section" class="nav-section">
58
+ <h3>Parent</h3>
59
+
60
+
61
+ <p class="link">Libro
62
+
63
+ </div>
64
+
65
+
66
+
67
+ <!-- Method Quickref -->
68
+ <div id="method-list-section" class="nav-section">
69
+ <h3>Methods</h3>
70
+
71
+ <ul class="link-list" role="directory">
72
+
73
+ <li class="calls-super" ><a href="#method-c-new">::new</a>
74
+
75
+ <li ><a href="#method-i-article">#article</a>
76
+
77
+ <li ><a href="#method-i-editores_to_s">#editores_to_s</a>
78
+
79
+ <li ><a href="#method-i-to_s">#to_s</a>
80
+
81
+ </ul>
82
+ </div>
83
+
84
+ </div>
85
+ </nav>
86
+
87
+ <main role="main" aria-labelledby="class-BiblioRefs::Articulo">
88
+ <h1 id="class-BiblioRefs::Articulo" class="class">
89
+ class BiblioRefs::Articulo
90
+ </h1>
91
+
92
+ <section class="description">
93
+
94
+ </section>
95
+
96
+
97
+
98
+
99
+ <section id="5Buntitled-5D" class="documentation-section">
100
+
101
+
102
+
103
+
104
+
105
+
106
+
107
+ <section class="attribute-method-details" class="method-section">
108
+ <header>
109
+ <h3>Attributes</h3>
110
+ </header>
111
+
112
+
113
+ <div id="attribute-i-editores" class="method-detail">
114
+ <div class="method-heading attribute-method-heading">
115
+ <span class="method-name">editores</span><span
116
+ class="attribute-access-type">[RW]</span>
117
+ </div>
118
+
119
+ <div class="method-description">
120
+
121
+
122
+
123
+ </div>
124
+ </div>
125
+
126
+ <div id="attribute-i-num_paginas" class="method-detail">
127
+ <div class="method-heading attribute-method-heading">
128
+ <span class="method-name">num_paginas</span><span
129
+ class="attribute-access-type">[RW]</span>
130
+ </div>
131
+
132
+ <div class="method-description">
133
+
134
+
135
+
136
+ </div>
137
+ </div>
138
+
139
+ <div id="attribute-i-titulo_obra" class="method-detail">
140
+ <div class="method-heading attribute-method-heading">
141
+ <span class="method-name">titulo_obra</span><span
142
+ class="attribute-access-type">[RW]</span>
143
+ </div>
144
+
145
+ <div class="method-description">
146
+
147
+
148
+
149
+ </div>
150
+ </div>
151
+
152
+ </section>
153
+
154
+
155
+
156
+ <section id="public-class-5Buntitled-5D-method-details" class="method-section">
157
+ <header>
158
+ <h3>Public Class Methods</h3>
159
+ </header>
160
+
161
+
162
+ <div id="method-c-new" class="method-detail ">
163
+
164
+ <div class="method-heading">
165
+ <span class="method-name">new</span><span
166
+ class="method-args">(autores, anyo_publicacion, titulo, editores, titulo_obra, num_paginas, num_edicion, volumen, editorial, isbn)</span>
167
+
168
+ <span class="method-click-advice">click to toggle source</span>
169
+
170
+ </div>
171
+
172
+
173
+ <div class="method-description">
174
+
175
+ <p>Constructor de la clase <a href="Articulo.html">Articulo</a></p>
176
+
177
+
178
+ <div class="method-calls-super">
179
+ Calls superclass method
180
+
181
+ </div>
182
+
183
+
184
+
185
+ <div class="method-source-code" id="new-source">
186
+ <pre><span class="ruby-comment"># File lib/biblio_refs/articulo.rb, line 7</span>
187
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">autores</span>, <span class="ruby-identifier">anyo_publicacion</span>, <span class="ruby-identifier">titulo</span>, <span class="ruby-identifier">editores</span>, <span class="ruby-identifier">titulo_obra</span>, <span class="ruby-identifier">num_paginas</span>, <span class="ruby-identifier">num_edicion</span>, <span class="ruby-identifier">volumen</span>, <span class="ruby-identifier">editorial</span>, <span class="ruby-identifier">isbn</span>)
188
+ <span class="ruby-keyword">super</span>(<span class="ruby-identifier">autores</span>, <span class="ruby-identifier">anyo_publicacion</span>, <span class="ruby-identifier">titulo</span>, <span class="ruby-keyword">nil</span>, <span class="ruby-identifier">num_edicion</span>, <span class="ruby-identifier">volumen</span>, <span class="ruby-identifier">editorial</span>, <span class="ruby-identifier">isbn</span>)
189
+ <span class="ruby-ivar">@titulo_obra</span> = <span class="ruby-identifier">titulo_obra</span>
190
+ <span class="ruby-ivar">@editores</span> = <span class="ruby-identifier">editores</span>
191
+ <span class="ruby-ivar">@num_paginas</span> = <span class="ruby-identifier">num_paginas</span>
192
+ <span class="ruby-ivar">@counter</span> = <span class="ruby-value">0</span>
193
+ <span class="ruby-keyword">end</span></pre>
194
+ </div>
195
+
196
+ </div>
197
+
198
+
199
+
200
+
201
+ </div>
202
+
203
+
204
+ </section>
205
+
206
+ <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
207
+ <header>
208
+ <h3>Public Instance Methods</h3>
209
+ </header>
210
+
211
+
212
+ <div id="method-i-article" class="method-detail ">
213
+
214
+ <div class="method-heading">
215
+ <span class="method-name">article</span><span
216
+ class="method-args">(articulo = {})</span>
217
+
218
+ <span class="method-click-advice">click to toggle source</span>
219
+
220
+ </div>
221
+
222
+
223
+ <div class="method-description">
224
+
225
+ <p>Método que asigna los valores partículares del objeto <a
226
+ href="Articulo.html">Articulo</a> creado mediante DSL</p>
227
+
228
+
229
+
230
+
231
+ <div class="method-source-code" id="article-source">
232
+ <pre><span class="ruby-comment"># File lib/biblio_refs/articulo.rb, line 16</span>
233
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">article</span>(<span class="ruby-identifier">articulo</span> = {})
234
+ <span class="ruby-ivar">@titulo_obra</span> = <span class="ruby-identifier">articulo</span>[<span class="ruby-value">:book</span>]
235
+ <span class="ruby-ivar">@editores</span> = <span class="ruby-identifier">articulo</span>[<span class="ruby-value">:editor</span>]
236
+ <span class="ruby-ivar">@num_paginas</span> = <span class="ruby-identifier">articulo</span>[<span class="ruby-value">:pages</span>]
237
+ <span class="ruby-ivar">@volumen</span> = <span class="ruby-identifier">articulo</span>[<span class="ruby-value">:volume</span>]
238
+ <span class="ruby-ivar">@fecha_publicacion</span> = <span class="ruby-constant">Date</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-string">&#39;1st January #{articulo[:year]}&#39;</span>)
239
+ <span class="ruby-keyword">end</span></pre>
240
+ </div>
241
+
242
+ </div>
243
+
244
+
245
+
246
+
247
+ </div>
248
+
249
+
250
+ <div id="method-i-editores_to_s" class="method-detail ">
251
+
252
+ <div class="method-heading">
253
+ <span class="method-name">editores_to_s</span><span
254
+ class="method-args">()</span>
255
+
256
+ <span class="method-click-advice">click to toggle source</span>
257
+
258
+ </div>
259
+
260
+
261
+ <div class="method-description">
262
+
263
+ <p>Método que devuelve una cadena de carácteres formateada de los editores</p>
264
+
265
+
266
+
267
+
268
+ <div class="method-source-code" id="editores_to_s-source">
269
+ <pre><span class="ruby-comment"># File lib/biblio_refs/articulo.rb, line 25</span>
270
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">editores_to_s</span>
271
+ <span class="ruby-identifier">final</span> = <span class="ruby-string">&quot;&quot;</span>
272
+ <span class="ruby-keyword">if</span> <span class="ruby-identifier">editores</span>.<span class="ruby-identifier">kind_of?</span>(<span class="ruby-constant">Array</span>)
273
+ <span class="ruby-identifier">editores</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">editor</span><span class="ruby-operator">|</span>
274
+ <span class="ruby-identifier">final</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">editor</span>
275
+ <span class="ruby-identifier">final</span> <span class="ruby-operator">+=</span> <span class="ruby-string">&quot; &amp; &quot;</span>
276
+ <span class="ruby-keyword">end</span>
277
+ <span class="ruby-identifier">final</span>[<span class="ruby-value">-3</span><span class="ruby-operator">...</span><span class="ruby-value">-1</span>] = <span class="ruby-string">&quot;&quot;</span>
278
+ <span class="ruby-keyword">else</span>
279
+ <span class="ruby-identifier">final</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">editores</span>
280
+ <span class="ruby-identifier">final</span> <span class="ruby-operator">+=</span> <span class="ruby-string">&quot; &quot;</span>
281
+ <span class="ruby-keyword">end</span>
282
+ <span class="ruby-identifier">final</span>.<span class="ruby-identifier">chop</span>
283
+ <span class="ruby-keyword">end</span></pre>
284
+ </div>
285
+
286
+ </div>
287
+
288
+
289
+
290
+
291
+ </div>
292
+
293
+
294
+ <div id="method-i-to_s" class="method-detail ">
295
+
296
+ <div class="method-heading">
297
+ <span class="method-name">to_s</span><span
298
+ class="method-args">()</span>
299
+
300
+ <span class="method-click-advice">click to toggle source</span>
301
+
302
+ </div>
303
+
304
+
305
+ <div class="method-description">
306
+
307
+ <p>Método que devuelve una cadena de carácteres formateada de los objetos de
308
+ la clase <a href="Articulo.html">Articulo</a></p>
309
+
310
+
311
+
312
+
313
+ <div class="method-source-code" id="to_s-source">
314
+ <pre><span class="ruby-comment"># File lib/biblio_refs/articulo.rb, line 41</span>
315
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">to_s</span>
316
+ <span class="ruby-identifier">formato_apa</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot; En &quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">editores_to_s</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot;, &quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">titulo_obra</span>.<span class="ruby-identifier">to_s</span>.<span class="ruby-identifier">capitalize</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot; (&quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">num_paginas</span>.<span class="ruby-identifier">to_s</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot;)(&quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">num_edicion_to_s</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot;)(&quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">volumen</span>.<span class="ruby-identifier">to_s</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot;). Lugar de publicación: &quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">editorial_to_s</span>.<span class="ruby-identifier">capitalize</span>
317
+ <span class="ruby-keyword">end</span></pre>
318
+ </div>
319
+
320
+ </div>
321
+
322
+
323
+
324
+
325
+ </div>
326
+
327
+
328
+ </section>
329
+
330
+ </section>
331
+ </main>
332
+
333
+
334
+ <footer id="validator-badges" role="contentinfo">
335
+ <p><a href="http://validator.w3.org/check/referer">Validate</a>
336
+ <p>Generated by <a href="http://docs.seattlerb.org/rdoc/">RDoc</a> 4.2.0.
337
+ <p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
338
+ </footer>
339
+